mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 08:27:12 -07:00
Always generate the shebang line
This commit is contained in:
parent
3ced5ffd10
commit
61f1c7c626
1 changed files with 5 additions and 7 deletions
|
@ -268,8 +268,7 @@ public class Main {
|
||||||
|
|
||||||
private void generateKobaltW(Path filePath) throws IOException {
|
private void generateKobaltW(Path filePath) throws IOException {
|
||||||
//
|
//
|
||||||
// For kobaltw: try to generate it with the correct env shebang. If this fails,
|
// For kobaltw: try to generate it with the correct env shebang.
|
||||||
// we'll generate it without the env shebang
|
|
||||||
//
|
//
|
||||||
File envFile = new File("/bin/env");
|
File envFile = new File("/bin/env");
|
||||||
if (!envFile.exists()) {
|
if (!envFile.exists()) {
|
||||||
|
@ -278,10 +277,9 @@ public class Main {
|
||||||
|
|
||||||
String content = "";
|
String content = "";
|
||||||
|
|
||||||
if (envFile.exists()) {
|
|
||||||
content = "#!" + envFile.getAbsolutePath() + " bash\n";
|
content = "#!" + envFile.getAbsolutePath() + " bash\n";
|
||||||
}
|
|
||||||
log(2, " Generating " + KOBALTW + (envFile.exists() ? " with shebang" : "") + ".");
|
log(2, " Generating " + KOBALTW + " with shebang.");
|
||||||
|
|
||||||
content += "java -jar $(dirname $0)/kobalt/wrapper/kobalt-wrapper.jar $*\n";
|
content += "java -jar $(dirname $0)/kobalt/wrapper/kobalt-wrapper.jar $*\n";
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue