fix: cleanup

This commit is contained in:
ange 2024-03-11 21:37:22 +01:00
parent 346a498e7d
commit ff9dc89009
Signed by: ange
GPG Key ID: 9E0C4157BB7BEB1D
20 changed files with 66 additions and 107 deletions

View File

@ -11,7 +11,7 @@
<C-q> = :prompt 'Quit?' quit<Enter> <C-q> = :prompt 'Quit?' quit<Enter>
[messages] [messages]
q = :prompt 'Quit?' quit<Enter> q = quit<Enter>
j = :next<Enter> j = :next<Enter>
<Down> = :next<Enter> <Down> = :next<Enter>

View File

@ -24,10 +24,10 @@ $passuser = passuser
$passpass = passpass $passpass = passpass
$passotp = passotp $passotp = passotp
exec-once=swayidle -w \ exec-once=swayidle -w \
timeout 300 '$screensaver' \ timeout 300 '$screensaver' \
timeout 315 'swaymsg "output * dpms off"' \ timeout 315 'swaymsg "output * dpms off"' \
resume 'swaymsg "output * dpms on"' \ resume 'swaymsg "output * dpms on"' \
before-sleep '$lock' before-sleep '$lock'
exec-once=/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 exec-once=/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
exec-once=gammastep exec-once=gammastep

View File

@ -2,3 +2,4 @@ set menu-feed-sorting unread-desc
set menu-item-sorting unread-desc set menu-item-sorting unread-desc
bind v exec mpv "%l" bind v exec mpv "%l"
bind V exec mpv --speed=1.5 "%l"

View File

@ -1,4 +1,4 @@
@ Global [1440] {100} @ Global [60] {100}
@ Entertainment @ Entertainment
https://www.youtube.com/feeds/videos.xml?channel_id=UCI4W-ck8ZLA_YljxMhlpg2g "ChessSimp" https://www.youtube.com/feeds/videos.xml?channel_id=UCI4W-ck8ZLA_YljxMhlpg2g "ChessSimp"

@ -1 +1 @@
Subproject commit 4f71c0c4a196ceb656c824a70792f3df3ce6bb6d Subproject commit f7adfc4b3f4f91aab6caebf42b3682945fbc35be

@ -1 +1 @@
Subproject commit dc1ea28cc2a02cd1cebb9d80e967807d668f78f8 Subproject commit 7472420f8734c710bd7009081cef9b97f08a3821

@ -1 +1 @@
Subproject commit 212b7a504cf56f85d1acc5be237261b42d7560c5 Subproject commit 7ff51f53b0efb6228df2e8539b51bb2e737b77f3

View File

