(Dennis, Ken)
Linux does not use code from UNIX.
The idea and names of commands are similar.
A computer terminal is a hardware device that is used for entering data into, and displaying or printing data from a computer or a computing system.
Frequently Used Terms
Directory Commands
File Commands
Special Commands
vi Editor, Print Commands and Symbols
User, Root and Home Directory
whoami
## emirtoker
Root directory symbol; “/
”. Home directory symbol; “~
”.
Environments and Backup
printenv
Command Line, Command
Warning, Error, Permission Denied, Segmentation Fault
pwd (Print Working Directory)
ls (List Directories)
cd (Change Directory)
mkdir (Make Directory)
(Print Working Directory)
pwd
## /Users/emirtoker/Desktop/Memurluk/Software_Tools_for_Earth_&_Environmental_Science/Software_Tools_R_Github
(List Directories)
ls
## LICENSE
## Presentation
## README.html
## README.md
## R_Home_Website
## R_Interactive_Samples_with_Shiny.Rmd
## R_Interactive_Samples_with_Shiny.html
## R_Interactive_Samples_with_Shiny_files
## R_Interactive_Training
## Software_Tools_R_Github.Rproj
## Software_Tools_for_Earth_and_Environmental_Science_Syllabus.png
## Software_Tools_for_Earth_and_Environmental_Science_Syllabus_2020_21_Fall.png
## _site.yml
## about.Rmd
## additional_course.Rmd
## book.Rmd
## code.Rmd
## data.Rmd
## data_sources.Rmd
## data_structure.Rmd
## datacamp.Rmd
## dc_logo1.png
## dc_logo2.png
## dc_logo3.png
## dc_logo4.png
## dc_logo5.png
## docs
## index.Rmd
## my_r_notebook.Rmd
## ncl.Rmd
## netcdf.Rmd
## new_accounts.Rmd
## new_data.csv
## python.Rmd
## r_and_rstudio.Rmd
## r_language.Rmd
## r_probability.Rmd
## r_programming.Rmd
## r_statistics.Rmd
## rsconnect
## syllabus.Rmd
## unix_linux.Rmd
(Change Directory)
cd Presentation/
(Make Directory)
mkdir <new_folder_name>
touch
cat (Concatenate)
rm (Remove)
cp (Copy)
mv (Move)
touch <my_new_file>
(Concatenate)
cat my_new_file
This is my new file. Hi!
(Copy)
cp my_new_file my_new_file2
(Move)
mv my_new_file2 my_new_file3
(Remove)
rm my_new_file my_new_file3
find
help
history
clear
date and cal
exit
find -name <name_of_file>
find --help
history
clear
date
## Thu Oct 22 01:30:50 +03 2020
cal
## October 2020
## Su Mo Tu We Th Fr Sa
## 1 2 3
## 4 5 6 7 8 9 10
## 11 12 13 14 15 16 17
## 18 19 20 21 _2_2 23 24
## 25 26 27 28 29 30 31
##
exit
*
(an unknown sroup of characters)cat my_profile | sort
ls > my_list
x=3
echo $x
ls my*
ls ?y_list*
vi
esc (default mode)
i (insert mode)
:q (just quit)
:q! (don’t save and quit)
:qw (write/save and quit)
grep and echo
head and tail
sed (stream editor)
(Default Mode)
(Insert Mode)
(Write/Save and Quit)
grep my_profile
grep ITU my_profile
echo my_profile
name=Emir
echo $name
head my_profile
tail my_profile
(Stream Editor)
Replacing or substituting string;
sed 's/ITU/ODTU/' my_profile
sed '5d' my_profile
touch my_bash_script.sh
vi my_bash_script.sh
x=5
y=3
echo $((x+y))
bash my_bash_script.sh
8
<my_new_dir>
)<my_new_dir>
(change your directory)<my_new_file>
)<my_new_file>
at the parent directory (move it)<my_new_file_2>
<my_new_dir>