From 0231b63cbcc35957e25702a038f5bd32a99bfadf Mon Sep 17 00:00:00 2001 From: ivanpeu28-sudo Date: Sun, 11 Oct 2026 23:28:54 +0200 Subject: [PATCH 1/5] Add linux.txt with Linux command history --- homework/linux.txt | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/homework/linux.txt b/homework/linux.txt index e69de29b..426513f7 100644 --- a/homework/linux.txt +++ b/homework/linux.txt @@ -0,0 +1,46 @@ +MrPrincipal@HopeOfTheWorld:~/lekcja$ cat selected.txt command.txt +19 +8 +345 mkdir lekcja +346 cd lekcja/ +347 touch processes.txt +348 ps aux +349 vim processes.txt +350 cp processes.txt copy.txt +351 mkdir backup +352 mv copy.txt ./backup +353 cd backup/ +354 ls +355 .. +356 cd .. +357 vim processes.txt +358 touch selected.txt +359 cat 19 selected.txt +360 cat selected.txt 19 +361 vim selected.txt +362 grep /bin +363 grep bin +364 vim processes.txt +365 grep root +366 ps +367 kill 795 +368 ps +369 kill -9 795 +370 ps +371 grep VSZ +372 grep -rni vsz +373 grep -rni /bin +374 vim selected.txt +375 cat 8 selected.txt +376 echo 8 >> selected.txt +377 cat selected.txt +378 history +379 history | tail +23 +380 history | tail +381 history | tail +2 +382 history | tail-2 +383 history | tail -2 +384 history | tail -23 +385 history | tail -30 +386 history | tail -32 +387 history | tail -43 From 09b129572c6e27e4825e5f233e21dc981c045adc Mon Sep 17 00:00:00 2001 From: MrPrincipal Date: Sun, 11 Oct 2026 23:50:47 +0200 Subject: [PATCH 2/5] Update linux.txt with command history and edits --- homework/linux.txt | 64 +++++++++++++--------------------------------- 1 file changed, 18 insertions(+), 46 deletions(-) diff --git a/homework/linux.txt b/homework/linux.txt index 426513f7..22f967b2 100644 --- a/homework/linux.txt +++ b/homework/linux.txt @@ -1,46 +1,18 @@ -MrPrincipal@HopeOfTheWorld:~/lekcja$ cat selected.txt command.txt -19 -8 -345 mkdir lekcja -346 cd lekcja/ -347 touch processes.txt -348 ps aux -349 vim processes.txt -350 cp processes.txt copy.txt -351 mkdir backup -352 mv copy.txt ./backup -353 cd backup/ -354 ls -355 .. -356 cd .. -357 vim processes.txt -358 touch selected.txt -359 cat 19 selected.txt -360 cat selected.txt 19 -361 vim selected.txt -362 grep /bin -363 grep bin -364 vim processes.txt -365 grep root -366 ps -367 kill 795 -368 ps -369 kill -9 795 -370 ps -371 grep VSZ -372 grep -rni vsz -373 grep -rni /bin -374 vim selected.txt -375 cat 8 selected.txt -376 echo 8 >> selected.txt -377 cat selected.txt -378 history -379 history | tail +23 -380 history | tail -381 history | tail +2 -382 history | tail-2 -383 history | tail -2 -384 history | tail -23 -385 history | tail -30 -386 history | tail -32 -387 history | tail -43 +MrPrincipal@HopeOfTheWorld:~$ history | tail -17 > commands.txt + 401 c test + 402 cd test + 403 touch processes.txt + 404 ps aux > processes.txt + 405 cp processes.txt copy.txt + 406 mkdir backup + 407 mv copy.txt backup/ + 408 touch selected.txt + 409 echo 50 selected.txt + 410 echo 50 > selected.txt + 411 grep -rni /bin + 412 grep -rni /bin >> selected.txt + 413 history + 414 history | tail -14 + 415 history | tail -16 + 416 touch commands.txt + 417 history | tail -17 > commands.txt From 4030ed56e9f93c0df943a610d4a76862c3b88fde Mon Sep 17 00:00:00 2001 From: MrPrincipal Date: Sun, 11 Oct 2026 23:53:25 +0200 Subject: [PATCH 3/5] Revise command history in linux.txt Updated command history in linux.txt to include new entries. --- homework/linux.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/homework/linux.txt b/homework/linux.txt index 22f967b2..07d3f273 100644 --- a/homework/linux.txt +++ b/homework/linux.txt @@ -16,3 +16,4 @@ MrPrincipal@HopeOfTheWorld:~$ history | tail -17 > commands.txt 415 history | tail -16 416 touch commands.txt 417 history | tail -17 > commands.txt +MrPrincipal@HopeOfTheWorld:~$ cat selected.txt commands.txt From 87d4533a08a25343ff284eaad56d249c4d9089fd Mon Sep 17 00:00:00 2001 From: MrPrincipal Date: Mon, 9 Nov 2026 14:31:19 +0100 Subject: [PATCH 4/5] Update history commands in linux.txt --- homework/linux.txt | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/homework/linux.txt b/homework/linux.txt index 07d3f273..1b536963 100644 --- a/homework/linux.txt +++ b/homework/linux.txt @@ -1,19 +1,20 @@ -MrPrincipal@HopeOfTheWorld:~$ history | tail -17 > commands.txt - 401 c test - 402 cd test - 403 touch processes.txt - 404 ps aux > processes.txt - 405 cp processes.txt copy.txt - 406 mkdir backup - 407 mv copy.txt backup/ - 408 touch selected.txt - 409 echo 50 selected.txt - 410 echo 50 > selected.txt - 411 grep -rni /bin - 412 grep -rni /bin >> selected.txt - 413 history - 414 history | tail -14 - 415 history | tail -16 - 416 touch commands.txt - 417 history | tail -17 > commands.txt -MrPrincipal@HopeOfTheWorld:~$ cat selected.txt commands.txt +MrPrincipal@HopeOfTheWorld:~$ cat test/selected.txt test/commands.txt +27 +9:root 212 0.0 0.0 2888 2012 ? Ss 14:15 0:00 /bin/sh /usr/lib/systemd/scripts/chronyd-starter.sh -n -F 1 +12:root 218 0.0 0.3 44096 29784 ? Ss 14:15 0:00 /usr/bin/python3 /usr/bin/networkd-dispatcher --run-startup-triggers +17:root 273 0.0 0.4 123464 32584 ? Ssl 14:15 0:00 /usr/bin/python3 /usr/share/unattended-upgrades/unattended-upgrade-shutdown --wait-for-signal + 865 mkdir test + 866 touch test/processes.txt + 867 ps aux >> test/processes.txt + 868 cp test/processes.txt test/copy.txt + 869 mkdir backup + 870 mv test/copy.txt backup/ + 871 vim test/processes.txt + 872 echo 27 >> test selected.txt + 873 echo 27 >> test/selected.txt + 874 grep -n "/bin" processes.txt >> selected.txt + 875 grep -n "/bin" test/processes.txt >> test/selected.txt + 876 historia + 877 history + 878 history | tail -n +865 > test commands.txt + 879 history | tail -n +865 > test/commands.txt From aa284b1748550934c24c05c6583ef996eaa0753b Mon Sep 17 00:00:00 2001 From: MrPrincipal Date: Mon, 9 Nov 2026 14:37:17 +0100 Subject: [PATCH 5/5] Modify linux.txt with updated commands and corrections Updated commands in linux.txt to include line count and fixed command errors. --- homework/linux.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/homework/linux.txt b/homework/linux.txt index 1b536963..9ee3b8c6 100644 --- a/homework/linux.txt +++ b/homework/linux.txt @@ -10,8 +10,8 @@ MrPrincipal@HopeOfTheWorld:~$ cat test/selected.txt test/commands.txt 869 mkdir backup 870 mv test/copy.txt backup/ 871 vim test/processes.txt - 872 echo 27 >> test selected.txt - 873 echo 27 >> test/selected.txt + 872 wc -l < test processes.txt > test/selected.txt + 873 wc -l < test/processes.txt > test/selected.txt 874 grep -n "/bin" processes.txt >> selected.txt 875 grep -n "/bin" test/processes.txt >> test/selected.txt 876 historia