Skip to content

Tags: soul2zimate/jbang

Tags

v0.56.0

Toggle v0.56.0's commit message
<a name="0.56.0"></a>

Big `jbang app` feature + bugfixes.

There is now a `jbang app` which install jbang applications/scripts locally.

You use it by first calling the one time setup (`jbang app setup`) to configure your local environment
to have a `PATH` that `jbang` can install "apps" into.

Now you can do things like `jbang app install properties@jbangdev` to get a `properties` into your `PATH` so you can
call it from anywhere as if it was any other application or script.

`jbang app install` works with scripts, jars, urls, aliases etc.

Really excited to this come to fruition - send feedback/open issues for this - do you like it or hate it ?

`jbang edit` now honor jitpack and `//REPOS` so now dependency resolution
will work in your IDE when you use these.

This is a small tweak to the parsing so if you have a comment at the end of line of a `//DEPS` or similar command then `jbang` will ignore it.

That is useful for when using asciidoc reference in comments feature, which gives you this:

```
//DEPS info.picocli:picocli:4.5.0 // <.>
//DEPS org.zeroturnaround:zt-exec:1.12 // <.>
//DEPS commons-codec:commons-codec:1.15 // <.>
//DEPS org.slf4j:slf4j-nop:1.7.30 // <.>
```

In previous versions jbang would try and resolve `//` and `<.>` as dependencies. Now it will ignore '` // `' (notice the surrounding spaces) and anything following it.

New repositories on GitHub defaults to `main` breaking the jitpack integration.
Now instead of using `master` as default we use `HEAD` which gives you the
tip of the default branch independent of its actual name.

