jbangdev / jbang

Unleash the power of Java - JBang Lets Students, Educators and Professional Developers create, edit and run self-contained source-only Java programs with unprecedented ease.
https://jbang.dev
MIT License
1.43k stars 159 forks source link

let catalogs resolve against hosts not just git based content #463

Open maxandersen opened 4 years ago

maxandersen commented 4 years ago

today aliases/catalogs looksup using <alias>@<org/username>[/<repo>] against github, gitlab, etc. to locate a jbang-catalog.

wondering if we should make it that if the <org/username> part has a dot (.) in it should treat it as a plain up hostname to resolve against.

i.e. run@golo-lang.org would look for https://golo-lang.org/jbang-catalog.json since its not a valid org/username.

maxandersen commented 3 years ago

@quintesse wdyt ? feels like should be fairly trivial ?

quintesse commented 3 years ago

Sure, although it seems to me it should be possible to specify a path as well. I think there won't be that many options where you have access to the root of a domain except in those cases where the domain is yours (and even then you might not want to use the root path).