mirror of
https://github.com/spirit-x64/scripts.git
synced 2024-11-23 23:23:11 +03:00
27 lines
541 B
Bash
Executable File
27 lines
541 B
Bash
Executable File
{51da0bdcf2d1b673b28ad220a1cb5d388a23bf33 true 541 void-init.sh 0xc002be5810}
#!/bin/bash
|
|
|
|
if [ -z "$USERNAME" ]; then
|
|
USERNAME="spirit"
|
|
fi
|
|
|
|
cp /usr/share/xbps.d/*-repository-*.conf /etc/xbps.d/
|
|
|
|
xbps-install -Suy xbps
|
|
xbps-install -uy
|
|
xbps-install -y base-system
|
|
xbps-remove -y base-voidstrap
|
|
xbps-reconfigure -fa
|
|
|
|
useradd -m -G wheel -s /bin/bash $USERNAME
|
|
sed -i 's/# %wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers
|
|
|
|
xbps-install -y opendoas
|
|
bash -c "echo 'permit nopass $USERNAME as root' > /etc/doas.conf"
|
|
|
|
if [[ "$1" == "--wsl" ]]; then
|
|
cat <<EOF > /etc/wsl.conf
|
|
[user]
|
|
default=$USERNAME
|
|
EOF
|
|
fi
|