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

Validate markdown before source build #4307

Closed
wants to merge 1 commit into from
Closed

Conversation

handrews
Copy link
Member

idk about y'all but the chances of me remembering to run two commands instead of one is a lot smaller than the chances of me remembering to do one.

Let's have the src (but not production!) build run markdown validation as a pre-check. Any reason not to?

@handrews handrews added the script Pull requests that update Bash or JavaScript code label Jan 16, 2025
@handrews handrews requested review from a team as code owners January 16, 2025 22:41
@@ -4,6 +4,8 @@

# run this script from the root of the repo

npm run validate-markdown || exit -1
Copy link
Contributor

@ralfhandl ralfhandl Jan 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think of npm scripts as a layer on top of bash or JS scripts and would rather extend the build-src script in package.json to

"build-src": "npm run validate && bash bash ./scripts/md2html/build-src.sh",

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@handrews that works for me, although I think you only want one bash... or is there also supposed to be a bash before npm run validate? Either way I'll take this down and either you or I can post a PR with this approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
script Pull requests that update Bash or JavaScript code
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants