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

Add jbangcatalog and make qrcode more resilient #246

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

maxandersen
Copy link

Why:

  • its tedious to write: jbang https://github.com/quarkusio/quarkus-workshops/blob/main/quarkus-workshop-super-heroes/docs/src/resource-generation/qrcode.java https://shattereddisk.github.io/rickroll/ mycode.png
  • would much rather just do: jbang qrcode@quarkusio/quarkus-workshops https://shattereddisk.github.io/rickroll and have the filename be optional. or simply jbang qrcode https://shattereddisk.github.io/rickroll mycode.png anywhere within the repo.

This change addreses the need by:

  • add jbang-catalog.json to the repo made using jbang alias add -f . quarkus-workshop-super-heroes/docs/src/resource-generation/qrcode.java
  • made qrcode.java default the file name to avoid having to specify it and to avoid exception thrown.

Why:

 * its tedious to write:
    `jbang https://github.com/quarkusio/quarkus-workshops/blob/main/quarkus-workshop-super-heroes/docs/src/resource-generation/qrcode.java https://shattereddisk.github.io/rickroll/ mycode.png`
* would much rather just do:
    `jbang qrcode@quarkusio/quarkus-workshops https://shattereddisk.github.io/rickroll` and have the filename be optional.
    or simply
    `jbang qrcode https://shattereddisk.github.io/rickroll mycode.png` anywhere within the repo.

This change addreses the need by:

 * add `jbang-catalog.json` to the repo
    made using `jbang alias add -f . quarkus-workshop-super-heroes/docs/src/resource-generation/qrcode.java`
* made `qrcode.java` default the file name to avoid having to specify it and to avoid exception thrown.
@holly-cummins
Copy link
Collaborator

I like the change to qrcode.java, but I'm slightly unsure about putting jbang catalog content into the top level of the repo, since the repo's main purpose is as a sample application to teach Quarkus. The QR code generation is only used as part of the CI, here, and we probably want to keep it isolated from the user-visible parts of the repo.

I wonder, if we think there's likely to be re-use of the script, if it should be re-homed and catalog-ed somewhere else.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants