Compare commits

16 Commits

Author SHA1 Message Date
49baeffca5 Update main config 2024-03-14 11:14:59 +03:00
e1759cd443 Set terminal type 2023-12-29 10:21:33 +03:00
855b3adad6 Fix typo 2023-12-27 10:58:32 +03:00
b22b428cb0 Update zsh submodule 2023-12-26 11:54:59 +03:00
c7cbf63290 Add .gitconfig 2023-12-26 01:12:02 +03:00
bdcbf75faa Add zsh env 2023-12-26 01:07:26 +03:00
e4f4b48478 Add zsh config 2023-12-26 00:55:43 +03:00
98ae969c4d Update submodules 2023-12-26 00:23:48 +03:00
f4684c9a01 Add custom scripts 2023-12-26 00:12:37 +03:00
80da014e84 Add nvim config as a submodule 2023-12-25 23:55:49 +03:00
64f6f14afd Add taskwarrior config 2023-12-25 23:24:05 +03:00
67e6e7ad29 Add timewarrior config 2023-12-25 23:19:20 +03:00
a59ccb2487 Add btop config 2023-12-25 15:25:30 +03:00
509bed69ec Add bat config 2023-12-25 15:18:20 +03:00
7782cf36bc Add alacritty config 2023-12-25 15:14:27 +03:00
ff39f68a7f Enable kitty shortcuts because I use them while copy paste 2023-12-25 15:08:54 +03:00
27 changed files with 71 additions and 538 deletions

View File

@ -56,7 +56,7 @@ update_ms = 2000
#* Processes sorting, "pid" "program" "arguments" "threads" "user" "memory" "cpu lazy" "cpu direct", #* Processes sorting, "pid" "program" "arguments" "threads" "user" "memory" "cpu lazy" "cpu direct",
#* "cpu lazy" sorts top process over time (easier to follow), "cpu direct" updates top process directly. #* "cpu lazy" sorts top process over time (easier to follow), "cpu direct" updates top process directly.
proc_sorting = "cpu lazy" proc_sorting = "memory"
#* Reverse sorting order, True or False. #* Reverse sorting order, True or False.
proc_reversed = False proc_reversed = False

View File

@ -1,19 +0,0 @@
# DISPLAY=:0
XDG_RUNTIME_DIR=/run/user/1000
# Example of job definition:
# .---------------- minute (0 - 59)
# | .------------- hour (0 - 23)
# | | .---------- day of month (1 - 31)
# | | | .------- month (1 - 12) OR Jan-Dec
# | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR SUN-SAT
# | | | | |
# * * * * * user-name command to be executed
# * any value
# , value list separator
# - range of values
# / step values
* * * * * /home/sahin/scripts/check-battery.sh 10

View File

@ -1,3 +0,0 @@
lat: 40.0
lng: 29.0
dbusserver: true

View File

@ -1,7 +0,0 @@
#!/usr/bin/env bash
# trigger a small, passive popup dialog to inform the user about darkman's activity
# reference https://wiki.archlinux.org/title/Desktop_notifications#Usage_in_programming
theme=$(darkman get)
notify-send --app-name="darkman" --urgency=low --icon=weather-clear-night "switching to $theme mode"

View File

@ -1,12 +0,0 @@
#!/usr/bin/env bash
# Change the global Plasma Theme. On Manjaro you can use "org.manjaro.breath-dark.desktop"
# or you can create your own global Plasma Theme with the "Plasma Look And Feel Explorer".
# Reference: https://userbase.kde.org/Plasma/Create_a_Global_Theme_Package
#
# Since Plasma 5.26 the lookandfeeltool does not work anymore without "faking" the screen.
# Reference: https://bugs.kde.org/show_bug.cgi?id=460643
lookandfeeltool -platform offscreen --apply "org.kde.breeze.desktop"
# lookandfeeltool -platform offscreen --apply "org.kde.breezetwilight.desktop"
# lookandfeeltool -platform offscreen --apply "org.kde.breezedark.desktop"

View File

