3 ms·
My first experience with the JVM classpath was when I started using Clojure with zero Java experience. I quickly understood it more or less works the same as UN
by capableweb 5y ago
My first experience with the JVM classpath was when I started using Clojure with zero Java experience. I quickly understood it more or less works the same as UNIX $PATH (although the devil is in the details, they are not identical), and since then I haven't really hit any issues. nodejs/npm does something similar by instead of being user set by default, it defaults to "./node_modules && ./node_modules/*/node_modules" (recursively).
Most languages deal with paths in mostly similar ways (except Go until recently). What precisely is your issues with the Java classpath that someone who have been writing Clojure code for years haven't hit yet?
- amelius 5y agoOne issue is that you can't have a colon in your path names.
- capableweb 5y agoIs that something you come across frequently enough to hate the Java classpath? AFAIK, $PATH might be tripped up by that as well, as `:` is part of the syntax for delimiting. Just because I was curious, I tried searching for all directories containing ":" and besides /sys and /run, I got three hits. One because of "https:// https://", one because of "localhost:8080" (both mirrors made from wget) and one where it actually seems to be on purpose. It seems, to me at least, that having colon in path names is unpopular enough for this to not be a real problem. Edit: desktop I tried the command (`# find / -name ':' -type d`) on has been running daily since beginning of 2018 (2196 packages installed atm), with daily pacman updates, so should have enough data for a average workstation.
- fnord123 5y agoColon is an invalid character on Windows systems. I've used it when making log files where they have an intermediate suffix with an ISO 8601 timestamp but indeed I don't see a reason to have it in a path with class or jar files.
- aww_dang 5y agoCan't you just use an escape character?
- cjaybo 5y agoWhy is that an issue?
- fulafel 5y agoHow does this work out on Windows?
- vbezhenar 5y agoWindows uses ';' for path delimiter.