Browse Source

docs(change-struct): moving the subject to the folder devops

changing the structure of the Readme
pull/1658/head
miguel 2 years ago committed by MSilva95
parent
commit
232bbf2b5c
  1. 72
      subjects/devops/change-struct/README.md

72
subjects/change-struct/README.md → subjects/devops/change-struct/README.md

@ -1,38 +1,10 @@
## Change struct
You need to rearrange the file structure that you created earlier in the "file-struct" exercise.
Here is an example of how to move, rename, copy and delete a file or repo:
**_Copy_**
```console
cp `file to copy` `path of destination`
cp -r `repo to copy` `path of destination`
```
**_Move or Rename_**
```console
User-> mv `file to move` `path of destination`
User-> mv -r `repo to move` `path of destination`
User-> ls
text.txt old_repo
User-> mv text.txt new_text.txt
User-> mv old_repo new_repo
User-> ls
new_text.txt old_repo
```
**_Delete_**
```console
User-> rm `file to remove`
User-> rm -r `repo to remove`
```
### Instructions
Use those commands to create the following file structure:
You need to rearrange the file structure that you created earlier in the "file-struct" exercise.
Use the correct commands to create the following file structure:
- Copy the `struct` repo that you created and change its name to `new_struct`.
- Create the `0_to_3` and `6_to_9` folders.
@ -67,13 +39,43 @@ new-struct/
Once it is done, use the command below to create the file `done.tar` to be submitted.
```console
User-> tar -cf done.tar *
User-> ls new-struct/
$ tar -cf done.tar *
$ ls new-struct/
0_to_3 4 6_to_9 A done.tar
```
**Only `done.tar` should be submitted.**
**Tips:**
### Hints
Here is an example of how to move, rename, copy and delete a file or repo:
**_Copy_**
```console
cp `file to copy` `path of destination`
cp -r `repo to copy` `path of destination`
```
**_Move or Rename_**
```console
$ mv `file to move` `path of destination`
$ mv -r `repo to move` `path of destination`
$ ls
text.txt old_repo
$ mv text.txt new_text.txt
$ mv old_repo new_repo
$ ls
new_text.txt old_repo
```
**_Delete_**
```console
$ rm `file to remove`
$ rm -r `repo to remove`
```
Use the command `man <name of the command>` to get more info on some command that you need to use.
> You have to use Man or Google to know more about commands flags, in order to solve this exercise!
> Google and Man will be your friends!
Loading…
Cancel
Save