Live data from Hacker News

Java Pain

tbray.org

31–40 of 151 posts

Re: Java Pain

#31

Without the code and error message, this is just a rant from some (famous) guy who can't/won't figure out his tools. First of al­l, it took me for­ev­er to fig­ure out the ja­va command-line in­can­ta­tions to tell it that it need­ed my project’s class files and the json.org li­brary (which I’d al­ready down­load­ed so I could com­pile the suck­er). Yeah, I used to know that stuff ten years ago, but there re­al­ly sh…

Referring to things like unusual command line options as "incantations" has been reasonably common across the history of computer usage at least from the 1970s or so, if not earlier.

See: http://www.catb.org/jargon/html/I/incantation.html

Re: Java Pain

#32

Without the code and error message, this is just a rant from some (famous) guy who can't/won't figure out his tools. First of al­l, it took me for­ev­er to fig­ure out the ja­va command-line in­can­ta­tions to tell it that it need­ed my project’s class files and the json.org li­brary (which I’d al­ready down­load­ed so I could com­pile the suck­er). Yeah, I used to know that stuff ten years ago, but there re­al­ly sh…

I was going to say: "first things first: learning your tools is the 1st step" but I see it's been told already.

This is just a rant and personally I can't sympathize with. How that is a newsworthy is another issue, though.

Re: Java Pain

#33
post #31

Without the code and error message, this is just a rant from some (famous) guy who can't/won't figure out his tools. First of al­l, it took me for­ev­er to fig­ure out the ja­va command-line in­can­ta­tions to tell it that it need­ed my project’s class files and the json.org li­brary (which I’d al­ready down­load­ed so I could com­pile the suck­er). Yeah, I used to know that stuff ten years ago, but there re­al­ly sh…

Referring to things like unusual command line options as "incantations" has been reasonably common across the history of computer usage at least from the 1970s or so, if not earlier. See: http://www.catb.org/jargon/html/I/incantation.html

  Especially used of tricks that are so poorly documented
  that they must be learned from a wizard.

Re: Java Pain

#34
post #31

Without the code and error message, this is just a rant from some (famous) guy who can't/won't figure out his tools. First of al­l, it took me for­ev­er to fig­ure out the ja­va command-line in­can­ta­tions to tell it that it need­ed my project’s class files and the json.org li­brary (which I’d al­ready down­load­ed so I could com­pile the suck­er). Yeah, I used to know that stuff ten years ago, but there re­al­ly sh…

Referring to things like unusual command line options as "incantations" has been reasonably common across the history of computer usage at least from the 1970s or so, if not earlier. See: http://www.catb.org/jargon/html/I/incantation.html

what's so unusual about -cp (or "-classpath")

Re: Java Pain

#35

you're kidding me, right? rhodey@rhodey$ mvn package rhodey@rhodey$ java -jar .jar

I don't think you read the article. You don't address his certificate issues. Your solution also requires writing a pom.xml which is non-trivial.

Maven can generate one for you:

  mvn archetype:generate -DgroupId=com.mycompany.app -DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false
Which is not trivial I suppose, but it is pretty easy to do.

Re: Java Pain

#36
post #34
post #31

Earlier quoted context omitted.

Referring to things like unusual command line options as "incantations" has been reasonably common across the history of computer usage at least from the 1970s or so, if not earlier. See: http://www.catb.org/jargon/html/I/incantation.html

what's so unusual about -cp (or "-classpath")

[deleted]

Re: Java Pain

#37
post #16
post #7

"Dear Java: I can run Ru­by and Python and Go and JavaScript and C code from the com­mand line on my Mac." - to be fair most of those languages are scripting languages.

In my opinion, the difference between "scripting" languages and other languages hasn't been relevant for about a decade.

Scripting languages are those that the code gets thrown away when the application gets rewritten in C, C++, Java, C#, ... in order to perform properly.

Re: Java Pain

#38
Yup, he's right. Most of these problems have been solved with tools, not by the JDK. If I have arbitrary Java that I want to execute quickly I write a unit test, not a test program for precisely this reason.

I guess it doesn't slow me down, because I know the unit test 'trick', in the same way as I know how to get Light Table to execute arbitrary s-expressions to get around Clojures load times has meant that I'm far less obsessed with Clojures slow startup.

Its a problem, sure, but I don't think Java is broken, its just never had the CLI in mind.

Re: Java Pain

#39
In java to be able to crawl a https url you have to do the following - http://www.coderanch.com/t/134619/Security/JDK-trust-Certifi... Its easier in other languages but its not that hard in java. Just export certificate via IE and save to disk and from the jre/lib/security folder and issue one command keytool -import -alias mycert -keystore cacerts -file d:\mycert.cer. (default password is changeit) Done.
Post reply on HN