@ -1,16 +0,0 @@
#!/usr/bin/env bash
# GTK apps are not affected by the Plasma Global Theme, which only applies to Qt based programs.
# GTK themes can be installed here: Global Theme > Application Style > Configure GNOME/GTK Application Style.
# Reference: https://wiki.archlinux.org/title/Uniform_look_for_Qt_and_GTK_applications
source "$HOME/scripts/common-vars.sh"
if [ $theme == "dark" ]; then
theme_string="Breeze-dark-gtk"
else
theme_string="Default"
fi
echo "string:$theme_string"
dbus-send --session --dest=org.kde.GtkConfig --type=method_call /GtkConfig org.kde.GtkConfig.setGtkTheme "string:$theme_string"

View File

@ -1,3 +0,0 @@
#!/bin/sh
makoctl set-mode dark

View File

@ -1,4 +0,0 @@
#!/usr/bin/env bash
theme=$(darkman get)
gsettings set org.gnome.desktop.interface color-scheme "prefer-$theme"

View File

@ -1,31 +0,0 @@
#!/usr/bin/env bash
# trigger a small, passive popup dialog to inform the user about darkman's activity
# reference https://wiki.archlinux.org/title/Desktop_notifications#Usage_in_programming
theme=$(darkman get)
PATH="$HOME/.local/bin/:$PATH"
if [ $theme == "dark" ]; then
sed -i 's/tokyonight_day/tokyonight_storm/g' "$HOME/.config/kitty/kitty.conf"
sed -i 's/Light/Origin/g' "$HOME/.config/bat/config"
sed -i 's/flat-remix-light/tokyo-storm/g' "$HOME/.config/btop/btop.conf"
else
sed -i 's/tokyonight_storm/tokyonight_day/g' "$HOME/.config/kitty/kitty.conf"
sed -i 's/Origin/Light/g' "$HOME/.config/bat/config"
sed -i 's/tokyo-storm/flat-remix-light/g' "$HOME/.config/btop/btop.conf"
fi
kill -SIGUSR1 $(pgrep kitty)
tmux source-file "$HOME/.config/tmux/$theme.conf"
# This uses the neovim-remote python package to control other neovim instances.
# see: https://github.com/mhinz/neovim-remote
# Further, it is assumed that toggling the background in neovim is enough.
# Anything else should be handled by the set color scheme.
for server in $(nvr --serverlist); do
nvr --servername "$server" -cc "set background=$theme"
done

View File

