add sway commit. various changes
parent
f1712213ee
commit
650bf9b2a5
|
@ -78,7 +78,7 @@
|
||||||
vim htop radeontop
|
vim htop radeontop
|
||||||
|
|
||||||
#GUI programs
|
#GUI programs
|
||||||
firefox palemoon transmission-gtk mcomix
|
firefox transmission-gtk mcomix
|
||||||
|
|
||||||
#Theming
|
#Theming
|
||||||
gnome3.adwaita-icon-theme gnome3.defaultIconTheme
|
gnome3.adwaita-icon-theme gnome3.defaultIconTheme
|
||||||
|
|
|
@ -0,0 +1,112 @@
|
||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
# bash script to let dbus know about important env variables and
|
||||||
|
# propogate them to relevent services run at the end of sway config
|
||||||
|
# see
|
||||||
|
# https://github.com/emersion/xdg-desktop-portal-wlr/wiki/"It-doesn't-work"-Troubleshooting-Checklist
|
||||||
|
# note: this is pretty much the same as /etc/sway/config.d/nixos.conf but also restarts
|
||||||
|
# some user services to make sure they have the correct environment variables
|
||||||
|
dbus-sway-environment = pkgs.writeTextFile {
|
||||||
|
name = "dbus-sway-environment";
|
||||||
|
destination = "/bin/dbus-sway-environment";
|
||||||
|
executable = true;
|
||||||
|
|
||||||
|
text = ''
|
||||||
|
dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
|
||||||
|
systemctl --user stop pipewire pipewire-media-session xdg-desktop-portal xdg-desktop-portal-wlr
|
||||||
|
systemctl --user start pipewire pipewire-media-session xdg-desktop-portal xdg-desktop-portal-wlr
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
# currently, there is some friction between sway and gtk:
|
||||||
|
# https://github.com/swaywm/sway/wiki/GTK-3-settings-on-Wayland
|
||||||
|
# the suggested way to set gtk settings is with gsettings
|
||||||
|
# for gsettings to work, we need to tell it where the schemas are
|
||||||
|
# using the XDG_DATA_DIR environment variable
|
||||||
|
# run at the end of sway config
|
||||||
|
configure-gtk = pkgs.writeTextFile {
|
||||||
|
name = "configure-gtk";
|
||||||
|
destination = "/bin/configure-gtk";
|
||||||
|
executable = true;
|
||||||
|
text = let
|
||||||
|
schema = pkgs.gsettings-desktop-schemas;
|
||||||
|
datadir = "${schema}/share/gsettings-schemas/${schema.name}";
|
||||||
|
in ''
|
||||||
|
export XDG_DATA_DIRS=${datadir}:$XDG_DATA_DIRS
|
||||||
|
gnome_schema=org.gnome.desktop.interface
|
||||||
|
gsettings set $gnome_schema gtk-theme 'Dracula'
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
in
|
||||||
|
{
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
alacritty # gpu accelerated terminal
|
||||||
|
sway
|
||||||
|
dbus-sway-environment
|
||||||
|
configure-gtk
|
||||||
|
wayland
|
||||||
|
glib # gsettings
|
||||||
|
dracula-theme # gtk theme
|
||||||
|
gnome3.adwaita-icon-theme # default gnome cursors
|
||||||
|
swaylock
|
||||||
|
swayidle
|
||||||
|
grim # screenshot functionality
|
||||||
|
slurp # screenshot functionality
|
||||||
|
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
|
||||||
|
bemenu # wayland clone of dmenu
|
||||||
|
mako # notification system developed by swaywm maintainer
|
||||||
|
swaybg
|
||||||
|
waybar
|
||||||
|
xwayland
|
||||||
|
gammastep
|
||||||
|
|
||||||
|
#cli programs
|
||||||
|
viu
|
||||||
|
bat
|
||||||
|
yt-dlp
|
||||||
|
neovim
|
||||||
|
|
||||||
|
|
||||||
|
#programs I use
|
||||||
|
librewolf
|
||||||
|
zathura
|
||||||
|
imv
|
||||||
|
pavucontrol
|
||||||
|
];
|
||||||
|
|
||||||
|
#add 32bit support for graphics
|
||||||
|
hardware.opengl.driSupport32Bit = true;
|
||||||
|
|
||||||
|
|
||||||
|
services.pipewire = {
|
||||||
|
enable = true;
|
||||||
|
alsa.enable = true;
|
||||||
|
pulse.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
services.pipewire.wireplumber.enable = true;
|
||||||
|
|
||||||
|
|
||||||
|
# xdg-desktop-portal works by exposing a series of D-Bus interfaces
|
||||||
|
# known as portals under a well-known name
|
||||||
|
# (org.freedesktop.portal.Desktop) and object path
|
||||||
|
# (/org/freedesktop/portal/desktop).
|
||||||
|
# The portal interfaces include APIs for file access, opening URIs,
|
||||||
|
# printing and others.
|
||||||
|
services.dbus.enable = true;
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
wlr.enable = true;
|
||||||
|
# gtk portal needed to make gtk apps happy
|
||||||
|
extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
|
||||||
|
gtkUsePortal = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# enable sway window manager
|
||||||
|
programs.sway = {
|
||||||
|
enable = true;
|
||||||
|
wrapperFeatures.gtk = true;
|
||||||
|
};
|
|
@ -16,6 +16,15 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
xdg.portal.wlr.enable = true;
|
||||||
|
|
||||||
|
#enable pipewire
|
||||||
|
services.pipewire.enable = true;
|
||||||
|
services.pipewire.alsa.enable = true;
|
||||||
|
services.pipewire.pulse.enable = true;
|
||||||
|
services.pipewire.wireplumber.enable = true;
|
||||||
|
services.pipewire.audio.enable = true;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#environment = {
|
#environment = {
|
||||||
|
@ -84,12 +93,6 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
# services.redshift = {
|
|
||||||
# enable = true;
|
|
||||||
# Redshift with wayland support isn't present in nixos-19.09 atm. You have to cherry-pick the commit from https://github.com/NixOS/nixpkgs/pull/68285 to do that.
|
|
||||||
# package = pkgs.redshift;
|
|
||||||
# };
|
|
||||||
|
|
||||||
programs.waybar.enable = true;
|
programs.waybar.enable = true;
|
||||||
|
|
||||||
systemd.user.services.kanshi = {
|
systemd.user.services.kanshi = {
|
||||||
|
|
|
@ -184,42 +184,44 @@ font:
|
||||||
|
|
||||||
# If `true`, bold text is drawn using the bright color variants.
|
# If `true`, bold text is drawn using the bright color variants.
|
||||||
#draw_bold_text_with_bright_colors: true
|
#draw_bold_text_with_bright_colors: true
|
||||||
# Base16 Atlas - alacritty color config
|
|
||||||
# Alex Lende (https://ajlende.com)
|
# Base16 Gruvbox dark, hard - alacritty color config
|
||||||
|
# Dawid Kurek (dawikur@gmail.com), morhetz (https://github.com/morhetz/gruvbox)
|
||||||
colors:
|
colors:
|
||||||
# Default colors
|
# Default colors
|
||||||
primary:
|
primary:
|
||||||
background: '0x002635'
|
background: '0x1d2021'
|
||||||
foreground: '0xa1a19a'
|
foreground: '0xd5c4a1'
|
||||||
|
|
||||||
# Colors the cursor will use if `custom_cursor_colors` is true
|
# Colors the cursor will use if `custom_cursor_colors` is true
|
||||||
cursor:
|
cursor:
|
||||||
text: '0x002635'
|
text: '0x1d2021'
|
||||||
cursor: '0xa1a19a'
|
cursor: '0xd5c4a1'
|
||||||
|
|
||||||
# Normal colors
|
# Normal colors
|
||||||
normal:
|
normal:
|
||||||
black: '0x002635'
|
black: '0x1d2021'
|
||||||
red: '0xff5a67'
|
red: '0xfb4934'
|
||||||
green: '0x7fc06e'
|
green: '0xb8bb26'
|
||||||
yellow: '0xffcc1b'
|
yellow: '0xfabd2f'
|
||||||
blue: '0x5dd7b9'
|
blue: '0x83a598'
|
||||||
magenta: '0x9a70a4'
|
magenta: '0xd3869b'
|
||||||
cyan: '0x14747e'
|
cyan: '0x8ec07c'
|
||||||
white: '0xa1a19a'
|
white: '0xd5c4a1'
|
||||||
|
|
||||||
# Bright colors
|
# Bright colors
|
||||||
bright:
|
bright:
|
||||||
black: '0x6c8b91'
|
black: '0x665c54'
|
||||||
red: '0xf08e48'
|
red: '0xfe8019'
|
||||||
green: '0x00384d'
|
green: '0x3c3836'
|
||||||
yellow: '0x517f8d'
|
yellow: '0x504945'
|
||||||
blue: '0x869696'
|
blue: '0xbdae93'
|
||||||
magenta: '0xe6e6dc'
|
magenta: '0xebdbb2'
|
||||||
cyan: '0xc43060'
|
cyan: '0xd65d0e'
|
||||||
white: '0xfafaf8'
|
white: '0xfbf1c7'
|
||||||
|
|
||||||
draw_bold_text_with_bright_colors: false
|
draw_bold_text_with_bright_colors: false
|
||||||
|
|
||||||
# Visual Bell
|
# Visual Bell
|
||||||
#
|
#
|
||||||
# Any time the BEL code is received, Alacritty "rings" the visual bell. Once
|
# Any time the BEL code is received, Alacritty "rings" the visual bell. Once
|
||||||
|
|
|
@ -1,40 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
BEMENUOPTS_FILE="$HOME/.config/bemenu/bemenu_opts.sh"
|
|
||||||
|
|
||||||
HEIGHT="22" #height in pixels to make the bemenu prompt
|
|
||||||
|
|
||||||
! [ -f "$1" ] && echo "input base16 color file for first argument." && exit
|
|
||||||
|
|
||||||
NB=""
|
|
||||||
NF=""
|
|
||||||
HB=""
|
|
||||||
HF=""
|
|
||||||
SB=""
|
|
||||||
SF=""
|
|
||||||
TB=""
|
|
||||||
TF=""
|
|
||||||
FB=""
|
|
||||||
FF="#ffffff"
|
|
||||||
|
|
||||||
IFS='
|
|
||||||
'
|
|
||||||
|
|
||||||
COUNT=0
|
|
||||||
for LINE in $(cat "$1")
|
|
||||||
do
|
|
||||||
case $COUNT in
|
|
||||||
0) NB="$LINE" && HB="$LINE" && TB="$LINE" && FB="$LINE";;
|
|
||||||
1) SB="$LINE";;
|
|
||||||
6) HF="$LINE" && SF="$LINE";;
|
|
||||||
10) NF="$LINE" && TF="$LINE";;
|
|
||||||
esac
|
|
||||||
|
|
||||||
COUNT=$((COUNT + 1))
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "bemenu colors updated."
|
|
||||||
|
|
||||||
echo "#!/bin/sh" > "$BEMENUOPTS_FILE"
|
|
||||||
echo "#generated from: $1" >> "$BEMENUOPTS_FILE"
|
|
||||||
echo "export BEMENU_OPTS=\"-H $HEIGHT --nb $NB --nf $NF --hb $HB --hf $HF --sb $SB --sf $SF --tb $TB --tf $TF --fb $FB --ff $FF\"" >> "$BEMENUOPTS_FILE"
|
|
|
@ -1,3 +1,3 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
#generated from: colors/base16-atlas
|
#generated from: ./colors/base16-gruvbox-dark-hard
|
||||||
export BEMENU_OPTS="-H 22 --nb #002635 --nf #ffcc1b --hb #002635 --hf #e6e6dc --sb #00384d --sf #e6e6dc --tb #002635 --tf #ffcc1b --fb #002635 --ff #ffffff"
|
export BEMENU_OPTS="-H 22 --nb #1d2021 --nf #fabd2f --hb #1d2021 --hf #ebdbb2 --sb #3c3836 --sf #ebdbb2 --tb #1d2021 --tf #fabd2f --fb #1d2021 --ff #ffffff"
|
||||||
|
|
|
@ -0,0 +1,7 @@
|
||||||
|
[user]
|
||||||
|
email = "alex@ahubbard.xyz"
|
||||||
|
name = Alex
|
||||||
|
[pull]
|
||||||
|
rebase = false
|
||||||
|
[init]
|
||||||
|
defaultBranch = master
|
|
@ -55,7 +55,7 @@ cmd open ${{
|
||||||
image/jpeg) setsid imv $f ;;
|
image/jpeg) setsid imv $f ;;
|
||||||
image/png) setsid imv $f ;;
|
image/png) setsid imv $f ;;
|
||||||
image/*) setsid imv $f ;;
|
image/*) setsid imv $f ;;
|
||||||
video/*) setsid mpv $f ;;
|
video/*) setsid mpv $f --loop=inf ;;
|
||||||
application/json) $EDITOR $f;;
|
application/json) $EDITOR $f;;
|
||||||
*) for f in $fx; do setsid $OPENER $f > /dev/null 2> /dev/null & done;;
|
*) for f in $fx; do setsid $OPENER $f > /dev/null 2> /dev/null & done;;
|
||||||
esac
|
esac
|
||||||
|
|
|
@ -229,7 +229,8 @@ bindsym $mod+shift+s exec ss.sh -s
|
||||||
|
|
||||||
#include ~/.config/sway/colors/base16-atlas
|
#include ~/.config/sway/colors/base16-atlas
|
||||||
#include ~/.local/src/base16-sway/themes/base16-gruvbox-dark-medium.config
|
#include ~/.local/src/base16-sway/themes/base16-gruvbox-dark-medium.config
|
||||||
include ~/.local/src/base16-sway/themes/base16-atlas.config
|
#include ~/.local/src/base16-sway/themes/base16-atlas.config
|
||||||
|
include ~/.local/src/base16-sway/themes/base16-gruvbox-dark-hard.config
|
||||||
|
|
||||||
#
|
#
|
||||||
# Status Bar:
|
# Status Bar:
|
||||||
|
@ -284,6 +285,9 @@ gaps outer 10
|
||||||
#border
|
#border
|
||||||
default_border pixel 2
|
default_border pixel 2
|
||||||
|
|
||||||
|
#set windows to float by default
|
||||||
|
for_window [class="Matplotlib"] floating enable
|
||||||
|
|
||||||
#input config
|
#input config
|
||||||
input type:pointer accel_profile flat
|
input type:pointer accel_profile flat
|
||||||
input type:pointer pointer_accel -0.5
|
input type:pointer pointer_accel -0.5
|
||||||
|
|
|
@ -0,0 +1,69 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
BEMENUOPTS_FILE="$HOME/.config/bemenu/bemenu_opts.sh"
|
||||||
|
|
||||||
|
HEIGHT="22" #height in pixels to make the bemenu prompt
|
||||||
|
|
||||||
|
help () {
|
||||||
|
echo " usage: sh bemenu-colorgen.sh FILE"
|
||||||
|
echo " where FILE contains hex values of a base16 color scheme in this format:"
|
||||||
|
echo " NOTE: the file must contain 16 color values"
|
||||||
|
echo " ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
echo " #282936"
|
||||||
|
echo " #3a3c4e"
|
||||||
|
echo " #F7CA88"
|
||||||
|
echo " #626483"
|
||||||
|
echo " #62d6e8"
|
||||||
|
echo " #e9e9f4"
|
||||||
|
echo " #f1f2f8"
|
||||||
|
echo " #f7f7fb"
|
||||||
|
echo " #ea51b2"
|
||||||
|
echo " #b45bcf"
|
||||||
|
echo " #00f769"
|
||||||
|
echo " #ebff87"
|
||||||
|
echo " #a1efe4"
|
||||||
|
echo " #62d6e8"
|
||||||
|
echo " #b45bcf"
|
||||||
|
echo " #00f769"
|
||||||
|
echo " ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
FILE="$1"
|
||||||
|
|
||||||
|
! [ -f "$FILE" ] && help && exit
|
||||||
|
[ "$( wc -l "$FILE" | cut -d ' ' -f 1 )" != "16" ] && help && exit
|
||||||
|
|
||||||
|
|
||||||
|
NB=""
|
||||||
|
NF=""
|
||||||
|
HB=""
|
||||||
|
HF=""
|
||||||
|
SB=""
|
||||||
|
SF=""
|
||||||
|
TB=""
|
||||||
|
TF=""
|
||||||
|
FB=""
|
||||||
|
FF="#ffffff"
|
||||||
|
|
||||||
|
IFS='
|
||||||
|
'
|
||||||
|
|
||||||
|
COUNT=0
|
||||||
|
for LINE in $(cat "$FILE")
|
||||||
|
do
|
||||||
|
case $COUNT in
|
||||||
|
0) NB="$LINE" && HB="$LINE" && TB="$LINE" && FB="$LINE";;
|
||||||
|
1) SB="$LINE";;
|
||||||
|
6) HF="$LINE" && SF="$LINE";;
|
||||||
|
10) NF="$LINE" && TF="$LINE";;
|
||||||
|
esac
|
||||||
|
|
||||||
|
COUNT=$((COUNT + 1))
|
||||||
|
done
|
||||||
|
|
||||||
|
echo "bemenu colors updated."
|
||||||
|
|
||||||
|
echo "#!/bin/sh" > "$BEMENUOPTS_FILE"
|
||||||
|
echo "#generated from: $1" >> "$BEMENUOPTS_FILE"
|
||||||
|
echo "export BEMENU_OPTS=\"-H $HEIGHT --nb $NB --nf $NF --hb $HB --hf $HF --sb $SB --sf $SF --tb $TB --tf $TF --fb $FB --ff $FF\"" >> "$BEMENUOPTS_FILE"
|
|
@ -1,30 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
|
|
||||||
COLOR0="#282936"
|
|
||||||
COLOR1="#3a3c4e"
|
|
||||||
COLOR2="#F7CA88"
|
|
||||||
COLOR3="#626483"
|
|
||||||
COLOR4="#62d6e8"
|
|
||||||
COLOR5="#e9e9f4"
|
|
||||||
COLOR6="#f1f2f8"
|
|
||||||
COLOR7="#f7f7fb"
|
|
||||||
COLOR8="#ea51b2"
|
|
||||||
COLOR9="#b45bcf"
|
|
||||||
COLOR10="#00f769"
|
|
||||||
COLOR11="#ebff87"
|
|
||||||
COLOR12="#a1efe4"
|
|
||||||
COLOR13="#62d6e8"
|
|
||||||
COLOR14="#b45bcf"
|
|
||||||
COLOR15="#00f769"
|
|
||||||
|
|
||||||
WHITE="#ffffff"
|
|
||||||
BLACK="#000000"
|
|
||||||
|
|
||||||
|
|
||||||
BEMENU_OPTS="--nb $COLOR0 --nf $COLOR15 --hb $COLOR0 --hf $COLOR6 --sb $COLOR1 --sf $COLOR6 --tb $COLOR0 --tf $COLOR15 --fb $COLOR0 --ff $WHITE"
|
|
||||||
|
|
||||||
mkdir .config/bemenu/
|
|
||||||
|
|
||||||
echo "#!/bin/sh" > ~/.config/bemenu/bemenu_opts.sh
|
|
||||||
echo "export BEMENU_OPTS=\"$BEMENU_OPTS\"" >> ~/.config/bemenu/bemenu_opts.sh
|
|
2
.profile
2
.profile
|
@ -67,7 +67,7 @@ export AWT_TOOLKIT=MToolkit
|
||||||
|
|
||||||
#mount samba share, needs entry in /etc/fstab for this line to work
|
#mount samba share, needs entry in /etc/fstab for this line to work
|
||||||
# //192.168.1.218/storage /media/nagato cifs username=alex,pass=PASSWORD,workgroup=WORKGROUP,user,noauto 0 0
|
# //192.168.1.218/storage /media/nagato cifs username=alex,pass=PASSWORD,workgroup=WORKGROUP,user,noauto 0 0
|
||||||
mount /media/nagato &
|
mount /media/nagato/ &
|
||||||
|
|
||||||
|
|
||||||
[ "$(tty)" = /dev/tty1 ] && exec dbus-launch sway
|
[ "$(tty)" = /dev/tty1 ] && exec dbus-launch sway
|
||||||
|
|
Loading…
Reference in New Issue