1
0
Fork 0
mirror of https://codeberg.org/Mo8it/How_To_Linux.git synced 2024-10-18 09:42:38 +00:00

Fix typos

This commit is contained in:
Mo 2023-08-17 02:35:15 +02:00
parent f047a0ccc4
commit dd981a8ba8
4 changed files with 13 additions and 13 deletions

View file

@ -65,7 +65,7 @@ Enter the command `mkdir empty_house`.
Well, you don't see anything?
Did the command do something at all?
To check, run `ls` again.
Now you should see your new directory `empty_house` listed too!
Now, you should see your new directory `empty_house` listed too!
`mkdir` stands for _make directory_.
`empty_house` is just a name for our new directory.
You could have used `mkdir Images` for example to create a directory called `Images`.
@ -87,7 +87,7 @@ You should not be seeing anything because the directory is indeed empty, until n
An empty house is a sad house.
Let's give the house directory some friends to live within it.
Enter the command `touch friend1.txt`.
Now enter `ls` again:
Now, enter `ls` again:
```console
$ ls
@ -105,7 +105,7 @@ Enter the command `cd ..` to go one directory back.
The two dots `..` refer to the parent directory in Linux.
Now that you are back in `~`, enter `mv empty_house happy_house`.
Now enter `ls` again.
Now, enter `ls` again.
You can see that `empty_house` does not exist anymore.
It was renamed to `happy_house` (_since it has at least one friend now_).
`mv` stand for _move_.
@ -566,8 +566,8 @@ For typing a long path, you can use **autocompletion**.
Go back to the home directory using `cd`.
Let's say that we want to read the rules of the directory `happy_house`.
Type `cat hap` without hitting enter yet.
Now press `Tab` and see how the path is autocompleted to `cat happy_house/`
Now type `ru` and hit `Tab` again.
Now, press `Tab` and see how the path is autocompleted to `cat happy_house/`
Now, type `ru` and hit `Tab` again.
Then you have `cat happy_house/rules.txt`.
Much faster, right? 🏎️

View file

@ -17,7 +17,7 @@ But you should not find any updates since you did just install the crates.
The crate `tealdeer` provides you with the program `tldr`.
Run `tldr --update`. Now run the following two commands:
Run `tldr --update`. Then run the following two commands:
```bash
tldr dnf

View file

@ -9,7 +9,7 @@ In this task, we will learn about the power of macros in Vim.
1. Paste the names into the file. You should see 500 lines with a name in each line.
1. Record a macro that changes a line in the form `FIRST_NAME LAST_NAME` to `("FIRST_NAME", "LAST_NAME"),`.
1. Run the macro on all lines.
1. Now go to the beginning of the file (`gg`) and add this line as a first line: `names = [`
1. Now, go to the beginning of the file (`gg`) and add this line as a first line: `names = [`
1. Go to the end of the file (`G`) and add this line as last line: `]`
Congratulations, you did just convert the names into a form that could be directly used by a Python program! It is a list of tuples now.
@ -42,7 +42,7 @@ We will use the program `inotifywait`. This program can monitor a directory and
1. Based on the output, choose an event that you want to listen to with `inotifywait` that tells you when a file is _completely_ added to the directory `jobs`. Use the manual to read more about specific events.
1. Find an option that lets you tell `inotifywait` to only notify when the chosen event occurs.
1. Find an option that lets you format the output of the notification of `inotifywait`. Since we only listen on one event and monitor only one directory, an output that shows only the name of the new file should be enough.
1. Enter the command that you have until now in a script. Now extend it by using a `while` loop that continuously listens on the notifications of `inotifywait`. Use the following snippet while replacing the sections with `(...)`:
1. Enter the command that you have until now in a script. Now, extend it by using a `while` loop that continuously listens on the notifications of `inotifywait`. Use the following snippet while replacing the sections with `(...)`:
```bash
inotifywait (...) | while read FILENAME
do

View file

@ -28,7 +28,7 @@ After that I add you public key, connect to the server using the host name that
Replace `USERNAME` with your name.
1. Now set a password for the new user:
1. Now, set a password for the new user:
```bash
sudo passwd USERNAME
@ -94,16 +94,16 @@ In this task, we want to compile the program `tmate`.
1. Go to the [website of `tmate`](https://tmate.io/) and find out how to compile from source (there are instructions for compiling on Ubuntu).
1. Follow the compilation instructions in the container.
1. After compilation, you will find the binary `tmate` in the directory of the git repository.
1. Don't exit the container yet, otherwise you will lose what you have done in it. Now open a new terminal (tab) and copy the binary `tmate` from the container to the directory `bin` in your home directory. Use the command `podman cp CONTAINERNAME:SRC_PATH DESTINATION_PATH`.
1. Don't exit the container yet, otherwise you will lose what you have done in it. Now, open a new terminal (tab) and copy the binary `tmate` from the container to the directory `bin` in your home directory. Use the command `podman cp CONTAINERNAME:SRC_PATH DESTINATION_PATH`.
1. Verify that the binary `tmate` was copied to `DESTINATION_PATH` and then exit the container in the first terminal (tab).
Now write a script called `compile_tmate.sh` that automates what you have done in the container to compile `tmate`. Just copy all the commands that you used in the container to a script.
Now, write a script called `compile_tmate.sh` that automates what you have done in the container to compile `tmate`. Just copy all the commands that you used in the container to a script.
Add to the end of the script `mv PATH_TO_TMATE_BINARY_IN_CONTAINER /volumes/bin` to copy the binary to the directory `/volumes/bin` after compilation.
Create a directory called `scripts` and put the script in it.
Now write a second script in the parent directory of the directory `scripts`. The second script should automate creating the container that runs the first script.
Now, write a second script in the parent directory of the directory `scripts`. The second script should automate creating the container that runs the first script.
Do the following in the second script:
@ -129,7 +129,7 @@ Do the following in the second script:
After running the second script, you should see the container compiling and then exiting. At the end, you should find the binary `tmate` in the `bin` directory.
Now that you have the program `tmate`, find out what it does! Try it with a second person.
Now, that you have the program `tmate`, find out what it does! Try it with a second person.
### Hints