@ -1,245 +0,0 @@
########################################################################################
AUTOGENERATED HYPR CONFIG.
PLEASE USE THE CONFIG PROVIDED IN THE GIT REPO /examples/hypr.conf AND EDIT IT,
OR EDIT THIS ONE ACCORDING TO THE WIKI INSTRUCTIONS.
########################################################################################
#
# Please note not all available settings / options are set here.
# For a full list, see the wiki
#
# See https://wiki.hyprland.org/Configuring/Monitors/
#monitor=name,resolution,position,scale
monitor=,preferred,auto,auto
# centered
# monitor=eDP-1,preferred,500x1107,2.0
monitor=eDP-1,preferred,0x1107,2.0
monitor=HDMI-A-1,preferred,0x0,1.3
# monitor=eDP-1, disable
# monitor=,preferred,auto,1,mirror,HDMI-A-1
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
# Execute your favorite apps at launch
# exec-once = waybar & hyprpaper & firefox
exec-once = dunst
exec-once = /usr/libexec/kf5/polkit-kde-authentication-agent-1
# Dim screen after 60 seconds of inactivity
exec-once = swayidle -w timeout 60 'dim-screen &' resume 'undim-screen'
# Lock screen after idle for 300s
exec-once = swayidle -w timeout 300 'lock-screen'
# Dim screen 5 seconds after screen is locked. no -w option here.
exec-once = swayidle timeout 5 'if pgrep -x swaylock; then dim-screen; fi' resume 'undim-screen'
# Turn monitors off 20 seconds after screen is locked
exec-once = swayidle -w timeout 20 'if pgrep -x swaylock; then hyprctl dispatch dpms off; fi' resume 'hyprctl dispatch dpms on'
# exec-once = /usr/libexec/polkit-gnome-authentication-agent-1
# Source a file (multi-file configs)
# source = ~/.config/hypr/myColors.conf
# Some default env vars.
env = XCURSOR_SIZE,24
#
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
input {
kb_layout = tr
kb_variant = legacy-fix-ansi
kb_model =
kb_options =
kb_rules =
follow_mouse = 1
touchpad {
natural_scroll = yes
drag_lock = yes
}
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
}
device:apple-mtp-keyboard {
kb_layout = tr
kb_variant = legacy-fix-iso
kb_model =
kb_options = ctrl:swapcaps
kb_rules =
}
general {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
gaps_in = 5
gaps_out = 20
border_size = 2
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
col.inactive_border = rgba(595959aa)
layout = dwindle
# Please see https://wiki.hyprland.org/Configuring/Tearing/ before you turn this on
allow_tearing = false
}
decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
rounding = 10
blur {
enabled = true
size = 3
passes = 1
}
drop_shadow = yes
shadow_range = 4
shadow_render_power = 3
col.shadow = rgba(1a1a1aee)
}
animations {
enabled = yes
# Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
animation = windows, 1, 7, myBezier
animation = windowsOut, 1, 7, default, popin 80%
animation = border, 1, 10, default
animation = borderangle, 1, 8, default
animation = fade, 1, 7, default
animation = workspaces, 1, 6, default
}
dwindle {
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
preserve_split = yes # you probably want this
}
master {
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
new_is_master = true
}
gestures {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
workspace_swipe = on
workspace_swipe_cancel_ratio = 0.20
}
misc {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
force_default_wallpaper = -1 # Set to 0 to disable the anime mascot wallpapers
}
# Example per-device config
# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more
device:epic-mouse-v1 {
sensitivity = -0.5
}
# Example windowrule v1
# windowrule = float, ^(kitty)$
# Example windowrule v2
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
windowrulev2 = float,class:^(nm-connection-editor)$,
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
$mainMod = SUPER
bind = $mainMod, tab, workspace, previous
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
bind = $mainMod, return, exec, kitty
bind = $mainMod, q, killactive,
bind = $mainMod control, q, exit,
bind = $mainMod, E, exec, dolphin
bind = $mainMod, V, togglefloating,
bind = $mainMod, semicolon, exec, wofi --show drun --normal-window
bind = $mainMod, p, exec, passmenu
bind = $mainMod, t, pseudo, # dwindle
bind = $mainMod, s, togglesplit, # dwindle
# Move focus with mainMod + arrow keys
bind = $mainMod, h, movefocus, l
bind = $mainMod, l, movefocus, r
bind = $mainMod, k, movefocus, u
bind = $mainMod, j, movefocus, d
# Switch workspaces with mainMod + [0-9]
bind = $mainMod, a, workspace, 1
bind = $mainMod, s, workspace, 2
bind = $mainMod, d, workspace, 3
bind = $mainMod, f, workspace, 4
bind = $mainMod, g, workspace, 5
bind = $mainMod, 1, workspace, 1
bind = $mainMod, 2, workspace, 2
bind = $mainMod, 3, workspace, 3
bind = $mainMod, 4, workspace, 4
bind = $mainMod, 5, workspace, 5
bind = $mainMod, 6, workspace, 6
bind = $mainMod, 7, workspace, 7
bind = $mainMod, 8, workspace, 8
bind = $mainMod, 9, workspace, 9
bind = $mainMod, 0, workspace, 10
# Move active window to a workspace with mainMod + SHIFT + [0-9]
bind = $mainMod SHIFT, a, movetoworkspace, 1
bind = $mainMod SHIFT, s, movetoworkspace, 2
bind = $mainMod SHIFT, d, movetoworkspace, 3
bind = $mainMod SHIFT, f, movetoworkspace, 4
bind = $mainMod SHIFT, g, movetoworkspace, 5
bind = $mainMod SHIFT, 1, movetoworkspace, 1
bind = $mainMod SHIFT, 2, movetoworkspace, 2
bind = $mainMod SHIFT, 3, movetoworkspace, 3
bind = $mainMod SHIFT, 4, movetoworkspace, 4
bind = $mainMod SHIFT, 5, movetoworkspace, 5
bind = $mainMod SHIFT, 6, movetoworkspace, 6
bind = $mainMod SHIFT, 7, movetoworkspace, 7
bind = $mainMod SHIFT, 8, movetoworkspace, 8
bind = $mainMod SHIFT, 9, movetoworkspace, 9
bind = $mainMod SHIFT, 0, movetoworkspace, 10
# Example special workspace (scratchpad)
bind = $mainMod, i, togglespecialworkspace, magic
bind = $mainMod SHIFT, i, movetoworkspace, special:magic
# Scroll through existing workspaces with mainMod + scroll
bind = $mainMod, mouse_down, workspace, e+1
bind = $mainMod, mouse_up, workspace, e-1
# Move/resize windows with mainMod + LMB/RMB and dragging
bindm = $mainMod, mouse:272, movewindow
bindm = $mainMod, mouse:273, resizewindow
# screen
bindle=,XF86MonBrightnessUp, exec, light -A 3; light -O
bindle=,XF86MonBrightnessDown, exec, light -U 3; light -O
# bindle=,XF86KbdBrightnessUp, exec, ags -r 'brightness.kbd++; indicator.kbd()'
# bindle=,XF86KbdBrightnessDown, exec, ags -r 'brightness.kbd--; indicator.kbd()'
#
#
bindle=,XF86AudioRaiseVolume, exec, volume up
bindle=,XF86AudioLowerVolume, exec, volume down
bindle=,XF86AudioMute, exec, volume toggle-mute
bind = $mainMod SHIFT, q, exec, lock-screen
# bindl = $mainMod SHIFT, L, exec, sleep 1 && hyprctl dispatch dpms off
windowrulev2 = stayfocused,class:(wofi)
windowrulev2 = noborder,class:(wofi)

