I pasted about 1000 photos on the desktop of my macbook by mistake, then files on the desktop no longer can be seen but other apps work fine -- How can I have the desktop back?
Do you mean they've all been opened at once, or do you have 1,000 jpeg (or otherwise) icons cluttering the Desktop? Is it too late to do File>Undo Paste?
I don't understand Limnos's suggestion. Another user won't be able to see or have permission to make those changes. Might work using sudo mv, but need to establish the proper path first and that would probably involve moving the entire contents of the Desktop folder somewhere else -- unless you can manage to move all these photos to some new folder on the Desktop, but it sounds like the Desktop is too crippled for that -- then selectively moving non-photo items back.
Just having thousands of files on the desktop will cripple the machine. They don't even need to be open. You have to go into another user area where it is not trying to use that Desktop folder for the desktop but where it is just a normal folder, then get the majority of those files out of the Desktop folder. Either that or come up with some other way (such as single user mode) to move those files so they are not part of the active desktop in the account you want to use. I was presenting two options but there are likely others. The sudo command would likely work and you could combine it with a wildcard and .jpg so it just moved photo files.
I just went to a non-admin account on my computer. I clicked on a folder in my admin. account which was showing the prohibitory sign for me in the other account. Got info. Showed details. Clicked on the unlock icon. Clicked on the "group" which was set to my main user. Dragged down menu to non-admin user account I was using. It asked me if I wanted to change access and presented me with a sysadmin user and password prompt. I didn't want to do any more but it looks like you can do it from another userID which was what I was remembering.
OK, that should probably do it. But still leaves unanswered just what would be moved, if they're all over this crippled Desktop -- and in what form we still don't know, opened or unopened.
If they could all be moved into a folder e.g., one titled "Pictures," you could log into another user and move them into Documents in the original user. For example (the user "helengy" is hypothetical):
sudo mv /Users/helengy/Desktop/Pictures /Users/helengy/Documents/Pictures
But, and this is a big but, since the Finder is crippled for the Desktop, I don't see how you get them into another folder, Pictures in this case, in order to move them. And if you could do that you wouldn't need to log in to another user in the first place.
And you could do a sudo mv from another user, but just what are you moving, the entire Desktop folder? If you copy/move the entire Desktop folder somewhere, that still leaves you with a completely unmanageable folder in that new location.
I think the biggest obstacle is finding some way to isolate them, get them caged up, if you will, in preparation for a move, whatever kind of move that might be. Here I'm stumped.
Limnos wrote: The sudo command would likely work and you could combine it with a wildcard and .jpg so it just moved photo files.
Missed that. I'm bumping up against the limits of my beginner's Unix writing skills here -- could try to write something, but I'm not sure I wouldn't mangle it (reminder to self: must get a decent book soon), but maybe someone can supply an example using mv, .jpg, the wildcard, grep and pipe. With those, I would think it doesn't even have to be done using sudo or from another user either.
sudo mv /Users/helengy/Desktop/Pictures /Users/helengy/Documents/Pictures
sudo mv /users/helengy/Desktop/*.jpg then wherever you want to put them. Haven't tried it (last few days for working outside before winter!) but should work. See the links I posted below on using Single User Mode.
If you copy/move the entire Desktop folder somewhere, that still leaves you with a completely unmanageable folder in that new location.
The Desktop folder is special in how it behaves with interacting with Finder. According to BDAqua's frequent posts it uses a lot more resources. It isn't the content as such that is the problem, it is the large number of files in that special folder when it is part of Fidner's activities when logged into that person's account. The critical thing is to just get those files out of it. 1000 files in another folder will be fine. Frankly it might work to just open the folder Desktop in the user's area and drag them out but it is possible it is using so many resources that Finder is almost completely locked up. By logging into a different account the folder Desktop in the first person's account is just acting like any other folder as long as you can get access to it. Likewise, if you do this from Single User Mode and the command line interface you don't even have Finder running so it isn't having indigestion with the Desktop folder.
Mac OS X: How to start up in single-user or verbose mode http://support.apple.com/kb/HT1492
Topic: How to move files using Single User Mode - http://discussions.apple.com/message.jspa?messageID=11188922
I would think that moving those, especially if they're all in the opened state, but even if not, to another folder will just clog up the Finder and probably hog all the window server resources once they show up over there, even if they can be moved sans Finder from single user, another user or the command line. After all, Desktop is just another folder/Directory. I think maybe it only comes in for special treatment, at least pre-10.6 (I think beginning with 10.6 it stops being an issue) because it's where people are likely to place a lot of clutter.
What I'm guessing would be best would be to find out how to write a command to look for all the jpegs on the Desktop and then rm -rf them all. This shouldn't be a problem, since if they were pasted, they were copied from somewhere and the originals still exist.
Thinking it through some more, I think you must be right, that the Desktop isn't quite like any ordinary folder. After all, those 1,000 photos must have been -- and still are -- sitting in a folder or folders somewhere and weren't and aren't using Window Server resources as they are now. Unlike in an ordinary folder, at least one not set to icon view, each icon on the Desktop is acting as its own window.
So those on the Desktop probably could just be moved out to some other folder from single user, another user or the command line, or even using the Finder booted from an external clone, if one exists.
Still, just nuking them immediately seem the more direct solution, if possible.
Thanks Limons, and WZZZ?,
Due to the time difference, I posted the question and then went to bed straight -- Many thanks for your kindness!
I logged in a guest account as Limons instructed, but I could see nothing on the desktop still -- obviously, the damage is much more serious than we thought?
My laptop is rather aged, probably I should just get a new one -- the files are very much precious, and I do want them...
I wish I did not try to copy those photos at the first place!
The following will safely move all those photos out of the Desktop to a new folder called "photossaved." When this is all finished, this new folder with all the photos inside will appear on the Desktop. It won't delete them. In the very unlikely event you already have a folder titled "photossaved," it will move all of them there. Leave it all as one word. This is done on purpose. Do not do this from another account, if you have one. This must be done from the same account where all the photos are on the Desktop. This probably means you don't have to do anything but stay where you already are.
First, you will need to open Terminal, which is located in Applications>Utilities. That's inside the Macintosh HD folder that normally sits on your Desktop. Since you can't use the Desktop, use the menubar where you see Go>Go to Folder and enter /Macintosh HD and hit Go.
You will be entering these commands into the Terminal window, which you will enter one at a time. You should only copy/paste them in. After hitting return, you should wait until you see the $ sign return. When it reappears it means it's ready for the next command.
Then hit return. This will tell Terminal you want to look in the Desktop, which is where all those photos were mistakenly pasted.
and hit return again. This will tell Terminal you want to create a new folder titled "photossaved." Again, leave it as one word. This is done on purpose
mv *.jpg photossaved/
and hit return. This will find all the photos on the Desktop and move them into that new folder, "photossaved." It may take a bit of time for this to work. You will know it's finished moving them there when you see the $ sign reappear. Then just close the Terminal window.
Since you can't use the Desktop, use the menubar where you see Go>Go to Folder and enter /Macintosh HD and hit Go.
It may be this folder isn't called Macintosh HD. In that case just enter / and whatever the name is, if you remember it. Or just enter / and it will present you with a choice from which you can select it.