The Scripting Dilemma If you're like me, as a Java developer, you struggle to remember bash or python syntax for quick scripts. You end up "vibe coding" it, then struggle again when you need to adapt it. If only you could write it in Java! You might say "Java is not for scripting" and "I…...
#CLIscript #Java #Javascripting #JBang #PicoCLI #script
https://foojay.io/today/java-for-scripting/
How to Use Java as a Scripting Language

Discover how Java has evolved into a powerful scripting language, eliminating boilerplate and enabling instant execution for automation tasks

foojay
Pretty command line apps with added JBang. See ConsoleUI and AsciiTable in action #java #jbang #picocli https://robintegg.com/2025/04/01/pretty-command-line-apps-with-added-jbang.html
JavaでCLIツールを作る - Qiita

はじめにプロジェクトで簡単にCLIツールを作って業務を改善したいケースがありました。プロジェクトメンバーの得意言語がJavaであるため、メンテナンスのことも考えJavaでCLIツールを作る方法を調…

Qiita

@dpecos if you opt for the jvm approach, take a look at #picocli

https://picocli.info

picocli - a mighty tiny command line interface

#picocli: I used an `IExecutionStrategy` to require a positional parameter only for some commands

https://github.com/michael-simons/garmin-babel/blob/main/app/src/main/java/ac/simons/garmin/Application.java#L203-L211

I was looking at `@ArgGroup` first, but that would not have had helped me here, teaching the simple program to download all registered devices from #Garmin, without a #GDPR archive

Btw, is Remko Popma here? Can't find him…

#Java #Fun

garmin-babel/app/src/main/java/ac/simons/garmin/Application.java at main · michael-simons/garmin-babel

Tooling for the archive created by Garmin datamanagement. - michael-simons/garmin-babel

GitHub

On Foojay , @bazlur_rahman shows you how to create a script with #JBang and #PicoCLI to generate release notes. Check it out, complete steps and #Java code snippets included.

https://foojay.io/today/creating-a-command-line-tool-with-jbang-and-picocli-to-generate-release-notes

#foojaytip

Creating a Command Line Tool with JBang and PicoCLI to Generate Release Notes

Learn how to create a Java command-line tool with JBang and PicoCLI to automate generating release notes from GitHub.

foojay

@cwensel we recently used #picocli and I can't recommend it enough!

https://picocli.info/

Started working on this new cli app using #picocli. It seems easier to work with than #ApacheCommonsCLI. Will share more about my cli app once I make enough progress!

For example: I wanna write a easy-to-write & read #commandline / #cli option-parser for #cpp where you dont need to know how exactly #getopt works and what global variables & states it has.

One of the best other libraries out there for such stuff is #picocli ( https://picocli.info/ ). So naturally I wanna build something similar in #cpp .

But theres soooo many problems: bc c++ dosnt has real generics, only templates, there is ofc no typeerasure, meaning that I constantly need to pass around all template params. Wich means that theres no easy way having a type `Option<Cmd>` (options for a specific command), inside a list like `std::vector`! Even tho the storage space of a pointer is the same: 8 bytes, and thanks to virtual methods calling the right methods isnt a problem either!

🛠️ Unleash precision and performance! The New Grails Forge (https://github.com/grails/grails-forge) is powered by Picocli and Rocker Template Engine, delivering an outstanding command-line experience. #GrailsCLI #GrailsForge #Grails6 #GrailsFramework #ApacheGroovy #Picocli #RockerTemplate
GitHub - grails/grails-forge: This project represents a Micronaut-based Grails project creator. Grails projects may be created using the browser interface, Command Line, or via CURL.

This project represents a Micronaut-based Grails project creator. Grails projects may be created using the browser interface, Command Line, or via CURL. - GitHub - grails/grails-forge: This project...

GitHub