UNIX-1.11 zip, basename, mktemp, script and rcs commands


Make sure to subscribe to my channel for more videos on UNIX, Perl and SQL.
facebook: facebook.com/fuzicast
twitter: @fuzicast
youtube: youtube.com/yuejdesigner85

zip -r filename.zip file1 file2 file3 – zip and compress files, recursively
unzip filename.zip – unzip a zip file
rmdir dirname – remove empty directory
basename fullpath – returns the file or directory name
dirname fullpath – returns the directory
mktemp – creates a temporary file and outputs temp filename
factor number – list the factors of a number
script -a script.out – starts recording your output screen, ctrl+D to stop recording
kill %% – kills previous command
sudo apt-get install rcs – to install linux revision control system (RCS)
mkdir RCS – create a directory called RCS to store all versions of file
ci script.sh – checks in a file, file is not readable until checked out
ci -u script.sh – checks in a file, file is visible for others to read
co -l script.sh – checks out a file, holds the lock.
co -lr1.1 script.sh – checks out a version of file, holds the lock
rcsdiff script.sh – compares current file with latest checked in version
rcsdiff -r1.1 -r1.2 script.sh – compares version 1.1 and 1.2
which command – tells you where such command resides in
locate keyword – searches for files or paths that contains keyword (that are accessible to you)

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s