1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 10:11:08 +01:00
+ Bluetooth audio
~ Move more consequently to configs/graphics
+ configs/networks
~ Make battery info platform neutral
+ xautolock: killer
~ redshift: manual location
~ unclutter: increase timeout
+ packages
This commit is contained in:
Kierán Meinhardt
2018-09-22 20:26:42 +02:00
parent 98b56b0cb0
commit 7ccdb8c3e2
4 changed files with 76 additions and 36 deletions

View File

@@ -10,29 +10,29 @@ in {
./configs/editors.nix
./configs/graphics.nix
./configs/packages.nix
./configs/networks.nix
];
nixpkgs.config = {
allowUnfree = true;
packageOverrides =
let nix-writers = builtins.fetchGit {
url = https://cgit.krebsco.de/nix-writers/;
ref = "tags/v3.0.0";
# sha256 = "066y18q19d35x5jjr3kdn1dwi7s1l12icr90s2vxwzif6ahnzmb3";
}; in import "${nix-writers}/pkgs" pkgs;
};
time.timeZone = "Europe/Berlin";
sound.enable = true;
hardware.pulseaudio.enable = true;
hardware.bluetooth.enable = true;
hardware.pulseaudio = {
enable = true;
package = pkgs.pulseaudioFull; # for bluetooth sound output
};
hardware.bluetooth = {
enable = true;
extraConfig = ''
[General]
Enable=Source,Sink,Media,Socket
'';
};
security.sudo.enable = true;
security.sudo.extraConfig = "Defaults insults";
fonts.enableDefaultFonts = true;
users.mutableUsers = false;
users.users.kfm = {
@@ -58,12 +58,6 @@ in {
knownHosts = [];
};
services.redshift = {
enable = true;
provider = "geoclue2";
temperature = { night = 25000; day = 1000; };
};
programs.tmux = {
enable = true;
extraTmuxConf = import ./dot/tmux.nix;
@@ -71,17 +65,6 @@ in {
terminal = "screen-256color";
};
networking.hosts = {
"192.168.178.27" = [ "printer.local" ];
};
networking.wireless.enable = true;
networking.wireless.networks = {
Aether = { pskRaw = "e1b18af54036c5c9a747fe681c6a694636d60a5f8450f7dec0d76bc93e2ec85a"; };
"Asoziales Netzwerk" = { pskRaw = "8e234041ec5f0cd1b6a14e9adeee9840ed51b2f18856a52137485523e46b0cb6"; };
"c-base-public" = {};
};
home-manager.users.kfm = {
gtk = {
enable = true;

View File

@@ -28,10 +28,25 @@ let
'';
battery_info = pkgs.writeBash "battery.info" ''
BAT_DIR="/sys/class/power_supply/$BLOCK_INSTANCE/"
[ -d $BAT_DIR ] && cd $BAT_DIR || exit 1
if [ -d "$BAT_DIR" ]; then
cd "$BAT_DIR"
else
exit 1
fi
if [ -e charge_now ] && [ -e charge_full ]; then
FULL_CHARGE=charge_full
CURR_CHARGE=charge_now
elif [ -e energy_now ] && [ -e energy_full ]; then
FULL_CHARGE=energy_full
CURR_CHARGE=energy_now
else
ls >&2
exit 1
fi
status=$(cat status)
charge_f=$((100 * $(cat charge_now) / $(cat charge_full)))
charge_f=$((100 * $(cat $CURR_CHARGE) / $(cat $FULL_CHARGE)))
if [[ "$charge_f" -lt 20 ]]; then
printf '\uf244'
@@ -65,7 +80,7 @@ let
printf '%s\u2009W, ' "$rate"
fi
charge_d=$((100 * $(cat charge_now) / $(cat charge_full)))
charge_d=$((100 * $(cat $CURR_CHARGE) / $(cat $FULL_CHARGE)))
printf '%s%%\n' "$charge_d"
if [[ "$status" == 'Discharging' ]]; then
@@ -284,7 +299,7 @@ in {
libinput.enable = true;
xautolock = {
enable = true;
time = 15;
killer = "${pkgs.systemd}/bin/systemctl suspend";
locker = config.defaultApplications.locker;
nowlocker = config.defaultApplications.locker;
enableNotifier = true;
@@ -299,6 +314,10 @@ in {
configFile = pkgs.writeText "i3.conf" i3_conf;
extraPackages = [];
};
windowManager.xmonad = {
enable = true;
enableContribAndExtras = true;
};
};
i18n = {
@@ -314,6 +333,16 @@ in {
shadowOpacity = "0.3";
};
services.redshift = {
enable = true;
latitude = "52.516667";
longitude = "13.388889";
};
services.illum.enable = true;
services.unclutter.enable = true;
services.unclutter = {
enable = true;
timeout = 10;
};
}

12
configs/networks.nix Normal file
View File

@@ -0,0 +1,12 @@
{
networking.hosts = {
"192.168.178.27" = [ "printer.local" ];
};
networking.wireless.enable = true;
networking.wireless.networks = {
Aether = { pskRaw = "e1b18af54036c5c9a747fe681c6a694636d60a5f8450f7dec0d76bc93e2ec85a"; };
"Asoziales Netzwerk" = { pskRaw = "8e234041ec5f0cd1b6a14e9adeee9840ed51b2f18856a52137485523e46b0cb6"; };
"c-base-public" = {};
};
}

View File

@@ -1,6 +1,17 @@
{ config, pkgs, ... }:
with pkgs;
{
nixpkgs.config = {
allowUnfree = true;
packageOverrides =
let nix-writers = builtins.fetchGit {
url = https://cgit.krebsco.de/nix-writers/;
ref = "tags/v3.0.0";
# sha256 = "066y18q19d35x5jjr3kdn1dwi7s1l12icr90s2vxwzif6ahnzmb3";
}; in import "${nix-writers}/pkgs" pkgs;
};
fonts.enableDefaultFonts = true;
fonts.fonts = [
eb-garamond
fira-code
@@ -12,6 +23,8 @@ with pkgs;
];
environment.systemPackages = [
arandr
blueman
chromium
config.constants.theme.gtk.package
config.constants.theme.icon.package
@@ -23,10 +36,13 @@ with pkgs;
imagemagick
libnotify
libreoffice-fresh
lsof
lxappearance
mpv
pamixer
pavucontrol
pmount
ranger
ripgrep tree
rlwrap
tor-browser-bundle-bin