I have a Java executable file, swagger-codegen-cli.jar
, that I'd like to be able to execute globally from the console like I would with an .exe
in my environment PATH.
Currently if I want to execute it, I have to type java -jar C:\Users\Jacob\swagger-codegen-cli.jar
.
How can I "alias" (what's the proper term?) this command globally as something succinct, like swagger-codegen
? So something like this:
java -jar C:\Users\Jacob\swagger-codegen-cli.jar generate -i http://localhost/swagger/docs/v1
becomes this:
swagger-codegen generate -i http://localhost/swagger/docs/v1