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

Create dev build infrastructure #4223

Open
5 tasks
handrews opened this issue Nov 22, 2024 · 3 comments · May be fixed by #4254
Open
5 tasks

Create dev build infrastructure #4223

handrews opened this issue Nov 22, 2024 · 3 comments · May be fixed by #4254
Assignees
Labels
script Pull requests that update Bash or JavaScript code

Comments

@handrews
Copy link
Member

handrews commented Nov 22, 2024

I had a check fail on #4188 on v3.2-dev and realized that there's no way to build without copying things over to the publish location (and even then something went weird when it was trying to build the old versions b/c the dev branches aren't set up for that).

We should be able to build just src/oas.md for testing purposes on dev and all branches derived from dev.

This change should go into dev and be merged/cherry-picked out from there.

If Arazzo and Overlay are going to use the same system, this might also be a good time to start building a shared system instead of continuing to patch things in triplicate.

  • Build src/oas.md
  • Build schemas from src
  • Test schemas in src upon push
  • Validate & lint src/oas.md upon push
  • Format src/oas.md
@handrews handrews added the script Pull requests that update Bash or JavaScript code label Nov 22, 2024
@ralfhandl
Copy link
Contributor

@handrews How luxurious do you want it to be?

The simplest solution would be to add a script npm run build-src that creates a static oas.html next to the oas.md (or anywhere you like) and add that file to .gitignore.

A nicer experience would be to start a tiny express server via npm run serve-src that dynamically produces an ephemeral oas.html on every change of oas.md and tells the browser to auto-refresh. That way you could have a browser window next to your editor window, type in one and live-check the other.

I have copy templates for both approaches lying around 😎

@handrews
Copy link
Member Author

@ralfhandl I'm perfectly happy with the simple version (and would be more likely to use it TBH because all of my dev tools tend to be the lowest-tech that works for me). But if you want to do the more complicated thing I'm not going to stop you.

Although... express seems like a bit dependency to add, and I'd kind-of like to be able to just build and look at the HTML without running a server. I guess just make sure I don't have to understand express at all to use the build system.

@ralfhandl ralfhandl linked a pull request Dec 16, 2024 that will close this issue
5 tasks
@ralfhandl ralfhandl linked a pull request Dec 16, 2024 that will close this issue
5 tasks
@ralfhandl
Copy link
Contributor

ralfhandl commented Dec 16, 2024

I'm perfectly happy with the simple version

@handrews Please check

@ralfhandl ralfhandl moved this to In Progress in Automation & Infrastructure Dec 19, 2024
@ralfhandl ralfhandl self-assigned this Dec 19, 2024
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: In Progress
Development

Successfully merging a pull request may close this issue.

2 participants