maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Troubleshooting (https://talk.maemo.org/forumdisplay.php?f=6)
-   -   I am trying to move files that i can see! but 770 says do not exist? (https://talk.maemo.org/showthread.php?t=5076)

stuH 2007-03-05 14:17

I am trying to move files that i can see! but 770 says do not exist?
 
Hi i've had a lot of v-good advise from the forum and ive used the method cp and mv to move files before, this time i cant get it to happen, eg.

./.MyDocs/.documents/gnokki
I want to move gnokii to /var/lib/install/usr/bin but when i do

mv ./.MyDocs/.documents/gnokii var/lib/install/usr/bin it tels me no such file or directory, ive copyd it exactly as it is in my list of files?

any help or idiot errors ive made! let me know please.

fanoush 2007-03-05 14:54

Re: I am trying to move files that i can see! but 770 says do not exist?
 
Better use tab file completion i.e. type few letters and press tab key to let the shell complete file name for you. In this case .MyDocs is the problem, there is in fact no such thing on your device.

SeRi@lDiE 2007-03-05 15:04

Re: I am trying to move files that i can see! but 770 says do not exist?
 
Take the first dot out of the line.... There shouldnt be a dot there.
It should be
Code:

mv /.MyDocs/.documents/gnokii var/lib/install/usr/bin/gnokii

stuH 2007-03-05 15:23

Re: I am trying to move files that i can see! but 770 says do not exist?
 
still no joy, dont understand as i used the same method only days ago! dropped the . and still saying no such file or dir.
is it possoble the . is a hidden command, matbe command is not the right word but maybe it should be typed in completely"whatever it is" ?
just a thought as i remember something about . being hidden files!

TA-t3 2007-03-05 15:49

Re: I am trying to move files that i can see! but 770 says do not exist?
 
su - user
pwd
(should show /home/user)
ls -l
(should show MyDocs among others)
mv MyDocs/.documents/gnokii .. and so on.
Note: MyDocs is really /home/user/MyDocs and there is no "." in front of MyDocs
Note2: If the above 'mv' doesn't work, possibly because /var/lib/install isn't writeable by 'user' (I don't know as I don't have that directory) then you must be root not user (i.e. no 'su - user', and you must have used gainroot before), and modify the mv command to 'mv /home/user/MyDocs/.documents ...' and so on (it's best to use tab completion here, as someone else mentioned)

rcull 2007-03-05 15:52

Re: I am trying to move files that i can see! but 770 says do not exist?
 
The first dot is fine. theproblem appears to be you have no leading / in the too path ie.

mv ./MyDocs/.documents/gnokii /var/lib/install/usr/bin/gnokii

or

mv MyDocs/.documents/gnokii /var/lib/install/usr/bin/gnokii

The shell is reporting 'No such file or directory' for your 'Too' path, the "current directory" does not have a var directory, var is under root hence /var. The shorthand './' in the 'From' path just means current directory.

Edit: paths corrected and of course you must be in root ( both SeRi@lDiE and TA-t3 are correct :) :)

SeRi@lDiE 2007-03-05 15:56

Re: I am trying to move files that i can see! but 770 says do not exist?
 
It wont work under user thats for sure.

stuH 2007-03-05 17:01

Re: I am trying to move files that i can see! but 770 says do not exist?
 
I am in RD mode, i was in redpill to download an app lastnight, thats now back to blue pill just now !
So RD mode, the mv cp commands worked moving files from my mmc a few days ago but not from my docs now, tried all suggestions maybe forgeting to say i was in RD mode got me wrong advise! or would that matter?

TA-t3 2007-03-05 17:02

Re: I am trying to move files that i can see! but 770 says do not exist?
 
Some useful commands (enter without apostrophes):
'id' tells you who you are (e.g. root or user)
'pwd' tells you where you are (e.g. /root or /home/user etc.)
'cd' changes to some other directory, e.g. cd /home/user
'cd -' changes back to the directory you were in before your last 'cd somewhere'
'ls' lists the files in the directory you are
'ls /home' ditto for /home
'ls -A' as above but will also list files and dirs starting with a "." (dot)
'mv' renames or moves a file, e.g. 'mv old new'
'cp' copy a file, e.g. 'cp file file.backup'
'df' to see the mounted filesystems (including your card(s)).
'df -h' the same, in human-readable format (i.e. kilobytes or megabytes)

And for those commands taking filenames as parameters: Use 'tab completion', e.g. 'mv some-f<tab>' will complete some-f to whatever starts with 'some-f', press tab twice to see all alternatives, then enter another character+tab to resolve ambiguity as necessary.
Tab completion also works for commands, e.g. you think the command starts with 'l' but you don't remember the rest: Enter 'l', then press tab a couple of times.

And lastly:
'command --help' (e.g. ls --help) will show the options.

EDIT: Added the 'df' command.

TA-t3 2007-03-05 17:06

Re: I am trying to move files that i can see! but 770 says do not exist?
 
stuH: As Aflegg said the other day: It's better (well, he thinks so and I agree) to leave the pill in blue mode, and instead install becomeroot and use 'sudo gainroot' whenever you need to do something as root, and just 'exit' and/or leave xterm after you're done. Then you can forget all about the pill (as it's too easy to forget it in the wrong mode anyway)


All times are GMT. The time now is 08:58.

vBulletin® Version 3.8.8