Skip to content

Instantly share code, notes, and snippets.

@mattuu
mattuu / pre-commit.sh
Created June 25, 2019 11:49 — forked from akfish/pre-commit.sh
Run MSBuild and MSTest for C# project from git pre-commit hook
#!/bin/sh
# Helper
safeRunCommand() {
typeset cmd="$*"
typeset ret_code
echo cmd=$cmd
eval $cmd
ret_code=$?