Я попробовал создать test.jsh:
Код: Выделить всё
#!/usr/bin/env jshell -s
System.out.println("Hello World")
/exit
Код: Выделить всё
⚡ ./test.jsh
| Error:
| illegal character: '#'
| #!/usr/bin/env jshell -s
| ^
| Error:
| illegal start of expression
| #!/usr/bin/env jshell -s
| ^
Hello World
Есть ли другой способ сделать это?
Подробнее здесь: https://stackoverflow.com/questions/449 ... ith-jshell
Мобильная версия