Same issue here. I’m on Intel, Big Sur, node 16.9.1. I believe I also installed node via homebrew.
/usr/local/lib/node_modules (the equivalent path to yours on Intel) is owned by my username and group admin, and has mode 755. When I inspect that directory, there is no
@airtable subdirectory. I may also be using the asdf version manager, but I don’t remember exactly how I configured it and this issue seems widely-reported enough that I don’t think I need to care.
What I ended up doing to workaround the issue is invoke the command directly with npx:
$ npx @airtable/blocks-cli init appblahblahblah/blkblahblahblah --template=https://github.com/example project_name – basically replacing
block init in the guide with
npx @airtable/blocks-cli init.
After the new project is created and you’ve
cd'd to it, you can then install the package locally as a dev dependency with
npm install -D @airtable/blocks-cli. (Frankly, my opinion is that
npm -g is an antipattern, so I don’t mind this.)
Then, from within the project directory, you can prefix any
block command with
npx to have NPM run the command directly from the installed dev dependency. So instead of
block run, you just do
npx block run.
Note that we couldn’t do
npx block init in the first step because npx has no idea what
block means until we install the package to the project – so instead we bootstrap by using the full name of
Hope this helps. Also hope Airtable fixes their broken package.