How to execute script from JAR file?

前端 未结 3 1132
醉酒成梦
醉酒成梦 2020-12-19 17:55

I have a maven project, in which, I am trying to execute a script (written in R). I put this script file in the source code directory as well. I found this script is not exe

3条回答
  •  一向
    一向 (楼主)
    2020-12-19 18:19

    You will need to extract the script from the jar file:

    jar -xvf my.jar com/foo/my.script.sh
    

提交回复
热议问题