koreoxy / my-archlinux-setting

my repo for my arch linux setting and install or setup window manager on arch linux and manjaro linux

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

My Arch Linux Setting

My Setup Image

newdesk

idk

Jump to

Command Arch Linux

Command Description
xrandr Check list resolution monitor
xrandr --output "Virtual-1" --mode 1920x1080 Change resolution monitor


Keybind DWM

Keybind Description
ALT + SHIFT + ENTER Open terminal
ALT + J Toggle forward and backward between window viewing FORWARD
ALT + K Toggle forward and backward between window viewing BACKWARD
ALT + SHIFT + c Close Window on active
ALT + p Run program with dmenu
ALT + 1 2 3 4 Move workspace
ALT + SHIFT + 1 2 3 4 Move window to different workspace
ALT + h move space window to left
ALT + l move space window to right
ALT + d Move window to down
ALT + i Move window to up
ALT + SPACE Change mode window to float
ALT + B hide top bar dmenu
CTRL + SHIFT PgUp zoom in and zoom in terminal
CTRL + SHIFT + pgDn zoom in and zoom out terminal


My Config file .bashrc

function cdf() {
    cd "$(find * -type d | fzf)"
}

alias sn='sudo shutdown now'

n() {
  nvim "$@"
}


Install Arch Linux

  1. synchronizing package database
# pacman -Syy
  1. check partition
# lsblk
  1. format partition
# gdisk /dev/"name disk"
# gdisk /dev/sda

Output : VirtualBoxVM_XdpMEIa01p

  1. install archlinux keyring package
# pacman -S archlinux-keyring
  1. update package
# pacman -Sy archinstall
  1. trigger installation
# archinstall

Output Image :

  • Setup Partition : VirtualBoxVM_uCfvdjegzd bPtMg06mBr
  • Aditional Package : M72VmRaGBI
  • All Setting Installation : VirtualBoxVM_k5i7UXRfhE
  1. After installation done reboot or shutdown computer
# reboot
# shutdown now


Post Install Arch Linux

  • Change session cli to dekstop environment ALT F1 or F2
  • Upadate all package
# sudo pacman -Syu
  • Install app
# sudo pacman -S firefox
  • Install yay package
# git clone https://aur.archlinux.org/yay-bin.git
# cd yay-bin
# makepkg -si

// install app with yay
# yay -S firefox
  • Install xorg for graphics
# sudo pacman -S xorg
  • Install desktop environment (KDE Plasma)
# sudo pacman -S plasma-desktop
  • Install xorg-xinit
# sudo pacman -S xorg-xinit
  • Add script file .bash_profile
# vim .bash_profile

// Add script
if [ -z "${DISPLAY}"] && [ "${XDG_VTNR}" -eq 1 ]; then
    exec startx
fi
  • Edit file xinitrc
# vim .xinitrc

// Add script
exec startplasma-x11
  • Install konsole terminal KDE
# sudo pacman -S konsole
  • Install fonts
# sudo pacman -S gnu-free-fonts noto-fonts ttf-jetbrains-mono


Install Window Manager dwm

reference : https://dwm.suckless.org/

  1. clone dwm
# git clone https://git.suckless.org/dwm
  1. clone dmenu
# git clone https://git.suckless.org/dmenu
  1. clone st
# git clone https://git.suckless.org/st
  1. create folder
# mkdir suckless
  1. move file dwm, dmenu and st to folder suckless
# mv dwm dmenu st suckless/
  1. open file dwm, dmenu and st and install
# cd dwm
# sudo make clean install
  1. edit script file .xinitrc (Home directory)
# vim .xinitrc

// Add script
#exec startplasma-x11
exec dwm
  1. Keybind dwm
  • Open terminal ALT + SHIFT + ENTER
  • Toggle forward and backward between window viewing FORWARD = ALT + J, BACKWARD = ALT + K
  • Close Window on active ALT + SHIFT + c
  • Run program with dmenu ALT + p
  • Move workspace ALT + 1 2 3 4
  • Move window to different workspace ALT + SHIFT + 1 2 3 4
  • move space window to left ALT + h, right ALT + l
  • Move window to down ALT + d to left ALT + i
  • Change mode window to float ALT + SPACE
  • hide top bar dmenu ALT + B
  • zoom in and zoom out in terminal CTRL + SHIFT PgUp and CTRL + SHIFT + pgDn

Patching dwm

  1. Download patches : https://dwm.suckless.org/patches/
  2. create folder in suckless/dwm/patches
  3. copy file config cp config.h config.def.h
  4. install patch patch -i patches/dwm-name-version.diff
  5. after isntall patch sudo make clean install on folder dwm