View File

@ -1,5 +1,19 @@
# vim:fileencoding=utf-8:foldmethod=marker # vim:fileencoding=utf-8:foldmethod=marker
# map f1 show_kitty_env_vars
kitty_mod alt
#: Special modifier key alias for default shortcuts. You can change
#: the value of this option to alter all default shortcuts that use
#: kitty_mod.
clear_all_shortcuts yes
#: Remove all shortcut definitions up to this point. Useful, for
#: instance, to remove the default shortcuts.
# kitty-scrollback.nvim Kitten alias
action_alias kitty_scrollback_nvim kitten $HOME/.local/share/nvim/lazy/kitty-scrollback.nvim/python/kitty_scrollback_nvim.py
# include ./themes/themes/OneDark.conf # include ./themes/themes/OneDark.conf
include ~/.local/share/nvim/lazy/tokyonight.nvim/extras/kitty/tokyonight_day.conf include ~/.local/share/nvim/lazy/tokyonight.nvim/extras/kitty/tokyonight_day.conf

View File

@ -27,11 +27,11 @@ hooks.location=~/.config/task/hooks
# Color theme (uncomment one to use) # Color theme (uncomment one to use)
include solarized-dark-256.theme # include solarized-dark-256.theme
#include dark-16.theme # include dark-16.theme
#include light-16.theme # include light-16.theme
#include light-256.theme # include light-256.theme
#include dark-256.theme # include dark-256.theme
#include dark-red-256.theme #include dark-red-256.theme
#include dark-green-256.theme #include dark-green-256.theme
#include dark-blue-256.theme #include dark-blue-256.theme
@ -45,3 +45,4 @@ include solarized-dark-256.theme
news.version=2.6.0 news.version=2.6.0
# #
color.calendar.holiday=black on yellow color.calendar.holiday=black on yellow
include light-256.theme

View File

@ -1 +0,0 @@
import /home/sahin/.config/timewarrior/holidays/holidays.tr-TR

View File

