Browse Source

Update

master
Albakham 2 months ago
parent
commit
39e5dd3cd5
Signed by: albakham <dev@geber.ga> GPG Key ID: 6CE390277A579221

+ 0
- 5
bin/brightness View File

@@ -1,5 +0,0 @@
#!/bin/bash

old_brightness=$(cat /sys/class/backlight/amdgpu_bl0/brightness)
new_brightness=$(($old_brightness $1))
echo $new_brightness > /sys/class/backlight/amdgpu_bl0/brightness

+ 4
- 2
bin/kolours View File

@@ -8,10 +8,12 @@ WP="$(find ~/Images/Wallpapers -not -path '*/\.*' -type f | shuf | head -n1 )"

# Generate a GTK theme/colour scheme
# Apply the colour scheme to terminals
wal -i "$WP" -a 75
#wal -i "$WP"
#wal --theme random
wal --theme sexy-tartan

# Scale the wallpaper (fixes multi-monitor setups)
feh --bg-scale "$WP"
feh --bg-center "$WP"

# restart dunst
dunst

+ 2
- 2
bin/mkpkg View File

@@ -1,12 +1,12 @@
#!/bin/bash
sudo -v; while : ; do sudo -v ; sleep 240 ; done &
mkdir ~/repo
cd ~/repos
mkdir ~/clones
cd ~/clones
for i in $(pacman -Qmq); do
git clone https://aur.archlinux.org/${i}.git
cd $i
makechrootpkg -c -r $CHROOT
mv *.pkg.tar.xz $HOME/repo/
mv *.pkg.tar.xz $HOME/repos/
done


+ 6
- 4
compton/.config/compton.conf View File

@@ -61,19 +61,19 @@ shadow-exclude = [
"class_g *= 'Compton'",
"class_g *= 'compton'",
"class_g *= 'conky'",
"class_g *= 'mpv'",
"class_g = 'Chromium' && argb",
"class_g = 'Firefox' && argb",
"class_g ?= 'maim'",
#"!focused",
"fullscreen",
"width >= 1920",
"width >= 1366",
"window_type *= 'normal' && ! name ~= ''"
];
focus-exclude = [
"name *= 'rofi'",
"class_i = 'Popup'",
"class_g = 'mpv'"
];
@@ -85,11 +85,13 @@ blur-background-exclude = [
"class_g ?= 'maim'",
"class_g ?= 'slop'",
"class_g = 'vlc'",
"class_g = 'plexmediaplayer'"
"class_g = 'plexmediaplayer'",
"class_g = 'mpv'"
];
fade-exclude = [
"width >= 1920",
"class_g = 'mpv'",
"width >= 1366",
"fullscreen"
];

+ 11
- 11
conky/.config/conky/conky.conf View File