File .xinitrc

~/.fehbg &
xrandr --output "Virtual-1" --mode 1280x720 &
picom &
slstatus &

#exec startplasma-x11
exec dwm

Set wallpaper

see general command man feh

  1. install feh sudo pacman -S feh
  2. set wallpaper feh --bg-scale Pictures/name-wallpaper

Opacity or blur terminal

  1. install picom sudo pacman -S picom
  2. run picom picom &
  3. open folder xdg cd /etc/xdg/
  4. open file picom.conf sudo vim picom.conf
  5. add script :

A83RxMDKBu QD7shlnnWe VirtualBoxVM_wDM4tCMHF3


Generate Color theme with pywal

reference : https://github.com/dylanaraps/pywal

  1. Install pywwal sudo pacman -S python-pywal
  2. generate color wallpaper which is being used wal -i wallpaper/name-wallpaper.png
  3. open cd .cache/wal to see color results
  4. add #include "/home/<USER>/.cache/wal/colors-wal-dwm.h" in file config.h on folder /dwm


Install App

Install alacritty (terminal)

  1. First, On Arch Linux, you need a few extra libraries to build Alacritty. Here's a pacman command that should install all of them. If something is still found to be missing, please open an issue.
pacman -S cmake freetype2 fontconfig pkg-config make libxcb libxkbcommon python
  1. Install
sudo pacman -S alacritty
  1. Customize setting alacritty create file on folder ~/.config/alacritty/alacritty.toml
[font]
normal = {family = "Hack", style = "Regular"}
bold = {family = "Hack", style = "Bold"}
size = 12

[window]
opacity = 1
blur = true

Install Docker

A. Install and Running Dcoker

  1. install docker
sudo pacman -S docker -y
  1. check version docker
docker --version
  1. install docker desktop, first download docker desktop for arc linux. link : https://docs.docker.com/desktop/release-notes/
  2. and install docker desktop
sudo pacman -U ./docker-desktop-<version>-<arch>.pkg.tar.zst
  1. check docker running or not
sudo systemctl status docker
  1. if not running run this command
sudo systemctl start docker

B. Command Docker

Command Description
sudo docker version Check version docker

Install bat (for cat display)

Reference : https://github.com/sharkdp/bat A cat(1) clone with syntax highlighting and Git integration.

  1. Install bat
sudo pacman -S bat

Install fzf (Fuzzy Finder)

  1. Install fzf with yay
yay -S fzf
  1. run fzf
fzf
  1. open folder with fzf
alias cdf='cd $(find * -type d | fzf)'
  1. Custom script fzf
 vim ~/.bashrc
  1. add script in file .bashrc
function cdf() {
  cd "$(find * -type d | fzf)"
}
  1. run fzf with custom script cdf

Install Audio

  1. install pipewire sudo pacman -S pipewire pipewire-pulse
  2. install pavucontrol sudo pacman -S pavucontrol
  3. Restart computer

Install Kdenlive

reference : https://linux-packages.com/arch-linux/package/kdenlive

  1. Install kdenlive and update package

     sudo pacman -Sy
     sudo pacman -S kdenlive
    
  2. Uninstall kdenlive

     sudo pacman -Rcns kdenlive
    

Install GIMP

reference : https://archlinux.org/packages/extra/x86_64/gimp/

  1. Install GIMP and update package

     sudo pacman -Sy
     sudo pacman -S gimp
    
  2. Uninstall GIMP

     sudo pacman -Rcns gimp
    

Install krita

reference : https://archlinux.org/packages/extra/x86_64/gimp/

  1. Install krita and update package

     sudo pacman -Sy
     sudo pacman -S krita
    
  2. Uninstall krita

     sudo pacman -Rcns krita
    

Install Virtualbox

  1. first update system

     sudo pacman -Syu
  2. Install virtualbox with headers

    sudo pacman -S linux$(uname -r | grep -o -E '[0-9]+' | head -n 2 | sed 'N;s/\n//')-headers virtualbox virtualbox-host-dkms
  3. Add user to group

    sudo usermod -aG vboxusers $USER

Install Mysql and MySQL Workbench

