Tuesday, April 26, 2011

Bash Scripting Homework - Extra Credit

This assignment is for extra credit and due by Friday, April 29th at 5:00 pm 10:00 am.  (Correction for when grades are due)

Write a bash script to correct typos in file names.  It should take two arguments - the first is the typo and the second is the correction.  It should replace all instances of the typo with the correction in the file names in the current directory.  If only one argument is supplied, then it should simply delete the typo from the file names.  If either zero or more than two arguments are supplied, the script should output a message alerting the user that the script requires 1 or 2 arguments.

Save this script as bash_extra.sh and email it to the instructor.

Thursday, March 31, 2011

Wednesday, March 16, 2011

sed and awk Homework

Here is the homework over sed and awk, due next class:

Here are two files that you will need to complete the homework:

Tuesday, March 15, 2011

Lecture - sed and awk

Here is the lecture over sed and awk:

Here are a couple of links with more background information in case you're curious:

Wednesday, February 9, 2011

Bash Part 2 and Vi/Vim Homework

Here is this week's homework and associated file:

I realized that in the lecture notes, I forgot to go over how you save and how you close out of a file in Vi/Vim.  From command mode, use the following
  • :w - this will save the current file
  • :w filename - this will save the current file with the name "filename"
  • :q - this will quit Vi/Vim
  • :q!  - this will quit Vi/Vim discarding any changes to the document
  • :wq - this will save and quit the current document
Also, I think there was a typo on the lecture slides, and until I get a chance to fix it, here's a correction.  The find/replace (or substitute) command needs to begin with a colon ( : ) character.  For example, replacing every letter a with the letter b in a file would be done as:
  • :%s/a/b/g

Tuesday, February 8, 2011

Lecture - Bash part 2 and vi/vim

Sorry for the super late notes, but I was fixing the projector for class.  Here are the notes.  I'll post links with more information later.

Tuesday, January 25, 2011

Bash Homework

Today, also marks the first homework assignment for the class.  Homework is due by the beginning of class February 1, 2011.  Here is the link to the homework assignment:

Bash Lab

Today is the first day that we will be in the lab and actually playing with a live Linux environment.  Here is the link to the lab assignment:

Monday, January 24, 2011

Lecture - Bash part 1

Here is the link to the first lecture on Bash (this time with ink-saving white background!):
Here are a few good sites for further reading on Bash:

Monday, January 17, 2011

First Lecture

Here are links to the lecture slides.  Hopefully, we'll get through them in the first class:

Here are a couple of good links to go with the File System slides:

First Post

And so begins the blog of the CS399 - Linux class for the Spring 2011 semester at Blackburn College.  Meeting on Tuesdays from 6:30 - 7:20 pm.  Here you'll be able to find links to lecture notes, assignments, and all things Linux.