-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Massive (hypr migration and misc updates)
- Loading branch information
Showing
44 changed files
with
1,124 additions
and
102 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
.DS_Store | ||
files/git | ||
packer_compiled.lua | ||
todo.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -lt 1 ] | ||
then | ||
cat << HELP | ||
dockertags -- list all tags for a Docker image on a remote registry. | ||
EXAMPLE: | ||
- list all tags for ubuntu: | ||
dockertags ubuntu | ||
- list all php tags containing apache: | ||
dockertags php apache | ||
HELP | ||
fi | ||
|
||
|
||
image_arr=($(echo $1 | tr "/" "\n")) | ||
|
||
if [ "${#image_arr[@]}" -eq 1 ]; then | ||
org=library | ||
image=${image_arr[0]} | ||
else | ||
org=${image_arr[0]} | ||
image=${image_arr[1]} | ||
|
||
fi | ||
|
||
URL="https://registry.hub.docker.com/v2/repositories/${org}/${image}/tags?page_size=1024" | ||
|
||
tags=`curl -L -s ${URL} | jq '."results"[]["name"]'` | ||
|
||
if [ -n "$2" ] | ||
then | ||
tags=` echo "${tags}" | grep "$2" ` | ||
fi | ||
|
||
echo "${tags}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
vivaldi-stable \ | ||
--disable-software-rasterizer \ | ||
--disable-gpu-driver-bug-workarounds \ | ||
--disable-gpu-driver-workarounds \ | ||
--disable-gpu-vsync \ | ||
--ozone-platform-hint=auto \ | ||
--disable-reading-from-canvas \ | ||
--enable-accelerated-2d-canvas \ | ||
--enable-accelerated-video-decode \ | ||
--enable-accelerated-mjpeg-decode \ | ||
--enable-features=VaapiVideoEncoder,VaapiVideoDecoder,CanvasOopRasterization \ | ||
--enable-gpu-compositing \ | ||
--enable-native-gpu-memory-buffers \ | ||
--enable-gpu-rasterization \ | ||
--enable-oop-rasterization \ | ||
--enable-raw-draw \ | ||
--enable-zero-copy \ | ||
--ignore-gpu-blocklist \ | ||
--use-gl=desktop \ | ||
--num-raster-threads=6\ | ||
--disable-features=UseChromeOSDirectVideoDecoder |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#/!bin/bash | ||
polybar & |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
#!/usr/bin/env bash | ||
# https://gitlab.com/wef/dotfiles/-/blob/master/bin/sway-prop | ||
# shellcheck disable=SC2034 | ||
TIME_STAMP="20230211.212842" | ||
|
||
# Copyright (C) 2020-2021 Bob Hepple <bob dot hepple at gmail dot com> | ||
|
||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License as published by | ||
# the Free Software Foundation, either version 3 of the License, or (at | ||
# your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, but | ||
# WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
# General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
PROG=$( basename "$0" ) | ||
|
||
case "$1" in | ||
-h|--help) | ||
echo "Usage: $PROG" | ||
echo | ||
# shellcheck disable=SC2016 | ||
echo 'shows the properties of the focused window | ||
best bindings: | ||
bindsym $mod+question exec sway-prop | ||
bindsym $a+$c+question exec sway-prop | ||
but if running from a terminal rather than a sway key binding: | ||
sleep 2; sway-prop' | ||
exit 0 | ||
;; | ||
esac | ||
|
||
TMP=/tmp/sway-prop-$$.tmp | ||
|
||
trap 'rm $TMP' EXIT | ||
|
||
swaymsg -t get_tree | jq '.. | select(.type?) | select(.focused==true)' > "$TMP" | ||
|
||
if [[ "$1" || -t 1 ]]; then | ||
cat "$TMP" | ||
else | ||
# I prefer to popup a terminal eg: | ||
if type foot &> /dev/null; then | ||
kitty -1 --instance-group modal --class floating -o initial_window_width=800 -o initial_window_height=1000 -e bash -c "bat $TMP" | ||
else | ||
# ... but sway doesn't have anything like i3-sensible-terminal. | ||
# swaynag is always installed with sway, so: | ||
swaynag -l -m "sway-prop" < "$TMP" | ||
fi | ||
fi | ||
|
||
# Local Variables: | ||
# mode: shell-script | ||
# time-stamp-pattern: "4/TIME_STAMP=\"%:y%02m%02d.%02H%02M%02S\"" | ||
# eval: (add-hook 'before-save-hook 'time-stamp) | ||
# End: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/sh | ||
|
||
echo "123" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/usr/bin/env bash | ||
|
||
if [[ "${1:-}" = slack://* ]]; then | ||
exec /usr/lib/slack/slack --enable-crashpad "$1" | ||
fi | ||
|
||
exec /usr/bin/xdg-open "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[user] | ||
email = [email protected] | ||
name = 'Anton Shuvalov' | ||
name = Anton Shuvalov | ||
[core] | ||
editor = nvim | ||
bare = false | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#! /bin/bash | ||
STATS_FILE=~/.tmp/pomodoro.log | ||
|
||
F=`cat ${STATS_FILE} | grep $(date '+%Y-%m-%d') | grep F | wc -l` | ||
R=`cat ${STATS_FILE} | grep $(date '+%Y-%m-%d') | grep R | wc -l` | ||
P=`cat ${STATS_FILE} | grep $(date '+%Y-%m-%d') | grep P | wc -l` | ||
|
||
echo "F:${F} R:${R} P:${P}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#! /bin/bash | ||
while true; do uair; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
#! /usr/bin/python3 | ||
|
||
# Dependencies: | ||
# - hyprctl | ||
# - jq | ||
|
||
import os | ||
import logging | ||
import subprocess | ||
import random | ||
import time | ||
from pathlib import Path | ||
|
||
|
||
WALLPAPERS_DIR = os.path.expanduser("~/Pictures/Wallpapers") | ||
INTERVAL = 60 | ||
SUPPORTED_IMAGE_EXTS = ['.jpg', 'jpeg', '.png'] | ||
|
||
|
||
logging.basicConfig( | ||
format='wallpapers.py [%(levelname)s]: %(message)s', | ||
level=logging.DEBUG, | ||
) | ||
|
||
|
||
def get_wallpapers(): | ||
wallpapers = Path(WALLPAPERS_DIR).glob("**/*.jpg") | ||
wallpapers = (p.resolve() for p in Path(WALLPAPERS_DIR).glob("**/*") if p.suffix in SUPPORTED_IMAGE_EXTS) | ||
wallpapers = [w for w in wallpapers] | ||
logging.info(f'Found {len(wallpapers)} wallpapers') | ||
return wallpapers | ||
|
||
|
||
def get_displays(): | ||
stdout = subprocess.check_output('hyprctl monitors -j | jq ".[].name"', shell=True).decode("utf-8") | ||
displays = stdout.replace('"', '').split('\n') | ||
displays = list(filter(len, displays)) | ||
logging.info(f'Found {[d for d in displays]} displays') | ||
return displays | ||
|
||
def set_wallpapers(): | ||
wallpapers = get_wallpapers() | ||
displays = get_displays() | ||
|
||
if not len(wallpapers): | ||
logging.warning("No wallpapers have been found") | ||
return | ||
|
||
subprocess.run("hyprctl hyprpaper unload all", shell=True) | ||
|
||
for display in displays: | ||
wallpaper = random.choice(wallpapers) | ||
logging.info(f'Setting wallpaper for {display}: {wallpaper}') | ||
subprocess.run(f'hyprctl hyprpaper preload {wallpaper}', shell=True) | ||
time.sleep(2) | ||
subprocess.run(f'hyprctl hyprpaper wallpaper {display},{wallpaper}', shell=True) | ||
|
||
|
||
def main(): | ||
logging.info('Started') | ||
while True: | ||
set_wallpapers() | ||
time.sleep(INTERVAL) | ||
|
||
main() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
env = XDG_SESSION_TYPE,wayland | ||
env = WLR_NO_HARDWARE_CURSORS,1 | ||
env = XCURSOR_SIZE,48 | ||
|
||
#env XCURSOR_SIZE,32 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# env = LIBVA_DRIVER_NAME,nvidia | ||
# env = GBM_BACKEND,nvidia | ||
# env = __GLX_VENDOR_LIBRARY_NAME,nvidia | ||
|
||
#env = WLR_DRM_NO_ATOMIC,1 | ||
#env = WLR_RENDERER,vulkan | ||
|
||
#env = __GL_GSYNC_ALLOWED,0 | ||
#env = __GL_VRR_ALLOWED,0 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
exec-once = waybar --config ~/.config/waybar/top.config --style ~/.config/waybar/top.style.css & | ||
exec-once = waybar --config ~/.config/waybar/bottom.config --style ~/.config/waybar/bottom.style.css & | ||
exec-once = swaync & | ||
exec-once = blueman-applet & | ||
exec-once = nm-applet --indicator & | ||
exec-once = udiskie -an --tray -f dolphin & | ||
exec-once = pasystray & | ||
exec-once = albert & | ||
exec-once = ~/.config/hypr/bin/wallpapers.py > ~/.tmp/logs/wallpapers.py.log | ||
exec-once = ~/.config/hypr/bin/uair.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# See https://wiki.hyprland.org/Configuring/Monitors/ | ||
monitor=eDP-1, [email protected], 200x1728, 1.25 | ||
monitor=HDMI-A-2, [email protected], 0x0, 1.25 | ||
|
||
# monitor=eDP-2, [email protected], 200x1728, 1.25 | ||
# monitor=HDMI-A-1, [email protected], 0x0, 1.25 | ||
|
||
exec-once = hyprpaper & | ||
exec-once = hyprctl hyprpaper wallpaper "eDP-1,~/Pictures/Wallpapers/dune-2.jpg" | ||
exec-once = hyprctl hyprpaper wallpaper "HDMI-A-2,~/Pictures/Wallpapers/dune-2.jpg" | ||
|
||
# exec = hyprctl hyprpaper wallpaper "eDP-2,~/Pictures/Wallpapers/after_all_desktop.jpg" | ||
# exec = hyprctl hyprpaper wallpaper "HDMI-A-1,~/Pictures/Wallpapers/after_all_desktop.jpg" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/ | ||
input { | ||
kb_layout = us,ru | ||
kb_variant = ,mac | ||
kb_options = grp:caps_toggle | ||
|
||
follow_mouse = 1 | ||
|
||
touchpad { | ||
natural_scroll = yes | ||
tap-to-click = yes | ||
clickfinger_behavior = 1 | ||
} | ||
|
||
sensitivity = 0 # -1.0 - 1.0, 0 means no modification. | ||
} | ||
|
Oops, something went wrong.