Reference : https://gist.github.com/oddlyspaced/8856bd3db5132ef3714ecc40a9fe37ea

  1. Updating system

    sudo pacman -Syyu
  2. Installing software dependencies

    sudo pacman -S git gnome-keyring
  3. Compile and Install MySQL Server, Note : (This might take like ~4 hours since it's compiling the source)

    git clone https://aur.archlinux.org/mysql.git
    cd mysql
    makepkg -si
  4. Install MySQL-Workbench

    sudo pacman -S mysql-workbench
  5. Setting up database

    sudo rm -rf /var/lib/mysql
    sudo mysqld --initialize --user=mysql --basedir=/usr --datadir=/var/lib/mysql
    # ^ Once the above command is executed successfully, make sure to copy paste the demo password displayed at screen!
  6. Enabling the service

    sudo systemctl enable --now mysqld
  7. Verifying

    mysql -u root -p
    # ^ Enter your dummy password from Part 5

Install xampp and configuration

reference : https://wiki.archlinux.org/title/XAMPP

  1. Download xampp for linux on website https://www.apachefriends.org/download.html
  2. open file in directory Downloads
  3. run this command # sudo chmod +x xampp-linux-x64-8.2.12-0-installer.run
  4. and install xampp with # ./xampp-linux-x64-8.2.12-0-installer.run
  5. install other package # sudo pacman -S libxcrypt-compat and # sudo pacman -S net-tools
  6. after install start xampp apache with this command # /opt/lampp/lampp startapache
  7. start mysql # /opt/lampp/lampp startmysql
  8. example command to start,stop,restart xampp # /opt/lampp/xampp start,stop,restart
  9. open localhost in browser http://localhost/phpmyadmin/

Install Composer

reference : https://getcomposer.org/download

  1. Update package
# sudo pacman -Sy
  1. install composer
# sudo pacman -S composer
  1. check version composer
# composer -v


Change Languages Arch Linux

  1. Add languages by editing /etc/locale.gen. Uncomment the languages you want to
#en_SG ISO-8859-1
en_US.UTF-8 UTF-8
#en_US ISO-8859-1
  1. Run locale-gen to load those languages.
$ sudo locale-gen
Generating locales...
  en_US.UTF-8... done
  en_US.UTF-8... done
Genertaion complete.
  1. Set your system language by editing vim /etc/locale.conf. Add LANG= and the language
  2. Reboot

Backup file .xinitrc manjaro-linux

#!/bin/bash
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap

DEFAULT_SESSION=startplasma-x11

# merge in defaults and keymaps

if [ -f $sysresources ]; then
    xrdb -merge $sysresources
fi

if [ -f $sysmodmap ]; then
    xmodmap $sysmodmap
fi

if [ -f "$userresources" ]; then
    xrdb -merge "$userresources"
fi

if [ -f "$usermodmap" ]; then
    xmodmap "$usermodmap"
fi

# start some nice programs

if [ -d /etc/X11/xinit/xinitrc.d ] ; then
    for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
        [ -x "$f" ] && . "$f"
    done
    unset f
fi

get_session(){
    local dbus_args=(--sh-syntax --exit-with-session)
    case $1 in
        awesome) dbus_args+=(awesome) ;;
        bspwm) dbus_args+=(bspwm-session) ;;
        budgie) dbus_args+=(budgie-desktop) ;;
        cinnamon) dbus_args+=(cinnamon-session) ;;
        deepin) dbus_args+=(startdde) ;;
        enlightenment) dbus_args+=(enlightenment_start) ;;
        fluxbox) dbus_args+=(startfluxbox) ;;
        gnome) dbus_args+=(gnome-session) ;;
        i3|i3wm) dbus_args+=(i3 --shmlog-size 0) ;;
        jwm) dbus_args+=(jwm) ;;
        kde) dbus_args+=(startplasma-x11) ;;
        lxde) dbus_args+=(startlxde) ;;
        lxqt) dbus_args+=(lxqt-session) ;;
        mate) dbus_args+=(mate-session) ;;
        xfce) dbus_args+=(xfce4-session) ;;
        openbox) dbus_args+=(openbox-session) ;;
        *) dbus_args+=($DEFAULT_SESSION) ;;
    esac

    echo "dbus-launch ${dbus_args[*]}"
}

exec $(get_session "$1")


Fix Error In Arch Linux

Fix unable to lock database

reference : https://ostechnix.com/how-to-fix-unable-to-lock-database-error-in-arch-linux/

  1. Remove file db.lck

    sudo rm /var/lib/pacman/db.lck
    
  2. And update again package

    sudo pacman -Syu
    

Command terminal perhaps help me

Set audio volume from terminal

  1. Gets a list of simple mixer controls
     amixer scontrols 
    
  2. and set increse audio with this example
     amixer sset 'Master' 100%
    

About

my repo for my arch linux setting and install or setup window manager on arch linux and manjaro linux


Languages

Language:C 94.7%Language:Roff 3.3%Language:Makefile 1.9%Language:Shell 0.1%