configuration/local/bin/subgit-symlinks
2022-01-04 00:25:10 +01:00

15 lines
291 B
Bash
Executable File

#!/bin/sh
# lines of form:
# Givenname Last Name (student number) <email address>
LIST="${LIST:-$HOME/.local/share/students.list}"
while read line; do
name="${line% (*}"
number="${line%) *}"
number="${number#* (}"
if [ -e "$number" ]; then
ln -s "$number" "$name"
fi
done < "$LIST"