D2L Logo

At MSU we use Desire to Learn for our classroom content management system. Students can go to D2L to get their assignments and turn in their assignments though the D2L dropbox.

When grading, I can download all of the student's submissions into a zip file such as the following:

Part 1 - Software Evaluation Download Mar 23, 2019 609 AM.zip

HW1 - Matrix Transpose Download Feb 2, 2019 1001 AM.zip

If this folder is unzipped files similar to the following will appear:

323771-372818 - Sam Smith - Jan 21, 2019 652 PM - submission.tgz
325034-372818 - Nan Carpenter - Jan 21, 2019 330 PM - 1d wave eqn.pages
325034-372818 - Nan Carpenter - Jan 21, 2019 330 PM - wave1d.py
331582-372818 - Joe Taylor - Jan 19, 2019 315 PM - HW1.ipynb
331582-372818 - Joe Taylor - Jan 19, 2019 315 PM - HW1_report.pdf
331582-372818 - Joe Taylor - Jan 19, 2019 315 PM - short.mp4
331582-372818 - Joe Taylor - Jan 19, 2019 320 PM - HW1.tgz

For many of the topics we cover (mostly programming) these filenames are not easy to use. In my classes student often submit files that need to work together with given file names (everything after the final dash). I wrote the following program to convert the directory of complex filenames into folders. A separate folder for each student with the files in the folder:

#!/bin/bash
files=`ls`
find . -iname "*" | while read file
do
        echo $file
        folder=`echo $file | cut -d "-" -f 3 | xargs`
        echo "creating folder $folder"
        mkdir -p "$folder"
        newname=`echo $file | cut -d "-" -f5- | xargs`
        echo "Renaming to $newname"
        mv "$file" "./$folder/$newname"
done
Sam Smith
Nan Carpenter
Joe Taylor

Each directory contains that student's files. For example the Joe Taylor folder will have:

HW1.ipynb
HW1_report.pdf
short.mp4
HW1.tgz

I hope you find this script useful.


Planning a new Course

Sun 10 June 2018 by Dr. Dirk Colbry

This post describes a technique I use to plan an organize a course from scratch. I learned this technique from Dr. Brian O'Shea.

At Michigan State University (MSU) my official title is curriculum specialist. I have the unique opportunity to help develop entirely new courses for a brand new department …

read more

White Noise and Teaching

Wed 23 May 2018 by Dr. Dirk Colbry

It can be difficult to be the first student to talk in a quite classroom. I have been experimenting with the use of white noise to raise the overall din in the room and encourage taking more quickly.

When I teach I try to encourage peer and group discussions. Activities …

read more