8 releases (4 breaking)
0.5.0 | Apr 7, 2024 |
---|---|
0.4.0 | Apr 7, 2024 |
0.3.0 | Apr 6, 2024 |
0.1.2 | Apr 1, 2024 |
0.0.2 | Mar 30, 2024 |
#792 in Command line utilities
320KB
1.5K
SLoC
sha512sum arch.pdf
269036e9752ef3edb89d8ec0b351bc745d25499b45a0c3f9038ed97b8c6b3caa9f9b7af4d08ef71cab74148b67199e73d221f5dffa6ed6aab50ca0010940f703 arch.pdf
sha512sum arch.epub
8ddf24144aeb1abfe16d3500ccefa72ab46c9a513dbdc76c3b34d387bc76d66640d54f77a5ce26facde6012110ef9fb257bed04ec87edf087416acfceb9bcb46 arch.epub
Set keymap
loadkeys <keymap>
Partitioning
- 1024MB EFI partition # ef00 /boot/efi
- 4096MB Linux partition # 8300 /boot
- 100% Linux partition # 8300 /
cgdisk /dev/sda
Formatting
/boot/efi
mkfs.vfat -F 32 /dev/sda1
/boot
mkfs.ext2 /dev/sda2
/
mkfs.ext4 /dev/sda3
Mounting
The root partition
mount /dev/sda3 /mnt
Create the boot mount point
mkdir /mnt/boot
Mounting the boot partition
mount /dev/sda2 /mnt/boot
Create the EFI mount point
mkdir /mnt/boot/efi
Mounting the EFI partition
mount /dev/sda1 /mnt/boot/efi
Update mirrorlist
reflector -c <country> --sort delay --save /etc/pacman.d/mirrorlist -p https
Init pacman
pacman-key --init && pacman-key --populate archlinux
Installation
The base system
pacstrap /mnt base base-devel wget git linux linux-firmware vim efibootmgr rustup sudo grub networkmanager w3m archiso reflector <shell> <ucode> <graphics_driver>
Generate fstab
genfstab -U /mnt >> /mnt/etc/fstab
Enter in the new system
arch-chroot /mnt && cd ~
Manage accounts
Create your account
useradd -m -U -c 'YOUR REAL NAME' -s <shell> <username>
Generate root password
passwd root
Generate your password
passwd <username>
Add your account to sudoers file
echo '<username> ALL=(ALL) ALL' > /etc/sudoers.d/<username>
Sign in
su - <username>
Configure rust
rustup default stable
Modify pacman.conf
sudo vim /etc/pacman.conf
Refresh repositories
sudo pacman -Sy
Installation of yay
git clone https://aur.archlinux.org/yay
cd yay
makepkg -si
cd ..
rm -rf yay
Install arch
From GitHub
git clone https://github.com/otechdo/arch
cd arch
make
sudo make install
From Crates.io
cargo install arch
install -m 755 "$HOME/.cargo/bin/arch" /usr/bin/arch
From Aur
paru -Syu manager
Setup a new arch
arch --setup
Desktop
Install all selected packages on arch
arch --install
arch -S <pkg> <pkg>
Quit the fresh new system
exit
Umount all mounted partitions
umount -R /mnt
Reboot
reboot
Arch commands
Setup a new arch
arch -i
arch --setup
Remove packages
arch -R <pkg> <pkg>
arch --uninstall
Install new packages
arch -S <pkg> <pkg>
arch --install
Update mirrorlist
arch -M
arch --mirrors
Check updates
arch -C
arch --check
Install packages as dependencies
arch -d
arch --deps
Update archlinux
arch
arch -u
arch --update
Search a package
arch -s <pkg>
arch --search <pkg>
Show arch current version
arch -v
arch --version
Download updates
arch -d
arch --download-updates
Show help message
arch -h
arch --help
Cancel the upgrade reboot
arch -x
arch --cancel
Upgrade the system and reboot
arch -U
arch --upgrade
Generate arch packages cache
arch -c
arch --cache
Navigate on news
arch -n
arch --news
Navigate on the Aur
arch -a
arch --aur
Navigate on the forum
arch -f
arch --forum
Navigate on the man pages
arch -m
arch --man
arch --woman
Navigate on the wiki
arch -w
arch --wiki
Toolbox support
List all toolbox
os --list
Create a new toolbox
os --add fedora 39 workstation
os --add fedora 39
Create a new toolbox from an image
os --add-from quay.io/toolbx-images/debian-toolbox:12
Enter in toolbox
os --use workstation
os --use fedora-toolbox-39
Run a command in toolbox
os --run workstation ls
os --run fedora-toolbox-39 ls
Stop a toolbox
os --stop workstation
os --stop fedora-toolbox-39
Remove a toolbox
os --rm workstation
os --rm fedora-toolbox-39
Key Bindings
This file lists all of the key bindings currently registered by prompts.
All prompts
These key bindings may be used with all prompts.
command | description |
---|---|
enter | Submit answer. |
esc | Cancel the prompt*. |
ctrl + c | Interrupt the prompt*. |
* Canceling and interrupting a prompt have two different meanings. Canceling is defined specially for when the end user is allowed to skip a prompt, the library user can then use prompt_skippable
which wraps the return type into an Option
and catches the CanceledOperation
error transforming it into a Ok(None)
result. Interrupted operations are closer to "stop-the-world" operations, where the library user should treat them as termination commands.
Text Input
These key bindings may be used with all prompts that ask the user for text input: Text
, Select
, MultiSelect
, Confirm
, CustomType
and Password
. The Editor
prompt is not included because it opens a separate text editor for text input.
command | description |
---|---|
character | Insert the character into the input. |
left | Move the cursor back one character. |
right | Move the cursor forward one character. |
ctrl + left | Move one word to the left of the cursor. |
ctrl + right | Move one word to the right of the cursor. |
home | Move cursor to the start of the line*. |
end | Move cursor to the end of the line*. |
backspace | Delete one character to the left of the cursor. |
delete | Delete the character at the cursor. |
ctrl + delete | Delete one word to the right of the cursor. |
* Key bindings not supported on Select
and MultiSelect
prompts.
Text Prompts
These key bindings may be used in Text
prompts.
command | description |
---|---|
enter | Submit the current current text input. |
up | When suggestions are displayed, move cursor one row up. |
down | When suggestions are displayed, move cursor one row down. |
page up | When suggestions are displayed, move cursor one page up. |
page down | When suggestions are displayed, move cursor one page down. |
tab | Replace current input with the resulting suggestion if any. |
others | See Text Input and All Prompts |
Select Prompts
These key bindings may be used in Select
prompts.
command | description |
---|---|
enter | Submit the current highlighted option. |
up | Move cursor one row up. |
down | Move cursor one row down. |
k | Move cursor one row up when vim mode is enabled. |
j | Move cursor one row down when vim mode is enabled. |
page up | Move cursor one page up. |
page down | Move cursor one page down. |
home | Move cursor to the first option. |
end | Move cursor to the last option. |
others | See Text Input and All Prompts |
MultiSelect Prompts
These key bindings may be used in MultiSelect
prompts.
command | description |
---|---|
enter | Submit the options currently selected. |
space | Toggle the selection of the current highlighted option. |
up | Move cursor one row up. |
down | Move cursor one row down. |
k | Move cursor one row up when vim mode is enabled. |
j | Move cursor one row down when vim mode is enabled. |
page up | Move cursor one page up. |
page down | Move cursor one page down. |
home | Move cursor to the first option. |
end | Move cursor to the last option. |
left | Unselect all options. |
right | Select all options. |
others | See Text Input and All Prompts |
DateSelect Prompts
These key bindings may be used in the interactive calendar of the DateSelect
prompt.
command | description |
---|---|
space bar or enter | Submit the current highlighted date. |
up | Move cursor one row up. |
down | Move cursor one row down. |
left | Move cursor one column to the left. |
right | Move cursor one column to the right. |
k | Move cursor one row up when vim mode is enabled. |
j | Move cursor one row down when vim mode is enabled. |
h | Move cursor one column to the left when vim mode is enabled. |
l | Move cursor one column to the right when vim mode is enabled. |
ctrl + up | Move calendar back by one year. |
ctrl + down | Move calendar forward by one year. |
ctrl + left | Move calendar back by one month. |
ctrl + right | Move calendar forward by one month. |
Editor Prompts
These key bindings may be used in Editor
prompts.
command | description |
---|---|
e | Open the editor. |
enter | Submit the current content of the temporary file being edited. |
Dependencies
~8–18MB
~247K SLoC