Skip to content
Snippets Groups Projects
Verified Commit 9b305a15 authored by mielimom02's avatar mielimom02
Browse files

feat(fugit): added fugit and fugitclean scripts for working with student repos

parent ed670e16
No related branches found
No related tags found
No related merge requests found
fugit.sh 0 → 100755
#!/bin/sh
if [ $# -gt 2 ]; then
printf "Usage: %s [branch] [reponame]" $(basename $0) >&2
printf "Default branch name will be read from comments.txt" >&2
printf "Default reponame will be npvp-exercises" >&2
exit 1
fi
if [ -z $2 ]; then
repo_name=`echo $PWD | sed 's/.*(\([a-z0-9]*\))$/\1/'`
repo_name="$repo_name/npvp-exercises"
else
repo_name=$2
fi
if [ -z $1 ]; then
# read branch name from comments.txt
branch_name=`cat comments.txt`
else
branch_name=$1
fi
`git clone -b $branch_name git@git.imp.fu-berlin.de:$repo_name git-solution`
#!/bin/sh
# this script cleans all checked out repositories when called from the same folder that contains the grades.csv
# or a singular checked out repo when called from within a student folder
find -type d \
-wholename "*/git-solution" -prune \
-execdir sh -c "rm -rf ./git-solution/" {} \;
#! /bin/sh #! /bin/sh
scripts="fixpdf.sh fucopy.sh fufixpdf.sh fuzip.sh fuxournalexport.sh" scripts="fixpdf.sh fucopy.sh fufixpdf.sh fuzip.sh fuxournalexport.sh fugit.sh fugitclean.sh"
destdir="${DESTDIR:=$HOME/.local/bin}" destdir="${DESTDIR:=$HOME/.local/bin}"
mkdir -p "$destdir" mkdir -p "$destdir"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment