Monday, 01/26/2026

🧳 Affirm due!


⏰ Meetings

  • 08:00 😧 Dr. Joseph Worischeck
  • 08:00 🏋️ Workout with Kassidy
  • 10:00 Office Hours
  • 12:00 CIS238RH (30361)
  • 17:45 CLD120 (26372)

📋 Tasks

  • Pay Affirm #money #todo
  • Check this weeks slide's. #cis238rh #cis238rh #todo
    • Proofread. #todo
    • Remove lab? #todo
  • Import grades. #cld110 #cld120 #todo
  • Check Canvas for accuracy. #cis126rh #cis238rh #cld110 #cld120
  • Print Attendance. #cis238rh #todo
  • Link next to next chapter slides. See CIS126RH. #cis238rh #todo

CIS238RH (30361)

  • Preview next class.
  • /etc/crontab
  • Increase size of GNOME desktop.
  • Lab: Analyze and Store Logs
  • Ignore labs in slides.

Retrieval Practice

  1. Create an empty file in students home directory named hello.sh.
  2. Make the file executable.
  3. Demonstrate the which ls command. What does the results of that command show you?
  4. Now try the which command with hello.sh. How is the output different?
  5. Move hello.sh into ~/bin. Create the directory if needed.
  6. Again, run which hello.sh.
  7. Explain why the output is different from the first time.

Guided Exercise: Match Text with Regular Expressions

  • Demo search (/) in Vim.

Lab: Shell Scripting

  • 1.3 Close Vim to make script executable or move Step 1.3 to after you create the script.
  • 2.1 Copy and paste
  • Explain what each step of the script does. #AI
  • :set number
  • ls -l will confirm that the script is executable.
🛠 Script Explained

Below is a step-by-step explanation of what this Bash script does and how each part works.

Shebang line

bash
#!/usr/bin/bash
  1. This line tells the operating system to run the script using the Bash shell located at /usr/bin/bash.
  2. When the script is executed, Bash interprets and runs each command in order.

    Variable definitions

    USER='student'
    PREFIX='/home/student/output'
    

  3. Each output file will be created in /home/student/ and will start with the name output.
  4. Using variables makes the script easier to read and modify. For example, changing the username or output directory requires editing only one line.

    The for loop

    for SERVER in servera serverb; do
    

  5. This loop iterates over two hostnames: servera and serverb.
  6. During the first iteration, `SERVER` is set to servera.
  7. During the second iteration, `SERVER` is set to serverb.
  8. The commands inside the loop run once for each server.

Tags

  • money
  • todo
  • cis238rh
  • cld110
  • cld120
  • cis126rh
  • ai