diff --git a/.config/fish/config.fish b/.config/fish/config.fish deleted file mode 100644 index 33f1119..0000000 --- a/.config/fish/config.fish +++ /dev/null @@ -1,52 +0,0 @@ -if status is-login - # Utilities - if type -q nvim - set --global --export EDITOR "nvim" - else if type -q vim - set --global --export EDITOR "vim" - end - set --global --export PAGER "less" - type -q kitty && set --global --export TERMINAL "kitty" - - # Path - function add_path - set --function bin_path "$argv[1]" - if test -d "$bin_path" - if not contains "$bin_path" $PATH - set --global --export PATH "$bin_path" $PATH - end - end - end - add_path "$HOME/.local/bin" - add_path "$HOME/.cargo/bin" - - # SSH agent - # Enable it using `systemctl enable --user ssh-agent.service` - begin - set --local ssh_agent_socket "$XDG_RUNTIME_DIR/ssh-agent.socket" - test -S "$ssh_agent_socket" && set --global --export SSH_AUTH_SOCK "$ssh_agent_socket" - end - - # XDG - set --global --export XDG_USER_DIR_FILE "$HOME/.config/user-dirs.dirs" - set --global --export XDG_DESKTOP_DIR "$HOME/desktop" - set --global --export XDG_DOWNLOAD_DIR "$HOME/downloads" - set --global --export XDG_TEMPLATES_DIR "$HOME/templates" - set --global --export XDG_PUBLICSHARE_DIR "$HOME/public_share" - set --global --export XDG_DOCUMENTS_DIR "$HOME/documents" - set --global --export XDG_MUSIC_DIR "$HOME/music" - set --global --export XDG_PICTURES_DIR "$HOME/pictures" - set --global --export XDG_VIDEOS_DIR "$HOME/videos" - - # Java - # https://wiki.archlinux.org/title/Java#Switching_between_JVM - set --global --export JAVA_HOME "/usr/lib/jvm/default" -end - -if status is-interactive - # Disable the Fish greeting message - set --global fish_greeting - - # zoxide - zoxide init fish | source -end diff --git a/.config/fish/functions/audio-dl.fish b/.config/fish/functions/audio-dl.fish deleted file mode 100644 index e62d9bb..0000000 --- a/.config/fish/functions/audio-dl.fish +++ /dev/null @@ -1,3 +0,0 @@ -function audio-dl - command yt-dlp --extract-audio --audio-quality 0 --audio-format "vorbis" $argv -end diff --git a/.config/fish/functions/clang-format.fish b/.config/fish/functions/clang-format.fish deleted file mode 100644 index cac82b7..0000000 --- a/.config/fish/functions/clang-format.fish +++ /dev/null @@ -1,4 +0,0 @@ -function clang-format - set --local style "{BasedOnStyle: llvm, IndentWidth: 4, AllowShortFunctionsOnASingleLine: None, KeepEmptyLinesAtTheStartOfBlocks: false}" - command clang-format -style="$style" $argv -end diff --git a/.config/fish/functions/df.fish b/.config/fish/functions/df.fish deleted file mode 100644 index 32e65a9..0000000 --- a/.config/fish/functions/df.fish +++ /dev/null @@ -1,3 +0,0 @@ -function df - command df -h $argv -end diff --git a/.config/fish/functions/du.fish b/.config/fish/functions/du.fish deleted file mode 100644 index 55d0ed1..0000000 --- a/.config/fish/functions/du.fish +++ /dev/null @@ -1,7 +0,0 @@ -function du - if type -q duf - command duf $argv - else - command du $argv - end -end diff --git a/.config/fish/functions/grep.fish b/.config/fish/functions/grep.fish deleted file mode 100644 index 2221e6f..0000000 --- a/.config/fish/functions/grep.fish +++ /dev/null @@ -1,9 +0,0 @@ -function grep - if test "$pipestatus" = "0" - # No pipe before the grep - command grep -n --color=auto $argv - else - # There is a pipe before the grep - command grep --color=auto $argv - end -end diff --git a/.config/fish/functions/hx.fish b/.config/fish/functions/hx.fish deleted file mode 100644 index 004f300..0000000 --- a/.config/fish/functions/hx.fish +++ /dev/null @@ -1,3 +0,0 @@ -function hx - command helix $argv -end diff --git a/.config/fish/functions/ip.fish b/.config/fish/functions/ip.fish deleted file mode 100644 index 8781758..0000000 --- a/.config/fish/functions/ip.fish +++ /dev/null @@ -1,3 +0,0 @@ -function ip - command ip --color $argv -end diff --git a/.config/fish/functions/j.fish b/.config/fish/functions/j.fish deleted file mode 100644 index 3bb0650..0000000 --- a/.config/fish/functions/j.fish +++ /dev/null @@ -1,3 +0,0 @@ -function j - command jobs $argv -end diff --git a/.config/fish/functions/kitty_ssh.fish b/.config/fish/functions/kitty_ssh.fish deleted file mode 100644 index 0e152f2..0000000 --- a/.config/fish/functions/kitty_ssh.fish +++ /dev/null @@ -1,3 +0,0 @@ -function kitty_ssh - command kitty +kitten ssh $argv -end diff --git a/.config/fish/functions/l.fish b/.config/fish/functions/l.fish deleted file mode 100644 index 5b82ad3..0000000 --- a/.config/fish/functions/l.fish +++ /dev/null @@ -1,3 +0,0 @@ -function l - ls -AlihF $argv -end diff --git a/.config/fish/functions/ls.fish b/.config/fish/functions/ls.fish deleted file mode 100644 index 1855245..0000000 --- a/.config/fish/functions/ls.fish +++ /dev/null @@ -1,11 +0,0 @@ -function ls - if type -q eza - command eza $argv - else - if test "$(uname -s | tr '[:upper:]' '[:lower:]')" = 'linux' - command ls --color=auto $argv - else - command ls $argv - end - end -end diff --git a/.config/fish/functions/mount_ro.fish b/.config/fish/functions/mount_ro.fish deleted file mode 100644 index 472e0d1..0000000 --- a/.config/fish/functions/mount_ro.fish +++ /dev/null @@ -1,3 +0,0 @@ -function mount_ro - command mount -o ro,noexec,noatime,nodev,nosuid,noiversion $argv -end diff --git a/.config/fish/functions/sqlmap-tor.fish b/.config/fish/functions/sqlmap-tor.fish deleted file mode 100644 index 04977a8..0000000 --- a/.config/fish/functions/sqlmap-tor.fish +++ /dev/null @@ -1,3 +0,0 @@ -function sqlmap-tor - sqlmap --tor --tor-type=SOCKS5 $argv -end diff --git a/.config/fish/functions/sqlmap.fish b/.config/fish/functions/sqlmap.fish deleted file mode 100644 index 7e1d3e2..0000000 --- a/.config/fish/functions/sqlmap.fish +++ /dev/null @@ -1,3 +0,0 @@ -function sqlmap - command sqlmap --user-agent="Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" $argv -end diff --git a/.config/fish/functions/t.fish b/.config/fish/functions/t.fish deleted file mode 100644 index 88c3ddb..0000000 --- a/.config/fish/functions/t.fish +++ /dev/null @@ -1,3 +0,0 @@ -function t - command tree $argv -end diff --git a/.config/fish/functions/top.fish b/.config/fish/functions/top.fish deleted file mode 100644 index 6bb4c8d..0000000 --- a/.config/fish/functions/top.fish +++ /dev/null @@ -1,9 +0,0 @@ -function top - if type -q btop - command btop $argv - else if type -q htop - command htop $argv - else - command top $argv - end -end diff --git a/.config/fish/functions/vim.fish b/.config/fish/functions/vim.fish deleted file mode 100644 index 5c16704..0000000 --- a/.config/fish/functions/vim.fish +++ /dev/null @@ -1,7 +0,0 @@ -function vim - if type -q nvim - command nvim $argv - else - command vim $argv - end -end diff --git a/.config/hypr/hyprland.conf b/.config/hypr/hyprland.conf index e03cd84..a87e1bc 100644 --- a/.config/hypr/hyprland.conf +++ b/.config/hypr/hyprland.conf @@ -45,7 +45,6 @@ $lock = swaylock --color=000000 --daemonize # exec-once = waybar & hyprpaper & firefox exec-once = ~/.local/bin/set_wallpaper exec-once = waybar -exec-once = hyprctl keyword monitor "Unknown-1, disable" ############################# diff --git a/.config/i3/config b/.config/i3/config new file mode 100644 index 0000000..452ec29 --- /dev/null +++ b/.config/i3/config @@ -0,0 +1,165 @@ +# This file has been auto-generated by i3-config-wizard(1). +# It will not be overwritten, so edit it as you like. +# +# Should you change your keyboard layout some time, delete +# this file and re-run i3-config-wizard(1). +# + +# i3 config file (v4) +# +# Please see http://i3wm.org/docs/userguide.html for a complete reference! + +set $mod Mod4 +set $media_player rhythmbox + +# Font for window titles. Will also be used by the bar unless a different font +# is used in the bar {} block below. +font pango:monospace 8 + +# This font is widely installed, provides lots of unicode glyphs, right-to-left +# text rendering and scalability on retina/hidpi displays (thanks to pango). +#font pango:DejaVu Sans Mono 8 + +# Before i3 v4.8, we used to recommend this one as the default: +# font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1 +# The font above is very space-efficient, that is, it looks good, sharp and +# clear in small sizes. However, its unicode glyph coverage is limited, the old +# X core fonts rendering does not support right-to-left and this being a bitmap +# font, it doesn’t scale on retina/hidpi displays. + +# Use Mouse+$mod to drag floating windows to their wanted position +floating_modifier $mod + +# start a terminal +bindsym $mod+Return exec i3-sensible-terminal + +# kill focused window +bindsym $mod+Shift+q kill + +# start dmenu (a program launcher) +bindsym $mod+d exec dmenu_run +# There also is the (new) i3-dmenu-desktop which only displays applications +# shipping a .desktop file. It is a wrapper around dmenu, so you need that +# installed. +# bindsym $mod+d exec --no-startup-id i3-dmenu-desktop + +# change focus +bindsym $mod+Left focus left +bindsym $mod+Down focus down +bindsym $mod+Up focus up +bindsym $mod+Right focus right + +# move focused window +bindsym $mod+Shift+j move left +bindsym $mod+Shift+k move down +bindsym $mod+Shift+l move up +bindsym $mod+Shift+semicolon move right + +# alternatively, you can use the cursor keys: +bindsym $mod+Shift+Left move left +bindsym $mod+Shift+Down move down +bindsym $mod+Shift+Up move up +bindsym $mod+Shift+Right move right + +# split in horizontal orientation +bindsym $mod+h split h + +# split in vertical orientation +bindsym $mod+v split v + +# enter fullscreen mode for the focused container +bindsym $mod+f fullscreen toggle + +# change container layout (stacked, tabbed, toggle split) +bindsym $mod+s layout stacking +bindsym $mod+w layout tabbed +bindsym $mod+e layout toggle split + +# toggle tiling / floating +bindsym $mod+Shift+space floating toggle + +# change focus between tiling / floating windows +bindsym $mod+space focus mode_toggle + +# focus the parent container +bindsym $mod+a focus parent + +# focus the child container +#bindsym $mod+d focus child + +# switch to workspace +bindsym $mod+1 workspace 1 +bindsym $mod+2 workspace 2 +bindsym $mod+3 workspace 3 +bindsym $mod+4 workspace 4 +bindsym $mod+5 workspace 5 +bindsym $mod+6 workspace 6 +bindsym $mod+7 workspace 7 +bindsym $mod+8 workspace 8 +bindsym $mod+9 workspace 9 +bindsym $mod+0 workspace 10 + +# move focused container to workspace +bindsym $mod+Shift+1 move container to workspace 1 +bindsym $mod+Shift+2 move container to workspace 2 +bindsym $mod+Shift+3 move container to workspace 3 +bindsym $mod+Shift+4 move container to workspace 4 +bindsym $mod+Shift+5 move container to workspace 5 +bindsym $mod+Shift+6 move container to workspace 6 +bindsym $mod+Shift+7 move container to workspace 7 +bindsym $mod+Shift+8 move container to workspace 8 +bindsym $mod+Shift+9 move container to workspace 9 +bindsym $mod+Shift+0 move container to workspace 10 + +# reload the configuration file +bindsym $mod+Shift+c reload +# restart i3 inplace (preserves your layout/session, can be used to upgrade i3) +bindsym $mod+Shift+r restart +# exit i3 (logs you out of your X session) +bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'" + +# resize window (you can also use the mouse for that) +mode "resize" { + # These bindings trigger as soon as you enter the resize mode + + # Pressing left will shrink the window’s width. + # Pressing right will grow the window’s width. + # Pressing up will shrink the window’s height. + # Pressing down will grow the window’s height. + bindsym j resize shrink width 10 px or 10 ppt + bindsym k resize grow height 10 px or 10 ppt + bindsym l resize shrink height 10 px or 10 ppt + bindsym semicolon resize grow width 10 px or 10 ppt + + # same bindings, but for the arrow keys + bindsym Left resize shrink width 10 px or 10 ppt + bindsym Down resize grow height 10 px or 10 ppt + bindsym Up resize shrink height 10 px or 10 ppt + bindsym Right resize grow width 10 px or 10 ppt + + # back to normal: Enter or Escape + bindsym Return mode "default" + bindsym Escape mode "default" +} + +bindsym $mod+r mode "resize" + +# Screenshot +bindsym Print exec scrot -e 'mv $f ~/pictures/ 2>/dev/null' + +# Screen lock +bindsym $mod+l exec 'lock' + +# Media player controls + +bindsym XF86AudioPlay exec playerctl --player $media_player play-pause +bindsym XF86AudioPause exec playerctl --player $media_player play-pause +bindsym XF86AudioNext exec playerctl --player $media_player next +bindsym XF86AudioPrev exec playerctl --player $media_player previous + +# Start i3bar to display a workspace bar (plus the system information i3status +# finds out, if available) +bar { + position top + status_command i3status +} diff --git a/.config/i3status/config b/.config/i3status/config new file mode 100644 index 0000000..6833a0c --- /dev/null +++ b/.config/i3status/config @@ -0,0 +1,45 @@ +# i3status configuration file. +# see "man i3status" for documentation. + +# It is important that this file is edited as UTF-8. +# The following line should contain a sharp s: +# ß +# If the above line is not correctly displayed, fix your editor first! + +general { + colors = true + interval = 5 +} + +order += "disk /" +order += "disk /home" +order += "ipv6" +order += "ethernet _first_" +order += "load" +order += "tztime local" + +ethernet _first_ { + # if you use %speed, i3status requires root privileges + format_up = "E: %ip (%speed)" + format_down = "E: down" +} + +tztime local { + format = "%A %d %B %Y %H:%M:%S" +} + +load { + format = "%1min" +} + +disk "/" { + format = "%free (%avail) / %total" + threshold_type = "gbytes_avail" + low_threshold = "5" +} + +disk "/home" { + format = "/home %free (%avail) / %total" + threshold_type = "gbytes_avail" + low_threshold = "20" +} diff --git a/.config/liquidpromptrc b/.config/liquidpromptrc new file mode 100644 index 0000000..18eaf97 --- /dev/null +++ b/.config/liquidpromptrc @@ -0,0 +1,142 @@ + +#################################### +# LIQUID PROMPT CONFIGURATION FILE # +#################################### + +# If you want to use different themes and features, +# you can load the corresponding files here: +#source ~/code/liquidprompt/nojhan.theme +#LP_PS1_FILE="~/code/liquidprompt/nojhan.ps1" +LP_PS1_POSTFIX="-> " + +############# +# BEHAVIOUR # +############# + +# Maximal value under which the battery level is displayed +# Recommended value is 75 +LP_BATTERY_THRESHOLD=75 + +# Minimal value after which the load average is displayed +# Recommended value is 60 +LP_LOAD_THRESHOLD=60 + +# Minimal value after which the temperature is displayed (in celsius degrees) +# Recommended value is 60 +LP_TEMP_THRESHOLD=60 + +# The maximum percentage of the screen width used to display the path +# Recommended value is 35 +LP_PATH_LENGTH=35 + +# How many directories to keep at the beginning of a shortened path +# Recommended value is 2 +LP_PATH_KEEP=2 + +# Do you want to display the hostname, even if not connected through network? +# Defaults to 0 (do not display hostname when localy connected) +# set to 1 if you want to always see the hostname +LP_HOSTNAME_ALWAYS=0 + +# Do you want to display the user, even if he is the same than the logged one? +# Defaults to 1 (always display the user) +# set to 0 if you want to hide the logged user (it will always display different users) +LP_USER_ALWAYS=1 + +# Do you want to display the percentages of load/batteries along with their +# corresponding marks? Set to 0 to only print the colored marks. +# Defaults to 1 (display percentages) +LP_PERCENTS_ALWAYS=1 + +# Do you want to use the permissions feature ? +# Recommended value is 1 +LP_ENABLE_PERM=1 + +# Do you want to use the shorten path feature ? +# Recommended value is 1 +LP_ENABLE_SHORTEN_PATH=1 + +# Do you want to use the proxy detection feature ? +# Recommended value is 1 +LP_ENABLE_PROXY=1 + +# Do you want to use the jobs feature ? +# Recommended value is 1 +LP_ENABLE_JOBS=1 + +# Do you want to use the load feature ? +# Recommended value is 1 +LP_ENABLE_LOAD=1 + +# Do you want to use the batt feature ? +# Recommended value is 1 +LP_ENABLE_BATT=1 + +# Do you want to use vcs features with root account +# Recommended value is 0 +LP_ENABLE_VCS_ROOT=0 + +# Do you want to use the git special features ? +# Recommended value is 1 +LP_ENABLE_GIT=1 + +# Do you want to use the svn special features ? +# Recommended value is 1 +LP_ENABLE_SVN=1 + +# Do you want to use the mercurial special features ? +# Recommended value is 1 +LP_ENABLE_HG=1 + +# Do you want to use the fossil special features ? +# Recommended value is 1 +LP_ENABLE_FOSSIL=1 + +# Do you want to use the bzr special features ? +# Recommanded value is 1 +LP_ENABLE_BZR=1 + +# Show time of the last prompt display +# Recommended value is 0 +LP_ENABLE_TIME=0 + +# Show runtime of the last command if over LP_RUNTIME_THRESHOLD +# Recommended value is 0 +LP_ENABLE_RUNTIME=0 + +# Minimal runtime to be displayed +# Recommended value is 2 +LP_RUNTIME_THRESHOLD=2 + +# Display the virtualenv that is currently activated, if any +# Recommended value is 1 +LP_ENABLE_VIRTUALENV=1 + +# Show average system temperature +LP_ENABLE_TEMP=1 + +# When showing time, use an analog clock instead of numeric values. +# The analog clock is "accurate" to the nearest half hour. +# You must have a unicode-capable terminal and a font with the "CLOCK" +# characters. +# Recommended value is 0 +LP_TIME_ANALOG=0 + +# Use the liquid prompt as the title of the terminal window +# This may not work properly on exotic terminals, thus the +# recommended value is 0 +# See LP_TITLE_OPEN and LP_TITLE_CLOSE to change escape characters to adapt this +# feature to your specific terminal. +LP_ENABLE_TITLE=0 + +# Enable Title for screen and byobu +LP_ENABLE_SCREEN_TITLE=0 + +# Use differents colors for differents hosts you SSH in +LP_ENABLE_SSH_COLORS=0 + +# Specify a list of complete and colon (":") separated paths in which, all vcs +# will be disabled +LP_DISABLED_VCS_PATH="" + +# vim: set et sts=4 sw=4 tw=120 ft=sh: diff --git a/.config/rodolphe/.aliases b/.config/rodolphe/.aliases new file mode 100644 index 0000000..f3fbe1c --- /dev/null +++ b/.config/rodolphe/.aliases @@ -0,0 +1,55 @@ +# +# Aliases for ls +# + +[ "$(uname -s | tr '[:upper:]' '[:lower:]')" = 'linux' ] && alias ls='ls --color=auto' +alias ll='ls -lihF' +alias la='ls -A' +alias l='ll -A' +hash eza 2>/dev/null && alias ls='eza' + + +# +# Aliases for common commands +# + +alias df='df -h' +alias grep='grep -n --color=auto' +alias ip='ip --color' +alias ipb='ip --color --brief' +alias j='jobs' +alias mount_ro='mount -o ro,noexec,noatime,nodev,nosuid,noiversion' +alias sudo='sudo ' + + +# +# Aliases for installed programs +# + +hash clang-format 2>/dev/null && alias clang-format='clang-format -style="{BasedOnStyle: llvm, IndentWidth: 4, AllowShortFunctionsOnASingleLine: None, KeepEmptyLinesAtTheStartOfBlocks: false}"' +hash duf 2>/dev/null && alias du='duf' +hash helix 2>/dev/null && alias hx='helix' +hash htop 2>/dev/null && alias top='htop' +hash kitty 2>/dev/null && alias kitty_ssh='kitty +kitten ssh' +hash nvim 2>/dev/null && alias vim='nvim' +hash tree 2>/dev/null && alias t='tree' +hash yt-dlp 2>/dev/null && alias audio-dl='yt-dlp --extract-audio --audio-quality 0 --audio-format "vorbis"' + +if hash sqlmap 2>/dev/null; then + alias sqlmap='sqlmap --user-agent="Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"' + alias sqlmap-tor='sqlmap --tor --tor-type=SOCKS5' +fi + +# https://github.com/OpenXRay/xray-16 +if hash xr_3da 2>/dev/null; then + alias stalker_shadow_of_chernobyl='xr_3da -soc' + alias stalker_clear_sky='xr_3da -cs' + alias stalker_call_of_pripyat='xr_3da' +fi + +if hash yay 2>/dev/null; then + reinstall_pattern() { + PATTERN="$1" + yay -S $(pacman -Qm | /bin/grep "$PATTERN" | cut -d ' ' -f1) + } +fi diff --git a/.config/rodolphe/.set_compose_key.sh b/.config/rodolphe/.set_compose_key.sh new file mode 100755 index 0000000..da417dc --- /dev/null +++ b/.config/rodolphe/.set_compose_key.sh @@ -0,0 +1,11 @@ +# Since all keyboards does not include the same keys, the compose key +# should be customized. In order to achieve that, this script requires +# a symbolic link to point to a file containing the name of the key that +# will be used as a compose key. + +COMPOSE_KEY_FILE="$HOME/.compose_key" + +if [ -f "$COMPOSE_KEY_FILE" ]; then + COMPOSE_KEY=$(cat "$COMPOSE_KEY_FILE") + setxkbmap -option "compose:$COMPOSE_KEY" +fi diff --git a/.config/rodolphe/.setpath.sh b/.config/rodolphe/.setpath.sh new file mode 100644 index 0000000..b954a24 --- /dev/null +++ b/.config/rodolphe/.setpath.sh @@ -0,0 +1,11 @@ +add_path() { + BIN_PATH="$1" + if [ -d "$BIN_PATH" ]; then + found=$(echo $PATH | tr ':' '\n' | grep -w "$BIN_PATH") + [ ! "$found" ] && export PATH="$BIN_PATH:$PATH" + true + fi +} + +add_path "$HOME/.local/bin" +add_path "$HOME/.cargo/bin" diff --git a/.config/rodolphe/.xdg_set_env.sh b/.config/rodolphe/.xdg_set_env.sh new file mode 100755 index 0000000..b1fb69d --- /dev/null +++ b/.config/rodolphe/.xdg_set_env.sh @@ -0,0 +1,6 @@ +XDG_USER_DIR_FILE="$HOME/.config/user-dirs.dirs" + +if [ -f "$XDG_USER_DIR_FILE" ]; then + . "$XDG_USER_DIR_FILE" + export XDG_PICTURES_DIR="$XDG_PICTURES_DIR" +fi diff --git a/.config/zsh/.zprofile b/.config/zsh/.zprofile new file mode 100644 index 0000000..808cf24 --- /dev/null +++ b/.config/zsh/.zprofile @@ -0,0 +1,6 @@ +# create the missing directories +[ ! -d "$HISTFILE_DIR" ] && mkdir -p "$HISTFILE_DIR" +[ ! -d "$COMPDIR" ] && mkdir -p "$COMPDIR" + +hash transmission-daemon 2>/dev/null && transmission-daemon +hash kitty 2>/dev/null && export TERMINAL="kitty" diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc new file mode 100644 index 0000000..cd6dc9c --- /dev/null +++ b/.config/zsh/.zshrc @@ -0,0 +1,62 @@ +setopt no_beep inc_append_history hist_ignore_dups hist_ignore_space extended_glob no_match notify +bindkey -e +bindkey "^[[3~" delete-char +bindkey "^[3;5~" delete-char + +# Colors +[ "$CLICOLOR" -ne 0 ] && hash dircolors 2>/dev/null && eval $(dircolors -b) + +# Command completion +autoload -U compinit +[ -f "$COMPDIR/.zcompdump" ] && compinit -d "$COMPDIR/.zcompdump" + +# Prompt +if [ -f "/usr/bin/liquidprompt" ]; then + unset PROMPT_COMMAND + . "/usr/bin/liquidprompt" +elif [ -f "/usr/share/liquidprompt/liquidprompt" ]; then + unset PROMPT_COMMAND + . "/usr/share/liquidprompt/liquidprompt" +elif [ -f "$HOME/liquidprompt/liquidprompt" ]; then + unset PROMPT_COMMAND + . "$HOME/liquidprompt/liquidprompt" +elif [ "$CLICOLOR" -ne 0 ]; then + autoload -U colors && colors + PS1="%{$fg[red]%}%n%{$reset_color%}@%{$fg[yellow]%}%M%{$fg[red]%}->%{$reset_color%} " +else + PS1='%n@%M-> ' +fi + +# Syntax-highlighting +if [ -f "/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" ]; then + . "/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" +fi + +# SSH agent +# Enable it using `systemctl enable --user ssh-agent.service` +[ -S "$XDG_RUNTIME_DIR/ssh-agent.socket" ] && export SSH_AUTH_SOCK="$XDG_RUNTIME_DIR/ssh-agent.socket" + +# Aliases +[ -f "$MY_CONFIG/.aliases" ] && . "$MY_CONFIG/.aliases" + +# Proxy settings +[ -f "$HOME/.proxy" ] && . "$HOME/.proxy" + +# skim +[ -f "/usr/share/skim/key-bindings.zsh" ] && . /usr/share/skim/key-bindings.zsh +[ -f "/usr/share/skim/completion.zsh" ] && . /usr/share/skim/completion.zsh + +# zoxide +hash zoxide 2>/dev/null && eval "$(zoxide init zsh)" + +# Java +# +# Use `archlinux-java` to change the default Java environment. +# List directories in `/usr/lib/jvm/` to see all possible values. +# +# Example: +# sudo archlinux-java set java-13-openjdk +[ -d "/usr/lib/jvm/default" ] && export JAVA_HOME="/usr/lib/jvm/default" + +# Exit with a success status +true diff --git a/.gitignore b/.gitignore index ee3e922..e45ea76 100644 --- a/.gitignore +++ b/.gitignore @@ -14,17 +14,5 @@ __pycache__/ # Emacs .emacs.d/auto-save-list/ -# Fish -.config/fish/completions -.config/fish/conf.d -.config/fish/fish_plugins -.config/fish/fish_variables -.config/fish/themes - -# Tide -.config/fish/functions/_tide_* -.config/fish/functions/fish_* -.config/fish/functions/tide* - # Auto-generated hyprpaper configuration file .config/hypr/hyprpaper.conf diff --git a/.zshenv b/.zshenv new file mode 100644 index 0000000..cbbbde1 --- /dev/null +++ b/.zshenv @@ -0,0 +1,26 @@ +# ZSH configuration +export ZDOTDIR="$HOME/.config/zsh" + +# Custom configuration +export MY_CONFIG="$HOME/.config/rodolphe" + +# History +export HISTFILE_DIR="$HOME/.local/share/zsh" +export HISTFILE="$HISTFILE_DIR/.zsh_history" +export HISTSIZE=5000 +export SAVEHIST=100000 + +# CLI config +export COMPDIR="$HOME/.cache/zsh" +export CLICOLOR=1 +export EDITOR='vim' +export PAGER='less' + +# Packaging +export USER_NICKNAME="Rodolphe Bréard" +export DEBEMAIL="packages+deb@what.tf" +export DEBFULLNAME="$USER_NICKNAME" + +# Path +[ -f "$MY_CONFIG/.setpath.sh" ] && . "$MY_CONFIG/.setpath.sh" +[ -f "$MY_CONFIG/.xdg_set_env.sh" ] && . "$MY_CONFIG/.xdg_set_env.sh" diff --git a/README.md b/README.md index 0e5db44..80f3dd6 100644 --- a/README.md +++ b/README.md @@ -9,21 +9,17 @@ Installing packages: ``` sh # Base utils -pacman -S bat duf eza fish fisher htop inetutils jq kitty-terminfo neovim openssh tmux transmission-cli tree wget whois zellij +pacman -S bat duf eza htop inetutils jq kitty-terminfo neovim openssh tmux transmission-cli tree wget whois zellij zsh zsh-syntax-highlighting pacman -S shared-mime-info xdg-user-dirs pacman -S reflector pacman -S skim pacman -S yazi unarchiver ffmpegthumbnailer fd ripgrep-all poppler zoxide -# Fonts -pacman -S nerd-fonts noto-fonts noto-fonts-emoji ttf-dejavu ttf-inconsolata ttf-liberation ttf-roboto # Rust pacman -S cargo-audit cargo-outdated cargo-release rustup # Python pacman -S python ruff uv -# Java -pacman -S java-runtime-common # CLI software -pacman -S exiv2 gnupg imagemagick mkcert ncdu nmap pass playerctl python-shodan python-weasyprint qrencode rsync shellcheck sqlmap ssh-audit xsv yt-dlp +pacman -S dog exiv2 gnupg imagemagick mkcert ncdu nmap pass playerctl python-shodan python-weasyprint qrencode rsync shellcheck sqlmap ssh-audit xsv yt-dlp # Hyprland pacman -S hyprland xdg-desktop-portal-hyprland qt5-wayland qt6-wayland pacman -S pipewire wireplumber pipewire-audio pipewire-alsa pipewire-pulse pipewire-jack pipewire-x11-bell @@ -33,6 +29,8 @@ pacman -S swaylock # Graphical software pacman -S atril firefox gedit gimp handbrake kitty mpv openshot pcmanfm-gtk3 rhythmbox ristretto sweethome3d tumbler thunderbird vlc pacman -S gvfs xarchiver +# Fonts +pacman -S noto-fonts noto-fonts-emoji ttf-dejavu ttf-inconsolata ttf-liberation ttf-roboto # Archives pacman -S unrar p7zip zip unzip minizip # Command-line copy/paste utilities @@ -60,33 +58,17 @@ pacman -U "yay--x86_64.pkg.tar.zst" Installing packages: ``` sh -# Vim plugin manager -yay -S vim-plug +# Base utils +yay -S liquidprompt vim-plug # Printer yay -S brother-dcp1610w brscan-skey brscan4 # Graphical software yay -S cardpeek ``` +## vim / neovim -## Fish - -Install the Tide prompt: - -``` -fisher install IlanCosman/tide@v6 -``` - -Configure the prompt: - -``` -tide configure -``` - - -## Vim / Neovim - -Compatibility workaround for Neovim: +Compatibility workaround for NeoVim: ``` ln -s .config/vim .vim