Is anyone here familiar with BBEdit 9?


Recommended Posts

A while ago I made a topic about wanting to compile and run Java programs with a text editor. I was using TextMate for a while, but ending up switching to BBEdit. It does the job, but I can't figure out how to compile and run the Java programs I write. This is what I get:

post-119000-1258763868.png

I'm not sure what a "shebang" is.

Link to comment
Share on other sites

http://en.wikipedia.org/wiki/Shebang_%28Unix%29

It looks like it's trying to invoke some kind of bash script which is lacking a line like

#!/bin/bash

or similar.

Hmm... All I'm testing is a basic Java program...

#!/bin/bash

public class Hello {
	public static void main(String[] args) {
		System.out.println("Hello World!");
	}
}

This will let me run the Terminal, but then I get this:

post-119000-1258764778_thumb.png

Link to comment
Share on other sites

Hmm... All I'm testing is a basic Java program...

#!/bin/bash

public class Hello {
	public static void main(String[] args) {
		System.out.println("Hello World!");
	}
}

This will let me run the Terminal, but then I get this:

I've never seen a java program start with #!/bin/bash...... that's for bash scripts...

Link to comment
Share on other sites

I've never seen a java program start with #!/bin/bash...... that's for bash scripts...

Yea, a Java program would never need the shebang. It's just that BBEdit's "Run" command just tries to run whatever you've made as a shell script and not use the specific method of whatever language you're writing in.

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.