@ -1,77 +1,60 @@
function update() { function update() {
$TERM --hold -e "$SHELL" -c "sudo pacman -Syu && echo -e '\e[32mDONE\e[0m'" & $TERM --hold -e "$SHELL" -c "sudo pacman -Syu && echo -e '\e[32mDONE\e[0m'" &
$TERM --hold -e "$SHELL" -c "flatpak update && echo -e '\e[32mDONE\e[0m'" & $TERM --hold -e "$SHELL" -c "flatpak update && echo -e '\e[32mDONE\e[0m'" &
$TERM --hold -e "$SHELL" -c "git --git-dir='$HOME/.dotfiles/' --work-tree='$HOME' submodule update --remote --recursive --init && echo -e '\e[32mDONE\e[0m'" & $TERM --hold -e "$SHELL" -c "git --git-dir='$HOME/.dotfiles/' --work-tree='$HOME' submodule update --remote --recursive --init && echo -e '\e[32mDONE\e[0m'" &
} }
alias pac='sudo pacman' \ alias pac='sudo pacman' \
vi='$EDITOR' \ vi='$EDITOR' \
qcp='qcp -o tabsize=4' \ qcp='qcp -o tabsize=4' \
qmv='qmv -o tabsize=4' \ qmv='qmv -o tabsize=4'
mutt='neomutt'
alias config='git --git-dir="$HOME/.dotfiles/" --work-tree="$HOME"' \ alias config='git --git-dir="$HOME/.dotfiles/" --work-tree="$HOME"' \
viconf='(cd "$XDG_CONFIG_HOME/nvim" && $EDITOR .)' \ viconf='(cd "$XDG_CONFIG_HOME/nvim" && $EDITOR .)' \
zconf='(cd "$ZDOTDIR/" && $EDITOR .) && . "$ZDOTDIR/.zshrc"' zconf='(cd "$ZDOTDIR/" && $EDITOR .) && . "$ZDOTDIR/.zshrc"'
alias valgrind='epitest valgrind' \ alias ssh='TERM=linux ssh'
ssh='TERM=linux ssh'
function coloralias() { alias sudo='sudo ' \
$1 $(echo - "${@:2}" | sed 's/--color=\w\+/--color=always/') watch='watch -c -- ' \
}
alias _='sudo ' \
sudo='sudo ' \
watch='coloralias watch -c -- ' \
xargs='xargs ' xargs='xargs '
function j() { function j() {
local cmd=( dests=(**/"$1"*~cvs~node_modules/)
find . -mount -name "$1*" -type d \
\! -path '*/.bzr/*' \
\! -path '*/.cache/*' \
\! -path '*/.git/*' \
\! -path '*/.hg/*' \
\! -path '*/.idea/*' \
\! -path '*/.svn/*' \
\! -path '*/.tox/*' \
\! -path '*/.venv/*' \
\! -path '*/.vscode/*' \
\! -path '*/CVS/*' \
\! -path '*/node_modules/*'
)
local dests=("${(@f)$(${cmd[@]} 2> /dev/null)}")
local dest="${dests:-$1}"
[ -n "${dests[2]}" ] && dest="$(printf '%s\n' "${dests[@]}" | fzf)" [ -n "${dests[2]}" ] && dests=("$(printf '%s\n' "${dests[@]}" | fzf)")
cd "$dest" cd "${dests[1]}"
} }
function tmp() { function tmp() {
cd "$(mktemp -d --tmpdir "$1"XXX)" cd "$(mktemp -d --tmpdir "$1"XXX)"
} }
alias -g ...='../..' \ alias -g ...='../..' \
....='../../..' \ ....='../../..' \
.....='../../../..' \ .....='../../../..' \
......='../../../../..' ......='../../../../..'
alias cp="cp -vi" \ alias cp="cp -vi" \
mv="mv -vi" \ mv="mv -vi" \
rm="rm -i" \ rm="rm -i" \
mkdir="mkdir -v" \ mkdir="mkdir -v" \
rsync="rsync -P" rsync="rsync -P"
alias ls='ls --color=tty' \ alias ls='ls --color' \
ll='ls -lh' \ ll='ls -lh' \
l='ll -a' \ l='ll -a' \
la='ll -A' la='ll -A'
alias diff='diff --color' alias diff='diff --color'
alias grep="grep --color=auto --exclude-dir={.bzr,.cache,.git,.hg,.idea,.svn,.tox,.venv,.vscode,CVS,node_modules}" \ alias grep="grep --color --exclude-dir={.bzr,.cache,.git,.hg,.idea,.svn,.tox,.venv,.vscode,CVS,node_modules}" \
egrep="grep -E" \ egrep="grep -E" \
fgrep="grep -F" fgrep="grep -F"
alias monero='monero-wallet-cli \
--daemon-address monero.maby.dev:18081 \
--wallet-file /home/ange/.config/monero/ange --trusted-daemon \
--log-file=/tmp/monero-wallet-cli.log'
# vim: ft=zsh # vim: ft=zsh

View File

