Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Here's the basic script from a batch file. I'm trying to do something similar to this, but on Linux that would tell Minecraft(Java) that the home folder was located somewhere else (like a flash drive). If it's even possible?

start %CD%\minecraft.exe

I have a .zip file with all the files you would extract to a root of the drive. I've wrapped up the .bat file into the .exe.

share|improve this question
Have you tried googling for "Portable Minecraft"? – Daniel Beck Feb 29 '12 at 6:30
None of them are for Linux. That's what I'm trying to do. – Altkey Mar 1 '12 at 13:41

The following bash script does what your batch file does. Haven't tested if it works with minecraft, but I'm thinking you probably don't actually want to run a Windows binary on a Linux system, at least not without Wine or something in between.

export HOME="$CD"
share|improve this answer
Is there a special way to have this run .jar files? Edit: Nevermind. I can get the jar to execute, but it still uses the default home. – Altkey Mar 1 '12 at 14:22

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.