Skip to content

Commit

Permalink
Clean up unused sway configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
serverwentdown committed Nov 25, 2024
1 parent ff9ef21 commit ec70903
Show file tree
Hide file tree
Showing 8 changed files with 60 additions and 160 deletions.
5 changes: 5 additions & 0 deletions .config/git/config
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,8 @@
rebase = true
[alias]
lg = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(auto)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)'
[filter "lfs"]
required = true
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
25 changes: 24 additions & 1 deletion .config/sway/framework
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,29 @@
# Output configuration:
#
set $output_laptop "BOE 0x095F Unknown"
output $output_laptop position 0 0 transform 0 scale 1.25
output $output_laptop position 1080 0 transform 0 scale 1.25
bindsym $mod+XF86MonBrightnessDown output $output_laptop scale 1.25
bindsym $mod+XF86MonBrightnessUp output $output_laptop scale 1.5

set $output_primary "Hewlett Packard HP E240 6CM73329XK"
output $output_primary position 0 0 transform 270
bindsym $mod+Shift+F4 output $output_primary transform 90 clockwise
bindsym $mod+F4 output $output_primary transform 90 anticlockwise

#
# Display controls:
#
# Remember to configure udev. See https://blog.tcharles.fr/ddc-ci-screen-control-on-linux/
set $monitor_global --noverify --sleep-multiplier 0.1
set $monitor_primary --bus 8
# Display brightness controls:
set $monitor_brightness_step 0x0a
bindsym --locked $mod+F2 exec ddcutil $monitor_global $monitor_primary setvcp 0x10 - $monitor_brightness_step
bindsym --locked $mod+F3 exec ddcutil $monitor_global $monitor_primary setvcp 0x10 + $monitor_brightness_step

#
# Display output toggle:
#
# This is so crazy performant that I did not notice it worked. Was expecting my main display to go blank for a while but it didn't even flash
bindswitch --reload --locked lid:on output $output_laptop disable
bindswitch --reload --locked lid:off output $output_laptop enable
39 changes: 0 additions & 39 deletions .config/sway/home

This file was deleted.

44 changes: 0 additions & 44 deletions .config/sway/triple

This file was deleted.

65 changes: 0 additions & 65 deletions .config/sway/work

This file was deleted.

7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
.cargo/registry
.cargo/.crates.toml
.cargo/.crates2.json
.cargo/.global-cache
.cargo/.package-cache
.cargo/.package-cache-mutate
.cert/nm-openvpn
Expand Down Expand Up @@ -112,10 +113,13 @@
.local/bin/poetry
.local/bin/pygmentize
.local/bin/step
.local/bin/tilt
.local/bin/turn_usb
.local/bin/vagrant
.local/bin/virtualenv
.local/bin/yadm
.local/bin/yq
.local/bin/zed
.local/lib
.local/share/*
!.local/share/MultiMC
Expand All @@ -126,6 +130,7 @@
!.local/share/yadm/archive
.local/state
.local/zephyr*
.local/zed-preview.app
.mc/share
.mozilla/*
!.mozilla/firefox
Expand Down Expand Up @@ -159,6 +164,8 @@
.terraform.d
.tflint.d
.thunderbird
.tilt-dev
.vagrant.d
.var/app
.viminfo
.vscode
Expand Down
16 changes: 16 additions & 0 deletions .local/bin/iptables-vis
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/sh

set -euo pipefail

install=/tmp/iptables-vis

mkdir -p $install
if ! [ -f $install/iptables-vis.awk ]; then
wget -O $install/iptables-vis.awk https://github.com/Nudin/iptable_vis/raw/b89e0ca5e30679c8b350b44879637eff9562cdf6/iptables-vis.awk >&2
fi
if ! [ -f $install/venv/bin/pip ]; then
python -m virtualenv $install/venv >&2
$install/venv/bin/pip install Pillow==9.5.0 blockdiag==3.0.0 >&2
fi

awk -f $install/iptables-vis.awk | $install/venv/bin/blockdiag /dev/stdin -T svg -o /dev/stdout
19 changes: 8 additions & 11 deletions .local/share/MultiMC/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,26 @@ set -euo pipefail
echo "Installing MultiMC"

INSTALL_LOCATION="$HOME/.local/share/MultiMC"
DOWNLOAD_URL="https://files.multimc.org/downloads/mmc-stable-lin64.tar.gz"
LOGO_URL="https://avatars2.githubusercontent.com/u/5411890"
DOWNLOAD_URL="https://files.multimc.org/downloads/mmc-develop-lin64.tar.gz"

# Paths
mkdir -p "$INSTALL_LOCATION"

# Package
wget --output-document /tmp/multimc.tar.gz "$DOWNLOAD_URL"
tar --extract --strip-components 1 --file /tmp/multimc.tar.gz --directory "$INSTALL_LOCATION"

# Logo
wget --output-document $HOME/.local/share/icons/multimc.png "$LOGO_URL"
tar --verbose --extract --strip-components 1 --file /tmp/multimc.tar.gz --directory "$INSTALL_LOCATION"

# Desktop Entry
cat > $HOME/.local/share/applications/multimc.desktop <<EOF
cat > $HOME/.local/share/applications/MultiMC.desktop <<EOF
[Desktop Entry]
Type=Application
Name=MultiMC
Categories=Game;
X-GNOME-FullName=MultiMC
Comment=MultiMC Minecraft Launcher
Icon=multimc
Exec=$INSTALL_LOCATION/MultiMC
Exec=$INSTALL_LOCATION/MultiMC -d $INSTALL_LOCATION
StartupNotify=true
Terminal=false
Path=$INSTALL_LOCATION
Icon=$INSTALL_LOCATION/icons/shortcut-icon.png
EOF

# Cleanup
Expand Down

0 comments on commit ec70903

Please sign in to comment.