Add a little script to configure a dev VM

I wrote that long ago for my packaging tutorial at RMLL, would probably
needs some fixing.
This commit is contained in:
François Revol 2016-10-20 01:04:37 +02:00
parent a37925696f
commit faf79e7f78

47
3rdparty/mmu_man/scripts/QuickConfig.sh vendored Executable file
View File

@ -0,0 +1,47 @@
#!/bin/sh
notice () {
notify --messageID QC$$ --type information \
--icon /boot/system/apps/Installer \
--title "Update" \
"$@"
echo "$@"
}
notice "Generating new SSH keys..."
SETTINGSSSHDIR=`finddir B_COMMON_SETTINGS_DIRECTORY`/ssh
hostKeyDir=${SETTINGSSSHDIR}
trash $hostKeyDir/ssh_host_*key*
/system/boot/post-install/sshd_keymaker.sh
notice "Please set your prefered locale…"
Locale
notice "Please set your prefered keymap…"
Keymap
notice "Please set your prefered editor…"
case `alert "Which editor do you want by default?" "Pe" "vim" "nano"` in
Pe)
echo 'export EDITOR=lpe' >> ~/.profile
;;
vim)
echo 'export EDITOR=vim' >> ~/.profile
;;
nano|*)
echo 'export EDITOR=nano' >> ~/.profile
;;
esac
notice "Please fill in your name and email address for git commits…"
EDITOR=lpe git config --global -e
notice "Please fill in your name and email address for packaging…"
lpe ~/config/settings/haikuports.conf