New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus • Advice and insight from world-class Apple enthusiasts • Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
OS X - Operating System General OS operation information and support

Using Terminal - Copied Folder Converted to Document


Post Reply New Thread Subscribe

 
Thread Tools
scamper3

 
Member Since: Jul 17, 2013
Posts: 2
scamper3 is on a distinguished road

scamper3 is offline
Hi,

Using Terminal, my boss copied a folder on her desktop to another folder, also on her desktop. Somehow, in copying, she overwrote the destination folder - which contained other files. It changed the destination folder to a text file.

She closed the window before alerting me, so I don't know the exact path she typed. Still it was probably something like this:

Code:
cp -av [filepath/folders/to/copy] [filepath/destination]
She typed "cp -av" and dragged the folders into the Terminal window (she never typed the path). So, Terminal places the exact filepath. In the text file, it looks like the information is still there, it just needs to be converted back.

The odd thing, is that we performed some tests afterwards, performing the same steps with other directories, and it worked correctly - copied the entire folder and subsequent files into the destination folder intact. I and another have performed this before and after, again, with no problems.

I thought it might be because in Terminal, there was no end slash ("/"), but when testing, even though I didn't see end slashes, it copied over just fine.

I'd like to know if anyone else has experienced this issue and how they resolved it. I want to convert the document back to it's original folder structure.

The OS is 10.6.8.

Please let me know if I need to provide any further information.

Thanks.

Stephen
QUOTE Thanks
cradom

 
cradom's Avatar
 
Member Since: Feb 14, 2004
Location: Nederland, Texas
Posts: 3,469
cradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant future
Mac Specs: 13in macbook - 10.10.1

cradom is offline
If it hasn't been too long (days) open a Terminal and type 'history' without the quotes.
This will tell you what was typed to do this and might reveal a possible solution.

Craig Domingue - resident redneck.
“Never argue with an idiot. He will only bring you down to his level and beat you with experience.”, George Carlin
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,352
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
Or, if you haven't executed much else, just push the up arrow until you find the command. It's perhaps not as elegant as cradom's suggestion but I thought I'd throw another option in there.

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks
scamper3

 
Member Since: Jul 17, 2013
Posts: 2
scamper3 is on a distinguished road

scamper3 is offline
Took a while to get the information.

Thanks - typing 'history' provided this:

Kxxx-Bxxx:~ kxxxxxxx$ history
1 /Volumes/1234567_MAC/LS\ Agency/\ \ \ \ \ \ TEMPORARY\ FOLDER/\ \ \ \ \ \ XYZ\ Client\ Sample\ files/XYZ\ Decision\ Guide/XYZDecGuide ; exit;
2 /Users/kxxxxxxx/Desktop/SF3-removal-tool.command ; exit;
3 cp -av /Users/kxxxxxxx/Desktop/Kxxxx /Users/kxxxxxxx/Desktop/\ CURRENT\ PROJECTS
4 cp -av /Users/kxxxxxxx/Desktop/\ CURRENT\ PROJECTS /Users/kxxxxxxx/Desktop/untitled\ folder
5 cp -av /Users/kxxxxxxx/Desktop/Segmentation\ Examps /Users/kxxxxxxx/Desktop/test
6 cp -av /Users/kxxxxxxx/Desktop/INFOGRAPHICS /Users/kxxxxxxx/Desktop/test
7 history

I don't know what #1 and #2 are. Those may be the ones that caused the problem. #3-6 look fine to me. #5 and #6 where the ones I watched her perform.

Does the line with "removal-tool.command" imply that the files were removed (deleted)?

Thanks.

Stephen
QUOTE Thanks
cradom

 
cradom's Avatar
 
Member Since: Feb 14, 2004
Location: Nederland, Texas
Posts: 3,469
cradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant futurecradom has a brilliant future
Mac Specs: 13in macbook - 10.10.1

cradom is offline
Ok, first off, if you're working with Terminal a lot, don't use spaces in file/directory names. Too much work to escape them.
Also, don't use certain characters in names (/\ etc. It's very hard to read no 1, cant tell what's file/dir and what's an escape.
No 1: Some kind of command on an external drive?
No 2: looks like something 'might' have been removed.
No 3: copying Kxxxx into CURRENT PROJECTS
NO 4: copying CURRENT PROJECTS into untitled folder

More copy commands. I cant really see a mistake. Try ls -la in Terminal in the Desktop folder. Which folder turned into a file?

Craig Domingue - resident redneck.
“Never argue with an idiot. He will only bring you down to his level and beat you with experience.”, George Carlin
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,352
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
The SF3-removal-tool command file is the uninstaller for Suitcase Fusion (see here).

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks

Post Reply New Thread Subscribe


« How to transfer files from macbook Pro to Seagate GoFlex 500GB | Launching new processes spikes CPU to 100, running programs function as normal »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread
Thread Starter
Forum
Replies
Last Post
Accidentally changed "Home" folder name... confusing reprecussions... uli_kunkel OS X - Operating System 3 01-19-2010 07:34 PM
Where is home folder? Mac 10.5 to Active Directory schoolhelper OS X - Operating System 0 08-02-2009 09:24 PM
Deleting personal files from company computer Aisho Switcher Hangout 3 04-25-2008 02:24 AM
How do I access folders that contain space in Terminal. (ie. My Folder) AlexN Switcher Hangout 6 09-26-2005 02:01 AM
Copying one folder over another of the same name destroys data! Cloudane Switcher Hangout 28 05-18-2005 08:10 PM

All times are GMT -4. The time now is 09:11 AM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?