fix: uncomment init

This commit is contained in:
manuel 2025-09-30 21:22:14 +08:00
parent 6be5cdb120
commit 2bad78fea9

View File

@ -29,8 +29,6 @@ systemcheck() {
# create a list of repos # create a list of repos
setup() { setup() {
# rm -f "$CONF"
if [ -e "$CONF" ]; then if [ -e "$CONF" ]; then
echo "WARNING: $CONF already exists!" echo "WARNING: $CONF already exists!"
read -n1 -p "Delete and continue, edit and exit, or exit? (d/e/X) " confwarn read -n1 -p "Delete and continue, edit and exit, or exit? (d/e/X) " confwarn
@ -38,7 +36,7 @@ setup() {
echo echo
case "$confwarn" in case "$confwarn" in
d) echo rm -f "$CONF" d) rm -f "$CONF"
;; ;;
e) sensible-editor "$CONF" e) sensible-editor "$CONF"
return return
@ -98,30 +96,30 @@ EOF
# clone all repos # clone all repos
init() { init() {
# for i in ${REPOS[@]}; do for i in ${REPOS[@]}; do
# git clone "$GITURL/$i" git clone "$GITURL/$i"
# done done
# echo "Set up: email, name, merge strategy, lfs" echo "Set up: email, name, merge strategy, lfs"
# # for bots use a different email address # for bots use a different email address
# read -p "Input the jaccount or bot account to use: " jaccount read -p "Input the jaccount or bot account to use: " jaccount
# if [ -n "${jaccount%bot-*}" ]; then if [ -n "${jaccount%bot-*}" ]; then
# email=$jaccount@sjtu.edu.cn email=$jaccount@sjtu.edu.cn
# else else
# email=$jaccount@focs.ji.sjtu.edu.cn email=$jaccount@focs.ji.sjtu.edu.cn
# fi fi
# read -p "Input your name: " name read -p "Input your name: " name
# for j in ${REPOS[@]/*\/}; do for j in ${REPOS[@]/*\/}; do
# cd $j cd $j
# git config user.email $email git config user.email $email
# git config user.name "$name" git config user.name "$name"
# git config pull.rebase true git config pull.rebase true
# git lfs install > /dev/null git lfs install > /dev/null
# cd .. cd ..
# done done
echo "Cloning JOJ repo" echo "Cloning JOJ repo"
if [ -d "${REPOS[0]%/*}-joj" ]; then if [ -d "${REPOS[0]%/*}-joj" ]; then