* Don't attempt to minimse jboss-logging (jbangdev#562) (#8fc92b68)
* PowerShell zero-install now works again (jbangdev#572) (#f61aa98c)
* `app install` with relative file paths now works (#2767b22b)
* handle the fact that on Windows paths can be on different roots (#777d7870)
* watchService's event is relative to watched directory (#7395c4fb)
* use dependency cache when launching GAV. (jbangdev#586) (#44a88580, closes jbangdev#222)
* support urls with extension less files Fixes jbangdev#568 (jbangdev#585) (#fbdec5c2, closes jbangdev#568)
* jitpack no long assumes default branch is master (jbangdev#588) (#654667ca, closes jbangdev#564)

* minimal jitpack and //REPOS support in edit/live mode (jbangdev#570) (#f134fb5c)
* added `install` command that turns scripts as user commands (#5406bae8)
* implemented `app unistall` and `app list` (#63973382)
* // commands ignore // comments  (jbangdev#584) (#732cc69b, closes jbangdev#567)

* split jbang installation off from `setup` to `install`
* Introduce `app` command and turn `install` into a subcommand
* Made `setup` a subcommand of `app`
* `app install` name is now an option

v0.55.2

Toggle v0.55.2's commit message
<a name="0.55.2"></a>

Bug fixes - mainly jbangdev#562 to avoid breaking Quarkus build integration.

* running tests won't affect user's environment anymore (jbangdev#553) (#fdcd0ff1)
* attempt of a more explicit edit message (jbangdev#555) (#f15cd878, closes jbangdev#551)
* Don't attempt to minimse jboss-logging (jbangdev#562) (#15c89b87)

v0.55.1

Toggle v0.55.1's commit message
<a name="0.55.1"></a>

Bug fixes to setup so curl install actually works without having jbang already installed
and simplified Windows script as turns out we don't need to worry about locked jar files.

* installation of Jbang from startup scripts now works again (#ea40fc14)
* jbang setup should gracefully fail on mising bash/zshrc (#5395fa1a)

* simplified setup of Jbang

v0.55.0

Toggle v0.55.0's commit message
<a name="0.55.0"></a>

jbang can now setup and install itself using `jbang setup`.

This will setup `~/.jbang/bin` in your `PATH`.

Might not look at much but this enables you to do:

`curl -Ls https://sh.jbang.dev | bash -s - setup`

And after this you have `jbang` installed in your path.

Similar is available for Windows powershell.

* Fixed more instances of relative file handling (jbangdev#543) (#361a9f62)

* jbang setup (jbangdev#540) [minor] (#fad20f0b)

v0.54.1

Toggle v0.54.1's commit message
<a name="0.54.1"></a>

A quick bug fix so `//FILES myresource.png` when called via aliases and swizzled urls resolves properly.

* Fixed relative path handling in FileRef and URLRef (jbangdev#538) [patch] (#822a1a47)

v0.54.0

Toggle v0.54.0's commit message
<a name="0.54.0"></a>

Mainly a bunch of minor bug fixes and improvements, highlights being:

There are now a `--fresh` flag to use to indicate to jbang to use fresh data, not cached data.
Allow you to force a build for a specific run without having to clear the full cache.

Temporary Gradle now includes `application` definition making IDE's like intellij able to provide run/debug out of the box.

Fixed command line handling on Windows so now long classpaths will not fail, but instead use @-file support of java to run with
commands with more than 8192 characters.

JavaFX Windows dependency resolution was broken and should now be fixed!

More details below...

* force update. Add -f --fresh flag (jbangdev#495) (#49ae10ef)
* added snap publishing on tag (#2ba737ee)

* use shell comment in direct run example (jbangdev#500) (#b5d22bdd)
* remove brew explicit dependency on java being installed (#dd66cf7c)
* build.gradle having full classname  (#6bc5a0e1, closes jbangdev#18)
* Default JDK wasn't properly set on Windows (jbangdev#525) (#6804ecc8)
* jfxname magic property fixed on windows Fixes jbangdev#526 (jbangdev#527) (#03e315cf, closes jbangdev#526)
* long classpath problem on Windows (jbangdev#524) (#6310bbd4)
* do not pickup commented out @grab  (#d943577f, closes jbangdev#434)
* **jbangdev#18:** enable gradle run, fix 'build.gradle' formatting (redundant tabs) (#d26e6382)
* **jbangdev#519:** Fix disabled ::add-path:: command in ci-build (jbangdev#520) (#c0fb96d8)

* `build()` now cleans up after itself (jbangdev#499)

v0.53.2

Toggle v0.53.2's commit message
Quick fix to have `jbang <url-to-jar>` working.

This lets you run [joinery](https://bintray.com/cardillo/maven/joinery/1.9) which does not publish a proper jar in a maven repository, but does have a .jar posted at an url.

Thus todays bugfix lets you do:

```shell
jbang https://bintray.com/cardillo/maven/download_file?file_path=joinery%2Fjoinery-dataframe%2F1.9%2Fjoinery-dataframe-1.9-jar-with-dependencies.jar shell
> df = new DataFrame()
[empty data frame]
> df.add("value")
[empty data frame]
> [10, 20, 30].forEach(function(val) { df.append([val]) })
> df
  	value
 0	   10
 1	   20
 2	   30
 ```

* run jar from a https url (#890787f8, closes jbangdev#490)

v0.53.1

Toggle v0.53.1's commit message
<a name="0.53.1"></a>

Bug fixes, with one notable change/fix that `jbang catalog` and `jbang alias` commands support
catalogs located in any default branch whether named `master`, `main` or something else. It will now
look for `HEAD` which points to the latest commit on the default branch.

* aliases no longer look for master, asks for HEAD instead  (#0a93f0c1, closes jbangdev#485)
* original source must be what's in ScriptResource.originalSource (jbangdev#488) (#3885a0a8)
* it must allow same //SOURCES in different paths (jbangdev#489) (#6337d26f)

v0.53.0

Toggle v0.53.0's commit message
<a name="0.53.0"></a>

Lots of fixes, but also some nice features!

`//SOURCES` will now  recursively include `//SOURCES` and `//DEPS` allowing for better reuse/componentization for
multi source scripts/apps.

Yes, multiple source is supported in JBang - it actually been for a while as javac will
automatically include reference classes available relative to a file.

When we realized that worked we enabled `jbang edit` to work with multiple files including
proper package handling and now `//SOURCES` support file patterns, i.e. `//SOURCES model/**/*.java`
to include all java files found under `model`.

Furthermore you can now even use URL's in `//SOURCES`, like `//SOURCES https://gist.github.com/tivrfoa/bb5deb269de39eb8fca9636dd3c9f123#file-gsonhelper-java`.

And that last example shows the last major feature you can now refer to individual files via a anchor in a gist url.

Big parts of these were contributed by [@tivrfor](https://github.com/tivrfoa) as his first contributions! Thank you.

* search //SOURCES and //DEPS in multiple files (#169e67c4)

* support nested multiple sources and gist with specific filenames (#924e2963)
* better check for String contains main method (jbangdev#468) (#87ff6813)
* update base path when resolving //SOURCES (jbangdev#477) (#2c372185)
* jbang cache clear --deps  (#be3c2b37, closes jbangdev#475)
* fail if class name for  is not valid java  (#ecc1b19d, closes jbangdev#460)
* **jbangdev#274:** brew install now should work out of the box since no longer keg_only (#e5f85afc)

v0.52.1

Toggle v0.52.1's commit message
<a name="0.53.0"></a>

A few bug fixes and "feature" making it so jbang can now run/install java vm's on Raspberry Pi 3 and possibly earlier versions.

* **jbangdev#459:** aliased GAV now resolving correctly (#8e74b5ae)
* allow MSYS2 to pass OS check in jbang script (#66dccf4a)

* Added support downloading JDK if not found on Raspberry Pi (jbangdev#457) (#72959205)