Linux Shell Commands - Tutorial 2


Change to your home directory:
	cd
Verify your current directory:
	pwd
Create a subdirectory to temporarily test some commands in:
	mkdir test
Change down a level into the test subdirectory:
	cd test
Download data.tar from the class web page into the current directory using a web browser, then verify it is present:
	ls
Display the contents of the archive file data.tar:
	tar -tf data.tar
Extract the contents of the archive file data.tar in the current directory:
	tar -xf data.tar
Change down a level into the data subdirectory created from the archive:
	cd data
See the files created from the archive:
	ls
Start an interactive gnuplot process:
	gnuplot
Change directory up a level:
	cd ..
Delete entire branch under 'data':
	rm -r data
Download superecho.c from the class web page into the current directory, then verify it is present:
	ls
Display the C source code file:
	cat superecho.c
Compile the C source code into an executable binary file:
	gcc superecho.c -o superecho
Try running the superecho program with some command line arguments:
	./superecho one two three
Check its exit code:
	echo $?
Try running the superecho program with more command line arguments:
	./superecho one two three four five
Check its exit code:
	echo $?
Delete everything here:
	rm *
Change directory up a level to the home directory:
	cd ..
Remove the test directory:
	rmdir test