-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathinstall
executable file
·94 lines (68 loc) · 2.43 KB
/
install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
#!/bin/bash
# writen by Nicolai H. Brand (lytix.dev) 2022
# Artix linux with runit on an efi system installation script.
# Run after mounting the root partition on /mnt and boot partition on /mnt/boot/efi
# Note on runit:
# Available services can be found in /etc/runit/sv
# To start a service, link a service in /etc/runit/sv to /run/runit/service
HOSTNAME="artix"
USERNAME="nic"
# do amd-ucode if on an amd cpu instead of intel-ucode
basestrap /mnt base base-devel runit elogind-runit linux linux-firmware vim intel-ucode
# generate file system tables using uuid
fstabgen -U /mnt >> /mnt/etc/fstab
# chroot into the installation
artix-chroot /mnt
# set timezone to Oslo
ln -sf /usr/share/zoneinfo/Europe/Oslo /etc/localtime
# sync hwc
hwclock --systohc
# locale
echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen
echo "LANG=en_US.UTF-8" >> /etc/locale.conf
locale-gen
# hostname
echo "$HOSTNAME" > /etc/hostname
echo -n "127.0.0.1\tlocalhost" >> /etc/hosts
echo -n "::1\tlocalhost" >> /etc/hosts
echo -n "127.0.1.1\t"$HOSTNAME".localdomain\t"$HOSTNAME"" >> /etc/hosts
# set password
passwd
# install needed packages
pacman -S grub efibootmgr networkmanager networkmanager-runit network-manager-applet dosfstools linux-headers bluez bluez-runit bluez-utils cups cups-runit xdg-utils xdg-user-dirs
# install bootloader
grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB
grub-mkconfig -o /boot/grub/grub.cfg
# create user
useradd -mG wheel "$USERNAME"
passwd "$USERNAME"
# TODO: give wheel group sudo access
exit
# unmount disks
umount -R /mnt
reboot
# TODO: log in as the newly created user
# enable service and start it right away
ln -s /etc/runit/sv/NetworkManager /run/runit/service/NetworkManager
ln -s /etc/runit/sv/bluetoothd /run/runit/service/bluetoothd
ln -s /etc/runit/sv/cupsd /run/runit/service/cupsd
# TODO: connect to internet using nmtui
# install more needed packages
# use amdgup or nvidia over intel on those gpus
pacman -S xf86-video-intel xorg --ignore xorg-server-xdmx xorg-xinit i3-gaps firefox git
# set keyboard layout
echo "KEYMAP=no-latin1" > /etc/vconsole.conf
# create directories
mkdir -p ~/Documents/projects
mkdir ~/Documents/programs
mkdir ~/Scripts
mkdir ~/School
mkdir ~/Media
mkdir ~/Pictures
# clone dotfiles
git clone "https://github.com/lytixdev/dotfiles.git"
# TODO: setup arch repos for artix
# TODO: setup dotfiles
# add user to docker group
sudo groupadd docker
sudo usermod -aG docker "$(whoami)"