Update README.md (#32)

chmod function updated for beter clarity.
This commit is contained in:
Mohammed Umar 2017-04-25 00:25:07 +05:30 committed by Adnan Ahmed
parent d85384a847
commit 15a44de8ea
1 changed files with 27 additions and 0 deletions

View File

@ -120,6 +120,33 @@ Lets you change the read, write, and execute permissions on your files.
```bash
chmod -options filename
```
Syntax : (for numericals role assignment)
```bash
chmod nnn /path/to/file
```
Where n is number from 0 to 7
<ul>Here,
<li>First number is for Owner</li>
<li>Second number is for group</li>
<li>Third number is for Other</li>
</ul>
<b>Following number are used for permissions</b></br>
0 - no permissions</br>
1 - execute</br>
2 - write</br>
3 - write and execute</br>
4 - read</br>
5 - read and execute</br>
6 - read and write</br>
7 - read, write and execute.</br>
For example to provide full access to only Owner
```bash
chmod 700 path/to/file
```
### c. `cp`
Copies a file from one location to other.