Compare commits

...

3 Commits

Author SHA1 Message Date
mediocregopher
247127647b Fix Browser 2024-01-06 13:13:48 +01:00
mediocregopher
f083ef86f2 Simplify awesome even further, wrap startx internally 2024-01-06 13:06:41 +01:00
mediocregopher
2c8176faa0 More re-arranging of applications 2024-01-06 12:30:23 +01:00
3 changed files with 16 additions and 19 deletions

View File

@ -11,12 +11,7 @@
name = "xorg-inner-env"; name = "xorg-inner-env";
paths = [ paths = [
pkgs.xorg.xorgserver pkgs.xorg.xorgserver
pkgs.xorg.xinit
pkgs.xorg.xauth
pkgs.xorg.xset
pkgs.xorg.xf86inputlibinput pkgs.xorg.xf86inputlibinput
pkgs.xorg.xrandr
pkgs.xsel
(pkgs.runCommand "xorg-conf-inner" {} '' (pkgs.runCommand "xorg-conf-inner" {} ''
mkdir -p "$out"/share/X11/xorg.conf.d/ mkdir -p "$out"/share/X11/xorg.conf.d/
@ -39,12 +34,6 @@ EOF
done done
''; '';
startx = pkgs.writeShellScriptBin "startx-awesome" ''
# TODO pass .xinitrc into here, somehow
export XORGCONFIG=${xorgConf}
exec startx
'';
# nativeWrap is used for apps which are not installed via nix which don't play # nativeWrap is used for apps which are not installed via nix which don't play
# nicely with it. # nicely with it.
nativeWrap = pkgs.writeScriptBin "native-wrap" '' nativeWrap = pkgs.writeScriptBin "native-wrap" ''
@ -66,14 +55,15 @@ EOF
wp_dir = "${wp}/" wp_dir = "${wp}/"
''; '';
awesome = pkgs.writeScriptBin "awesome" '' # awesomeInner is what is started up by startx, within an X session.
awesomeInner = pkgs.writeScript "awesome" ''
#!${pkgs.bash}/bin/bash #!${pkgs.bash}/bin/bash
set -e -x set -e -x
# Turn off powersaving (fuck the environment) # Turn off powersaving (fuck the environment)
xset -dpms ${pkgs.xorg.xset}/bin/xset -dpms
xset s off ${pkgs.xorg.xset}/bin/xset s off
${config.awesome.startupExtra} ${config.awesome.startupExtra}
@ -109,6 +99,11 @@ EOF
2>&1 2>>$this_log 2>&1 2>>$this_log
''; '';
awesome = pkgs.writeShellScriptBin "awesome" ''
export XORGCONFIG=${xorgConf}
exec startx ${awesomeInner}
'';
env = pkgs.buildEnv { env = pkgs.buildEnv {
name = "awesome-env"; name = "awesome-env";
paths = [ paths = [
@ -116,9 +111,7 @@ EOF
# We only include utilities in here which are directly used by awesome. # We only include utilities in here which are directly used by awesome.
# General purpose applications go in the root default.nix env. # General purpose applications go in the root default.nix env.
pkgs.pavucontrol pkgs.xorg.xinit
pkgs.xdg-utils
pkgs.arandr
pkgs.scrot pkgs.scrot
pkgs.feh pkgs.feh
pkgs.brightnessctl pkgs.brightnessctl
@ -128,7 +121,6 @@ EOF
xorgInnerEnv xorgInnerEnv
nativeWrap nativeWrap
awesome awesome
startx
]; ];
}; };
} }

View File

@ -114,6 +114,11 @@ in rec {
pkgs.sylpheed pkgs.sylpheed
pkgs.calibre pkgs.calibre
pkgsEdge.lagrange pkgsEdge.lagrange
pkgs.pavucontrol
pkgs.xdg-utils
pkgs.arandr
pkgs.xsel
pkgs.xorg.xrandr
bin bin
((import ./nvim) {}).nvim ((import ./nvim) {}).nvim

View File

@ -18,7 +18,7 @@
plugins=(git vi-mode) plugins=(git vi-mode)
source $ZSH/oh-my-zsh.sh source $ZSH/oh-my-zsh.sh
export BROWSER=${config.browser}/bin/browser export BROWSER=${config.browser}
. ${./zshrc} . ${./zshrc}
. ${./aliases} . ${./aliases}