# Hugo Pipes not picking up local npx installation

**URL:** https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586
**Category:** support
**Created:** [August 2, 2023, 4:32pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586 "2023-08-02T16:32:24Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![jaypipes](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jaypipes/32/20032_2.png) [@jaypipes](https://discourse.gohugo.io/u/jaypipes)
#### Post date: [August 2, 2023, 4:32pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/1 "2023-08-02T16:32:25Z")

</div>

I’ve purchased a theme from gethugothemes and am attempting to follow the instructions here:

> **[Theme Installation](https://docs.gethugothemes.com/docbox/installation/)**
>
> Documentation for the installation and configuration of our themes.

I have unzipped the theme into my hugo project’s themes/ directory, set the theme in the `hugo.toml` file and copied the theme’s `exampleSite` files into my project root. I then call `hugo server`.

Unfortunately, this fails with an error:

```auto
Error: error building site: POSTCSS: failed to transform "css/style.css" (text/css). Check your PostCSS installation; install with "npm install postcss-cli". See https://gohugo.io/hugo-pipes/postcss/: binary with name "npx" not found

```

However, I _do_ have `npx` installed:

```auto
$ which npx
/home/jaypipes/.nvm/versions/node/v19.4.0/bin/npx

```

```auto
$ hugo env
hugo v0.115.4-dc9524521270f81d1c038ebbb200f0cfa3427cc5+extended linux/amd64 BuildDate=2023-07-20T06:49:57Z VendorInfo=snap:0.115.4
GOOS="linux"
GOARCH="amd64"
GOVERSION="go1.19.11"
github.com/sass/libsass="3.6.5"
github.com/webmproject/libwebp="v1.2.4"
github.com/sass/dart-sass/protocol="2.1.0"
github.com/sass/dart-sass/compiler="1.64.0"
github.com/sass/dart-sass/implementation="1.64.0"

```

I have made zero other changes and have followed the instructions on the above linked documentation page exactly.

---

<div class="post-metadata">

### Author: ![nternetinspired](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/nternetinspired/32/19706_2.png) [@nternetinspired](https://discourse.gohugo.io/u/nternetinspired)
#### Post date: [August 2, 2023, 5:15pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/2 "2023-08-02T17:15:48Z")

</div>

You need to ask the theme author then…

---

<div class="post-metadata">

### Author: ![jaypipes](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jaypipes/32/20032_2.png) [@jaypipes](https://discourse.gohugo.io/u/jaypipes)
#### Post date: [August 2, 2023, 5:23pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/3 "2023-08-02T17:23:03Z")

</div>

I have sent them an email about this already, yes.

However, I don’t believe it has to do with the theme. I think this is a Hugo Pipes issue as outlined in [Hugo Pipes not picking up local npx installation](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586)

---

<div class="post-metadata">

### Author: ![jmooring](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jmooring/32/4214_2.png) [@jmooring](https://discourse.gohugo.io/u/jmooring)
#### Post date: [August 2, 2023, 5:25pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/4 "2023-08-02T17:25:05Z")

</div>

From [my comment](https://github.com/gohugoio/hugo/issues/9730#issuecomment-1662528938) on the closed GitHub issue:

> Please create a topic on the forum, and be prepared to share your project repository, privately if you wish.

---

<div class="post-metadata">

### Author: ![jaypipes](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jaypipes/32/20032_2.png) [@jaypipes](https://discourse.gohugo.io/u/jaypipes)
#### Post date: [August 2, 2023, 5:35pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/5 "2023-08-02T17:35:11Z")

</div>

Maybe I’m not understanding something, Joe, but isn’t that exactly what I have done here? I created a topic…

---

<div class="post-metadata">

### Author: ![jmooring](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jmooring/32/4214_2.png) [@jmooring](https://discourse.gohugo.io/u/jmooring)
#### Post date: [August 2, 2023, 5:35pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/6 "2023-08-02T17:35:45Z")

</div>

We’re missing this bit…

> [@jmooring](#):
>
> and be prepared to share your project repository, privately if you wish

---

<div class="post-metadata">

### Author: ![jaypipes](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jaypipes/32/20032_2.png) [@jaypipes](https://discourse.gohugo.io/u/jaypipes)
#### Post date: [August 2, 2023, 5:48pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/7 "2023-08-02T17:48:19Z")

</div>

I cannot share the repository because this is a theme I downloaded (for $$$) and they disallow publicly sharing.

I was able to make progress by copying the `package.json` file from the theme into my top-level project root and running `npm install` then `npm dev run`.

For people who are not web developers and steeped in the (excruciatingly overcomplicated) world of all the Javascript tooling and endless libraries and frameworks, it’s very difficult to use Hugo with any of these themes that rely on the node.js toolset…

It’s like you need a PhD in CSS and Javascript just to get the most basic things to work…

---

<div class="post-metadata">

### Author: ![jmooring](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jmooring/32/4214_2.png) [@jmooring](https://discourse.gohugo.io/u/jmooring)
#### Post date: [October 5, 2023, 11:52pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/8 "2023-10-05T23:52:03Z")

</div>

A post was split to a new topic: [PostCSS problem with Cloudflare Pages](https://discourse.gohugo.io/t/postcss-problem-with-cloudflare-pages/46548)

---

<div class="post-metadata">

### Author: ![dpuig](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/dpuig/32/21795_2.png) [@dpuig](https://discourse.gohugo.io/u/dpuig)
#### Post date: [April 7, 2024, 4:24pm UTC](https://discourse.gohugo.io/t/hugo-pipes-not-picking-up-local-npx-installation/45586/9 "2024-04-07T16:24:33Z")

</div>

Try updating NodeJS dependencies step:  
- name: Install Node.js dependencies  
run: |  
[[-f package-lock.json || -f npm-shrinkwrap.json]] && npm ci || true  
sudo npm install -g postcss-cli  
sudo npm install -g npx --force  
npm install tailwindcss@latest
