Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Nogui

macrumors newbie
Original poster
Sep 5, 2011
7
0
Abu Dhabi
I've been trying to get Terminal to delete an old folder and replace it with a new one with folders from a different location. The folder creation goes fine, although when I try to copy the folders from the location, it gives me an error.

My code is as below, although it's only the last 4 lines that I have trouble with:

Code:
cd ~/Library/Application\ Support/
rm -rf minecraft/*
mkdir minecraft
cd ~/Library/Application\ Support/minecraft/
mkdir bin
mkdir saves
mkdir config
mkdir texturepacks
mkdir stats
mkdir resources
cd ~/Library/Application\ Support/minecraft/bin/
mkdir natives
mkdir minecraft.jar
cd ~/Library/Application\ Support/minecraft/bin/minecraft.jar/
jar xf ~/Desktop/womc/minecraft.jar
cd ~/Library/Application\ Support/minecraft/config/
jar xf ~/Desktop/womc/config.jar

I get the following error message for both minecraft.jar and config.jar:

Code:
java.io.FileNotFoundException: /Users/Minecraft/Desktop/womc/config.jar (No such file or directory)
	at java.io.FileInputStream.open(Native Method)
	at java.io.FileInputStream.<init>(FileInputStream.java:120)
	at java.io.FileInputStream.<init>(FileInputStream.java:79)
	at sun.tools.jar.Main.run(Main.java:238)
	at sun.tools.jar.Main.main(Main.java:1149)

It says that the folder does not exist, although it's in the location specified and is named correctly.

Any help is greatly appreciated.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.