Skip to content
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

🛠 Tooling: Run node lib/index.js --version instead of node lib/index.js #1353

Open
3 tasks done
danvk opened this issue Feb 28, 2024 · 2 comments
Open
3 tasks done
Labels
area: tooling Managing the repository's maintenance status: accepting prs Please, send a pull request to resolve this!

Comments

@danvk
Copy link
Contributor

danvk commented Feb 28, 2024

Bug Report Checklist

  • I have tried restarting my IDE and the issue persists.
  • I have pulled the latest main branch of the repository.
  • I have searched for related issues and found none that matched my issue.

Overview

The build.yml workflow tries to run node lib/index.js. But there's no reason to expect that invoking a command with no arguments is valid.

Running something like

node lib/index.js --version

might be safer. Of course, that assumes the program accepts command line arguments!

Additional Info

https://github.com/danvk/literate-ts/actions/runs/8072807240/job/22055278339?pr=246

@danvk danvk added the area: tooling Managing the repository's maintenance label Feb 28, 2024
@JoshuaKGoldberg JoshuaKGoldberg added the status: in discussion Not yet ready for implementation or a pull request label Mar 5, 2024
@JoshuaKGoldberg
Copy link
Owner

Hmm, yeah, super interesting. It's not 100% that every command would have a no-args-required --version... but at the very least, maybe it'd be reasonable as an override for this repository?

@JoshuaKGoldberg
Copy link
Owner

I think it'd be a good idea to add this in as an override for create-typescript-app. Specifically, that'd look like:

  • .github/workflows/ci.yml's build task would have - run: node ./bin/index.js --version
  • script/__snapshots__/migrate-test-e2e.ts.snap would have an added bit of diff to mention that

@JoshuaKGoldberg JoshuaKGoldberg added status: accepting prs Please, send a pull request to resolve this! and removed status: in discussion Not yet ready for implementation or a pull request labels Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: tooling Managing the repository's maintenance status: accepting prs Please, send a pull request to resolve this!
Projects
None yet
Development

No branches or pull requests

2 participants