Get current username in Julia (Linux)
An easy workaround:
run(`whoami`)
But unnecessary, as this works:
ENV["USER"]
This works on both Linux and Windows:
splitdir(homedir())[end]
An easy workaround:
run(`whoami`)
But unnecessary, as this works:
ENV["USER"]
This works on both Linux and Windows:
splitdir(homedir())[end]