-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
npm publish fails (g++: error: unrecognized command line option ‘-std=gnu++20’; did you mean ‘-std=gnu++2a’?) #16
Comments
🤔 can't reproduce, I just published the regex grammar here https://github.com/tree-sitter/tree-sitter-regex/actions/runs/11413533364, which has the same workflow setup in the C/TS repos Only thing I noticed in your run was that it fetched node v23, whereas regex used 22 |
@amaanq Thanks, that turned out to be the problem. Do you know what determines which version of node is used? I synced / downgraded dependencies to match tree-sitter-regex and now it also picks 22 and works for me. I expect others will face the same problem, it seems like it's pretty easy to reproduce if you upgrade dependencies in tree-sitter-regex:
|
Problem
I see there's been some changes recently relating to GH Actions CI and publishing. Do you have a working example of how to publish a tree-sitter grammar on npm?
Here is my grammar:
https://github.com/olehermanse/tree-sitter-cfengine
Publishing releases on GH, pypi, and crates.io is currently working using GH Actions. I've been trying to copy what is done in tree-sitter-c and tree-sitter-typescript, however I can see that those repos have had CI related changes in the last few days, but no releases since January, so I guess they are not currently working?
Specifically, the error I encounter in GH Actions is:
Steps to reproduce
N/A
Expected behavior
Publishing packages to npm works using the same GH Actions as the official tree-stter grammars.
Tree-sitter version (tree-sitter --version)
tree-sitter 0.24.3
Operating system/version
Ubuntu / macOS / windows
The text was updated successfully, but these errors were encountered: