Update 2023-04-30 16:29 OpenBSD/amd64-mini

This commit is contained in:
c0dev0id 2023-04-30 16:29:32 +02:00
parent e827e6cb8f
commit 7f49658cb9
3 changed files with 88 additions and 1 deletions

BIN
.bin/cbar

Binary file not shown.

8
.kshrc
View File

@ -292,6 +292,12 @@ l() {
# cam
alias camformats="ffplay -f v4l2 -list_formats all -i /dev/video"
alias cam="ffplay -loglevel quiet -f v4l2 -input_format mjpeg -video_size 640x480 -i /dev/video"
setcam() {
_dev=$1
echo ln -sf /dev/video${_dev:=0} /dev/video
doas ln -sf /dev/video${_dev:=0} /dev/video
}
########################################################################
# EMAIL HANDLING
@ -523,7 +529,7 @@ ytdl_audio() {
# KSH COMPLETIONS
########################################################################
[ -f $HOME/.ksh-complete ] && . $HOME/.ksh-complete
#[ -f $HOME/.ksh-complete ] && . $HOME/.ksh-complete
########################################################################
# SCREEN CONFIGURATION

81
init.sh Executable file
View File

@ -0,0 +1,81 @@
#!/bin/sh
#
mkdir -p /tmp/init
# INSTALL SSH
if [ ! -d ~/.ssh ]
then
scp -r home.codevoid.de:.ssh ~/
fi
# INSTALL DOAS
if [ ! -f /etc/doas.conf ]
then
scp home.codevoid.de:/etc/doas.conf /tmp/init/
echo "Now enter root password and perform:"
echo "cp /tmp/init/doas.conf /etc/doas.conf; exit;"
/usr/bin/su
fi
# INSTALL SHELL
scp home.codevoid.de:.profile ~/
scp home.codevoid.de:.kshrc ~/
mkdir -p ~/.dev ~/.cache/mutt
touch ~/.dev/dir
# INSTALL CORE PACKAGES
doas pkg_add rsync-- vim--no_x11 git-- notion-- spectrwm-- hsetroot-- autocutsel-- dunst-- xclip-- \
wget-- lftp-- autorandr-- xautolock-- gnupg-- curl-- w3m-- universal-ctags-- \
mutt--gpgme password-store bwm-ng-- sysclean-- fzf--
# INIT DOTFILES
if [ ! -d ~/.cfg ]
then
git --no-replace-objects clone --bare --depth 1 _gitea@git.uugrn.org:sdk/dotfiles.git $HOME/.cfg
git --git-dir=${HOME}/.cfg/ --work-tree=${HOME} config --local status.showUntrackedFiles no
git --git-dir=${HOME}/.cfg/ --work-tree=${HOME} checkout -f
fi
# INIT X stuff
if [ ! -f ~/.xsession ]
then
scp home.codevoid.de:.xsession ~/
fi
if [ ! -d ~/.fonts ]
then
scp -r home.codevoid.de:.fonts ~/
fi
if [ ! -d ~/code ]
then
mkdir ~/code
scp -r home.codevoid.de:code/st ~/code/
scp -r home.codevoid.de:code/cbar ~/code/
cd ~/code/st && make && doas make install
cd ~/code/cbar && make && doas make install
fi
# INSTALL BIG PACKAGES
doas pkg_add chromium
echo -n "Is this a secure machine [y/N]?: "
read
case $REPLY in
[yY]) SECURE_ENV=Y; ;;
esac
if [ "$SECURE_ENV" == "Y" ]
then
if [ ! -d ~/.password-store ]
then
git clone sdk@home.codevoid.de:.password-store.git
fi
if [ ! -d ~/.gnupg ]
then
scp -r home.codevoid.de:.gnupg ~/
fi
fi