@@ -4,7 +4,7 @@ conky.config = {
-- Generic Settings
-------------------------------------
background=true,
update_interval=1,
update_interval=3,
double_buffer=true,
no_buffers=true,
imlib_cache_size=10,
@@ -22,7 +22,7 @@ show_graph_range=false,
-------------------------------------
-- Window Specifications
-------------------------------------
gap_x=1100,
gap_x=1050,
gap_y=70,
minimum_height=620,
minimum_width=268,
@@ -101,7 +101,7 @@ template9=""
conky.text = [[
\
\
${execi 300 ~/.harmattan-assets/get_weather ${template6} ${template7} ${template8} ${template9}}\
${execi 1000 ~/.harmattan-assets/get_weather ${template6} ${template7} ${template8} ${template9}}\
\
\
\
@@ -137,11 +137,11 @@ ${color2}${voffset -13}${alignc -77}${execi 300 ~/.harmattan-assets/parse_weathe
\
\
\
${goto 36}${voffset -172}${font Droid Sans :size=36}${color4}${execi 300 jq -r .main.temp ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num}${if_match "$template8" == "metric"} °C${else}${if_match "$template8" == "imperial"} °F${else}${if_match "$template8" == "default"} K${endif}${endif}${endif}${font}${color}
${goto 46}${voffset 14}${font Droid Sans :size=12}${color4}${execi 300 jq -r .weather[0].description ~/.cache/harmattan-conky/weather.json | sed "s|\<.|\U&|g"}${font}${color}
${color1}${alignr 52}${voffset -73}${execi 300 jq -r .main.pressure ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num} hPa
${color1}${alignr 52}${voffset 7}${execi 300 jq -r .main.humidity ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num} %${color}
${color1}${alignr 52}${voffset 7}${execi 300 jq -r .wind.speed ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num}${if_match "$template8" == "metric"} m/s${else}${if_match "$template8" == "default"} m/s${else}${if_match "$template8" == "imperial"} mi/h${endif}${endif}${endif}${color}
${goto 36}${voffset -172}${font Droid Sans :size=36}${color4}${execi 1000 jq -r .main.temp ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num}${if_match "$template8" == "metric"} °C${else}${if_match "$template8" == "imperial"} °F${else}${if_match "$template8" == "default"} K${endif}${endif}${endif}${font}${color}
${goto 46}${voffset 14}${font Droid Sans :size=12}${color4}${execi 1000 jq -r .weather[0].description ~/.cache/harmattan-conky/weather.json | sed "s|\<.|\U&|g"}${font}${color}
${color1}${alignr 52}${voffset -73}${execi 1000 jq -r .main.pressure ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num} hPa
${color1}${alignr 52}${voffset 7}${execi 1000 jq -r .main.humidity ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num} %${color}
${color1}${alignr 52}${voffset 7}${execi 1000 jq -r .wind.speed ~/.cache/harmattan-conky/weather.json | awk '{print int($1+0.5)}' # round num}${if_match "$template8" == "metric"} m/s${else}${if_match "$template8" == "default"} m/s${else}${if_match "$template8" == "imperial"} mi/h${endif}${endif}${endif}${color}
\
\
\
@@ -247,7 +247,7 @@ ${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}
${image ~/.harmattan-assets/misc/Numix/God-Mode/pressure.png -p 224,97 -s 16x16}\
${image ~/.harmattan-assets/misc/Numix/God-Mode/humidity.png -p 224,117 -s 16x16}\
${image ~/.harmattan-assets/misc/Numix/God-Mode/wind-2.png -p 224,138 -s 16x16}\
${execi 300 cp -f ~/.harmattan-assets/icons/#dcdcdc__32/$(~/.harmattan-assets/parse_weather 'first' '.weather[0].id' '0').png ~/.cache/harmattan-conky/weather-1.png}${image ~/.cache/harmattan-conky/weather-1.png -p 41,207 -s 32x32}\
${execi 300 cp -f ~/.harmattan-assets/icons/#dcdcdc__32/$(~/.harmattan-assets/parse_weather 'first' '.weather[0].id' '1').png ~/.cache/harmattan-conky/weather-2.png}${image ~/.cache/harmattan-conky/weather-2.png -p 119,207 -s 32x32}\
${execi 300 cp -f ~/.harmattan-assets/icons/#dcdcdc__32/$(~/.harmattan-assets/parse_weather 'first' '.weather[0].id' '2').png ~/.cache/harmattan-conky/weather-3.png}${image ~/.cache/harmattan-conky/weather-3.png -p 195,207 -s 32x32}${font}${voffset -120}\
${execi 1000 cp -f ~/.harmattan-assets/icons/#dcdcdc__32/$(~/.harmattan-assets/parse_weather 'first' '.weather[0].id' '0').png ~/.cache/harmattan-conky/weather-1.png}${image ~/.cache/harmattan-conky/weather-1.png -p 41,207 -s 32x32}\
${execi 1000 cp -f ~/.harmattan-assets/icons/#dcdcdc__32/$(~/.harmattan-assets/parse_weather 'first' '.weather[0].id' '1').png ~/.cache/harmattan-conky/weather-2.png}${image ~/.cache/harmattan-conky/weather-2.png -p 119,207 -s 32x32}\
${execi 1000 cp -f ~/.harmattan-assets/icons/#dcdcdc__32/$(~/.harmattan-assets/parse_weather 'first' '.weather[0].id' '2').png ~/.cache/harmattan-conky/weather-3.png}${image ~/.cache/harmattan-conky/weather-3.png -p 195,207 -s 32x32}${font}${voffset -120}\
]]

+ 1
- 1
dunst/.config/dunst/dunstrc View File

@@ -104,7 +104,7 @@ follow = mouse

# Should a notification popped up from history be sticky or timeout
# as if it would normally do.
sticky_history = yes
sticky_history = no

# Maximum amount of notifications kept in history
history_length = 20

+ 1
- 0
fonts/.fonts/.fonts View File

@@ -0,0 +1 @@
./.fonts

+ 18
- 14
i3/.config/i3/config View File

@@ -18,7 +18,7 @@ font pango:DejaVu Sans Mono 8
floating_modifier $mod

# start a terminal
bindsym $mod+Return exec i3-sensible-terminal
bindsym $mod+Return exec kitty

# kill focused window
bindsym $mod+Shift+q kill
@@ -45,6 +45,10 @@ bindsym $mod+h focus left
bindsym $mod+j focus down
bindsym $mod+k focus up
bindsym $mod+l focus right
bindsym $mod+Left focus left
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Right focus right

# Pulse Audio controls
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 0 +5% #increase sound volume
@@ -52,8 +56,11 @@ bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 0 -5% #d
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 0 toggle # mute sound

# Sreen brightness controls
bindsym XF86MonBrightnessUp exec brightness +10
bindsym XF86MonBrightnessDown exec brightness -10
bindsym XF86MonBrightnessUp exec xbacklight -inc 10
bindsym XF86MonBrightnessDown exec xbacklight -dec 10

bindsym XF86KbdBrightnessUp exec ~/.config/i3/scripts/kbdbacklight.py + 1
bindsym XF86KbdBrightnessDown exec ~/.config/i3/scripts/kbdbacklight.py - 1

# Media player controls
bindsym XF86AudioPlay exec playerctl play-pause
@@ -146,16 +153,16 @@ client.background $bg
################# Workspace Bindings #################
####################################################################################################

assign [class="Firefox Beta"] $ws1
assign [class="Firefox"] $ws1
assign [class="QOwnNotes"] $ws2
assign [class="code-oss"] $ws2
assign [class="termite"] $ws3
assign [class="Steam"] $ws4
assign [class="vlc"] $ws5
assign [class="nautilus"] $ws6
assign [class="Nautilus"] $ws6
assign [class="discord"] $ws7
assign [class="Keybase"] 7
assign [class="Riot"] 7
assign [class="Discord"] 7
assign [class="Keybase"] $ws7
assign [class="Riot"] $ws7
assign [class="Gimp-2.10"] $ws8
assign [class="Thunderbird"] $ws9
assign [class="Rhythmbox"] $ws10
@@ -167,9 +174,7 @@ assign [class="Rhythmbox"] $ws10
# run with reload
exec_always --no-startup-id "setxkbmap fr,fr oss,bepo grp:alt_caps_toggle,grp_led:scroll"
exec_always --no-startup-id "xrandr --auto --output HDMI1 --mode 1280x1024 --right-of eDP1"
exec_always --no-startup-id start-compton
exec_always --no-startup-id kolours
exec_always --no-startup-id lp
exec_always --no-startup-id xrdb -load ~/.Xresources
exec_always --no-startup-id xinput set-prop 12 280 1
exec_always --no-startup-id xinput set-prop 12 281 1
@@ -184,14 +189,12 @@ exec_always --no-startup-id anon
exec_always --no-startup-id dunst
exec_always --no-startup-id nm-applet
exec_always --no-startup-id redshift-gtk
exec_always --no-startup-id $HOME/dotfiles/i3/scripts/conky.sh
## too much proc [exec_always --no-startup-id ~/.config/i3/scripts/conky.sh]

# run on startup only
exec --no-startup-id compton
exec --no-startup-id xset b off
exec --no-startup-id ksuperkey -e 'Super_L=Alt_L|F1'
exec --no-startup-id lico-update.sh -r
exec --no-startup-id lico-update.sh -m
exec --no-startup-id playerctl pause
exec --no-startup-id xset r rate 300 100
exec --no-startup-id "eval $(/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1)"
@@ -233,7 +236,7 @@ bindsym $mod+Shift+r restart
# exit i3 (logs you out of your X session)
bindsym $mod+Shift+e exec ~/.config/rofi/scripts/powermenu.sh
# lock i3
bindsym $mod+shift+x exec playerctl pause && dm-tool lock
bindsym $mod+shift+x exec playerctl pause && i3lock -c 000000
# suspend system
bindsym $mod+s exec systemctl suspend
# launch flameshot
@@ -252,3 +255,4 @@ mode "resize" {
}

bindsym $mod+r mode "resize"


+ 29
- 41
polybar/.config/polybar/config View File

@@ -1,4 +1,4 @@
*;=====================================================
;=====================================================
;
; To learn more about how to configure Polybar
; go to https://github.com/jaagr/polybar
@@ -13,12 +13,18 @@
;--------------------------------------------------------------------;

[colors]
background = ${xrdb:color0:#222}
foreground = ${xrdb:color7:#222}
foreground-alt = ${xrdb:color7:#222}
primary = ${xrdb:color1:#222}
secondary = ${xrdb:color2:#222}
alert = ${xrdb:color3:#222}
#background = ${xrdb:color0:#222}
#foreground = ${xrdb:color7:#222}
#foreground-alt = ${xrdb:color7:#222}
#primary = ${xrdb:color1:#222}
#secondary = ${xrdb:color2:#222}
#alert = ${xrdb:color3:#222}

background = #272822
foreground = #f8f8f2
foreground-alt = #f8f8f2
primary = #4e9a06
alert = #f4bf75

accent = #fba922

@@ -59,28 +65,6 @@ scroll-down = i3wm-wsprev
cursor-click = pointer
cursor-scroll = ns-resize

[module/bspwm]
type = internal/bspwm

label-focused = %index% %icon%
label-focused-background = ${colors.primary}
;label-focused-underline= ${xrdb:color9:#222}
label-focused-padding = 2

label-occupied = %index%
label-occupied-padding = 2

label-urgent = %index%! %icon%
label-urgent-background = ${colors.alert}
label-urgent-padding = 2

label-empty = %index% %icon%
label-empty-foreground = ${colors.foreground-alt}
label-empty-padding = 2

; Separator in between workspaces
; label-separator = |

[module/i3]
type = internal/i3
format = <label-state> <label-mode>
@@ -95,25 +79,25 @@ label-mode-foreground = #000
label-mode-background = ${colors.primary}

; focused = Active workspace on focused monitor
label-focused = %index% %icon%
label-focused-background = ${module/bspwm.label-focused-background}
;label-focused-underline = ${module/bspwm.label-focused-underline}
label-focused-padding = ${module/bspwm.label-focused-padding}
label-focused = %name%
label-focused-background = ${colors.primary}
;label-focused-underline = ${colors.foreground-alt}
label-focused-padding = 2

; unfocused = Inactive workspace on any monitor
label-unfocused = %index% %icon%
label-unfocused-padding = ${module/bspwm.label-occupied-padding}
label-unfocused = %name%
label-unfocused-padding = 2

; visible = Active workspace on unfocused monitor
label-visible = %index% %icon%
label-visible = %name%
label-visible-background = ${self.label-focused-background}
;label-visible-underline = ${self.label-focused-underline}
label-visible-padding = ${self.label-focused-padding}

; urgent = Workspace with urgency hint set
label-urgent = %index% %icon%
label-urgent-background = ${module/bspwm.label-urgent-background}
label-urgent-padding = ${module/bspwm.label-urgent-padding}
label-urgent = %name%
label-urgent-background = ${colors.alert}
label-urgent-padding = 2

ws-icon-0 = 1;
ws-icon-1 = 2;
@@ -207,7 +191,6 @@ format-connected-prefix = ""
format-connected-prefix-foreground = #52FE2C



;--------------------------------------------------------------------;
; Bottom panel
;--------------------------------------------------------------------;
@@ -262,7 +245,7 @@ ramp-volume-0 = " "

[module/mpd]
type = internal/mpd
format-online = <icon-prev> <label-song> <icon-next>
format-online = <icon-prev> <label-song> <icon-next> <bar-progress>

icon-prev = 
icon-play = 
@@ -272,6 +255,11 @@ icon-next = 
label-song-maxlen = 0
label-song-ellipsis = true

bar-progress-width = 24
bar-progress-indicator = |
bar-progress-fill = ─
bar-progress-empty = ─

[module/powermenu]
type = custom/menu


+ 23
- 7
polybar/.config/polybar/pub-ip.sh View File

@@ -1,14 +1,22 @@
#! /bin/bash

function is_openvpn_currently_running() {
function is_openvpn_running() {
if [[ $(pgrep openvpn) == "" ]]; then
echo false
else
else
echo true
fi
}

function is_wireguard_running() {
if [[ $(ls /sys/class/net | grep wg0) != "" ]]; then
echo true
else
echo false
fi
}

for interface in $(ls /sys/class/net/ | grep -v wg0 | grep -v lo | grep -v tun0);
for interface in $(ls /sys/class/net/ | grep wlp2s0 || grep eth0);
do
if [[ $(cat /sys/class/net/$interface/carrier) = 1 ]]; then OnLine=1; fi
done
@@ -16,16 +24,24 @@ if ! [ $OnLine ]; then
# echo "" > /dev/stderr;
echo "Pas de connexion"
exit;
else
else
ip=$(wget --header 'x-pm-appversion: Other' \
--header 'x-pm-apiversion: 3' \
--header 'Accept: application/vnd.protonmail.v1+json' \
-o /dev/null \
--timeout 6 --tries 1 -q -O - 'https://api.protonmail.ch/vpn/location' \
| python -c 'import json; _ = open("/dev/stdin", "r").read(); print(json.loads(_)["IP"])' 2> /dev/null)
if [[ "$(is_openvpn_currently_running)" == true ]]; then
echo  $ip
if [[ "$(is_openvpn_running)" == true ]]; then
if [[ "$(is_wireguard_running)" == true ]]; then
echo   $ip
else
echo  $ip
fi
else
if [[ "$(is_wireguard_running)" == true ]]; then
echo  $ip
else
echo  $ip
echo  $ip
fi
fi
fi

BIN
ranger/.config/ranger/plugins/__pycache__/__init__.cpython-37.opt-1.pyc View File


BIN
ranger/.config/ranger/plugins/__pycache__/devicons_linemode.cpython-37.opt-1.pyc View File


+ 55
- 0
termite/.config/termite/config View File

@@ -0,0 +1,55 @@
[options]
scroll_on_output = false
scroll_on_keystroke = true
audible_bell = false
mouse_autohide = false
allow_bold = true
dynamic_title = true
urgent_on_bell = true
clickable_url = true
font = Fantasque Sans Mono 12
scrollback_lines = 10000
search_wrap = true
icon_name = utilities-terminal
geometry = 750x500
clickable_url = true
cursor_blink = system
cursor_shape = block
browser = exo-open
filter_unmatched_urls = true

[colors]
background = rgba(43,48,59,.75)
foreground = #c0c5ce
foreground_bold = #c0c5ce
cursor = #c0c5ce

# Black, Gray, Silver, White
color0 = #2b303b
color8 = #65737e
color7 = #F6F6F6
color15 = #c0c5ce

# Red
color1 = #bf616a
color9 = #bf616a

# Green
color2 = #a3be8c
color10 = #a3be8c

# Yellow
color3 = #ebcb8b
color11 = #ebcb8b

# Blue
color4 = #8fa1b3
color12 = #8fa1b3

# Purple
color5 = #b48ead
color13 = #b48ead

# Teal
color6 = #96b5b4
color14 = #96b5b4

+ 4
- 3
tmux/.tmux.conf View File

@@ -1,5 +1,6 @@
set-option -g prefix C-q
set-window-option -g mode-keys vi
bind-key -t vi-copy 'v' begin-selection
bind-key -t vi-copy 'y' copy-selection
set -g mouse on
set -g @plugin 'jimeh/tmux-themepack'
set -g @themepack 'powerline/default/orange'

source-file "${HOME}/.tmux-themepack/powerline/default/orange.tmuxtheme"

+ 2
- 1
zsh/.zshrc View File

@@ -1,3 +1,4 @@
export TERM=xterm-256color
ZSH_DISABLE_COMPFIX="true"
ZSH="/home/titouan/.oh-my-zsh"
ZSH_THEME="powerlevel10k/powerlevel10k"
@@ -96,4 +97,4 @@ GREP_COLOR='1;32' # (legacy) bright green rather than default red
GREP_COLORS="ms=$GREP_COLOR" # (new) Matching text in Selected line = green
alias grep='grep $GREP_OPTS'
alias egrep='egrep $GREP_OPTS'
alias fgrep='fgrep $GREP_OPTS'
alias fgrep='fgrep $GREP_OPTS'

Loading…
Cancel
Save