mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-19 19:40:37 +02:00
Compare commits
22 commits
7d508b346d
...
ef8571cb2e
Author | SHA1 | Date | |
---|---|---|---|
|
ef8571cb2e | ||
|
35e2366048 | ||
|
c591f7b3c0 | ||
|
ad11d0cb1d | ||
|
b0958b381a | ||
|
202f1a5d35 | ||
|
00d0f56d75 | ||
|
39038b50bd | ||
|
2d424131de | ||
|
a87a520f59 | ||
|
31a3c273f6 | ||
|
de7f5316dc | ||
|
fef5778952 | ||
|
78bdf17c4a | ||
|
9f7db9ccc6 | ||
|
02b51a027f | ||
|
94d91f9ff2 | ||
|
89cf17422c | ||
|
cb916838b2 | ||
|
f2a736bf27 | ||
|
b8be637d0b | ||
|
6d667c55de |
12 changed files with 169 additions and 217 deletions
115
usr/bin/archboot-launcher.sh
Executable file
115
usr/bin/archboot-launcher.sh
Executable file
|
@ -0,0 +1,115 @@
|
|||
#!/usr/bin/env bash
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
# written by Tobias Powalowski <tpowa@archlinux.org>
|
||||
_ANSWER="/tmp/.launcher"
|
||||
_RUNNING_ARCH="$(uname -m)"
|
||||
_TITLE="Archboot ${_RUNNING_ARCH} | Arch Linux Setup | Launcher"
|
||||
# _dialog()
|
||||
# an el-cheapo dialog wrapper
|
||||
#
|
||||
# parameters: see dialog(1)
|
||||
# returns: whatever dialog did
|
||||
_dialog() {
|
||||
dialog --backtitle "${_TITLE}" --aspect 15 "$@"
|
||||
return $?
|
||||
}
|
||||
|
||||
_dolauncher() {
|
||||
_dialog --title " Main Menu " --menu "" 9 40 5 \
|
||||
"1" "Launch Archboot Setup" \
|
||||
"2" "Launch Desktop Environment" \
|
||||
"3" "Exit Program" 2>${_ANSWER}
|
||||
case $(cat ${_ANSWER}) in
|
||||
"1")
|
||||
[[ -e /tmp/.launcher-running ]] && rm /tmp/.launcher-running
|
||||
setup
|
||||
exit 0 ;;
|
||||
"2")
|
||||
_LAUNCHER=""
|
||||
update | grep -q Gnome && _LAUNCHER="${_LAUNCHER} GNOME Gnome"
|
||||
update | grep -q KDE && _LAUNCHER="${_LAUNCHER} PLASMA KDE/Plasma"
|
||||
update | grep -q Sway && _LAUNCHER="${_LAUNCHER} SWAY Sway"
|
||||
update | grep -q Xfce && _LAUNCHER="${_LAUNCHER} XFCE Xfce"
|
||||
_ABORT=""
|
||||
if [[ -n "${_LAUNCHER}" ]]; then
|
||||
_dialog --title " Desktop Menu " --menu "" 10 30 6 ${_LAUNCHER} 2>${_ANSWER} || _ABORT=1
|
||||
else
|
||||
_dialog --msgbox "Error:\nNo Desktop Environments available." 0 0
|
||||
_ABORT=1
|
||||
fi
|
||||
[[ -e /tmp/.launcher-running ]] && rm /tmp/.launcher-running
|
||||
if [[ -n "${_ABORT}" ]]; then
|
||||
clear
|
||||
exit 1
|
||||
fi
|
||||
_EXIT="$(cat ${_ANSWER})"
|
||||
if [[ "${_EXIT}" == "GNOME" ]]; then
|
||||
if _dialog --defaultno --yesno "Gnome Desktop:\nDo you want to use the Wayland Backend?" 6 45; then
|
||||
clear
|
||||
update -gnome-wayland
|
||||
else
|
||||
clear
|
||||
update -gnome
|
||||
fi
|
||||
elif [[ "${_EXIT}" == "PLASMA" ]]; then
|
||||
if _dialog --defaultno --yesno "KDE/Plasma Desktop:\nDo you want to use the Wayland Backend?" 6 45; then
|
||||
clear
|
||||
update -plasma-wayland
|
||||
else
|
||||
clear
|
||||
update -plasma
|
||||
fi
|
||||
elif [[ "${_EXIT}" == "SWAY" ]]; then
|
||||
clear
|
||||
update -sway
|
||||
elif [[ "${_EXIT}" == "XFCE" ]]; then
|
||||
clear
|
||||
update -xfce
|
||||
fi
|
||||
exit 0
|
||||
;;
|
||||
"3")
|
||||
#shellcheck disable=SC2086
|
||||
_dialog --title " EXIT MENU " --menu "" 9 30 5 \
|
||||
"1" "Exit Program" \
|
||||
"2" "Reboot System" \
|
||||
"3" "Poweroff System" 2>${_ANSWER}
|
||||
_EXIT="$(cat ${_ANSWER})"
|
||||
if [[ "${_EXIT}" == "1" ]]; then
|
||||
return 0
|
||||
elif [[ "${_EXIT}" == "2" ]]; then
|
||||
_dialog --infobox "Rebooting in 10 seconds...\nDon't forget to remove the boot medium!" 4 50
|
||||
sleep 10
|
||||
clear
|
||||
reboot
|
||||
elif [[ "${_EXIT}" == "3" ]]; then
|
||||
_dialog --infobox "Powering off in 10 seconds...\nDon't forget to remove the boot medium!" 4 50
|
||||
sleep 10
|
||||
clear
|
||||
poweroff
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
if _dialog --yesno "Abort Program?" 6 40; then
|
||||
return 1
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
if [[ -e /tmp/.launcher-running ]]; then
|
||||
echo "launcher already runs on a different console!"
|
||||
echo "Please remove /tmp/.launcher-running first to launch launcher!"
|
||||
exit 1
|
||||
fi
|
||||
: >/tmp/.launcher
|
||||
: >/tmp/.launcher-running
|
||||
if ! _dolauncher; then
|
||||
[[ -e /tmp/.launcher-running ]] && rm /tmp/.launcher-running
|
||||
clear
|
||||
exit 1
|
||||
fi
|
||||
[[ -e /tmp/.launcher-running ]] && rm /tmp/.launcher-running
|
||||
clear
|
||||
exit 0
|
||||
# vim: set ts=4 sw=4 et:
|
0
usr/bin/archboot-net.sh → usr/bin/archboot-network.sh
Normal file → Executable file
0
usr/bin/archboot-net.sh → usr/bin/archboot-network.sh
Normal file → Executable file
|
@ -12,7 +12,6 @@
|
|||
. /usr/lib/archboot/installer/btrfs.sh
|
||||
. /usr/lib/archboot/installer/configuration.sh
|
||||
. /usr/lib/archboot/installer/mountpoints.sh
|
||||
. /usr/lib/archboot/installer/network.sh
|
||||
. /usr/lib/archboot/installer/pacman.sh
|
||||
. /usr/lib/archboot/installer/partition.sh
|
||||
. /usr/lib/archboot/installer/storage.sh
|
||||
|
|
|
@ -150,10 +150,10 @@ _configure_vconsole() {
|
|||
}
|
||||
|
||||
_configure_network() {
|
||||
if [[ -e /usr/bin/net ]]; then
|
||||
net && _NEXTITEM="2"
|
||||
elif [[ -e /usr/bin/archboot-net.sh ]]; then
|
||||
archboot-tz.sh && _NEXTITEM="2"
|
||||
if [[ -e /usr/bin/network ]]; then
|
||||
network && _NEXTITEM="2"
|
||||
elif [[ -e /usr/bin/archboot-network.sh ]]; then
|
||||
archboot-network.sh && _NEXTITEM="2"
|
||||
else
|
||||
_dialog --msgbox "Error:\nnet script not found, aborting network configuration" 0 0
|
||||
fi
|
||||
|
@ -205,7 +205,7 @@ _prepare_storagedrive() {
|
|||
fi
|
||||
_CANCEL=""
|
||||
#shellcheck disable=SC2086
|
||||
dialog ${_DEFAULT} --backtitle "${_TITLE}" --menu "Prepare Storage Device" 12 60 5 \
|
||||
_dialog ${_DEFAULT} --menu "Prepare Storage Device" 12 60 5 \
|
||||
"1" "Quick Setup (erases the ENTIRE storage device)" \
|
||||
"2" "Partition Storage Device" \
|
||||
"3" "Manage Software Raid, LVM2 And LUKS Encryption" \
|
||||
|
@ -300,7 +300,7 @@ _mainmenu() {
|
|||
_DEFAULT="--default-item 3"
|
||||
fi
|
||||
#shellcheck disable=SC2086
|
||||
dialog ${_DEFAULT} --backtitle "${_TITLE}" --title " MAIN MENU " \
|
||||
_dialog ${_DEFAULT} --title " MAIN MENU " \
|
||||
--menu "Use the UP and DOWN arrows to navigate menus.\nUse TAB to switch between buttons and ENTER to select." 17 58 14 \
|
||||
"0" "Configure Console" \
|
||||
"1" "Configure Network" \
|
||||
|
@ -350,7 +350,7 @@ _mainmenu() {
|
|||
_install_bootloader ;;
|
||||
"8")
|
||||
#shellcheck disable=SC2086
|
||||
dialog --backtitle "${_TITLE}" --title " EXIT MENU " --menu "" 9 30 5 \
|
||||
_dialog --title " EXIT MENU " --menu "" 9 30 5 \
|
||||
"1" "Exit Program" \
|
||||
"2" "Reboot System" \
|
||||
"3" "Poweroff System" 2>${_ANSWER}
|
||||
|
@ -365,7 +365,7 @@ _mainmenu() {
|
|||
echo "to restart the system."
|
||||
echo ""
|
||||
fi
|
||||
exit 0
|
||||
exit 0
|
||||
elif [[ "${_EXIT}" == "2" ]]; then
|
||||
_dialog --infobox "Rebooting in 10 seconds...\nDon't forget to remove the boot medium!" 4 50
|
||||
sleep 10
|
||||
|
|
|
@ -1,182 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
# created by Tobias Powalowski <tpowa@archlinux.org>
|
||||
_net_interfaces() {
|
||||
find /sys/class/net/* -type l ! -name 'lo' -printf '%f ' -exec cat {}/address \;
|
||||
}
|
||||
|
||||
_check_network() {
|
||||
if [[ -z "${_S_NET}" ]]; then
|
||||
_donetwork
|
||||
fi
|
||||
}
|
||||
|
||||
_essid_scan() {
|
||||
# scan the area
|
||||
iwctl station "${_INTERFACE}" scan
|
||||
# only show lines with signal '*'
|
||||
# kill spaces from the end and replace spaces with + between
|
||||
# '+' character is one of 6 forbidden characters in SSID standard
|
||||
for dev in $(iwctl station "${_INTERFACE}" get-networks | grep '\*' | cut -c 1-41 | sed -e 's|\ *.$||g' -e 's|^.*\ \ ||g' -e 's| |\+|g'); do
|
||||
echo "${dev}"
|
||||
[[ "${1}" ]] && echo "${1}"
|
||||
done
|
||||
}
|
||||
|
||||
_do_wireless() {
|
||||
_WLAN_HIDDEN=""
|
||||
_WLAN_SSID=""
|
||||
_WLAN_KEY=""
|
||||
_WLAN_AUTH=""
|
||||
if [[ "${_CONNECTION}" == "wireless" ]]; then
|
||||
# disconnect the interface first!
|
||||
iwctl station "${_INTERFACE}" disconnect &>"${_NO_LOG}"
|
||||
# clean old keys first!
|
||||
rm -f /var/lib/iwd/* &>"${_NO_LOG}"
|
||||
#shellcheck disable=SC2086,SC2046
|
||||
_dialog --menu "Choose your SSID:\n(Empty spaces in your SSID are replaced by '+' char)" 14 60 7 \
|
||||
$(_essid_scan _) \
|
||||
"Hidden" "_" 2>"${_ANSWER}" || return 1
|
||||
_WLAN_SSID=$(cat "${_ANSWER}")
|
||||
_WLAN_CONNECT="connect"
|
||||
if [[ "${_WLAN_SSID}" == "Hidden" ]]; then
|
||||
_dialog --inputbox "Enter the hidden SSID:" 8 65 \
|
||||
"secret" 2>"${_ANSWER}" || return 1
|
||||
_WLAN_SSID=$(cat "${_ANSWER}")
|
||||
_WLAN_CONNECT="connect-hidden"
|
||||
_WLAN_HIDDEN=1
|
||||
fi
|
||||
# replace # with spaces again
|
||||
#shellcheck disable=SC2001,SC2086
|
||||
_WLAN_SSID="$(echo ${_WLAN_SSID} | sed -e 's|\+|\ |g')"
|
||||
#shellcheck disable=SC2001,SC2086
|
||||
while [[ -z "${_WLAN_AUTH}" ]]; do
|
||||
# expect hidden network has a WLAN_KEY
|
||||
#shellcheck disable=SC2143
|
||||
if ! [[ "$(iwctl station "${_INTERFACE}" get-networks | grep -w "${_WLAN_SSID}" | cut -c 42-49 | grep -q 'open')" ]] || [[ "${_WLAN_CONNECT}" == "connect-hidden" ]]; then
|
||||
_dialog --inputbox "Enter your KEY for SSID='${_WLAN_SSID}'" 8 50 "SecretWirelessKey" 2>"${_ANSWER}" || return 1
|
||||
_WLAN_KEY=$(cat "${_ANSWER}")
|
||||
fi
|
||||
# time to connect
|
||||
_dialog --infobox "Connection to SSID='${_WLAN_SSID}' with interface ${_INTERFACE}..." 3 70
|
||||
_printk off
|
||||
if [[ -z "${_WLAN_KEY}" ]]; then
|
||||
iwctl station "${_INTERFACE}" "${_WLAN_CONNECT}" "${_WLAN_SSID}" &>"${_NO_LOG}" && _WLAN_AUTH=1
|
||||
else
|
||||
iwctl --passphrase="${_WLAN_KEY}" station "${_INTERFACE}" "${_WLAN_CONNECT}" "${_WLAN_SSID}" &>"${_NO_LOG}" && _WLAN_AUTH=1
|
||||
fi
|
||||
if [[ -n "${_WLAN_AUTH}" ]]; then
|
||||
_dialog --infobox "Authentification was successful. Continuing in 5 seconds..." 3 70
|
||||
sleep 5
|
||||
else
|
||||
_dialog --msgbox "Error:\nAuthentification failed. Please configure again!" 6 60
|
||||
fi
|
||||
_printk on
|
||||
done
|
||||
fi
|
||||
}
|
||||
|
||||
_donetwork() {
|
||||
_S_NET=""
|
||||
_NETPARAMETERS=""
|
||||
while [[ -z "${_NETPARAMETERS}" ]]; do
|
||||
# select network interface
|
||||
_INTERFACE=""
|
||||
_INTERFACES=$(_net_interfaces)
|
||||
while [[ -z "${_INTERFACE}" ]]; do
|
||||
#shellcheck disable=SC2086
|
||||
_dialog --ok-label "Select" --menu "Select a network interface:" 12 40 6 ${_INTERFACES} 2>"${_ANSWER}"
|
||||
case $? in
|
||||
1) return 1 ;;
|
||||
0) _INTERFACE=$(cat "${_ANSWER}") ;;
|
||||
esac
|
||||
done
|
||||
echo "${_INTERFACE}" >/tmp/.network-interface
|
||||
# iwd renames wireless devices to wlanX
|
||||
if echo "${_INTERFACE}" | grep -q wlan; then
|
||||
_CONNECTION="wireless"
|
||||
else
|
||||
_CONNECTION="ethernet"
|
||||
fi
|
||||
# profile name
|
||||
_NETWORK_PROFILE=""
|
||||
_dialog --inputbox "Enter your network profile name:" 7 40 "${_INTERFACE}-${_CONNECTION}" 2>"${_ANSWER}" || return 1
|
||||
_NETWORK_PROFILE=/etc/systemd/network/$(cat "${_ANSWER}").network
|
||||
# wifi setup first
|
||||
_do_wireless || return 1
|
||||
# dhcp switch
|
||||
_IP=""
|
||||
_dialog --yesno "Do you want to use DHCP?" 5 40
|
||||
#shellcheck disable=SC2181
|
||||
if [[ $? -eq 0 ]]; then
|
||||
_IP="dhcp"
|
||||
_IPADDR=""
|
||||
_GW=""
|
||||
_DNS=""
|
||||
else
|
||||
_IP="static"
|
||||
_dialog --inputbox "Enter your IP address and netmask:" 8 40 "192.168.1.23/24" 2>"${_ANSWER}" || return 1
|
||||
_IPADDR=$(cat "${_ANSWER}")
|
||||
_dialog --inputbox "Enter your gateway:" 8 40 "192.168.1.1" 2>"${_ANSWER}" || return 1
|
||||
_GW=$(cat "${_ANSWER}")
|
||||
_dialog --inputbox "Enter your DNS server IP:" 8 40 "192.168.1.1" 2>"${_ANSWER}" || return 1
|
||||
_DNS=$(cat "${_ANSWER}")
|
||||
fi
|
||||
# http/ftp proxy settings
|
||||
_dialog --inputbox "Enter your proxy server, for example:\nhttp://name:port\nhttp://ip:port\nhttp://username:password@ip:port\n\n Leave the field empty if no proxy is needed to install." 13 65 "" 2>"${_ANSWER}" || return 1
|
||||
_PROXY=$(cat "${_ANSWER}")
|
||||
_PROXIES="http_proxy https_proxy ftp_proxy rsync_proxy HTTP_PROXY HTTPS_PROXY FTP_PROXY RSYNC_PROXY"
|
||||
_dialog --yesno "Are these settings correct?\n\nInterface: ${_INTERFACE}\nConnection: ${_CONNECTION}\nNetwork profile: ${_NETWORK_PROFILE}\nSSID: ${_WLAN_SSID}\nHidden: ${_WLAN_HIDDEN}\nKey: ${_WLAN_KEY}\ndhcp or static: ${_IP}\nIP address: ${_IPADDR}\nGateway: ${_GW}\nDNS server: ${_DNS}\nProxy setting: ${_PROXY}" 0 0
|
||||
case $? in
|
||||
1) ;;
|
||||
0) _NETPARAMETERS=1 ;;
|
||||
esac
|
||||
done
|
||||
# write systemd-networkd profile
|
||||
echo "#$_NETWORK_PROFILE generated by archboot setup" > "${_NETWORK_PROFILE}"
|
||||
#shellcheck disable=SC2129
|
||||
echo "[Match]" >> "${_NETWORK_PROFILE}"
|
||||
echo "Name=${_INTERFACE}" >> "${_NETWORK_PROFILE}"
|
||||
echo "" >> "${_NETWORK_PROFILE}"
|
||||
echo "[Network]" >> "${_NETWORK_PROFILE}"
|
||||
[[ "${_IP}" == "dhcp" ]] && echo "DHCP=yes" >> "${_NETWORK_PROFILE}"
|
||||
if [[ "${_CONNECTION}" == "wireless" ]]; then
|
||||
#shellcheck disable=SC2129
|
||||
echo "IgnoreCarrierLoss=3s" >>"${_NETWORK_PROFILE}"
|
||||
fi
|
||||
if [[ "${_IP}" == "static" ]]; then
|
||||
#shellcheck disable=SC2129
|
||||
echo "Address=${_IPADDR}" >>"${_NETWORK_PROFILE}"
|
||||
echo "Gateway=${_GW}" >>"${_NETWORK_PROFILE}"
|
||||
echo "DNS=${_DNS}" >>"${_NETWORK_PROFILE}"
|
||||
fi
|
||||
# set proxies
|
||||
if [[ -z "${_PROXY}" ]]; then
|
||||
for i in ${_PROXIES}; do
|
||||
unset "${i}"
|
||||
done
|
||||
else
|
||||
for i in ${_PROXIES}; do
|
||||
export "${i}"="${_PROXY}"
|
||||
done
|
||||
fi
|
||||
if [[ -e /etc/systemd/network/10-wired-auto-dhcp.network ]]; then
|
||||
echo "Disabled Archboot's bootup wired auto dhcp browsing." >"${_LOG}"
|
||||
rm /etc/systemd/network/10-wired-auto-dhcp.network
|
||||
fi
|
||||
echo "Using setup's network profile ${_NETWORK_PROFILE} now..." >"${_LOG}"
|
||||
systemctl restart systemd-networkd
|
||||
systemctl restart systemd-resolved
|
||||
_dialog --infobox "Waiting for network link to come up..." 3 60
|
||||
# add sleep here for systemd-resolve get correct values
|
||||
sleep 5
|
||||
if ! getent hosts www.google.com &>"${_LOG}"; then
|
||||
_dialog --msgbox "Error:\nYour network is not working correctly, please configure again!" 6 70
|
||||
return 1
|
||||
fi
|
||||
_dialog --infobox "Link is up. Continuing in 5 seconds..." 3 60
|
||||
sleep 5
|
||||
_NEXTITEM="2"
|
||||
_S_NET=1
|
||||
}
|
||||
# vim: set ft=sh ts=4 sw=4 et:
|
|
@ -85,7 +85,7 @@ _enter_shell() {
|
|||
[[ -z $TTY ]] && TTY=$(tty)
|
||||
# dbus sources profiles again
|
||||
if ! echo "${TTY}" | grep -q pts; then
|
||||
echo -e "Hit \e[1m\e[92mENTER\e[m for \e[1mshell\e[m login."
|
||||
echo -e "Hit \e[1m\e[92mENTER\e[m for \e[1mlogin\e[m routine."
|
||||
cd /
|
||||
read -r
|
||||
clear
|
||||
|
@ -149,8 +149,8 @@ if ! [[ -e /.vconsole-run ]]; then
|
|||
else
|
||||
SIZE="16"
|
||||
fi
|
||||
echo KEYMAP=us > /etc/vconsole.conf
|
||||
echo FONT=ter-v${SIZE}n >> /etc/vconsole.conf
|
||||
echo KEYMAP=us >/etc/vconsole.conf
|
||||
echo FONT=ter-v${SIZE}n >>/etc/vconsole.conf
|
||||
systemctl restart systemd-vconsole-setup
|
||||
fi
|
||||
if ! [[ -e /.clean-pacman-db ]]; then
|
||||
|
@ -178,23 +178,34 @@ fi
|
|||
|
||||
if [[ -e /usr/bin/setup ]]; then
|
||||
_local_mode
|
||||
# wait on user interaction!
|
||||
_enter_shell
|
||||
# basic setup
|
||||
# basic environment setup:
|
||||
# glibc locale, vconsole, network, clock
|
||||
if ! [[ -e /tmp/.locale ]]; then
|
||||
archboot-locale.sh
|
||||
source /etc/locale.conf
|
||||
fi
|
||||
if ! [[ -e /tmp/.keymap ]]; then
|
||||
km && : > /tmp/.keymap
|
||||
km && : >/tmp/.keymap
|
||||
fi
|
||||
if ! [[ -e /tmp/.network && -e /var/cache/pacman/pkg/archboot.db ]]; then
|
||||
net && : > /tmp/.network
|
||||
if [[ ! -e /tmp/.network && ! -e "${_CACHEDIR}/archboot.db" ]]; then
|
||||
network && : >/tmp/.network
|
||||
fi
|
||||
if ! [[ -e /tmp/.timezone ]]; then
|
||||
tz && : >/tmp/.timezone
|
||||
fi
|
||||
if ! [[ -e /tmp/.setup ]]; then
|
||||
setup
|
||||
# switch for setup or launcher
|
||||
if [[ -e "${_CACHEDIR}/archboot.db" ]]; then
|
||||
if [[ ! -e /tmp/.setup ]]; then
|
||||
# run setup on local medium once!
|
||||
setup
|
||||
fi
|
||||
else
|
||||
# run launcher on latest/normal medium once!
|
||||
if [[ ! -e /tmp/.launcher ]]; then
|
||||
launcher
|
||||
fi
|
||||
fi
|
||||
# latest image, fail if less than 2GB RAM available
|
||||
elif [[ "$(grep -w MemTotal /proc/meminfo | cut -d ':' -f2 | sed -e 's# ##g' -e 's#kB$##g')" -lt 1970000 ]]; then
|
||||
|
|
|
@ -10,7 +10,7 @@ _start_sway() {
|
|||
echo -e "Launching \e[1mSway\e[m now, logging is done on \e[1m/dev/tty7\e[m..."
|
||||
echo -e "To relaunch \e[1mSway\e[m use: \e[92msway-wayland\e[m"
|
||||
echo "MOZ_ENABLE_WAYLAND=1 QT_QPA_PLATFORM=wayland XDG_SESSION_TYPE=wayland \
|
||||
XKB_DEFAULT_LAYOUT="$(grep 'KEYMAP' /etc/vconsole.conf | cut -d '=' -f2 | sed -e 's#-.*##g')" \
|
||||
XKB_DEFAULT_LAYOUT=$(grep 'KEYMAP' /etc/vconsole.conf | cut -d '=' -f2 | sed -e 's#-.*##g') \
|
||||
exec dbus-run-session sway >/dev/tty7 2>&1" > /usr/bin/sway-wayland
|
||||
chmod 755 /usr/bin/sway-wayland
|
||||
sway-wayland
|
||||
|
|
|
@ -52,7 +52,7 @@ usage () {
|
|||
fi
|
||||
if [[ "$(grep -w MemTotal /proc/meminfo | cut -d ':' -f2 | sed -e 's# ##g' -e 's#kB$##g')" -gt 1500000 ]]; then
|
||||
echo -e " \e[1m-sway\e[m Launch Sway desktop with VNC sharing enabled."
|
||||
echo -e " \e[1m-xfce\e[m Launch XFCE desktop with VNC sharing enabled."
|
||||
echo -e " \e[1m-xfce\e[m Launch Xfce desktop with VNC sharing enabled."
|
||||
echo -e " \e[1m-custom-xorg\e[m Install custom X environment."
|
||||
[[ "$(grep -w MemTotal /proc/meminfo | cut -d ':' -f2 | sed -e 's# ##g' -e 's#kB$##g')" -gt 2400000 ]] && echo -e " \e[1m-custom-wayland\e[m Install custom Wayland environment."
|
||||
echo ""
|
||||
|
@ -101,7 +101,7 @@ _download_latest() {
|
|||
# helper binaries
|
||||
echo -e "\e[1mStep 2/4:\e[m Downloading latest scripts..."
|
||||
# main binaries
|
||||
BINS="quickinst setup km tz update copy-mountpoint rsync-backup restore-usbstick"
|
||||
BINS="quickinst setup km tz launcher network update copy-mountpoint rsync-backup restore-usbstick"
|
||||
for i in ${BINS}; do
|
||||
[[ -e "${_BIN}/${i}" ]] && wget -q "${_SOURCE}${_BIN}/archboot-${i}.sh?inline=false" -O "${_BIN}/${i}"
|
||||
done
|
||||
|
@ -292,6 +292,8 @@ _prepare_graphic() {
|
|||
#shellcheck disable=SC2086
|
||||
pacman -Syu ${_IGNORE} --noconfirm &>/dev/null || exit 1
|
||||
[[ ! -e "/.full_system" ]] && _cleanup_install
|
||||
# check for qxl module
|
||||
grep -q qxl /proc/modules && grep -q xorg "${_GRAPHIC}" && _GRAPHIC="${_GRAPHIC} xf86-video-qxl"
|
||||
echo "Running pacman to install packages: ${_GRAPHIC}..."
|
||||
for i in ${_GRAPHIC}; do
|
||||
#shellcheck disable=SC2086
|
||||
|
@ -579,6 +581,16 @@ _prepare_sway() {
|
|||
fi
|
||||
}
|
||||
|
||||
_configure_dialog() {
|
||||
echo "Configuring dialog..."
|
||||
cat <<EOF > /etc/dialogrc
|
||||
border_color = (BLACK,WHITE,ON)
|
||||
border2_color = (BLACK,WHITE,ON)
|
||||
menubox_border_color = (BLACK,WHITE,ON)
|
||||
menubox_border2_color = (BLACK,WHITE,ON)
|
||||
EOF
|
||||
}
|
||||
|
||||
_configure_gnome() {
|
||||
echo "Configuring Gnome..."
|
||||
[[ "${_STANDARD_BROWSER}" == "firefox" ]] && gsettings set org.gnome.shell favorite-apps "['org.gnome.Settings.desktop', 'org.gnome.Terminal.desktop', 'org.gnome.Nautilus.desktop', 'firefox.desktop', 'org.gnome.DiskUtility.desktop', 'gparted.desktop', 'archboot.desktop']"
|
||||
|
@ -601,6 +613,7 @@ EOF
|
|||
echo "[DESKTOP ENTRY]" > /usr/share/applications/"${i}".desktop
|
||||
echo 'NoDisplay=true' >> /usr/share/applications/"${i}".desktop
|
||||
done
|
||||
_configure_dialog
|
||||
}
|
||||
|
||||
_configure_plasma() {
|
||||
|
@ -749,13 +762,7 @@ EOF
|
|||
sed -i -e 's#, "custom/media"##g' /etc/xdg/waybar/config
|
||||
sed -i -e 's#"mpd", "idle_inhibitor", "pulseaudio",##g' /etc/xdg/waybar/config
|
||||
fi
|
||||
echo "Configuring dialog..."
|
||||
cat <<EOF > /etc/dialogrc
|
||||
border_color = (BLACK,WHITE,ON)
|
||||
border2_color = (BLACK,WHITE,ON)
|
||||
menubox_border_color = (BLACK,WHITE,ON)
|
||||
menubox_border2_color = (BLACK,WHITE,ON)
|
||||
EOF
|
||||
_configure_dialog
|
||||
echo "Configuring wayvnc..."
|
||||
if ! grep -q wayvnc /etc/sway/config; then
|
||||
echo "address=0.0.0.0" > /etc/wayvnc
|
||||
|
|
|
@ -7,6 +7,7 @@ build ()
|
|||
map add_binary genfstab arch-chroot pacstrap \
|
||||
archboot-binary-check.sh archboot-not-installed.sh archboot-locale.sh hwdetect
|
||||
add_file "/usr/bin/archboot-setup.sh" "/usr/bin/setup"
|
||||
add_file "/usr/bin/archboot-launcher.sh" "/usr/bin/launcher"
|
||||
add_file "/usr/bin/archboot-quickinst.sh" "/usr/bin/quickinst"
|
||||
add_file "/usr/bin/archboot-copy-mountpoint.sh" "/usr/bin/copy-mountpoint.sh"
|
||||
add_file "/usr/bin/archboot-rsync-backup.sh" "/usr/bin/rsync-backup.sh"
|
||||
|
|
|
@ -18,7 +18,7 @@ if echo "${HOOKS[@]}" | grep -qw archboot_keymap ; then
|
|||
fi
|
||||
if echo "${HOOKS[@]}" | grep -qw archboot_net_common ; then
|
||||
echo -e "\e[1mNetwork Configuration:\e[m" >> "${MOTD}"
|
||||
echo -e " - Use the \e[1;92m'net'\e[m script to change your network settings." >> "${MOTD}"
|
||||
echo -e " - Use the \e[1;92m'network'\e[m script to change your network settings." >> "${MOTD}"
|
||||
fi
|
||||
if echo "${HOOKS[@]}" | grep -qw archboot_tz; then
|
||||
echo -e "\e[1mClock Configuration:\e[m" >> "${MOTD}"
|
||||
|
|
|
@ -6,7 +6,7 @@ build ()
|
|||
{
|
||||
add_all_modules -f '_cs|b44|broadcom/bnx2x|brocade|cavium|chelsio|cisco|netronome|mellanox|myricom|qlogic|qualcomm' '/drivers/net/ethernet|/net/ipv4|/net/ipv6|/drivers/net/usb'
|
||||
map add_binary ip getent ping wget
|
||||
add_file /usr/bin/archboot-net.sh /usr/bin/net
|
||||
add_file /usr/bin/archboot-network.sh /usr/bin/network
|
||||
# start dhcpcd on startup
|
||||
add_file "/usr/share/archboot/net/etc/systemd/network/10-wired-auto-dhcp.network" "/etc/systemd/network/10-wired-auto-dhcp.network"
|
||||
add_file /etc/wgetrc
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<body>
|
||||
<p><span><img src="/web/logo.png" alt="Logo"></span></p>
|
||||
<h1>Archboot Project | <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=Z7GXKW4MKHK7C"><img src="/web/donate.png" alt="Donate"></a></h1>
|
||||
<p><strong>© 2006 - 2023 | <a href=mailto:tpowa@archlinux.org>Tobias Powalowski</a></strong><br>Arch Linux Developer <strong><a href="https://archlinux.org/people/developers/#tpowa">tpowa</a><br>Last update: 11.07.2023 10:02</strong></p>
|
||||
<p><strong>© 2006 - 2023 | <a href=mailto:tpowa@archlinux.org>Tobias Powalowski</a></strong><br>Arch Linux Developer <strong><a href="https://archlinux.org/people/developers/#tpowa">tpowa</a><br>Last update: 12.07.2023 22:10</strong></p>
|
||||
<nav id="TOC" role="doc-toc">
|
||||
<ul>
|
||||
<li><a href="#introduction" id="toc-introduction"><strong><span class="toc-section-number">1.</span> Introduction</strong></a></li>
|
||||
|
@ -557,7 +557,7 @@
|
|||
</table>
|
||||
<p>This will also <strong>stop</strong> cleaning the system, while running other <strong><code>update</code></strong> tasks.</p>
|
||||
<h3 data-number="3.5" id="interactive-setup"><span class="header-section-number">3.5</span> <strong>Interactive Setup</strong></h3>
|
||||
<p>You can run each point for doing the mentioned task. If you do a fresh install, it is recommended to run each point in the order as presented.</p>
|
||||
<p>You can run each point for doing the mentioned task. If you do a fresh install, it is recommended to run each point in the order as presented.<br>The first 3 points are also covered by first login.</p>
|
||||
<h4 data-number="3.5.1" id="changing-keymap-and-console-fonts"><span class="header-section-number">3.5.1</span> <strong>Configure Console</strong></h4>
|
||||
<p>Your <a href="https://wiki.archlinux.org/title/Console_fonts" title="Console fonts"><strong>console fonts</strong></a> and <a href="https://wiki.archlinux.org/title/Keymap" title="Keymap"><strong>keymap</strong></a> will be set by <strong>km</strong> script.</p>
|
||||
<h4 data-number="3.5.2" id="setup-network"><span class="header-section-number">3.5.2</span> <strong>Configure Network</strong></h4>
|
||||
|
@ -568,11 +568,14 @@
|
|||
</ul></li>
|
||||
<li><strong>Online mode</strong>:
|
||||
<ul>
|
||||
<li>Your network will be set by <strong>network</strong> script.</li>
|
||||
<li>Your <a href="https://wiki.archlinux.org/title/Network" title="Network"><strong>network</strong></a> will be configured by <strong><a href="https://wiki.archlinux.org/title/systemd-networkd" title="Systemd-Networkd">systemd-networkd</a></strong>.</li>
|
||||
<li>Your <strong>wifi network</strong> will be authentificated by <strong><a href="https://wiki.archlinux.org/title/iwd" title="iwd">iwd</a></strong>.</li>
|
||||
</ul></li>
|
||||
</ul>
|
||||
<h4 data-number="3.5.3" id="select-source"><span class="header-section-number">3.5.3</span> <strong>Select Source</strong></h4>
|
||||
<h4 data-number="3.5.3" id="changing-timezone-and-date"><span class="header-section-number">3.5.3</span> <strong>Configure Clock</strong></h4>
|
||||
<p>You set your <a href="https://wiki.archlinux.org/title/Timezone" title="Timezone"><strong>timezone</strong></a> and <a href="https://wiki.archlinux.org/title/Date" title="Date"><strong>date</strong></a> with the <strong>tz</strong> script.</p>
|
||||
<h4 data-number="3.5.4" id="select-source"><span class="header-section-number">3.5.4</span> <strong>Select Source</strong></h4>
|
||||
<ul>
|
||||
<li><strong>Offline Mode</strong>:
|
||||
<ul>
|
||||
|
@ -585,8 +588,6 @@
|
|||
<li>If a new kernel is online available, you can decide to load the latest archboot environment<br>and cache packages for installation <strong><default=no></strong>.</li>
|
||||
</ul></li>
|
||||
</ul>
|
||||
<h4 data-number="3.5.4" id="changing-timezone-and-date"><span class="header-section-number">3.5.4</span> <strong>Configure Clock</strong></h4>
|
||||
<p>You set your <a href="https://wiki.archlinux.org/title/Timezone" title="Timezone"><strong>timezone</strong></a> and <a href="https://wiki.archlinux.org/title/Date" title="Date"><strong>date</strong></a> with the <strong>tz</strong> script.</p>
|
||||
<h4 data-number="3.5.5" id="prepare-storage-drive"><span class="header-section-number">3.5.5</span> <strong>Prepare Storage Drive</strong></h4>
|
||||
<ul>
|
||||
<li>You setup your storage drive, <a href="https://wiki.archlinux.org/title/Filesystems" title="Filesystems"><strong>filesystems</strong></a> and define your mountpoints.</li>
|
||||
|
|
Loading…
Reference in a new issue