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

Is it possible to provide arguments (args) to a script? #13

Closed
TobseF opened this issue Apr 3, 2018 · 4 comments
Closed

Is it possible to provide arguments (args) to a script? #13

TobseF opened this issue Apr 3, 2018 · 4 comments

Comments

@TobseF
Copy link

TobseF commented Apr 3, 2018

Can I provide arguments which blaze passes to the script? So it would be possible to write:

fun main(args: Array<String>) {
    print(args)
}

and call java -jar blaze.jar -args mySuperArgument ?

I saw the blaze.conf property option. But in this way I have to add a blaze dependency / import to my script, which I want to avoid. And it's not flexible enough like arguments.

Or is the java -Dname=value the only possibility to pass an argument to a script? Which is not typical if i run the script without blaze, or want to test it with JUnit.

@jjlauer
Copy link
Member

jjlauer commented Apr 3, 2018 via email

@TobseF
Copy link
Author

TobseF commented Apr 3, 2018

Thanks for the fast reply. Your idea with the config strategy sounds reasonable, and of course works pretty well in my case. To make it easier to migrate existing scripts something like a -a|--args options could help.

@jjlauer
Copy link
Member

jjlauer commented Apr 3, 2018 via email

@jjlauer
Copy link
Member

jjlauer commented Oct 26, 2023

Cleaning up old issues. This was addressed in recent blaze versions where "--argument" is now supported.

@jjlauer jjlauer closed this as completed Oct 26, 2023
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

No branches or pull requests

2 participants