updated
This commit is contained in:
parent
b488ac938a
commit
8957bb08b1
7 changed files with 82 additions and 31 deletions
|
@ -140,12 +140,12 @@ alias \
|
||||||
|
|
||||||
# function to detect os and assign aliases to package managers
|
# function to detect os and assign aliases to package managers
|
||||||
alias \
|
alias \
|
||||||
pac-up="yay -Syyu" \
|
pac-up="paru -Syu" \
|
||||||
pac-get="yay -S" \
|
pac-get="paru -S" \
|
||||||
pac-rmv="yay -Rcns" \
|
pac-rmv="paru -Rcns" \
|
||||||
pac-rmv-sec="yay -R" \
|
pac-rmv-sec="paru -R" \
|
||||||
pac-qry="yay -Ss" \
|
pac-qry="paru -Ss" \
|
||||||
pac-cln="yay -Scc"
|
pac-cln="paru -Scc"
|
||||||
|
|
||||||
# colorize grep output (good for log files)
|
# colorize grep output (good for log files)
|
||||||
alias \
|
alias \
|
||||||
|
|
|
@ -141,16 +141,13 @@ alias ll='exa -l --color=always --group-directories-first' # long format
|
||||||
alias lt='exa -aT --color=always --group-directories-first' # tree listing
|
alias lt='exa -aT --color=always --group-directories-first' # tree listing
|
||||||
alias l.='exa -a | egrep "^\."'
|
alias l.='exa -a | egrep "^\."'
|
||||||
|
|
||||||
# pacman and yay
|
# package management
|
||||||
alias pac-up='yay -Syu && yay -Sua' # update the system
|
alias pac-up='paru -Syu'
|
||||||
alias pac-get='yay -S' # install a program
|
alias pac-get='paru -S'
|
||||||
alias pac-rmv='yay -Rcns' # remove a program
|
alias pac-rmv='paru -Rcns'
|
||||||
alias pac-rmv-sec='yay -R' # remove a program (secure way)
|
alias pac-rmv-sec='paru -R'
|
||||||
alias pac-qry='yay -Ss' # search for a program
|
alias pac-qry='paru -Ss'
|
||||||
alias pac-cln='yay -Scc && yay -Rns (pacman -Qtdq)' # clean cache & remove orphaned packages
|
alias pac-cln='paru -Scc && paru -Rns (pacman -Qtdq)'
|
||||||
|
|
||||||
# neofetch is f***** slow
|
|
||||||
alias neofetch="pfetch"
|
|
||||||
|
|
||||||
# Colorize grep output (good for log files)
|
# Colorize grep output (good for log files)
|
||||||
alias grep='grep --color=auto'
|
alias grep='grep --color=auto'
|
||||||
|
|
|
@ -141,7 +141,6 @@ windowrule = workspace 1, ^(firefox)$
|
||||||
windowrule = workspace 1, ^(Librewolf)$
|
windowrule = workspace 1, ^(Librewolf)$
|
||||||
windowrule = workspace 1, ^(Chromium)$
|
windowrule = workspace 1, ^(Chromium)$
|
||||||
windowrule = workspace 1, ^(Brave-browser)$
|
windowrule = workspace 1, ^(Brave-browser)$
|
||||||
windowrule = workspace 1, ^(tut)$
|
|
||||||
## Workspace 2 - File management
|
## Workspace 2 - File management
|
||||||
windowrule = workspace 2, ^(file_manager)$
|
windowrule = workspace 2, ^(file_manager)$
|
||||||
windowrule = workspace 2, ^(Pcmanfm)$
|
windowrule = workspace 2, ^(Pcmanfm)$
|
||||||
|
@ -149,12 +148,8 @@ windowrule = workspace 2, ^(Pcmanfm)$
|
||||||
windowrule = workspace 3, ^(text_editor)$
|
windowrule = workspace 3, ^(text_editor)$
|
||||||
windowrule = workspace 3, ^(goneovim)$
|
windowrule = workspace 3, ^(goneovim)$
|
||||||
windowrule = workspace 3, ^(Code)$
|
windowrule = workspace 3, ^(Code)$
|
||||||
## Workspace 4 - Chat
|
## Workspace 4 - Todo management
|
||||||
windowrule = workspace 4, ^(chat_client)$
|
windowrule = workspace 4, ^(todo_app)$
|
||||||
windowrule = workspace 4, ^(whatsapp-for-linux)$
|
|
||||||
windowrule = workspace 4, ^(Element)$
|
|
||||||
windowrule = workspace 4, ^(Signal)$
|
|
||||||
windowrule = workspace 4, ^(revolt-desktop)$
|
|
||||||
## Workspace 5 - Audio
|
## Workspace 5 - Audio
|
||||||
windowrule = workspace 5, ^(music_player)$
|
windowrule = workspace 5, ^(music_player)$
|
||||||
windowrule = workspace 5, ^(ytfzf_music)$
|
windowrule = workspace 5, ^(ytfzf_music)$
|
||||||
|
@ -207,7 +202,6 @@ windowrule = workspace 10, ^(btop)$
|
||||||
windowrule = workspace 10, ^(htop)$
|
windowrule = workspace 10, ^(htop)$
|
||||||
windowrule = workspace 10, ^(pulsemixer)$
|
windowrule = workspace 10, ^(pulsemixer)$
|
||||||
windowrule = workspace 10, ^(alsamixer)$
|
windowrule = workspace 10, ^(alsamixer)$
|
||||||
windowrule = workspace 10, ^(geek-life)$
|
|
||||||
windowrule = workspace 10, ^(wdisplays)$
|
windowrule = workspace 10, ^(wdisplays)$
|
||||||
windowrule = workspace 10, ^(font-manager)$
|
windowrule = workspace 10, ^(font-manager)$
|
||||||
windowrule = workspace 10, ^(org.qbittorrent.qBittorrent)$
|
windowrule = workspace 10, ^(org.qbittorrent.qBittorrent)$
|
||||||
|
@ -341,7 +335,6 @@ binde = $supMod_$conMod, c, exec, hyprpicker -n -a
|
||||||
|
|
||||||
# QUICK TERMINAL SCRIPTS/COMMANDS
|
# QUICK TERMINAL SCRIPTS/COMMANDS
|
||||||
## Workspace 1 - Web
|
## Workspace 1 - Web
|
||||||
binde = $supMod_$altMod, t, exec, wezterm start --class tut -- tut # Mastodon client
|
|
||||||
binde = $supMod_$altMod, r, exec, wezterm start --class newsboat -- newsboat # RSS feed reader
|
binde = $supMod_$altMod, r, exec, wezterm start --class newsboat -- newsboat # RSS feed reader
|
||||||
## Workspace 5 - Audio
|
## Workspace 5 - Audio
|
||||||
binde = $supMod_$altMod, m, exec, wezterm start --class ytfzf_music -- ytfzf -mlstT chafa # Listen to YouTube Music on the terminal
|
binde = $supMod_$altMod, m, exec, wezterm start --class ytfzf_music -- ytfzf -mlstT chafa # Listen to YouTube Music on the terminal
|
||||||
|
@ -350,7 +343,6 @@ binde = $supMod_$altMod, f, exec, wezterm start --class flix_cli -- flix-cli
|
||||||
binde = $supMod_$altMod, a, exec, wezterm start --class ani_cli -- ani-cli # Watch anime on the terminal
|
binde = $supMod_$altMod, a, exec, wezterm start --class ani_cli -- ani-cli # Watch anime on the terminal
|
||||||
binde = $supMod_$altMod, y, exec, wezterm start --class ytfzf -- ytfzf -flstT chafa # Watch YouTube on the terminal
|
binde = $supMod_$altMod, y, exec, wezterm start --class ytfzf -- ytfzf -flstT chafa # Watch YouTube on the terminal
|
||||||
## Workspace 10 - Extras
|
## Workspace 10 - Extras
|
||||||
binde = $supMod_$altMod, g, exec, wezterm start --class geek-life -- geek-life # Todo manager
|
|
||||||
binde = $supMod_$altMod, p, exec, wezterm start --class pulsemixer -- pulsemixer # Open the volume mixer (pulsemixer)
|
binde = $supMod_$altMod, p, exec, wezterm start --class pulsemixer -- pulsemixer # Open the volume mixer (pulsemixer)
|
||||||
binde = $supMod_$altMod, o, exec, wezterm start --class alsamixer -- alsamixer # Open the volume mixer (alsamixer)
|
binde = $supMod_$altMod, o, exec, wezterm start --class alsamixer -- alsamixer # Open the volume mixer (alsamixer)
|
||||||
binde = $supMod_$altMod, b, exec, wezterm start --class btop -- btop # Open the system monitor (btop)
|
binde = $supMod_$altMod, b, exec, wezterm start --class btop -- btop # Open the system monitor (btop)
|
||||||
|
@ -363,8 +355,8 @@ binde = $supMod, w, exec, brave
|
||||||
binde = $supMod, f, exec, wezterm start --class file_manager -- vifm
|
binde = $supMod, f, exec, wezterm start --class file_manager -- vifm
|
||||||
## Workspace 3 - Editors
|
## Workspace 3 - Editors
|
||||||
binde = $supMod, e, exec, goneovim --nvim=$HOME/.local/bin/lvim --geometry=1920x1080
|
binde = $supMod, e, exec, goneovim --nvim=$HOME/.local/bin/lvim --geometry=1920x1080
|
||||||
## Workspace 4 - Chat
|
## Workspace 4 - Task management
|
||||||
binde = $supMod, c, exec, wezterm start --class chat_client -- gomuks
|
binde = $supMod, t, exec, wezterm start --class todo_app -- geek-life
|
||||||
## Workspace 5 - Audio
|
## Workspace 5 - Audio
|
||||||
binde = $supMod, m, exec, wezterm start --class music_player -- cmus
|
binde = $supMod, m, exec, wezterm start --class music_player -- cmus
|
||||||
## Workspace 9 - Games
|
## Workspace 9 - Games
|
||||||
|
|
|
@ -175,7 +175,33 @@ lvim.builtin.treesitter.highlight.enable = true
|
||||||
-- Additional Plugins
|
-- Additional Plugins
|
||||||
lvim.plugins = {
|
lvim.plugins = {
|
||||||
{"lunarvim/colorschemes"},
|
{"lunarvim/colorschemes"},
|
||||||
{"ellisonleao/gruvbox.nvim"},
|
{
|
||||||
|
"ellisonleao/gruvbox.nvim",
|
||||||
|
-- setup must be called before loading the colorscheme
|
||||||
|
-- Default options:
|
||||||
|
require("gruvbox").setup({
|
||||||
|
undercurl = true,
|
||||||
|
underline = true,
|
||||||
|
bold = true,
|
||||||
|
italic = {
|
||||||
|
strings = true,
|
||||||
|
comments = true,
|
||||||
|
operators = false,
|
||||||
|
folds = true,
|
||||||
|
},
|
||||||
|
strikethrough = true,
|
||||||
|
invert_selection = false,
|
||||||
|
invert_signs = false,
|
||||||
|
invert_tabline = false,
|
||||||
|
invert_intend_guides = false,
|
||||||
|
inverse = true, -- invert background for search, diffs, statuslines and errors
|
||||||
|
contrast = "hard", -- can be "hard", "soft" or empty string
|
||||||
|
palette_overrides = {},
|
||||||
|
overrides = {},
|
||||||
|
dim_inactive = false,
|
||||||
|
transparent_mode = false,
|
||||||
|
})
|
||||||
|
},
|
||||||
{"puremourning/vimspector"},
|
{"puremourning/vimspector"},
|
||||||
{
|
{
|
||||||
"iamcco/markdown-preview.nvim",
|
"iamcco/markdown-preview.nvim",
|
||||||
|
|
37
new-config/.config/rofi/scripts/rofi_mount
Executable file
37
new-config/.config/rofi/scripts/rofi_mount
Executable file
|
@ -0,0 +1,37 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
# List of available drives
|
||||||
|
devices=$(lsblk -lpo "name,size,type,mountpoint" --noheadings | grep -v -e "disk" -e "lvm" -e "nvme" | awk '{if ($4=="") {print $1, "(" $2 ")", "[unmounted]"} else {print $1, "(" $2 ")", "[" $4 "]"}}')
|
||||||
|
|
||||||
|
# Rofi menu
|
||||||
|
selected_device=$(echo -e "${devices}" | rofi -dmenu -i -p "Drive manager" | awk '{print $1}')
|
||||||
|
|
||||||
|
# Verify if the drive is mounted
|
||||||
|
if [ "$(lsblk -lp | grep "${selected_device}" | awk '{print $7}')" ]; then
|
||||||
|
# Check if the drive is encrypted
|
||||||
|
if [ "$(lsblk -n -o TYPE "${selected_device}")" == "crypt" ]; then
|
||||||
|
mmg_device=$(echo "${selected_device}" | sed -s 's/\/dev\/mapper\///')
|
||||||
|
udisksctl unmount -b "${selected_device}"
|
||||||
|
pkexec cryptsetup close "${mmg_device}"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
# If it's mounted, unmount it
|
||||||
|
udisksctl unmount -b "$selected_device"
|
||||||
|
notify-send "The drive was unmounted successfully"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
# If it's not mounted, check if it's an encrypted drive
|
||||||
|
if [ "$(lsblk -n -o FSTYPE "${selected_device}")" == "crypto_LUKS" ]; then
|
||||||
|
# If it's an encrypted drive, prompt for the passphrase and mount it
|
||||||
|
passphrase=$(rofi -dmenu -p "Enter passphrase for ${selected_device}" -password)
|
||||||
|
if [ -n "$passphrase" ]; then
|
||||||
|
echo "$passphrase" | pkexec cryptsetup open "${selected_device}" encrypted_"${selected_device##*/}"
|
||||||
|
udisksctl mount -b /dev/mapper/encrypted_"${selected_device##*/}"
|
||||||
|
notify-send "The encrypted drive was mounted successfully"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
udisksctl mount -b "$selected_device"
|
||||||
|
notify-send "The drive was mounted successfully"
|
||||||
|
exit 1
|
||||||
|
fi
|
|
@ -66,4 +66,3 @@ case "$action" in
|
||||||
$option7*)
|
$option7*)
|
||||||
exit 0
|
exit 0
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
"1": "\uf484",
|
"1": "\uf484",
|
||||||
"2": "\ue613",
|
"2": "\ue613",
|
||||||
"3": "\ue795",
|
"3": "\ue795",
|
||||||
"4": "\uf075",
|
"4": "\uf14a",
|
||||||
"5": "\uf001",
|
"5": "\uf001",
|
||||||
"6": "\uf03d",
|
"6": "\uf03d",
|
||||||
"7": "\ue22b",
|
"7": "\ue22b",
|
||||||
|
|
Loading…
Reference in a new issue