5. Print Working Directory $pwd [-LP] Opções: -P : The pathname printed will not contain symbolic links. -L : The pathname printed may contain symbolic links Exemplo:
6. Change Directory $cd [Opções] [Directoria] Opções: -P Do not follow symbolic links -L Follow symbolic links (default) Exemplo:
8. Change Directory $ cd . $ cd DirectoriasEspeciais Voltaratrásrapidamente: Subirumadirectoria: Directoria actual: Irpara HOME:
9. List Directory Contents $ ls [-ABCFGHLPRSTW@abcdefghiklmnopqrstuwx1] [file ...] Opções: -l List in long format -a List all entries incluiding those beginning with ‘.’ -G Enable colorized output -h When used with the -l option, use unit suffixes Exemplo:
10. Make Directories $ mkdir [-pv] [-mmodo] nome_directoria ... Opções: -p Create intermediate directories as required -v Be verbose when creating directories, listing them as they are created Modo Pordefeitoomodoé 0777, podendo ser definido de qualquer forma aceitepelochmod Exemplo:
12. Remove $ rm [-dfiPRrvW] ficheiro ... Opções: -f Attempt to remove the files without prompting for confirmation -R Attempt to remove the file hierarchy rooted in each file argument Exemplo:
18. Touch $touch [-acfm] [-r file] [-t [[CC]YY]MMDDhhmm[.SS]] ficheiro ... Funcionamento: Se oficheironãoexistireleécriado, se existe a data daúltimamodificaçãoéactualizadapara a data actual Exemplo:
21. ModosAbsolutos Soma de modos simples paraformarmodosabsolutos: O modoabsolutoquepermiteleitura, escritaeexecuçãopelo owner, leituraeexecuçãopormembros do grupoepelosoutroséo 755 (400 + 200 + 100+ 040 + 010 + 004 + 001) Símbolosperm: O equivalenteaomodoabsoluto 755 com símbolospermseriau=rwx, go=rx
22. Change Mode $chmod [-fv] [-R [-H | -L | -P]] modoficheiro ... Opções: -R Change the modes of the file hierarchies rooted in the files instead of just the files themselves Exemplo:
23. Execute as another user $sudo [-u] comando Opções: -u causes sudo to run the specified command as a user other than root Exemplo:
The user must have write permission in the parent directory.
If the permissions of the file do not permit writing, and the standard input device is a terminal, the user is prompted(on the standard error output) for confirmation. The rm utility removes symbolic links, not the files referenced by the links.
If the permissions of the file do not permit writing, and the standard input device is a terminal, the user is prompted(on the standard error output) for confirmation. The rm utility removes symbolic links, not the files referenced by the links.
If the permissions of the file do not permit writing, and the standard input device is a terminal, the user is prompted(on the standard error output) for confirmation. The rm utility removes symbolic links, not the files referenced by the links.