@ -30,11 +30,21 @@
# st.color7: #ACB0D0 # st.color7: #ACB0D0
# st.color15: #ABB2BF # st.color15: #ABB2BF
darker_accent="#e0af68" # # tokyonight
accent="#528ef5" # darker_accent="#e0af68"
lighter_accent="#3b4261" # accent="#518DF6"
# lighter_accent="#0B55D5"
# bg="default"
# fg_text="#111111"
# kanagawa
darker_accent="#44300D"
accent="#986e1f"
lighter_accent="#664915"
bg="default" bg="default"
fg_text="#111111" fg_text="#E4BC77"
prefix="#{?client_prefix,#[reverse]^Space#[noreverse],}" prefix="#{?client_prefix,#[reverse]^Space#[noreverse],}"
sync="#{?pane_synchronized,#[reverse] SYNC #[noreverse],}" sync="#{?pane_synchronized,#[reverse] SYNC #[noreverse],}"
mode="#{?pane_in_mode,#[reverse] #{pane_mode} #[noreverse],}" mode="#{?pane_in_mode,#[reverse] #{pane_mode} #[noreverse],}"
@ -56,9 +66,9 @@ setw -g window-status-activity-style "none"
setw -g window-status-separator "" setw -g window-status-separator ""
setw -g window-status-style "none,fg=$fg_text,bg=$bg" setw -g window-status-style "none,fg=$fg_text,bg=$bg"
set -g status-left "#[fg=$fg_text,bg=$accent] #S #[fg=$accent,bg=$bg,nobold,nounderscore,noitalics] " set -g status-left "#[fg=$fg_text,bg=$lighter_accent] #S #[fg=$lighter_accent,bg=$bg,nobold,nounderscore,noitalics] "
setw -g window-status-format "#[fg=$lighter_accent,bg=$bg]#[fg=$accent,bg=$lighter_accent] #I#[fg=$accent,bg=$lighter_accent]#W#[bg=$bg,fg=$lighter_accent]" setw -g window-status-format "#[fg=$lighter_accent,bg=$bg]#[fg=$fg_text,bg=$lighter_accent] #I#[fg=$fg_text,bg=$lighter_accent]#W#[bg=$bg,fg=$lighter_accent]"
setw -g window-status-current-format "#[fg=$accent,bg=$bg,nobold,nounderscore,noitalics]#[fg=$fg_text,bg=$accent,bold]#I#[fg=$fg_text,bg=$accent]#W#F#[fg=$accent,bg=$bg,nobold,nounderscore,noitalics]" setw -g window-status-current-format "#[fg=$accent,bg=$bg,nobold,nounderscore,noitalics]#[fg=$fg_text,bg=$accent,bold]#I#[fg=$fg_text,bg=$accent]#W#F#[fg=$accent,bg=$bg,nobold,nounderscore,noitalics]"
# set -g status-right "#[fg=$accent,bg=$bg,nobold,nounderscore,noitalics]#[fg=$fg_text,bg=$accent] $uptime %H:%M %d/%m/%Y#[bg=$accent,fg=$darker_accent,nobold,nounderscore,noitalics]#[bg=$fg_text,fg=$darker_accent,bold]$prefix$sync$mode" # set -g status-right "#[fg=$accent,bg=$bg,nobold,nounderscore,noitalics]#[fg=$fg_text,bg=$accent] $uptime %H:%M %d/%m/%Y#[bg=$accent,fg=$darker_accent,nobold,nounderscore,noitalics]#[bg=$fg_text,fg=$darker_accent,bold]$prefix$sync$mode"

View File

@ -11,7 +11,7 @@
# st.color5: #9854f1 # st.color5: #9854f1
# st.color6: #007197 # st.color6: #007197
# st.color7: #6172b0 # st.color7: #6172b0
# st.color8: #a1a6c5 # st.color8: #a1a6c5j
# st.color9: #f52a65 # st.color9: #f52a65
# st.color10: #587539 # st.color10: #587539
# st.color11: #8c6c3e # st.color11: #8c6c3e
@ -28,12 +28,20 @@
# prefix_color="colour11" # prefix_color="colour11"
# TokyoNight colors for Tmux # TokyoNight colors for Tmux
darker_accent="#6172b0" # darker_accent="#6172b0"
accent="#2e7de9" # accent="#2e7de9"
bg1="#d1d4e3" # bg1="#d1d4e3"
# bg2="default"
# grayish="#a8aecb"
# prefix_color="#8c6c3e"
# kanagawa colors
darker_accent="#727169"
accent="#727169"
bg1="#DCD7BA"
bg2="default" bg2="default"
grayish="#a8aecb" grayish="#C8C093"
prefix_color="#8c6c3e" prefix_color="#77713f"
prefix="#{?client_prefix,#[reverse]^Space#[noreverse],}" prefix="#{?client_prefix,#[reverse]^Space#[noreverse],}"
sync="#{?pane_synchronized,#[reverse] SYNC #[noreverse],}" sync="#{?pane_synchronized,#[reverse] SYNC #[noreverse],}"

