mirror of
https://github.com/frebib/dotfiles.git
synced 2024-06-14 12:57:23 +00:00
Compare commits
45 Commits
a41314ca34
...
master
Author | SHA1 | Date | |
---|---|---|---|
1da55a29c4 | |||
2cc93a1649
|
|||
787008fdb7
|
|||
79dc6a7389
|
|||
fede67c22a
|
|||
b87cf96ff2
|
|||
4143aa4e48
|
|||
73131b086f
|
|||
a7af23bfbb
|
|||
56fd0ad602
|
|||
cbb44c99ee
|
|||
2bd257243a
|
|||
d538b61cb1
|
|||
fa136cbd2a
|
|||
499b044fea
|
|||
14805b3f9a
|
|||
e03c93bf39
|
|||
ba6173e0ee
|
|||
dcfd191613
|
|||
db40ef08bb
|
|||
839d972e95
|
|||
ece2eb878a
|
|||
6f1569b35d
|
|||
5035afc8b4
|
|||
650eb08a80
|
|||
535697a31c
|
|||
f520784d9b
|
|||
ef4b739af1
|
|||
0ba6dc8e4b
|
|||
55e492cd8f
|
|||
19663fa4f1
|
|||
7e5b329e74
|
|||
0116be881a
|
|||
90038f8795
|
|||
7775fb62e4
|
|||
a48288ad50
|
|||
b519b48e83
|
|||
8e74101f3e
|
|||
898190a99f
|
|||
d771bf0448
|
|||
634db612a1
|
|||
a7778c30a7
|
|||
49554ca359
|
|||
895d0ff0aa
|
|||
7be83b7b70
|
@ -24,7 +24,7 @@
|
|||||||
],
|
],
|
||||||
"bug_report_endpoint_url": "https://riot.im/bugreports/submit",
|
"bug_report_endpoint_url": "https://riot.im/bugreports/submit",
|
||||||
"defaultCountryCode": "GB",
|
"defaultCountryCode": "GB",
|
||||||
"showLabsSettings": false,
|
"showLabsSettings": true,
|
||||||
"features": {
|
"features": {
|
||||||
"feature_font_scaling": "labs",
|
"feature_font_scaling": "labs",
|
||||||
"feature_pinning": "labs",
|
"feature_pinning": "labs",
|
||||||
|
@ -4,18 +4,20 @@
|
|||||||
export TERMINAL="alacritty"
|
export TERMINAL="alacritty"
|
||||||
export BROWSER="firefox"
|
export BROWSER="firefox"
|
||||||
|
|
||||||
export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel"
|
export GTK_THEME="$(grep gtk-theme-name "${XDG_CONFIG_HOME:-$HOME/.config}/gtk-3.0/settings.ini" | sed 's/.*\s*=\s*//')"
|
||||||
export GTK2_RC_FILES="$XDG_CONFIG_HOME/gtk-2.0/settings.ini"
|
export GTK2_RC_FILES="$XDG_CONFIG_HOME/gtk-2.0/settings.ini"
|
||||||
export QT_QPA_PLATFORMTHEME=qt5ct
|
export QT_QPA_PLATFORMTHEME=qt5ct
|
||||||
export XDG_CURRENT_DESKTOP="GNOME" # Fixes xdg-open
|
export XDG_CURRENT_DESKTOP="GNOME" # Fixes xdg-open
|
||||||
|
|
||||||
|
export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel"
|
||||||
|
|
||||||
# https://www.reddit.com/r/linux/comments/72mfv8/psa_for_firefox_users_set_moz_use_xinput21_to/
|
# https://www.reddit.com/r/linux/comments/72mfv8/psa_for_firefox_users_set_moz_use_xinput21_to/
|
||||||
export MOZ_USE_XINPUT2=1 # enable pixel-accurate scrolling in firefox
|
export MOZ_USE_XINPUT2=1 # enable pixel-accurate scrolling in firefox
|
||||||
|
|
||||||
|
|
||||||
# Load Xorg resources and set the DPI
|
# Load Xorg resources and set the DPI
|
||||||
xrdb -merge $XDG_CONFIG_HOME/X11/xresources
|
xrdb -merge "$XDG_CONFIG_HOME/X11/xresources"
|
||||||
xrandr --dpi $(xrdb -query | grep -i xft.dpi | cut -d: -f2)
|
"$XDG_CONFIG_HOME/scripts/dpi" "$(xrdb -query | grep -i xft.dpi | cut -d: -f2 | xargs)"
|
||||||
|
|
||||||
setxkbmap -option caps:none
|
setxkbmap -option caps:none
|
||||||
xset r rate 200 18
|
xset r rate 200 18
|
||||||
|
@ -36,4 +36,5 @@ Xft.hinting: true
|
|||||||
Xft.hintstyle: hintfull
|
Xft.hintstyle: hintfull
|
||||||
Xft.lcdfilter: lcddefault
|
Xft.lcdfilter: lcddefault
|
||||||
|
|
||||||
|
Xcursor.size: 16
|
||||||
Xcursor.theme: Breeze_Obsidian
|
Xcursor.theme: Breeze_Obsidian
|
||||||
|
@ -611,7 +611,7 @@ debug:
|
|||||||
# - Info
|
# - Info
|
||||||
# - Debug
|
# - Debug
|
||||||
# - Trace
|
# - Trace
|
||||||
log_level: Info
|
log_level: Warn
|
||||||
|
|
||||||
# Print all received window events.
|
# Print all received window events.
|
||||||
#print_events: false
|
#print_events: false
|
||||||
|
68
aliases
68
aliases
@ -46,7 +46,7 @@ alias sudo='sudo '
|
|||||||
alias open=xdg-open
|
alias open=xdg-open
|
||||||
|
|
||||||
# Command rewrites
|
# Command rewrites
|
||||||
alias rm='rm -i'
|
alias rm='rm -iv'
|
||||||
alias mv='mv -i'
|
alias mv='mv -i'
|
||||||
alias cp='cp -ir'
|
alias cp='cp -ir'
|
||||||
alias scp='scp -r'
|
alias scp='scp -r'
|
||||||
@ -110,25 +110,38 @@ alias ginit='git init'
|
|||||||
alias gignore='$EDITOR .gitignore'
|
alias gignore='$EDITOR .gitignore'
|
||||||
alias gitc='$EDITOR $XDG_CONFIG_HOME/git/config'
|
alias gitc='$EDITOR $XDG_CONFIG_HOME/git/config'
|
||||||
alias ggignore='$EDITOR $XDG_CONFIG_HOME/git/gitignore'
|
alias ggignore='$EDITOR $XDG_CONFIG_HOME/git/gitignore'
|
||||||
alias gcl="git clone --recursive"
|
|
||||||
alias gco="git checkout"
|
alias gco="git checkout"
|
||||||
alias gcom="git checkout master"
|
alias gcom="git checkout \"\$(git defbranch)\""
|
||||||
|
alias gsw="git switch"
|
||||||
|
alias gswm="git switch \"\$(git defbranch)\""
|
||||||
|
alias gbr="git branch"
|
||||||
|
alias gtg="git tag"
|
||||||
|
alias gbl="git blame"
|
||||||
|
alias gt="git tag"
|
||||||
|
alias gst="git status"
|
||||||
|
alias grl="git reflog"
|
||||||
|
alias gfp="git format-patch"
|
||||||
|
alias gcl="git clone --recursive"
|
||||||
|
|
||||||
alias ga="git add"
|
alias ga="git add"
|
||||||
alias gap="git add -p"
|
alias gap="git add -p"
|
||||||
alias gau="git add -u"
|
alias gau="git add -u"
|
||||||
alias gaN="git add -N"
|
alias gaN="git add -N"
|
||||||
alias gaa="ga -A"
|
alias gaa="ga -A"
|
||||||
alias grm="git rm"
|
alias grm="git rm"
|
||||||
alias gc="git commit -s"
|
alias gmv="git mv"
|
||||||
alias gcm="git commit -s -em"
|
|
||||||
alias gca="git commit -s --amend --date=\"\$(date -R)\""
|
alias gc="git commit -sv"
|
||||||
alias gcn="git commit -s --no-edit"
|
alias gcm="git commit -sv -em"
|
||||||
alias gcan="gca -s --no-edit"
|
alias gca="git commit -sv --amend --date=\"\$(date -R)\""
|
||||||
alias gcam="gca -s -m"
|
alias gcn="git commit -sv --no-edit"
|
||||||
alias gst="git status"
|
alias gcan="gca --no-edit"
|
||||||
|
alias gcam="gca -m"
|
||||||
|
|
||||||
alias gm="git merge"
|
alias gm="git merge"
|
||||||
alias gma="git merge --abort"
|
alias gma="git merge --abort"
|
||||||
|
alias gmc="git merge --continue"
|
||||||
|
|
||||||
alias grb="git rebase"
|
alias grb="git rebase"
|
||||||
alias grbi="grb -i"
|
alias grbi="grb -i"
|
||||||
@ -136,31 +149,38 @@ alias grba="grb --abort"
|
|||||||
alias grbc="grb --continue"
|
alias grbc="grb --continue"
|
||||||
alias grbsk="grb --skip"
|
alias grbsk="grb --skip"
|
||||||
alias grbsh="grb --show-current"
|
alias grbsh="grb --show-current"
|
||||||
alias grbom="git rebase origin/master"
|
alias grbom="git rebase \"origin/\$(git defbranch origin)\""
|
||||||
gfrb() { remote="${1%/*}"; git fetch "$remote" && git rebase "$@"; }
|
gfrb() { ref="${1:-origin/$(git defbranch origin)}"; remote="${ref%%/*}"; git fetch "$remote" && git rebase "$ref" "${@:2}"; }
|
||||||
gfrbi() { remote="${1%/*}"; git fetch "$remote" && git rebase -i "$@"; }
|
gfrbi() { ref="${1:-origin/$(git defbranch origin)}"; remote="${ref%%/*}"; git fetch "$remote" && git rebase -i "$ref" "${@:2}"; }
|
||||||
|
|
||||||
alias gam="git am"
|
alias gam="git am"
|
||||||
alias gama="git am --abort"
|
alias gama="git am --abort"
|
||||||
alias gamc="git am --continue"
|
alias gamc="git am --continue"
|
||||||
|
alias gamsk="git am --skip"
|
||||||
|
|
||||||
alias gcp="git cherry-pick"
|
alias gcp="git cherry-pick"
|
||||||
alias gcpa="git cherry-pick --abort"
|
alias gcpa="git cherry-pick --abort"
|
||||||
alias gcpc="git cherry-pick --continue"
|
alias gcpc="git cherry-pick --continue"
|
||||||
|
alias gcpsk="git cherry-pick --skip"
|
||||||
|
|
||||||
|
alias grv="git revert"
|
||||||
|
alias grva="git revert --abort"
|
||||||
|
alias grvc="git revert --continue"
|
||||||
|
alias grvsk="git revert --skip"
|
||||||
|
|
||||||
alias gf="git fetch"
|
alias gf="git fetch"
|
||||||
alias gp="git push"
|
alias gp="git push"
|
||||||
alias gpf="gp --force"
|
alias gpf="gp --force"
|
||||||
alias gpsu="git push --set-upstream"
|
alias gpsu="git push --set-upstream"
|
||||||
alias gpoH="git push origin HEAD"
|
alias gpoH="git push origin HEAD"
|
||||||
alias gpsuom="git push --set-upstream origin master"
|
alias gpsuom="git push --set-upstream origin \"\$(git defbranch)\""
|
||||||
alias gpall="git remote | xargs -L1 git push"
|
alias gpall="git remote | xargs -L1 git push"
|
||||||
alias gl="git pull --rebase"
|
alias gl="git pull --rebase"
|
||||||
alias glp="gl && gp"
|
alias glp="gl && gp"
|
||||||
alias gd="git diff --patch-with-stat"
|
alias gd="git diff --patch-with-stat --no-prefix"
|
||||||
alias gdni="gd --no-index"
|
alias gdni="gd --no-index --no-prefix"
|
||||||
alias gds="gd --staged"
|
alias gds="gd --staged --no-prefix"
|
||||||
alias gsh="git show --format=fuller --patch-with-stat"
|
alias gsh="git show --format=fuller --patch-with-stat --no-prefix"
|
||||||
alias glg="git log --color --format=fuller --stat --no-merges --graph"
|
alias glg="git log --color --format=fuller --stat --no-merges --graph"
|
||||||
alias glgp="git log --color --format=fuller --patch-with-stat --no-merges --graph"
|
alias glgp="git log --color --format=fuller --patch-with-stat --no-merges --graph"
|
||||||
alias glog="git log --color --oneline --decorate --graph"
|
alias glog="git log --color --oneline --decorate --graph"
|
||||||
@ -168,12 +188,10 @@ alias glog="git log --color --oneline --decorate --graph"
|
|||||||
alias grst="git reset"
|
alias grst="git reset"
|
||||||
alias gundo="git reset --keep @~1"
|
alias gundo="git reset --keep @~1"
|
||||||
alias gclean="git clean"
|
alias gclean="git clean"
|
||||||
alias gbr="git branch"
|
alias gclm="git cleanmerged"
|
||||||
alias gbrl="git for-each-ref --sort=committerdate refs/heads/ --format=\"%(refname:short)\" | fzf -x --ansi --multi --preview-window=right:70% --preview=\"git log --format=fuller --stat --color=always {} | head -n\$((\$(tput lines)*10))\""
|
alias gbrl="git for-each-ref --sort=committerdate refs/heads/ --format=\"%(refname:short)\" | fzf -x --ansi --multi --preview-window=right:70% --preview=\"git log --format=fuller --stat --color=always {} | head -n\$((\$(tput lines)*10))\""
|
||||||
alias gtg="git tag"
|
|
||||||
alias gbl="git blame"
|
|
||||||
alias gr="git remote"
|
alias gr="git remote"
|
||||||
alias grv="git revert"
|
|
||||||
alias gra="gr add"
|
alias gra="gr add"
|
||||||
alias grr="gr rm"
|
alias grr="gr rm"
|
||||||
alias grao="gra origin"
|
alias grao="gra origin"
|
||||||
@ -183,12 +201,12 @@ alias gsta='git stash'
|
|||||||
alias gstd='gsta drop'
|
alias gstd='gsta drop'
|
||||||
alias gstl='gsta list --stat --color'
|
alias gstl='gsta list --stat --color'
|
||||||
alias gstp='gsta pop'
|
alias gstp='gsta pop'
|
||||||
alias gstv="gsta show -p stash@{0}"
|
alias gstv="gsta show --patch-with-stat stash@{0}"
|
||||||
|
|
||||||
# Docker aliases
|
# Docker aliases
|
||||||
alias d=docker
|
alias d=docker
|
||||||
alias dps="docker ps --format='table {{.ID}}\t{{.Image}}\t{{.Label \"org.label-schema.version\"}}\t{{.Networks}}\t{{.RunningFor}}\t{{.Status}}\t{{.Names}}' | sed '1s/version/VERSION/'"
|
alias dps="docker ps --format='table {{.ID}}\t{{.Image}}\t{{.Label \"org.label-schema.version\"}}\t{{.Networks}}\t{{.RunningFor}}\t{{.Status}}\t{{.Names}}' | sed '1s/version/VERSION/'"
|
||||||
alias dpsa="docker ps -a --format='table {{.ID}}\t{{.Image}}\t{{.Label \"org.label-schema.version\"}}\t{{.Networks}}\t{{.RunningFor}}\t{{.Status}}\t{{.Names}}' | sed '1s/version/VERSION/'"
|
alias dpsa="docker ps -a --format='table {{.ID}}\t{{.Image}}\t{{.Label \"org.opencontainers.image.version\"}}\t{{.Networks}}\t{{.RunningFor}}\t{{.Status}}\t{{.Names}}' | sed '1s/version/VERSION/'"
|
||||||
alias dnets="docker network ls -q | xargs docker inspect | jq '.[] | select(.Name != \"host\" and .Name != \"none\") | [.] | map(.Name + \"\t\" + (.IPAM.Config | map(.Subnet) | join(\"\t\")))[]' -r | sort -V -k2,3 | column -t"
|
alias dnets="docker network ls -q | xargs docker inspect | jq '.[] | select(.Name != \"host\" and .Name != \"none\") | [.] | map(.Name + \"\t\" + (.IPAM.Config | map(.Subnet) | join(\"\t\")))[]' -r | sort -V -k2,3 | column -t"
|
||||||
daddrs() { docker inspect "${1:-bridge}" | jq '.[0].Containers | map(.Name + "\t" + .IPv4Address + "\t" + .IPv6Address)[]' -r | sort -V -k2,3 | column -t; }
|
daddrs() { docker inspect "${1:-bridge}" | jq '.[0].Containers | map(.Name + "\t" + .IPv4Address + "\t" + .IPv6Address)[]' -r | sort -V -k2,3 | column -t; }
|
||||||
alias din='docker inspect'
|
alias din='docker inspect'
|
||||||
@ -302,7 +320,7 @@ alias xresources="\$EDITOR \$XDG_CONFIG_HOME/X11/xresources ; xrdb merge \$XDG_C
|
|||||||
alias sshc="\$EDITOR ~/.ssh/config"
|
alias sshc="\$EDITOR ~/.ssh/config"
|
||||||
alias dotfiles="cd \$XDG_CONFIG_HOME"
|
alias dotfiles="cd \$XDG_CONFIG_HOME"
|
||||||
alias i3c="\$EDITOR \$XDG_CONFIG_HOME/i3/config; systemctl --user reload i3"
|
alias i3c="\$EDITOR \$XDG_CONFIG_HOME/i3/config; systemctl --user reload i3"
|
||||||
alias polybarc="\$EDITOR \$XDG_CONFIG_HOME/polybar/config; systemctl --user reload polybar@i3bar"
|
alias polybarc="\$EDITOR \$XDG_CONFIG_HOME/polybar/config.ini; systemctl --user reload polybar@i3bar"
|
||||||
|
|
||||||
alias rot13="tr '[A-Za-z]' '[N-ZA-Mn-za-m]'"
|
alias rot13="tr '[A-Za-z]' '[N-ZA-Mn-za-m]'"
|
||||||
|
|
||||||
|
@ -51,21 +51,16 @@
|
|||||||
# Ignore newlines '\n' in notifications.
|
# Ignore newlines '\n' in notifications.
|
||||||
ignore_newline = no
|
ignore_newline = no
|
||||||
|
|
||||||
# The geometry of the window:
|
# dynamic width from 0 to 400
|
||||||
# [{width}]x{height}[+/-{x}+/-{y}]
|
# width = (0, 400)
|
||||||
# The geometry of the message window.
|
# constant width of 400
|
||||||
# The height is measured in number of notifications everything else
|
width = (320, 360)
|
||||||
# in pixels. If the width is omitted but the height is given
|
|
||||||
# ("-geometry x2"), the message window expands over the whole screen
|
|
||||||
# (dmenu-like). If width is 0, the window expands to the longest
|
|
||||||
# message displayed. A positive x is measured from the left, a
|
|
||||||
# negative from the right side of the screen. Y is measured from
|
|
||||||
# the top and down respectevly.
|
|
||||||
# The width can be negative. In this case the actual width is the
|
|
||||||
# screen width minus the width defined in within the geometry option.
|
|
||||||
|
|
||||||
# 53 = 30 + 23 (bar-height)
|
# Position the notification in the top right corner
|
||||||
geometry = "360x5-30+30"
|
origin = top-right
|
||||||
|
|
||||||
|
# Offset from the origin
|
||||||
|
offset = 30x30
|
||||||
|
|
||||||
# Shrink window if it's smaller than the width. Will be ignored if
|
# Shrink window if it's smaller than the width. Will be ignored if
|
||||||
# width is 0.
|
# width is 0.
|
||||||
@ -74,7 +69,7 @@
|
|||||||
# The transparency of the window. Range: [0; 100].
|
# The transparency of the window. Range: [0; 100].
|
||||||
# This option will only work if a compositing windowmanager is
|
# This option will only work if a compositing windowmanager is
|
||||||
# present (e.g. xcompmgr, compiz, etc.).
|
# present (e.g. xcompmgr, compiz, etc.).
|
||||||
transparency = 15
|
transparency = 20
|
||||||
|
|
||||||
# Don't remove messages, if the user is idle (no mouse or keyboard input)
|
# Don't remove messages, if the user is idle (no mouse or keyboard input)
|
||||||
# for longer than idle_threshold seconds.
|
# for longer than idle_threshold seconds.
|
||||||
|
@ -9,7 +9,7 @@ GEM_SPEC_CACHE="$XDG_CACHE_HOME/gem"
|
|||||||
GOPATH="$XDG_DATA_HOME/go"
|
GOPATH="$XDG_DATA_HOME/go"
|
||||||
ICEAUTHORITY="$XDG_CACHE_HOME/ICEauthority"
|
ICEAUTHORITY="$XDG_CACHE_HOME/ICEauthority"
|
||||||
NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc"
|
NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc"
|
||||||
#PASSWORD_STORE_DIR="$XDG_DATA_HOME/pass"
|
PASSWORD_STORE_DIR="$XDG_DATA_HOME/pass"
|
||||||
PYTHONSTARTUP="$XDG_CONFIG_HOME/python/startup"
|
PYTHONSTARTUP="$XDG_CONFIG_HOME/python/startup"
|
||||||
RUSTUP_HOME="$XDG_DATA_HOME/rustup"
|
RUSTUP_HOME="$XDG_DATA_HOME/rustup"
|
||||||
TERMINFO="$XDG_DATA_HOME/terminfo"
|
TERMINFO="$XDG_DATA_HOME/terminfo"
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<edit name="family" mode="prepend" binding="strong">
|
<edit name="family" mode="prepend" binding="strong">
|
||||||
<string>Noto Sans</string>
|
<string>Noto Sans</string>
|
||||||
<string>Noto Color Emoji</string>
|
<string>Noto Color Emoji</string>
|
||||||
<string>FontAwesome 5 Pro Light</string>
|
<string>FontAwesome 6 Pro Light</string>
|
||||||
</edit>
|
</edit>
|
||||||
|
|
||||||
<edit name="hintstyle" mode="assign"><const>hintnone</const></edit>
|
<edit name="hintstyle" mode="assign"><const>hintnone</const></edit>
|
||||||
@ -18,7 +18,7 @@
|
|||||||
<edit name="family" mode="prepend" binding="strong">
|
<edit name="family" mode="prepend" binding="strong">
|
||||||
<string>Noto Serif</string>
|
<string>Noto Serif</string>
|
||||||
<string>Noto Color Emoji</string>
|
<string>Noto Color Emoji</string>
|
||||||
<string>FontAwesome 5 Pro Light</string>
|
<string>FontAwesome 6 Pro Light</string>
|
||||||
</edit>
|
</edit>
|
||||||
</match>
|
</match>
|
||||||
|
|
||||||
@ -27,7 +27,7 @@
|
|||||||
<edit name="family" mode="prepend" binding="strong">
|
<edit name="family" mode="prepend" binding="strong">
|
||||||
<string>Source Code Pro</string>
|
<string>Source Code Pro</string>
|
||||||
<string>Noto Color Emoji</string>
|
<string>Noto Color Emoji</string>
|
||||||
<string>FontAwesome 5 Pro Light</string>
|
<string>FontAwesome 6 Pro Light</string>
|
||||||
</edit>
|
</edit>
|
||||||
</match>
|
</match>
|
||||||
|
|
||||||
|
23
git/config
23
git/config
@ -19,8 +19,14 @@
|
|||||||
[pull]
|
[pull]
|
||||||
rebase = true
|
rebase = true
|
||||||
prune = true
|
prune = true
|
||||||
|
[merge]
|
||||||
|
ff = only
|
||||||
[rebase]
|
[rebase]
|
||||||
autoStash = true
|
autoStash = true
|
||||||
|
[remote "origin"]
|
||||||
|
fetch = +refs/pull/*/head:refs/remotes/origin/pr/*
|
||||||
|
[remote "upstream"]
|
||||||
|
fetch = +refs/pull/*/head:refs/remotes/upstream/pr/*
|
||||||
[log]
|
[log]
|
||||||
date = iso8601-local
|
date = iso8601-local
|
||||||
[format]
|
[format]
|
||||||
@ -31,6 +37,23 @@
|
|||||||
count = !echo $(pwd) && git rev-list HEAD --count
|
count = !echo $(pwd) && git rev-list HEAD --count
|
||||||
unpushed = !git log --oneline @{u}..HEAD
|
unpushed = !git log --oneline @{u}..HEAD
|
||||||
leaders = !git shortlog -s -n --all --no-merges
|
leaders = !git shortlog -s -n --all --no-merges
|
||||||
|
defbranch = "!defbranch() { \
|
||||||
|
r=\"${1:-origin}\"; \
|
||||||
|
{ \
|
||||||
|
git symbolic-ref \"refs/remotes/$r/HEAD\" || { \
|
||||||
|
git remote set-head \"$r\" -a >&2 && \
|
||||||
|
git symbolic-ref \"refs/remotes/$r/HEAD\"; \
|
||||||
|
}; \
|
||||||
|
} 2>/dev/null \
|
||||||
|
| sed \"s@^refs/remotes/$r/@@\"; \
|
||||||
|
}; defbranch"
|
||||||
|
cleanmerged = "!cleanmerged() { \
|
||||||
|
r=\"${1:-origin}\"; \
|
||||||
|
b=\"${2:-$(git defbranch \"$r\")}\"; \
|
||||||
|
git branch --merged \"$r/$b\" | \
|
||||||
|
grep -ve \"^\\\\*\" -e \"^. $b$\" | \
|
||||||
|
xargs -r git branch -d; \
|
||||||
|
}; cleanmerged"
|
||||||
[advice]
|
[advice]
|
||||||
statusHints = false
|
statusHints = false
|
||||||
pushUpdateRejected = false
|
pushUpdateRejected = false
|
||||||
|
@ -1,11 +1,8 @@
|
|||||||
# DO NOT EDIT! This file will be overwritten by LXAppearance.
|
|
||||||
# Any customization should be done in ~/.gtkrc-2.0.mine instead.
|
|
||||||
|
|
||||||
gtk-theme-name="Arc-Dark"
|
gtk-theme-name="Arc-Dark"
|
||||||
gtk-icon-theme-name="Xenlism-Wildfire"
|
gtk-icon-theme-name="Xenlism-Wildfire"
|
||||||
gtk-font-name="Noto Sans 9"
|
gtk-font-name="sans 9"
|
||||||
gtk-cursor-theme-name="Breeze_Obsidian"
|
gtk-cursor-theme-name="Breeze_Obsidian"
|
||||||
gtk-cursor-theme-size=0
|
gtk-cursor-theme-size=16
|
||||||
gtk-toolbar-style=GTK_TOOLBAR_BOTH
|
gtk-toolbar-style=GTK_TOOLBAR_BOTH
|
||||||
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||||
gtk-button-images=1
|
gtk-button-images=1
|
||||||
|
@ -2,9 +2,9 @@
|
|||||||
gtk-theme-name=Arc-Dark
|
gtk-theme-name=Arc-Dark
|
||||||
gtk-icon-theme-name=Xenlism-Wildfire
|
gtk-icon-theme-name=Xenlism-Wildfire
|
||||||
gtk-application-prefer-dark-theme=true
|
gtk-application-prefer-dark-theme=true
|
||||||
gtk-font-name=Noto Sans 9
|
gtk-font-name=sans 9
|
||||||
gtk-cursor-theme-name=Breeze_Obsidian
|
gtk-cursor-theme-name=Breeze_Obsidian
|
||||||
gtk-cursor-theme-size=0
|
gtk-cursor-theme-size=16
|
||||||
gtk-toolbar-style=GTK_TOOLBAR_BOTH
|
gtk-toolbar-style=GTK_TOOLBAR_BOTH
|
||||||
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||||
gtk-button-images=1
|
gtk-button-images=1
|
||||||
|
1
gtk-4.0/settings.ini
Symbolic link
1
gtk-4.0/settings.ini
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
../gtk-3.0/settings.ini
|
@ -142,16 +142,17 @@ bindsym $mod+space exec "pkill rofi; rofi -show run -sidebar-mode -
|
|||||||
bindsym $mod+Shift+p exec rofi-pass --root $(grep path ~/.config/gopass/config.yml | sed -E 's|^.*fs\+file://||g' | tr '\n' ':') | sed 's/:$//g'
|
bindsym $mod+Shift+p exec rofi-pass --root $(grep path ~/.config/gopass/config.yml | sed -E 's|^.*fs\+file://||g' | tr '\n' ':') | sed 's/:$//g'
|
||||||
bindsym $mod+Shift+e exec "pkill rofi; rofi -show emoji -modi emoji -normal-window"
|
bindsym $mod+Shift+e exec "pkill rofi; rofi -show emoji -modi emoji -normal-window"
|
||||||
bindsym $mod+Shift+i exec rofi-fontawesome
|
bindsym $mod+Shift+i exec rofi-fontawesome
|
||||||
bindsym --release Print exec screenshot
|
bindsym --release Print exec screenshot --clip
|
||||||
bindsym --release $mod+Print exec screenshot --clip
|
bindsym --release $mod+Print exec screenshot
|
||||||
bindsym --release Shift+Print exec screenshot --active
|
bindsym --release Shift+Print exec screenshot --active
|
||||||
bindsym --release $mod+Shift+Print exec screenshot --active --clip
|
bindsym --release $mod+Shift+Print exec screenshot --active --clip
|
||||||
bindsym $mod+Shift+x exec systemd-run-i3 -n i3-sensible-terminal --class floating-term --hold -e /bin/echo "$(xprop -id $(xdotool getactivewindow))"
|
bindsym $mod+Shift+x exec systemd-run-i3 -n i3-sensible-terminal --class floating-term --hold -e /bin/echo "$(xprop -id $(xdotool getactivewindow))"
|
||||||
bindsym $mod+$alt+space exec systemd-run-i3 -s background -n ~/.config/i3/cycleaudio.py
|
bindsym $mod+$alt+space exec systemd-run-i3 -s background -n ~/.config/i3/cycleaudio.py
|
||||||
bindsym $mod+numbersign exec systemd-run-i3 -n i3-sensible-terminal --hold -e sh -c 'xclip -o | gpg --decrypt 2>&1'
|
bindsym $mod+numbersign exec systemd-run-i3 -n i3-sensible-terminal --hold -e sh -c 'xclip -o | gpg --decrypt 2>&1'
|
||||||
bindsym $mod+r exec bash -c 'pwgen -snc 32 1 | tee >(xargs notify-send Generated\ password\:) | xclip -i -r'
|
bindsym $mod+r exec bash -c 'pwgen -snc 32 1 | tee >(xargs notify-send Generated\ password\:) | xclip -i -r'
|
||||||
bindsym $mod+g exec systemd-run-i3 -n notify-send -c transfer "$(gist -PRpc)"
|
bindsym $mod+g exec systemd-run-i3 -n bash -xc 'xclip -o | gh gist create -d Paste - 2>&1 | grep -vE "^[-✓] Creat(ing|ed) gist" | tee >(xclip -i >&2 >/dev/null) | xargs -r notify-send -c transfer'
|
||||||
bindsym --release $mod+i exec systemd-run-i3 -s background -n sh -c 'sleep 0.5 && xdotool getactivewindow type --delay 250 "$(xclip -o -selection clipboard)"'
|
bindsym --release $mod+i exec systemd-run-i3 -s background -n sh -c 'sleep 0.5 && xdotool getactivewindow type --delay 10 -- "$(xclip -o -selection clipboard)"'
|
||||||
|
bindsym $mod+z exec otp | rofi -dmenu -p otp | xargs otp
|
||||||
|
|
||||||
# Media player controls
|
# Media player controls
|
||||||
bindsym XF86AudioPlay exec --no-startup-id playerctl -a play-pause
|
bindsym XF86AudioPlay exec --no-startup-id playerctl -a play-pause
|
||||||
|
106
picom/picom.conf
106
picom/picom.conf
@ -4,31 +4,29 @@ log-level = "info";
|
|||||||
|
|
||||||
# Shadow
|
# Shadow
|
||||||
shadow = true;
|
shadow = true;
|
||||||
shadow-radius = 24;
|
shadow-radius = 30;
|
||||||
shadow-offset-x = -24;
|
shadow-offset-x = -30;
|
||||||
shadow-offset-y = -24;
|
shadow-offset-y = -26;
|
||||||
shadow-opacity = 0.6;
|
shadow-opacity = 0.35;
|
||||||
# shadow-red = 0.0;
|
shadow-color = "#000000";
|
||||||
# shadow-green = 0.0;
|
|
||||||
# shadow-blue = 0.0;
|
|
||||||
shadow-exclude = [
|
shadow-exclude = [
|
||||||
"class_g = 'slop'",
|
"class_g = 'slop'",
|
||||||
"class_g = 'Conky'",
|
"class_g = 'Conky'",
|
||||||
"class_g ?= 'Notify-osd'",
|
"class_g ?= 'Notify-osd'",
|
||||||
"class_g = 'Cairo-clock'",
|
"class_g = 'firefox' && argb && (window_type = 'utility' || window_type = 'popup_menu')",
|
||||||
"class_g = 'firefox' && argb",
|
|
||||||
"name = 'Notification'",
|
"name = 'Notification'",
|
||||||
"name = 'cpt_frame_window'",
|
"name = 'cpt_frame_window'",
|
||||||
"_GTK_FRAME_EXTENTS@:c"
|
"_GTK_FRAME_EXTENTS@:c"
|
||||||
];
|
];
|
||||||
# shadow-exclude = "n:e:Notification";
|
# shadow-exclude = "n:e:Notification";
|
||||||
# shadow-exclude-reg = "x10+0+0";
|
# shadow-exclude-reg = "x10+0+0";
|
||||||
|
# shadow-ignore-shaped = true;
|
||||||
xinerama-shadow-crop = true;
|
xinerama-shadow-crop = true;
|
||||||
|
|
||||||
# Opacity
|
# Opacity
|
||||||
frame-opacity = 1.0;
|
frame-opacity = 1.0;
|
||||||
# active-opacity = 0.8;
|
active-opacity = 1.0;
|
||||||
inactive-opacity = 0.6;
|
inactive-opacity = 0.5;
|
||||||
inactive-opacity-override = true;
|
inactive-opacity-override = true;
|
||||||
# inactive-dim = 0.2;
|
# inactive-dim = 0.2;
|
||||||
# inactive-dim-fixed = true;
|
# inactive-dim-fixed = true;
|
||||||
@ -40,7 +38,7 @@ opacity-rule = [
|
|||||||
blur:
|
blur:
|
||||||
{
|
{
|
||||||
method = "dual_kawase";
|
method = "dual_kawase";
|
||||||
strength = 8;
|
strength = 10;
|
||||||
};
|
};
|
||||||
blur-background-frame = true;
|
blur-background-frame = true;
|
||||||
blur-background-fixed = true;
|
blur-background-fixed = true;
|
||||||
@ -49,56 +47,88 @@ blur-background-exclude = [
|
|||||||
"class_g = 'Onboard'",
|
"class_g = 'Onboard'",
|
||||||
"class_g = 'slop'",
|
"class_g = 'slop'",
|
||||||
"class_g = 'Polybar'",
|
"class_g = 'Polybar'",
|
||||||
"class_g = 'firefox' && argb",
|
"class_g = 'firefox' && argb && (window_type = 'utility' || window_type = 'popup_menu')",
|
||||||
"window_type = 'dock'",
|
"window_type = 'dock'",
|
||||||
"window_type = 'desktop'",
|
"window_type = 'desktop'",
|
||||||
"_GTK_FRAME_EXTENTS@:c"
|
"_GTK_FRAME_EXTENTS@:c",
|
||||||
|
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_HIDDEN'"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Corners
|
||||||
|
corner-radius = 9;
|
||||||
|
|
||||||
# Fading
|
# Fading
|
||||||
fading = true;
|
fading = true;
|
||||||
fade-delta = 10;
|
fade-delta = 10;
|
||||||
fade-in-step = 0.04
|
fade-in-step = 0.035;
|
||||||
fade-out-step = 0.06;
|
fade-out-step = 0.06;
|
||||||
no-fading-openclose = false;
|
no-fading-openclose = false;
|
||||||
no-fading-destroyed-argb = false;
|
no-fading-destroyed-argb = false;
|
||||||
# fade-exclude = [ ];
|
# fade-exclude = [ ];
|
||||||
|
|
||||||
# Other
|
# Focus
|
||||||
backend = "glx";
|
|
||||||
mark-wmwin-focused = true;
|
|
||||||
mark-ovredir-focused = true;
|
|
||||||
use-ewmh-active-win = true;
|
|
||||||
detect-rounded-corners = true;
|
|
||||||
detect-client-opacity = true;
|
|
||||||
refresh-rate = 0;
|
|
||||||
# vsync = true;
|
|
||||||
# sw-opti = true;
|
|
||||||
# unredir-if-possible = true;
|
|
||||||
# unredir-if-possible-delay = 5000;
|
|
||||||
# unredir-if-possible-exclude = [ ];
|
|
||||||
focus-exclude = [
|
focus-exclude = [
|
||||||
"i:ai:chromium",
|
"i:ai:chromium",
|
||||||
"class_g = 'firefox'",
|
"class_g = 'firefox'",
|
||||||
"class_g = 'zoom'"
|
"class_g = 'zoom'",
|
||||||
|
"class_g = 'guvcview'",
|
||||||
|
"class_g = 'Entangle'",
|
||||||
|
"class_g = 'obs'",
|
||||||
|
"class_g = 'parsecd'",
|
||||||
|
"class_g = 'discord'",
|
||||||
|
"class_g = 'steam_app_271590'"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Other
|
||||||
|
# https://github.com/yshui/picom/blob/next/picom.sample.conf#L203
|
||||||
|
backend = "glx";
|
||||||
|
vsync = true;
|
||||||
|
mark-wmwin-focused = true;
|
||||||
|
mark-ovredir-focused = true;
|
||||||
|
detect-rounded-corners = true;
|
||||||
|
detect-client-opacity = true;
|
||||||
|
use-ewmh-active-win = true;
|
||||||
|
# unredir-if-possible = true;
|
||||||
|
# unredir-if-possible-delay = 5000;
|
||||||
|
# unredir-if-possible-exclude = [ ];
|
||||||
detect-transient = true;
|
detect-transient = true;
|
||||||
detect-client-leader = true;
|
detect-client-leader = true;
|
||||||
invert-color-include = [ ];
|
invert-color-include = [ ];
|
||||||
# resize-damage = 1;
|
resize-damage = 1;
|
||||||
|
|
||||||
# GLX backend
|
# GLX backend
|
||||||
glx-no-stencil = true;
|
glx-no-stencil = true;
|
||||||
glx-no-rebind-pixmap = true;
|
glx-no-rebind-pixmap = true;
|
||||||
xrender-sync-fence = true;
|
# xrender-sync-fence = true;
|
||||||
|
# no-use-damage = false;
|
||||||
use-damage = true;
|
use-damage = true;
|
||||||
|
|
||||||
# Window type settings
|
# Window type settings
|
||||||
wintypes:
|
wintypes: {
|
||||||
{
|
tooltip = {
|
||||||
tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };
|
opacity = 0.75;
|
||||||
dock = { shadow = false; }
|
full-shadow = false;
|
||||||
dnd = { shadow = false; }
|
blur-background = false;
|
||||||
popup_menu = { opacity = 0.8; }
|
}
|
||||||
dropdown_menu = { opacity = 0.8; }
|
|
||||||
|
dock = {
|
||||||
|
# Prevents polybar getting a forehead-shadow
|
||||||
|
shadow = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
dnd = {
|
||||||
|
# Prevents dragged text in a browser getting blur/shadow
|
||||||
|
shadow = false;
|
||||||
|
blur-background = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
popup_menu = {
|
||||||
|
opacity = 0.8;
|
||||||
|
}
|
||||||
|
|
||||||
|
dropdown_menu = {
|
||||||
|
opacity = 0.8;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# vim: ft=conf noet
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
[colours]
|
[colours]
|
||||||
background = transparent
|
background = #0000
|
||||||
text = #eceff1
|
text = #eceff1
|
||||||
icon = #147a82
|
icon = #147a82
|
||||||
warning = #ffcb00
|
warning = #ffcb00
|
||||||
@ -10,25 +10,23 @@ urgent = #e53935
|
|||||||
format-foreground = ${colours.text}
|
format-foreground = ${colours.text}
|
||||||
format-background = ${colours.background}
|
format-background = ${colours.background}
|
||||||
format-spacing = 0
|
format-spacing = 0
|
||||||
format-margin = 2.5
|
format-margin = 3
|
||||||
format-offset = 0
|
format-offset = 0
|
||||||
|
|
||||||
screenchange-reload = true
|
screenchange-reload = true
|
||||||
|
|
||||||
[bar/i3bar]
|
[bar/i3bar]
|
||||||
monitor = ${env:MONITOR:HDMI-0}
|
|
||||||
dpi = ${xrdb:Xft.dpi:96}
|
dpi = ${xrdb:Xft.dpi:96}
|
||||||
fixed-center = false
|
fixed-center = false
|
||||||
enable-ipc = true
|
enable-ipc = true
|
||||||
|
|
||||||
width = 100%
|
width = 100%
|
||||||
#offset-x = 18px
|
|
||||||
height = 16pt
|
height = 16pt
|
||||||
bottom = true
|
bottom = true
|
||||||
radius = 0
|
radius = 0
|
||||||
|
|
||||||
font-0 = sans:pixelsize=9;2pt
|
font-0 = sans:pixelsize=9;2pt
|
||||||
font-1 = FontAwesome5ProLight:pixelsize=10;2pt
|
font-1 = FontAwesome6ProLight:pixelsize=10;2pt
|
||||||
|
|
||||||
foreground = ${colours.text}
|
foreground = ${colours.text}
|
||||||
background = ${colours.background}
|
background = ${colours.background}
|
||||||
@ -39,22 +37,21 @@ padding-right = 2pt
|
|||||||
border-size = 0
|
border-size = 0
|
||||||
border-left-size = 16pt
|
border-left-size = 16pt
|
||||||
border-right-size = 16pt
|
border-right-size = 16pt
|
||||||
border-bottom-size = 8pt
|
border-bottom-size = 10pt
|
||||||
|
|
||||||
line-size = 0
|
line-size = 0
|
||||||
line-colour = #f00
|
line-colour = #f00
|
||||||
|
|
||||||
modules-left = i3
|
modules-left = i3
|
||||||
modules-center =
|
modules-center =
|
||||||
# modules-right = volume updates weather xkeyboard wlan gateway eth memory cpu xbacklight battery cputemp gputemp date
|
modules-right = volume updates weather wifi ethernet memory cpu cputemp backlight battery date
|
||||||
modules-right = volume updates weather wlan gateway eth memory cpu xbacklight battery cputemp gputemp date
|
|
||||||
|
|
||||||
tray-position = right
|
tray-position = right
|
||||||
tray-detached = false
|
tray-detached = false
|
||||||
tray-background = ${colours.background}
|
tray-background = ${colours.background}
|
||||||
#tray-offset-x = -20
|
#tray-offset-x = -20
|
||||||
#tray-offset-y = 0
|
#tray-offset-y = 0
|
||||||
tray-maxsize = 12pt
|
tray-maxsize = 16pt
|
||||||
tray-padding = 8pt
|
tray-padding = 8pt
|
||||||
tray-scale = 1.0
|
tray-scale = 1.0
|
||||||
|
|
||||||
@ -134,8 +131,9 @@ label-urgent-foreground = ${colours.urgent}
|
|||||||
label-urgent-padding = ${self.label-focused-padding}
|
label-urgent-padding = ${self.label-focused-padding}
|
||||||
|
|
||||||
|
|
||||||
[module/xbacklight]
|
[module/backlight]
|
||||||
type = internal/xbacklight
|
type = internal/backlight
|
||||||
|
card = intel_backlight
|
||||||
|
|
||||||
label = %percentage%
|
label = %percentage%
|
||||||
format = <label>
|
format = <label>
|
||||||
@ -143,12 +141,6 @@ format-prefix = " "
|
|||||||
format-prefix-foreground = ${colours.icon}
|
format-prefix-foreground = ${colours.icon}
|
||||||
|
|
||||||
|
|
||||||
[module/backlight-acpi]
|
|
||||||
inherit = module/xbacklight
|
|
||||||
type = internal/backlight
|
|
||||||
card = intel_backlight
|
|
||||||
|
|
||||||
|
|
||||||
[module/cpu]
|
[module/cpu]
|
||||||
type = internal/cpu
|
type = internal/cpu
|
||||||
interval = 2
|
interval = 2
|
||||||
@ -166,9 +158,9 @@ format-prefix-foreground = ${colours.icon}
|
|||||||
label = %percentage_used%%
|
label = %percentage_used%%
|
||||||
|
|
||||||
|
|
||||||
[module/wlan]
|
[module/wifi]
|
||||||
type = internal/network
|
type = internal/network
|
||||||
interface = wlp1s0
|
interface-type = wireless
|
||||||
interval = 3.0
|
interval = 3.0
|
||||||
|
|
||||||
format-connected = <ramp-signal> <label-connected>
|
format-connected = <ramp-signal> <label-connected>
|
||||||
@ -187,12 +179,12 @@ ramp-signal-2 =
|
|||||||
ramp-signal-foreground = ${colours.icon}
|
ramp-signal-foreground = ${colours.icon}
|
||||||
|
|
||||||
|
|
||||||
[module/eth]
|
[module/ethernet]
|
||||||
type = internal/network
|
type = internal/network
|
||||||
interface = eth0
|
interface-type = wired
|
||||||
interval = 3.0
|
interval = 10.0
|
||||||
|
|
||||||
label-connected = %local_ip%
|
label-connected = %local_ip% & %local_ip6%
|
||||||
format-connected-prefix = " "
|
format-connected-prefix = " "
|
||||||
format-connected-prefix-foreground = ${colours.icon}
|
format-connected-prefix-foreground = ${colours.icon}
|
||||||
format-connected-underline = ${colours.background}
|
format-connected-underline = ${colours.background}
|
@ -8,7 +8,7 @@ window {
|
|||||||
border: 0.3em;
|
border: 0.3em;
|
||||||
border-color: #2f343f;
|
border-color: #2f343f;
|
||||||
padding: 0.8em;
|
padding: 0.8em;
|
||||||
background-color: rgba(56, 60, 74, 0.95);
|
background-color: rgba(56, 60, 74, 0.9);
|
||||||
transparency: "real";
|
transparency: "real";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,9 +1,6 @@
|
|||||||
configuration {
|
configuration {
|
||||||
theme: "arc-dark";
|
|
||||||
font: "sans 14";
|
font: "sans 14";
|
||||||
dpi: 0;
|
dpi: 0;
|
||||||
width: 35;
|
|
||||||
lines: 10;
|
|
||||||
|
|
||||||
/* show-icons: true; */
|
/* show-icons: true; */
|
||||||
separator-style: "solid";
|
separator-style: "solid";
|
||||||
@ -142,4 +139,15 @@ configuration {
|
|||||||
/* me-accept-custom: "Control+MouseDPrimary";*/
|
/* me-accept-custom: "Control+MouseDPrimary";*/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@theme "arc-dark"
|
||||||
|
|
||||||
|
window {
|
||||||
|
width: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
listview {
|
||||||
|
lines: 10;
|
||||||
|
columns: 1;
|
||||||
|
}
|
||||||
|
|
||||||
/* vim: ft=css sw=2 */
|
/* vim: ft=css sw=2 */
|
||||||
|
54
scripts/dpi
54
scripts/dpi
@ -4,48 +4,66 @@ set -eu
|
|||||||
# Based on https://github.com/vincentbernat/awesome-configuration/blob/master/bin/xsettingsd-setup
|
# Based on https://github.com/vincentbernat/awesome-configuration/blob/master/bin/xsettingsd-setup
|
||||||
CONF_DIR="${XDG_CONFIG_HOME:-$HOME/.config}"
|
CONF_DIR="${XDG_CONFIG_HOME:-$HOME/.config}"
|
||||||
|
|
||||||
|
BLUR_STRENGTH=10
|
||||||
|
CORNER_RADIUS=9
|
||||||
|
CURSOR_SIZE=16
|
||||||
|
|
||||||
xrdbget() {
|
xrdbget() {
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
xrdb -query | grep -i -m1 "$1" | sed 's/^.*:\s//g' || echo "$2"
|
xrdb -query | grep -i -m1 "$1" | sed 's/^.*:\s//g' || echo "$2"
|
||||||
}
|
}
|
||||||
|
|
||||||
dpi=$1
|
xsetting_bool() {
|
||||||
|
case "$1" in
|
||||||
|
true) echo 1;;
|
||||||
|
false) echo 0;;
|
||||||
|
default) echo -1;;
|
||||||
|
*) echo -1;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
if [ -z "$1" ]; then
|
|
||||||
>&2 printf "Usage\n\t%s: <dpi>" "$(basename "$0")"
|
if [ -z "$1" ] || [ "$1" -gt 200 ] || [ "$1" -lt 96 ]; then
|
||||||
|
>&2 printf "Usage\n\t%s: value\n\n value\t Value must be within 96-200 inclusive\n" "$(basename "$0")"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Update picom and xorg
|
dpi=$1
|
||||||
sed -i "s/strength =.*$/strength = $(( dpi*8/96 ));/" "$CONF_DIR/picom/picom.conf" &
|
|
||||||
xrandr --dpi "$dpi" &
|
|
||||||
|
|
||||||
scale=$(( dpi/96 ))
|
scale=$(( dpi/96 ))
|
||||||
cursor=$(( dpi/6 ))
|
cursor=$(( (dpi*CURSOR_SIZE)/96 ))
|
||||||
|
|
||||||
|
# Update picom scale
|
||||||
|
sed -i -e "s/strength =.*$/strength = $(( (dpi*BLUR_STRENGTH)/96 ));/" \
|
||||||
|
-e "s/corner-radius =.*$/corner-radius = $(( (dpi*CORNER_RADIUS)/96 ));/" \
|
||||||
|
"$CONF_DIR/picom/picom.conf" &
|
||||||
|
|
||||||
# Build xsettingsd.conf
|
# Build xsettingsd.conf
|
||||||
mkdir -p "$CONF_DIR/xsettingsd"
|
mkdir -p "$CONF_DIR/xsettingsd"
|
||||||
{
|
{
|
||||||
cat "$CONF_DIR/xsettingsd.local" 2>/dev/null || true
|
cat "$CONF_DIR/xsettingsd.local" 2>/dev/null || :
|
||||||
echo "Xcursor/size $cursor"
|
echo "Xcursor/size $cursor"
|
||||||
echo "Gtk/CursorThemeSize $cursor"
|
echo "Gtk/CursorThemeSize $cursor"
|
||||||
echo "Gtk/CursorThemeName \"$(xrdbget Xcursor.theme Adwaita)\""
|
echo "Gtk/CursorThemeName \"$(xrdbget Xcursor.theme Adwaita)\""
|
||||||
echo "Xft/HintStyle \"$(xrdbget Xft.hintstyle hintfull)\""
|
echo "Xft/HintStyle \"$(xrdbget Xft.hintstyle hintfull)\""
|
||||||
echo "Xft/Hinting \"$(xrdbget Xft.hinting -1)\""
|
echo "Xft/Hinting $(xsetting_bool "$(xrdbget Xft.hinting default)")"
|
||||||
echo "Xft/RGBA \"$(xrdbget Xft.rgba rgb)\""
|
echo "Xft/RGBA \"$(xrdbget Xft.rgba rgb)\""
|
||||||
echo "Xft/DPI $(( dpi*1024 ))"
|
echo "Xft/DPI $(( dpi*1024 ))"
|
||||||
echo "Gdk/WindowScalingFactor $scale"
|
echo "Gdk/WindowScalingFactor $scale"
|
||||||
echo "Gdk/UnscaledDPI $(( dpi*1024/scale ))"
|
echo "Gdk/UnscaledDPI $(( dpi*1024/scale ))"
|
||||||
} > "$CONF_DIR/xsettingsd/xsettingsd.conf"
|
} > "$CONF_DIR/xsettingsd/xsettingsd.conf"
|
||||||
|
|
||||||
{
|
xrdb -merge <<EOF &
|
||||||
echo "Xft.dpi: $dpi"
|
Xft.dpi: $dpi
|
||||||
echo "Xcursor.size: $cursor"
|
Xcursor.size: $cursor
|
||||||
} | xrdb -merge &
|
EOF
|
||||||
|
xrandr --dpi "$dpi" &
|
||||||
systemctl --user reload-or-restart xsettingsd &
|
systemctl --user try-reload-or-restart xsettingsd &
|
||||||
wait
|
wait
|
||||||
|
|
||||||
systemctl --user reload \
|
systemctl --user try-reload-or-restart \
|
||||||
i3 \
|
i3 \
|
||||||
polybar@i3bar
|
polybar@i3bar &
|
||||||
|
systemctl --user try-restart \
|
||||||
|
dunst &
|
||||||
|
|
||||||
|
wait
|
||||||
|
45
scripts/otp
Executable file
45
scripts/otp
Executable file
@ -0,0 +1,45 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
NOTIF_PERSIST=30000
|
||||||
|
NOTIF_INFORM=5000
|
||||||
|
|
||||||
|
stdout=
|
||||||
|
caller=
|
||||||
|
notif=
|
||||||
|
|
||||||
|
while getopts "on:" o; do
|
||||||
|
case "${o}" in
|
||||||
|
o)
|
||||||
|
stdout=1;;
|
||||||
|
n)
|
||||||
|
caller="${OPTARG}"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
exec ykman oath accounts list
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
shift $((OPTIND-1))
|
||||||
|
|
||||||
|
if [ $# -lt 1 ]; then
|
||||||
|
exec ykman oath accounts list
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "$caller" ]; then
|
||||||
|
notif="$(notify-send -p -t $NOTIF_PERSIST "Touch your Yubikey" "$caller is requesting otp for $1")"
|
||||||
|
trap 'notify-send -r $notif -t 1 "Touch your Yubikey" "$caller is requesting otp for $1"' EXIT
|
||||||
|
fi
|
||||||
|
|
||||||
|
code=$(ykman oath accounts code -s "$1")
|
||||||
|
if [ -z "$stdout" ]; then
|
||||||
|
echo "$code" | tee >(xclip -i)
|
||||||
|
xdotool type "$code"
|
||||||
|
else
|
||||||
|
echo "$code"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "$code" ] && [ -n "$notif" ]; then
|
||||||
|
trap : EXIT
|
||||||
|
notify-send -r "$notif" -t $NOTIF_INFORM "Yubikey Touched" "otp generated for $caller"
|
||||||
|
fi
|
@ -1,5 +1,6 @@
|
|||||||
#!/bin/bash -e
|
#!/bin/bash -e
|
||||||
|
|
||||||
|
slice=app
|
||||||
rand=$(tr -dc 'a-f0-9' < /dev/urandom | head -c 8)
|
rand=$(tr -dc 'a-f0-9' < /dev/urandom | head -c 8)
|
||||||
|
|
||||||
args=()
|
args=()
|
||||||
@ -16,14 +17,11 @@ do case "$opt" in
|
|||||||
done
|
done
|
||||||
shift $((OPTIND-1))
|
shift $((OPTIND-1))
|
||||||
|
|
||||||
if [ -z "$slice" ]; then
|
|
||||||
slice=app
|
|
||||||
fi
|
|
||||||
|
|
||||||
exec systemd-run \
|
exec systemd-run \
|
||||||
--user \
|
--user \
|
||||||
--collect \
|
--collect \
|
||||||
--slice="$slice" \
|
--slice="$slice" \
|
||||||
--unit="$slice-$1-$rand" \
|
--unit="$slice-$1-$rand" \
|
||||||
--property=BindsTo=graphical-session.target \
|
--property=BindsTo=graphical-session.target \
|
||||||
${args[@]} -- "$@"
|
--property=ExitType=cgroup \
|
||||||
|
"${args[@]}" -- "$@"
|
||||||
|
13
ssh/askpass
Executable file
13
ssh/askpass
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
#!/bin/sh -e
|
||||||
|
|
||||||
|
if [ -z "$SSH_HOST" ]; then
|
||||||
|
>&2 echo 'Missing SSH_HOST variable'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "$SSH_HOST" in
|
||||||
|
*)
|
||||||
|
echo 'Unknown SSH host'
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
1
systemd/user/default.target.wants/pipewire.service
Symbolic link
1
systemd/user/default.target.wants/pipewire.service
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
/usr/lib/systemd/user/pipewire.service
|
@ -4,7 +4,7 @@ Requires=graphical-session.target
|
|||||||
After=dbus.service graphical-session.target xorg.target
|
After=dbus.service graphical-session.target xorg.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
ExecStart=/usr/bin/picom --experimental-backends --dbus
|
ExecStart=/usr/bin/picom --dbus
|
||||||
Restart=always
|
Restart=always
|
||||||
Slice=session.slice
|
Slice=session.slice
|
||||||
|
|
||||||
|
1
systemd/user/pipewire-session-manager.service
Symbolic link
1
systemd/user/pipewire-session-manager.service
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
/usr/lib/systemd/user/wireplumber.service
|
1
systemd/user/pipewire.service.wants/wireplumber.service
Symbolic link
1
systemd/user/pipewire.service.wants/wireplumber.service
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
/usr/lib/systemd/user/wireplumber.service
|
@ -1,11 +1,11 @@
|
|||||||
[Unit]
|
[Unit]
|
||||||
Description=Polybar
|
Description=Polybar bar %i
|
||||||
Requires=graphical-session.target
|
Requires=graphical-session.target
|
||||||
After=graphical-session.target pulseaudio.socket i3.service
|
After=graphical-session.target pulseaudio.socket i3.service
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
ExecStart=/usr/bin/polybar --reload --log=warning %i
|
ExecStart=/usr/bin/polybar --reload --log=warning %i
|
||||||
ExecReload=/usr/bin/polybar-msg cmd restart -p $MAINPID
|
ExecReload=/usr/bin/polybar-msg -p $MAINPID cmd restart
|
||||||
Restart=always
|
Restart=always
|
||||||
Slice=session.slice
|
Slice=session.slice
|
||||||
|
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
[Service]
|
|
||||||
Slice=session.slice
|
|
1
systemd/user/sockets.target.wants/pipewire.socket
Symbolic link
1
systemd/user/sockets.target.wants/pipewire.socket
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
/usr/lib/systemd/user/pipewire.socket
|
@ -1 +0,0 @@
|
|||||||
/usr/lib/systemd/user/pulseaudio.socket
|
|
13
systemd/user/ssh@.service
Normal file
13
systemd/user/ssh@.service
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=SSH persistent connection to %i
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=forking
|
||||||
|
Slice=ssh.slice
|
||||||
|
Environment=SSH_ASKPASS=%E/ssh/askpass
|
||||||
|
Environment=SSH_HOST=%i
|
||||||
|
ExecStart=/usr/bin/ssh -fNT %i
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=ssh.target
|
@ -70,7 +70,7 @@ set splitright " Vertical split to right of current.
|
|||||||
|
|
||||||
" Whitespace highlight settings
|
" Whitespace highlight settings
|
||||||
set list
|
set list
|
||||||
set listchars=eol:$,space:·,tab:>-,trail:◦,extends:▶,precedes:◀
|
set listchars=space:·,tab:>-,trail:◦,extends:▶,precedes:◀
|
||||||
highlight SpecialKey ctermfg=8
|
highlight SpecialKey ctermfg=8
|
||||||
|
|
||||||
set cc=+1
|
set cc=+1
|
||||||
|
27
zsh/.zshrc
27
zsh/.zshrc
@ -16,9 +16,10 @@ if exists tty && tty -s; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Configure less and add colours
|
# Configure less and add colours
|
||||||
export LESS="-RI --mouse --wheel-lines=3"
|
export LESS="-nRIFRSXM --mouse --wheel-lines=3"
|
||||||
export PAGER="less"
|
export PAGER="less"
|
||||||
export MANPAGER="less -+N"
|
export MANPAGER="less -+N"
|
||||||
|
export SYSTEMD_LESS="$LESS"
|
||||||
export SYSTEMD_PAGER="less $LESS"
|
export SYSTEMD_PAGER="less $LESS"
|
||||||
# Disable histfile
|
# Disable histfile
|
||||||
export LESSHISTFILE=-
|
export LESSHISTFILE=-
|
||||||
@ -59,13 +60,14 @@ ZINIT[HOME_DIR]="$XDG_CACHE_HOME/zsh/zinit"
|
|||||||
ZINIT[BIN_DIR]="${ZINIT[HOME_DIR]}/bin"
|
ZINIT[BIN_DIR]="${ZINIT[HOME_DIR]}/bin"
|
||||||
ZINIT[PLUGINS_DIR]="${ZINIT[HOME_DIR]}/plugins"
|
ZINIT[PLUGINS_DIR]="${ZINIT[HOME_DIR]}/plugins"
|
||||||
if [ ! -e "${ZINIT[HOME_DIR]}" ]; then
|
if [ ! -e "${ZINIT[HOME_DIR]}" ]; then
|
||||||
git clone https://github.com/zdharma/zinit.git "${ZINIT[HOME_DIR]}"
|
git clone https://github.com/zdharma-continuum/zinit.git "${ZINIT[HOME_DIR]}"
|
||||||
fi
|
fi
|
||||||
source "${ZINIT[HOME_DIR]}"/zinit.zsh
|
source "${ZINIT[HOME_DIR]}"/zinit.zsh
|
||||||
|
|
||||||
zinit wait lucid light-mode for \
|
zinit wait lucid for \
|
||||||
atinit"ZINIT[COMPINIT_OPTS]=-C;zicompinit;zicdreplay" \
|
atinit"ZINIT[COMPINIT_OPTS]=-C;zicompinit;zicdreplay" \
|
||||||
zdharma/fast-syntax-highlighting \
|
atload"FAST_HIGHLIGHT[chroma-zinit]=" \
|
||||||
|
zdharma-continuum/fast-syntax-highlighting \
|
||||||
blockf \
|
blockf \
|
||||||
zsh-users/zsh-completions \
|
zsh-users/zsh-completions \
|
||||||
atload"!_zsh_autosuggest_start" \
|
atload"!_zsh_autosuggest_start" \
|
||||||
@ -89,13 +91,16 @@ bindkey "^[[7~" beginning-of-line
|
|||||||
bindkey "^[[8~" end-of-line
|
bindkey "^[[8~" end-of-line
|
||||||
bindkey "^[[3~" delete-char
|
bindkey "^[[3~" delete-char
|
||||||
bindkey "^[[3;3~" delete-word
|
bindkey "^[[3;3~" delete-word
|
||||||
bindkey '^[[A' fzf-history-widget # Up (fzf)
|
|
||||||
bindkey '^[[B' fzf-history-widget # Down (fzf)
|
|
||||||
bindkey '^F' fzf-file-widget # Ctrl+F file search (fzf)
|
|
||||||
|
|
||||||
bindkey "^F" fzf-file-widget
|
bindkey "^F" fzf-file-widget # Ctrl+F file search (fzf)
|
||||||
|
bindkey "^[[A" fzf-history-widget # Up (fzf)
|
||||||
|
bindkey "^[[B" fzf-history-widget # Down (fzf)
|
||||||
|
bindkey "${terminfo[kcuu1]}" fzf-history-widget # Up (fzf)
|
||||||
|
bindkey "${terminfo[kcud1]}" fzf-history-widget # Down (fzf)
|
||||||
|
|
||||||
|
# Backspace across newlines when in vi-mode
|
||||||
|
bindkey -v '^?' backward-delete-char
|
||||||
bindkey -M vicmd "^W" backward-delete-word
|
bindkey -M vicmd "^W" backward-delete-word
|
||||||
|
|
||||||
bindkey -M vicmd d vi-backward-char
|
bindkey -M vicmd d vi-backward-char
|
||||||
bindkey -M vicmd h vi-down-line-or-history
|
bindkey -M vicmd h vi-down-line-or-history
|
||||||
bindkey -M vicmd t vi-up-line-or-history
|
bindkey -M vicmd t vi-up-line-or-history
|
||||||
@ -105,8 +110,8 @@ bindkey -M vicmd K vi-kill-eol
|
|||||||
bindkey -M vicmd j vi-find-next-char-skip
|
bindkey -M vicmd j vi-find-next-char-skip
|
||||||
bindkey -M vicmd l vi-repeat-search
|
bindkey -M vicmd l vi-repeat-search
|
||||||
|
|
||||||
# Backspace across newlines when in vi-mode
|
# Disable all fsh chromas, fixes `zi` being slow
|
||||||
bindkey -v '^?' backward-delete-char
|
FAST_HIGHLIGHT=()
|
||||||
|
|
||||||
ZSH_AUTOSUGGEST_USE_ASYNC=true
|
ZSH_AUTOSUGGEST_USE_ASYNC=true
|
||||||
ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=128
|
ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=128
|
||||||
|
@ -1,9 +1,19 @@
|
|||||||
# ZSH Theme emulating the Fish shell's default prompt.
|
# ZSH Theme emulating the Fish shell's default prompt.
|
||||||
|
|
||||||
_fishy_collapsed_wd() {
|
_fishy_collapsed_wd() {
|
||||||
pwd | sed -E 's|^'$HOME'|~|;s|(.*)/|\1%|;s|((^\|/)\.?[^/%]{1})[^/%]*|\1|g;s|(.*)%|\1/|'
|
pwd | sed -E 's|^'$HOME'|~|;s|([\.~]?[^/]{1})[^/]*/|\1/|g'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function zle-line-init zle-keymap-select {
|
||||||
|
case $KEYMAP in
|
||||||
|
vicmd) printf '\e[3 q';; # block cursor
|
||||||
|
*) printf '\e[2 q';; # less visible cursor
|
||||||
|
esac
|
||||||
|
zle reset-prompt
|
||||||
|
}
|
||||||
|
zle -N zle-line-init
|
||||||
|
zle -N zle-keymap-select
|
||||||
|
|
||||||
# Required for dynamic prompt
|
# Required for dynamic prompt
|
||||||
setopt prompt_subst
|
setopt prompt_subst
|
||||||
|
|
||||||
@ -11,4 +21,8 @@ local user_color='green'; [ $UID -eq 0 ] && user_color='red'
|
|||||||
PROMPT="%n@%m %F{$user_color}\$(_fishy_collapsed_wd)%f%(!.#.>) "
|
PROMPT="%n@%m %F{$user_color}\$(_fishy_collapsed_wd)%f%(!.#.>) "
|
||||||
PROMPT2='%F{red}\ %f'
|
PROMPT2='%F{red}\ %f'
|
||||||
|
|
||||||
RPROMPT='%F{red}%(?.. %?)%f'
|
RPROMPT='%F{cyan}${${KEYMAP/vicmd/ normal}/(main|viins)/}%f%(?.. %F{red}%?%f)'
|
||||||
|
|
||||||
|
# Disable trailing space
|
||||||
|
# https://superuser.com/questions/655607/removing-the-useless-space-at-the-end-of-the-right-prompt-of-zsh-rprompt
|
||||||
|
ZLE_RPROMPT_INDENT=0
|
||||||
|
Reference in New Issue
Block a user