@ -2460,7 +2460,7 @@ _git-config () {
'(3 -z --null --name-only --show-origin)--add[add new value without altering any existing ones]' \ '(3 -z --null --name-only --show-origin)--add[add new value without altering any existing ones]' \
'(2 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--unset[remove the first matching value of the key]' \ '(2 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--unset[remove the first matching value of the key]' \
'(2 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--unset-all[remove all matching values of the key]' \ '(2 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--unset-all[remove all matching values of the key]' \
'(3 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--rename-section[rename the given section]' \ '(3 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--rename-section[rename the given section]' \
'(3 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--remove-section[remove the given section]' \ '(3 --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)--remove-section[remove the given section]' \
'(: --bool --int --bool-or-int --bool-or-str --path)'{-l,--list}'[list all variables set in config file]' \ '(: --bool --int --bool-or-int --bool-or-str --path)'{-l,--list}'[list all variables set in config file]' \
'(-e --edit --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)'{-e,--edit}'[open config file for editing]' \ '(-e --edit --bool --int --bool-or-int --bool-or-str --path -z --null --name-only --show-origin)'{-e,--edit}'[open config file for editing]' \

View File

@ -1,5 +1,5 @@
#compdef j #compdef j
_j() { _j() {
_arguments "1: :($(find . -mount -name "$1*" -type d -printf "'%P' " 2> /dev/null))" _arguments "1: :(**/"$1"*~cvs~node_modules/)"
} }

2
bin/am
View File

@ -24,7 +24,7 @@ function clear_output() {
function main() { function main() {
while true; do while true; do
readarray -t LSBLK <<< "$(lsblk -n --paths --list | grep part)" mapfile -t LSBLK <<< "$(lsblk -n --paths --list | grep part)"
COLUMNS=1 COLUMNS=1
select dev in "${LSBLK[@]}"; do select dev in "${LSBLK[@]}"; do

View File

@ -1,5 +1,5 @@
#!/bin/bash -e #!/bin/bash -e
CRI=(sudo docker) CRI=(podman)
"${CRI[@]}" run --rm -it -v "$PWD:/mnt/" -w /mnt/ docker.io/archlinux/archlinux:base "${CRI[@]}" run --rm -it -v "$PWD:/mnt/" -w /mnt/ docker.io/archlinux/archlinux:base

View File

@ -1,15 +0,0 @@
#!/bin/bash -e
CRI=(sudo docker)
REPORTS="$(mktemp -d)"
LOGS="$REPORTS/coding-style-reports.log"
"${CRI[@]}" run --rm \
-v "$PWD:/mnt/delivery" \
-v "$REPORTS:/mnt/reports" \
ghcr.io/epitech/coding-style-checker:latest \
/mnt/delivery /mnt/reports
cat "$LOGS"
echo "$(grep -c ': MAJOR:' "$LOGS") major, $(grep -c ': MINOR:' "$LOGS") minor, $(grep -c ': INFO:' "$LOGS") info coding style error(s) reported in $LOGS"

View File

@ -1,5 +1,5 @@
#!/bin/bash -e #!/bin/bash -e
CRI=(sudo docker) CRI=(podman)
"${CRI[@]}" run --rm -it -v "$PWD:/mnt/" -w /mnt/ docker.io/debian:12-slim "${CRI[@]}" run --rm -it -v "$PWD:/mnt/" -w /mnt/ docker.io/debian:12-slim

View File

@ -1,6 +1,6 @@
#!/bin/bash -e #!/bin/bash -e
CRI=(sudo docker) CRI=(podman)
CRI_OPT=() CRI_OPT=()
if [ -z "$WAYLAND_DISPLAY" ]; then if [ -z "$WAYLAND_DISPLAY" ]; then
@ -11,20 +11,20 @@ if [ -z "$WAYLAND_DISPLAY" ]; then
) )
fi fi
"${CRI[@]}" run --rm -it --name epitest \ "${CRI[@]}" run --rm -it --name epitest \
"${CRI_OPT[@]}" \ "${CRI_OPT[@]}" \
--ipc=host \ --ipc=host \
--device /dev/dri/ \ --device /dev/dri/ \
-e DISPLAY \ -e DISPLAY \
-e XDG_RUNTIME_DIR \ -e XDG_RUNTIME_DIR \
-e MAKEFLAGS \ -e MAKEFLAGS \
-e CFLAGS=-g3 \ -e CFLAGS=-g3 \
-e CXXFLAGS=-g3 \ -e CXXFLAGS=-g3 \
-v /tmp/.X11-unix/:/tmp/.X11-unix/ \ -v /tmp/.X11-unix/:/tmp/.X11-unix/ \
-v "$XDG_RUNTIME_DIR:$XDG_RUNTIME_DIR" \ -v "$XDG_RUNTIME_DIR:$XDG_RUNTIME_DIR" \
-v /usr/share/fonts/:/usr/share/fonts/:ro \ -v /usr/share/fonts/:/usr/share/fonts/:ro \
-v "$PWD:$PWD" \ -v "$PWD:$PWD" \
-w "$PWD" \ -w "$PWD" \
--ulimit nofile=8192:8192 \ --ulimit nofile=8192:8192 \
docker.io/epitechcontent/epitest-docker:latest \ docker.io/epitechcontent/epitest-docker:latest \
"$@" "$@"

View File

@ -1,3 +1,4 @@
#!/bin/bash -e #!/bin/bash -e
xdg-open "$(pass "$(cat /tmp/passselect)" | sed -n '/^URL:/{s/URL:\s*//p;q}')" xdg-open \
"$(pass show "$(cat /tmp/passselect)" | sed -n '/^URL:/{s/URL:\s*//p;q}')"

View File

@ -1,8 +1,4 @@
#!/bin/bash -e #!/bin/bash -e
txt="$(pass otp "$(cat /tmp/passselect)")" xdotool type --clearmodifiers --delay 0 \
bak="$(xclip -o -sel c)" "$(pass otp "$(cat /tmp/passselect)")"
xclip -sel c <<< "$txt"
xdotool key --clearmodifiers 'ctrl+v'
xclip -sel c <<< "$txt"

View File

@ -1,8 +1,4 @@
#!/bin/bash -e #!/bin/bash -e
txt="$(pass "$(cat /tmp/passselect)" | head -n1 -)" xdotool type --clearmodifiers --delay 0 \
bak="$(xclip -o -sel c)" "$(pass show "$(cat /tmp/passselect)" | head -n1 -)"
xclip -sel c <<< "$txt"
xdotool key --clearmodifiers 'ctrl+v'
xclip -sel c <<< "$txt"

View File

@ -1,8 +1,4 @@
#!/bin/bash -e #!/bin/bash -e
txt="$(pass "$(cat /tmp/passselect)" | sed -n '/^Username:/{s/Username:\s*//p;q}')" xdotool type --clearmodifiers --delay 0 \
bak="$(xclip -o -sel c)" "$(pass show "$(cat /tmp/passselect)" | sed -n '/^Username:/{s/Username:\s*//p;q}')"
xclip -sel c <<< "$txt"
xdotool key --clearmodifiers 'ctrl+v'
xclip -sel c <<< "$txt"

1
bin/steam Executable file
View File

@ -0,0 +1 @@
#!/usr/bin/env -Scom.valvesoftware.Steam -no-browser +open 'steam://open/minigameslist'