View File

@ -1,12 +1,20 @@
# remap prefix to Control + Space # remap prefix to Control + Space
set -g prefix C-Space set -g prefix C-s
bind C-Space last-window bind C-s send-prefix
bind-key C-] send-keys "C-]"
# set -g prefix Escape # set -g prefix Escape
# bind Escape send-keys Escape # bind Escape send-keys Escape
# bind "'" last-window bind "'" last-window
unbind C-b unbind C-b
set-option -g allow-passthrough on set -sg escape-time 0 # see https://github.com/neovim/neovim/issues/2035
### required for showing images in terminal
set-option -gq allow-passthrough on
# for hiding images when window is switched
set -g visual-activity off
###
# Smart pane switching with awareness of Vim splits. # Smart pane switching with awareness of Vim splits.
# See: https://github.com/christoomey/vim-tmux-navigator # See: https://github.com/christoomey/vim-tmux-navigator
@ -86,7 +94,7 @@ bind-key -n C-Down swap-pane -s '{down-of}'
bind-key -n C-Left swap-pane -s '{left-of}' bind-key -n C-Left swap-pane -s '{left-of}'
bind-key -n C-Right swap-pane -s '{right-of}' bind-key -n C-Right swap-pane -s '{right-of}'
# set -g default-terminal "xterm-256color" set -g default-terminal "xterm-256color"
# tell Tmux that outside terminal supports true color # tell Tmux that outside terminal supports true color
# set -ga terminal-overrides ",xterm-256color*:Tc" # set -ga terminal-overrides ",xterm-256color*:Tc"
@ -122,10 +130,7 @@ bind-key C-j join-pane
# status bar theme # status bar theme
# set -g status 'on' # set -g status 'on'
set-option -g status-position bottom set-option -g status-position bottom
source-file ~/.config/tmux/dark.conf
if-shell '[ `darkman get` == "light" ]' \
'source-file ~/.config/tmux/light.conf' \
'source-file ~/.config/tmux/dark.conf'

4
.gitmodules vendored
View File

@ -9,8 +9,8 @@
[submodule ".config/nvim"] [submodule ".config/nvim"]
path = .config/nvim path = .config/nvim
url = https://github.com/sahinakkaya/nvim-config.git url = https://github.com/sahinakkaya/nvim-config.git
branch = linux branch = main
[submodule ".config/zsh"] [submodule ".config/zsh"]
path = .config/zsh path = .config/zsh
url = https://github.com/sahinakkaya/zsh-config.git url = https://github.com/sahinakkaya/zsh-config.git
branch = linux branch = main

View File

@ -1,35 +0,0 @@
#!/usr/bin/env bash
shopt -s nullglob globstar
typeit=0
if [[ $1 == "--type" ]]; then
typeit=1
shift
fi
if [[ -n $WAYLAND_DISPLAY ]]; then
dmenu=wofi
xdotool="ydotool type --file -"
elif [[ -n $DISPLAY ]]; then
dmenu=dmenu
xdotool="xdotool type --clearmodifiers --file -"
else
echo "Error: No Wayland or X11 display detected" >&2
exit 1
fi
prefix=${PASSWORD_STORE_DIR-~/.password-store}
password_files=( "$prefix"/**/*.gpg )
password_files=( "${password_files[@]#"$prefix"/}" )
password_files=( "${password_files[@]%.gpg}" )
password=$(printf '%s\n' "${password_files[@]}" | "$dmenu" --show dmenu --normal-window "$@")
[[ -n $password ]] || exit
if [[ $typeit -eq 0 ]]; then
pass show -c "$password" 2>/dev/null
else
pass show "$password" | { IFS= read -r pass; printf %s "$pass"; } | $xdotool
fi

View File

