CS2044 (Advanced Unix Tools), Spring 2010
MWF 12:20-1:10 PM, Hollister Hall 368
Course description
A focus on GNU Linux/Unix as a programming environment
for people with a basic knowledge of Linux/Unix and experience programming in
at least one language. Projects cover advanced shell scripts (bash)
Makefiles, and more modern scripting languages such as Perl and Python.
Students with little or no experience with Unix should take CS2042 first.
CS2044 is a four week, one credit, S/U only course. It runs
February 22 to March 19, 2010. The drop deadline is 3/1/10, one week
into the course. The course number is: 18550.
Instructor
- David Slater
- Email: dms236 + cornell.edu (replace + with @)
- Office hours: By Appointment Only
Grading and course policies
There will be no official textbook for this course; below you may find some books and websites that might be helpful. There are many books on this subject, so pick your favorite one. Feel free to contact me if you have any questions about this course.
There will be 3 homework assignments. You must complete all these assignments to pass this class. Please take a look at
Cornell University Code of Academic Integrity. Please
follow these guidelines when submitting your work.
Announcements
Most recent first:
- 2/22/2010: Welcome to Advanced UNIX! For those of you who
are curious to see what CS0242 UNIX Tools covers, please
take a look at the web pages for
2009,
2008,
2007, 2006, 2005 and 2004. In
the Advanced UNIX class you will study shell scripting in more
detail, and become familiar with writing scripts to automate everyday
tasks. The goal of this class is for you to become familiar with
writing scripts and gain experience by means of examples.
Lectures
- 2/22/2010 Lecture 1 Unix Basics
(all typos fixed hopefully)
- 2/24/2010 Lecture 2 Regular Expressions, Grep and Sed
- 2/26/2010 Lecture
3 Conditionals, Tests and Loops
- 3/1/2010 Lecture 4 How
The Bash Shell Works, Functions and Parameter Expansion
- 3/3/2010 Lecture 5 Grok
Gawk
- 3/5/2010 Lecture 6 Bash Arrays and Makefiles
- 3/8/2010 Lecture 7 Perl Basics
- 3/10/2010 Lecture
8 Perl Arrays and working with files.
- 3/12/2010 Lecture
9 Working with files in Perl and Associative Arrays
- 3/15/2010 Lecture
10 Perl Functions and an Intro to Python
- 3/17/2010 Lecture
11 More Python
Homework
- 2/22/2010 Questionnaire
Please complete the questionaire by class on friday and upload it and your script to CMS
- 2/26/2010
Homework
1 Due March 5th at 6pm on CMS. Please note that I have made a slight correction. Your script should print the lower bound of each bin not the upper bound. Here is a sample datafile. Here is the gnuplot setup script plot.gnu.
Here are solutions to check against for
solution1 and solution2.
- 3/8/2010 Homework
2
Due March 15th at 11:59pm on CMS.
- 3/7/2009 Homework
3 Due Sunday March 21th at 11:59PM
Very Useful links
- UNIX shells and scripts
- Perl
Useful books
- UNIX Shells by Example (2nd ed), E. Quigley,
Prentice
Hall,2000
- excellent presentation of all five
leading UNIX shells: C, Bourne, Korn, Bash, and tcsh; also covers three
main utilities in UNIX: grep (for searching), sed (for editing), and
awk (for scripting).
- UNIX in a Nutshell, A. Robbins, O'Reilly, 1999
- good general reference, contains alphabetized listing
of
core UNIX commands, and documentation on editors like Emacs, ex and vi,
among others
- Programming Perl (3rd ed), L. Wall, T.
Christiansen,
and
J. Orwant, O'Reilly, 2000
- the standard introduction to Perl
- Mastering Regular Expressions, J. Fried, O'Reilly,
1997
- in-depth presentation of the use of regular expressions
for
manipulating text and data; a special chapter is dedicated to Perl
All books are optional.
Miscellaneous
- 2/12/2008: One of the many links discussing scripting languages (WWW Journal, vol.2, spring '97)
- 2/12/2008: UNIX history as experienced by its creators: Dennis
Ritchie's
webpage