mirror of
https://github.com/BelfrySCAD/BOSL2.git
synced 2025-01-04 03:09:45 +00:00
0666f6482c
* Fixed ShellCheck.net warnings, including * exit -1: https://github.com/koalaman/shellcheck/wiki/SC2242 * cd || exit: https://github.com/koalaman/shellcheck/wiki/SC2164 * "$foo": https://github.com/koalaman/shellcheck/wiki/SC2086 * $(( $foo )): https://github.com/koalaman/shellcheck/wiki/SC2004 * grep | wc -l: https://github.com/koalaman/shellcheck/wiki/SC2126 * Use arrays instead of unquoted strings for loops and command arguments * Use (( ... )) arithmetic context instead of string comparisons * Use bash's built-in regex support instead of grep+sed+awk * Write errors to stderr
15 lines
339 B
Bash
Executable file
15 lines
339 B
Bash
Executable file
#!/bin/bash
|
|
|
|
if [[ ! -d BOSL2.wiki/.git ]] ; then
|
|
echo "Must be run from above the BOSL2.wiki repo." >&2
|
|
exit 1
|
|
fi
|
|
|
|
set -e # short-circuit if any command fails
|
|
cd BOSL2.wiki
|
|
rm -rf .git
|
|
git init
|
|
git add .
|
|
git commit -m "Purged wiki history."
|
|
git remote add origin git@github.com:revarbat/BOSL2.wiki.git
|
|
git push -u --force origin master
|