@ -1,3 +1,2 @@
export XDG_CONFIG_HOME="${XDG_CONFIG_HOME:=$HOME/.config}" export ZDOTDIR="$HOME/.config/zsh"
export ZDOTDIR="${ZDOTDIR:=$XDG_CONFIG_HOME/zsh}"
export PATH="$HOME/scripts/:$HOME/.local/bin/:$PATH" export PATH="$HOME/scripts/:$HOME/.local/bin/:$PATH"

View File

@ -1,20 +0,0 @@
#!/bin/bash
# Set limit to shell argument
batteryLimit=$1
fullAt=92
# Get the current battery level with acpi
batteryLevel=$(acpi | cut -d ' ' -f 4 | tr -d '%|,| ')
charging=$(acpi | cut -d ' ' -f 3 | tr -d ',| ')
echo $batteryLevel
if [[ "$batteryLevel" -le "$batteryLimit" ]] && [[ "$charging" == "Discharging" ]]; then
/usr/bin/notify-send -a "Battery Warning" --urgency critical "Battery level at ${batteryLevel}%" -i abrt -t 10000
/usr/bin/mpv /usr/share/sounds/Oxygen-Sys-Warning.ogg
# /usr/bin/aplay /usr/share/sounds/freedesktop/stereo/dialog-warning.oga
#elif [[ "$batteryLevel" -gt "$fullAt" ]] && [[ ! "$charging" == "Discharging" ]]; then
# /usr/bin/notify-send -a "Battery Warning" "Battery is full: ${batteryLevel}" -i abrt -t 10000
# /usr/bin/paplay /usr/share/sounds/freedesktop/stereo/dialog-warning.oga
fi

View File

@ -1,30 +0,0 @@
#!/usr/bin/python3
# Gradually decrease brightness level. Thanks ChatGPT
import subprocess
import time
def set_brightness(brightness):
subprocess.call(['light', '-S', str(brightness)])
def smooth_dimming(initial_brightness, final_brightness, duration, steps):
brightness_step = (initial_brightness - final_brightness) / steps
sleep_time = duration / steps
for i in range(steps + 1):
current_brightness = round(initial_brightness - i * brightness_step,2)
set_brightness(current_brightness)
print(current_brightness)
time.sleep(sleep_time)
set_brightness(final_brightness)
# Save brighness value for later
subprocess.call(['light', '-O'])
initial_brightness = float(subprocess.getoutput('light'))
final_brightness = 0 if initial_brightness < 20 else 5
dimming_duration = 0.3 if initial_brightness < 20 else .5
num_steps = 20 if initial_brightness < 20 else 50
smooth_dimming(initial_brightness, final_brightness, dimming_duration, num_steps)

View File

@ -1,3 +0,0 @@
#!/bin/bash
swaylock -f

View File

@ -1,9 +0,0 @@
#!/bin/bash
monitor=$(hyprctl -j monitors | jq '.[] | select(.name == "eDP-1") | .id')
if [[ $monitor == "" ]]; then
hyprctl keyword monitor eDP-1,preferred,0x1107,2.0
else
hyprctl keyword monitor eDP-1,disable
fi

View File

@ -1,7 +0,0 @@
#!/bin/bash
if pid=$(pgrep -x "dim-screen"); then
kill $pid
fi
light -I

View File

@ -1,59 +0,0 @@
#!/bin/bash
VOLUME_STEP=2
# Function to check if the audio is currently muted
is_muted() {
amixer sget Master | grep -q "\[off\]"
}
# Function to toggle mute status
toggle_mute() {
amixer sset Master toggle
}
# Function to increase volume
increase_volume() {
amixer sset Master "${VOLUME_STEP}%+"
}
# Function to decrease volume
decrease_volume() {
amixer sset Master "${VOLUME_STEP}%-"
}
# Main function
main() {
case "$1" in
"up")
if is_muted; then
toggle_mute
fi
increase_volume
;;
"down")
if is_muted; then
toggle_mute
fi
decrease_volume
;;
"toggle-mute")
toggle_mute
;;
*)
echo "Usage: $0 {up|down|toggle-mute}"
exit 1
;;
esac
# Display the current volume
amixer get Master | grep -oE "[0-9]+%"
}
# Check if an argument is provided
if [ $# -eq 1 ]; then
main "$1"
else
echo "Usage: $0 {up|down|toggle-mute}"
exit 1
fi