refactor: Last chagnes to remove digga
Some checks failed
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is failing

This commit is contained in:
Benjamin Bädorf 2023-10-03 13:08:10 +02:00
parent 38243e1583
commit b2cbebbd94
No known key found for this signature in database
GPG key ID: 4406E80E13CD656C
48 changed files with 9575 additions and 250 deletions

View file

@ -5,7 +5,7 @@
"adblockStevenBlack": "adblockStevenBlack",
"flake-utils": "flake-utils",
"nixpkgs": [
"nixos"
"nixpkgs"
]
},
"locked": {
@ -44,7 +44,7 @@
"nix-darwin"
],
"nixpkgs": [
"nixos"
"nixpkgs"
]
},
"locked": {
@ -88,7 +88,7 @@
"flake-compat"
],
"nixpkgs": [
"nixos"
"nixpkgs"
],
"utils": "utils"
},
@ -327,7 +327,7 @@
"home-manager": {
"inputs": {
"nixpkgs": [
"nixos"
"nixpkgs"
]
},
"locked": {
@ -350,7 +350,7 @@
"devshell": "devshell",
"flake-utils": "flake-utils_2",
"nixpkgs": [
"nixos"
"nixpkgs"
]
},
"locked": {
@ -405,7 +405,7 @@
"nix-darwin": {
"inputs": {
"nixpkgs": [
"nixos"
"nixpkgs"
]
},
"locked": {
@ -423,22 +423,6 @@
"type": "github"
}
},
"nixos": {
"locked": {
"lastModified": 1693636127,
"narHash": "sha256-ZlS/lFGzK7BJXX2YVGnP3yZi3T9OLOEtBCyMJsb91U8=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "9075cba53e86dc318d159aee55dc9a7c9a4829c1",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-23.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixos-flake": {
"locked": {
"lastModified": 1692742948,
@ -505,16 +489,16 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1695830400,
"narHash": "sha256-gToZXQVr0G/1WriO83olnqrLSHF2Jb8BPcmCt497ro0=",
"lastModified": 1696039360,
"narHash": "sha256-g7nIUV4uq1TOVeVIDEZLb005suTWCUjSY0zYOlSBsyE=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "8a86b98f0ba1c405358f1b71ff8b5e1d317f5db2",
"rev": "32dcb45f66c0487e92db8303a798ebc548cadedc",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"ref": "nixos-23.05",
"repo": "nixpkgs",
"type": "github"
}
@ -565,11 +549,11 @@
"master": "master",
"musnix": "musnix",
"nix-darwin": "nix-darwin",
"nixos": "nixos",
"nixos-flake": "nixos-flake",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_2",
"scan2paperless": "scan2paperless"
"scan2paperless": "scan2paperless",
"unstable": "unstable"
}
},
"scan2paperless": {
@ -683,6 +667,22 @@
"type": "github"
}
},
"unstable": {
"locked": {
"lastModified": 1696019113,
"narHash": "sha256-X3+DKYWJm93DRSdC5M6K5hLqzSya9BjibtBsuARoPco=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "f5892ddac112a1e9b3612c39af1b72987ee5783a",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"utils": {
"locked": {
"lastModified": 1667395993,

219
flake.nix
View file

@ -5,32 +5,32 @@
inputs = {
# Track channels with commits tested and built by hydra
nixos.url = "github:nixos/nixpkgs/nixos-23.05";
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.05";
unstable.url = "github:nixos/nixpkgs/nixos-unstable";
flake-compat.url = "github:edolstra/flake-compat";
flake-compat.flake = false;
nix-darwin.url = "github:lnl7/nix-darwin/master";
nix-darwin.inputs.nixpkgs.follows = "nixos";
nix-darwin.inputs.nixpkgs.follows = "nixpkgs";
home-manager.url = "github:nix-community/home-manager/release-23.05";
home-manager.inputs.nixpkgs.follows = "nixos";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
flake-parts.url = "github:hercules-ci/flake-parts";
nixos-flake.url = "github:srid/nixos-flake";
deploy-rs.url = "github:serokell/deploy-rs";
deploy-rs.inputs.nixpkgs.follows = "nixos";
deploy-rs.inputs.nixpkgs.follows = "nixpkgs";
deploy-rs.inputs.flake-compat.follows = "flake-compat";
agenix.url = "github:ryantm/agenix";
agenix.inputs.nixpkgs.follows = "nixos";
agenix.inputs.nixpkgs.follows = "nixpkgs";
agenix.inputs.darwin.follows = "nix-darwin";
nixos-hardware.url = "github:nixos/nixos-hardware";
keycloak-theme-pub-solar.url = "git+https://git.pub.solar/pub-solar/keycloak-theme?ref=main";
keycloak-theme-pub-solar.inputs.nixpkgs.follows = "nixos";
keycloak-theme-pub-solar.inputs.nixpkgs.follows = "nixpkgs";
master.url = "github:nixos/nixpkgs/master";
fix-yubikey-agent.url = "github:pub-solar/nixpkgs/fix/use-latest-unstable-yubikey-agent";
@ -39,7 +39,7 @@
musnix.url = "github:musnix/musnix";
adblock-unbound.url = "github:MayNiklas/nixos-adblock-unbound";
adblock-unbound.inputs.nixpkgs.follows = "nixos";
adblock-unbound.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = inputs@{ self, ... }:
@ -53,163 +53,100 @@
imports = [
inputs.nixos-flake.flakeModule
./modules
./hosts
./users
];
perSystem = { system, pkgs, config, ... }: {
# Code to consume overlays, see https://flake.parts/overlays#consuming-an-overlay
_module.args.pkgs = import inputs.nixos {
inherit system;
overlays = [
inputs.agenix.overlays.default
(import ./pkgs/default.nix)
];
perSystem = args@{ system, pkgs, config, ... }: {
_module.args = {
inherit inputs;
pkgs = import inputs.nixpkgs {
inherit system;
overlays = [
inputs.agenix.overlays.default
];
};
unstable = import inputs.unstable { inherit system; };
master = import inputs.master { inherit system; };
fix-yubikey-agent = import inputs.fix-yubikey-agent { inherit system; };
};
devShells.default = pkgs.mkShell {
buildInputs = [
pkgs.nixpkgs-fmt
pkgs.sops
pkgs.agenix
pkgs.ssh-to-age
];
};
};
flake = {
# Configurations for Linux (NixOS) machines
nixosConfigurations = {
biolimo = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "x86_64-linux";
imports = [
self.nixosModules.base
./hosts/biolimo/default.nix
./users/b12f/default.nix
];
};
chocolatebar = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "x86_64-linux";
imports = [
self.nixosModules.base
./hosts/chocolatebar/default.nix
./users/b12f/default.nix
];
};
pie = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "aarch64-linux";
imports = [
self.nixosModules.base
inputs.nixos-hardware.nixosModules.raspberry-pi-4
./hosts/pie/default.nix
./users/yule/default.nix
];
};
maoam = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "aarch64-linux";
imports = [
self.nixosModules.base
./hosts/maoam/default.nix
./users/yule/default.nix
];
};
};
nixosModules = rec {
arduino = import ./modules/arduino/default.nix;
audio = import ./modules/audio/default.nix;
# ci-runner = import ./modules/ci-runner/default.nix;
core = import ./modules/core/default.nix;
crypto = import ./modules/crypto/default.nix;
devops = import ./modules/devops/default.nix;
# docker = import ./modules/docker/default.nix;
# docker-ci-runner = import ./modules/docker-ci-runner/default.nix;
email = import ./modules/email/default.nix;
gaming = import ./modules/gaming/default.nix;
graphical = import ./modules/graphical/default.nix;
mobile = import ./modules/mobile/default.nix;
# nextcloud = import ./modules/nextcloud/default.nix;
# office = import ./modules/office/default.nix;
paperless = import ./modules/paperless/default.nix;
paranoia = import ./modules/paranoia/default.nix;
printing = import ./modules/printing/default.nix;
social = import ./modules/social/default.nix;
sway = import ./modules/sway/default.nix;
terminal-life = import ./modules/terminal-life/default.nix;
uhk = import ./modules/uhk/default.nix;
user = import ./modules/user/default.nix;
# virtualisation = import ./modules/virtualisation/default.nix;
root = import ./users/root/default.nix;
base.imports = [
self.nixosModules.home-manager
inputs.agenix.nixosModules.default
inputs.musnix.nixosModules.musnix
({ flake, pkgs, lib, ... }: {
nixpkgs.overlays = [ (import ./pkgs/default.nix) ];
({
flake,
pkgs,
lib,
unstable,
master,
fix-yubikey-agent,
...
}: {
nixpkgs.overlays = (import ./overlays) ++ [
(prev: next: {
scan2paperless = inputs.scan2paperless.legacyPackages.${prev.system}.scan2paperless;
nixd = inputs.unstable.legacyPackages.${prev.system}.nixd;
yubikey-agent = inputs.fix-yubikey-agent.legacyPackages.${prev.system}.yubikey-agent;
factorio-headless = inputs.master.legacyPackages.${prev.system}.factorio-headless;
paperless-ngx = inputs.master.legacyPackages.${prev.system}.paperless-ngx;
waybar = inputs.master.legacyPackages.${prev.system}.waybar;
element-desktop = inputs.master.legacyPackages.${prev.system}.element-desktop;
adlist = inputs.adblock-unbound.packages.${prev.system};
})
];
nix.nixPath = [
"nixpkgs=${inputs.nixpkgs}"
"nixos-config=${./lib/compat/nixos}"
"home-manager=${inputs.home-manager}"
];
})
arduino
audio
# ci-runner
core
crypto
devops
# docker
# docker-ci-runner
email
gaming
graphical
mobile
# nextcloud
# office
paperless
paranoia
printing
social
sway
terminal-life
uhk
user
# virtualisation
self.nixosModules.arduino
self.nixosModules.audio
self.nixosModules.ci-runner
self.nixosModules.core
self.nixosModules.crypto
self.nixosModules.devops
self.nixosModules.docker
self.nixosModules.docker-ci-runner
self.nixosModules.email
self.nixosModules.gaming
self.nixosModules.graphical
self.nixosModules.mobile
self.nixosModules.nix
self.nixosModules.nextcloud
self.nixosModules.office
self.nixosModules.paperless
self.nixosModules.paranoia
self.nixosModules.printing
self.nixosModules.social
self.nixosModules.sway
self.nixosModules.terminal-life
self.nixosModules.uhk
self.nixosModules.user
self.nixosModules.virtualisation
root
self.nixosModules.root
];
full-install = {
# pub-solar.audio.bluetooth.enable = true;
# pub-solar.docker.enable = true;
# pub-solar.nextcloud.enable = true;
# pub-solar.office.enable = true;
};
};
homeModules = { };
};
# deploy.nodes = {
# droppie = {
# hostname = "backup.b12f.io";
# sshUser = "yule";
# remoteBuild = true;
# path = inputs.deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.droppie;
# };
# pie = {
# sshUser = "yule";
# remoteBuild = true;
# path = inputs.deploy-rs.lib.aarch64-linux.activate.nixos self.nixosConfigurations.pie;
# };
# maoam = {
# sshUser = "b12f";
# remoteBuild = true;
# path = inputs.deploy-rs.lib.aarch64-linux.activate.nixos self.nixosConfigurations.maoam;
# };
# };
# checks = builtins.mapAttrs (system: deployLib: deployLib.deployChecks self.deploy) inputs.deploy-rs.lib;
};
}

View file

@ -1,6 +1,8 @@
{
config,
pkgs,
flake,
lib,
...
}:
with lib; let
@ -29,7 +31,7 @@ in {
pub-solar.paperless.sync.masterNode = true;
age.secrets."drone-runner-exec-config" = {
file = "${self}/secrets/drone-runner-exec-config";
file = "${flake.self}/secrets/drone-runner-exec-config";
mode = "400";
owner = psCfg.user.name;
};
@ -59,12 +61,12 @@ in {
];
age.secrets."vnc-key.pem" = {
file = "${self}/secrets/vnc-key-chocolatebar.pem";
file = "${flake.self}/secrets/vnc-key-chocolatebar.pem";
mode = "400";
owner = psCfg.user.name;
};
age.secrets."vnc-cert.pem" = {
file = "${self}/secrets/vnc-cert-chocolatebar.pem";
file = "${flake.self}/secrets/vnc-cert-chocolatebar.pem";
mode = "400";
owner = psCfg.user.name;
};

View file

@ -4,6 +4,6 @@
./hardware-configuration.nix
./virtualisation
./factorio
# ./factorio
];
}

View file

@ -2,7 +2,6 @@
config,
pkgs,
lib,
self,
...
}:
with lib; let

View file

@ -1,30 +1,43 @@
{ withSystem, self, inputs, ...}:
{
# Configuration common to all Linux systems
flake = {
nixosModules = {
# NixOS modules that are known to work on nix-darwin.
common.imports = [
./nix.nix
./caches
];
my-home = {
users.users.${config.people.myself}.isNormalUser = true;
home-manager.users.${config.people.myself} = {
imports = [
self.homeModules.common-linux
];
};
nixosConfigurations = {
biolimo = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "x86_64-linux";
imports = [
self.nixosModules.base
./biolimo
self.nixosModules.b12f
];
};
default.imports = [
self.nixosModules.home-manager
self.nixosModules.my-home
self.nixosModules.common
./self-ide.nix
./ssh-authorize.nix
./current-location.nix
];
chocolatebar = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "x86_64-linux";
imports = [
self.nixosModules.base
./chocolatebar
self.nixosModules.b12f
];
};
pie = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "aarch64-linux";
imports = [
self.nixosModules.base
inputs.nixos-hardware.nixosModules.raspberry-pi-4
./pie
self.nixosModules.yule
];
};
maoam = self.nixos-flake.lib.mkLinuxSystem {
nixpkgs.hostPlatform = "aarch64-linux";
imports = [
self.nixosModules.base
./maoam
self.nixosModules.yule
];
};
};
};
}

View file

@ -2,6 +2,7 @@
config,
pkgs,
lib,
flake,
...
}:
with lib; let
@ -44,14 +45,14 @@ in {
};
age.secrets."dyndns-droppie.key" = {
file = "${self}/secrets/dyndns-droppie.key";
file = "${flake.self}/secrets/dyndns-droppie.key";
mode = "400";
owner = "root";
};
# ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBZQSephFJU0NMbVbhwvVJ2/m6jcPYo1IsWCsoarqKin root@droppie
age.secrets."droppie-ssh-root.key" = {
file = "${self}/secrets/droppie-ssh-root.key";
file = "${flake.self}/secrets/droppie-ssh-root.key";
path = "/home/${psCfg.user.name}/.ssh/id_ed25519";
mode = "400";
owner = psCfg.user.name;

View file

@ -2,7 +2,6 @@
config,
pkgs,
lib,
self,
...
}:
with lib; let

View file

@ -5,7 +5,6 @@
config,
pkgs,
lib,
inputs,
...
}:
with lib; let

View file

@ -1,7 +1,4 @@
{ pkgs, inputs, ... }:
let
adlist = inputs.adblock-unbound.packages.${pkgs.system};
in {
{ pkgs, lib, ... }: {
networking.firewall.allowedUDPPorts = [ 53 ];
networking.firewall.allowedTCPPorts = [ 53 ];
@ -10,7 +7,7 @@ in {
settings = {
server = {
include = [
"\"${adlist.unbound-adblockStevenBlack}\""
"\"${pkgs.adlist.unbound-adblockStevenBlack}\""
];
interface = [ "0.0.0.0" ];
access-control = [ "192.168.178.0/24 allow" ];

View file

@ -6,7 +6,7 @@
}:
with lib; let
psCfg = config.pub-solar;
cfg = config.pub-solar.devops;
cfg = config.pub-solar.arduino;
in {
options.pub-solar.arduino = {
enable = mkEnableOption "Life with home automation";

View file

@ -2,7 +2,7 @@
lib,
config,
pkgs,
self,
flake,
...
}:
with lib; let
@ -37,7 +37,7 @@ in {
};
age.secrets."drone-runner-exec-config" = {
file = "${self}/secrets/drone-runner-exec-config";
file = "${flake.self}/secrets/drone-runner-exec-config";
mode = "700";
owner = psCfg.user.name;
};

View file

@ -12,7 +12,6 @@ in {
./fonts.nix
./i18n.nix
./networking.nix
./nix.nix
./packages.nix
./services.nix
];

31
modules/default.nix Normal file
View file

@ -0,0 +1,31 @@
{
# Configuration common to all Linux systems
flake = {
nixosModules = {
arduino = import ./arduino;
audio = import ./audio;
ci-runner = import ./ci-runner;
core = import ./core;
crypto = import ./crypto;
devops = import ./devops;
docker = import ./docker;
docker-ci-runner = import ./docker-ci-runner;
email = import ./email;
gaming = import ./gaming;
graphical = import ./graphical;
mobile = import ./mobile;
nix = import ./nix;
nextcloud = import ./nextcloud;
office = import ./office;
paperless = import ./paperless;
paranoia = import ./paranoia;
printing = import ./printing;
social = import ./social;
sway = import ./sway;
terminal-life = import ./terminal-life;
uhk = import ./uhk;
user = import ./user;
virtualisation = import ./virtualisation;
};
};
}

View file

@ -2,7 +2,6 @@
lib,
config,
pkgs,
self,
...
}:
with lib; let

View file

@ -1,11 +0,0 @@
{
channel,
inputs,
...
}: {
nix.nixPath = [
"nixpkgs=${channel.input}"
"nixos-config=${../lib/compat/nixos}"
"home-manager=${inputs.home}"
];
}

View file

@ -2,7 +2,7 @@
config,
pkgs,
lib,
inputs,
flake,
...
}: {
nix = {
@ -10,6 +10,7 @@
package = pkgs.nix;
gc.automatic = true;
optimise.automatic = true;
settings = {
# Improve nix store disk usage
auto-optimise-store = true;
@ -20,6 +21,7 @@
# Allow only group wheel to connect to the nix daemon
allowed-users = ["@wheel"];
};
# Generally useful nix option defaults
extraOptions = lib.mkForce ''
experimental-features = flakes nix-command
@ -28,5 +30,11 @@
keep-derivations = true
fallback = true
'';
nixPath = [
"nixpkgs=${flake.inputs.nixpkgs}"
"nixos-config=${../../lib/compat/nixos}"
"home-manager=${flake.inputs.home-manager}"
];
};
}

View file

@ -2,7 +2,6 @@
lib,
config,
pkgs,
inputs,
...
}:
with lib; let
@ -86,7 +85,7 @@ in {
home-manager = pkgs.lib.setAttrByPath ["users" psCfg.user.name] {
home.packages = with pkgs; [
inputs.scan2paperless.legacyPackages.x86_64-linux.scan2paperless
scan2paperless
sane-backends
python310Packages.img2pdf
];

View file

@ -32,7 +32,7 @@ in {
# Don't set this if you need sftp
services.openssh.allowSFTP = false;
services.openssh.openFirewall = false; # Lock yourself out
# services.openssh.openFirewall = false; # Lock yourself out
# Limit the use of sudo to the group wheel
security.sudo.execWheelOnly = true;

View file

@ -1,7 +1,6 @@
{
config,
pkgs,
self,
...
}: let
psCfg = config.pub-solar;
@ -106,8 +105,6 @@ in {
irssi = "irssi --config=$XDG_CONFIG_HOME/irssi/config --home=$XDG_DATA_HOME/irssi";
drone = "DRONE_TOKEN=$(secret-tool lookup drone token) drone";
no = "manix \"\" | grep '^# ' | sed 's/^# \(.*\) (.*/\1/;s/ (.*//;s/^# //' | fzf --preview=\"manix '{}'\" | xargs manix";
# fix nixos-option
nixos-option = "nixos-option -I nixpkgs=${self}/lib/compat";
myip = "dig +short myip.opendns.com @208.67.222.222 2>&1";
nnn = "nnn -d -e -H -r";
};

View file

@ -2,7 +2,6 @@
lib,
config,
pkgs,
self,
...
}:
with lib; let
@ -24,17 +23,6 @@ in {
config = mkIf cfg.enable {
programs.command-not-found.enable = false;
environment.systemPackages = with pkgs; [
screen
];
# Starship is a fast and featureful shell prompt
# starship.toml has sane defaults that can be changed there
programs.starship = {
enable = true;
settings = import ./starship.toml.nix;
};
home-manager = with pkgs;
pkgs.lib.setAttrByPath ["users" psCfg.user.name] {
home.packages = [
@ -55,25 +43,34 @@ in {
];
}))
powerline
screen
silver-searcher
watson
];
# Starship is a fast and featureful shell prompt
# starship.toml has sane defaults that can be changed there
programs.starship = {
enable = true;
settings = import ./starship.toml.nix;
};
programs.bash = import ./bash {
inherit config;
inherit pkgs;
inherit self;
inherit lib;
};
programs.fzf = import ./fzf {
inherit config;
inherit pkgs;
};
programs.neovim = import ./nvim {
inherit config;
inherit pkgs;
inherit lib;
};
};
};
};
}

View file

@ -0,0 +1,243 @@
# Configuration file for dircolors, a utility to help you set the
# LS_COLORS environment variable used by GNU ls with the --color option.
# Copyright (C) 1996-2014 Free Software Foundation, Inc.
# Copying and distribution of this file, with or without modification,
# are permitted provided the copyright notice and this notice are preserved.
# The keywords COLOR, OPTIONS, and EIGHTBIT (honored by the
# slackware version of dircolors) are recognized but ignored.
# You can copy this file to .dir_colors in your $HOME directory to override
# the system defaults.
# Below, there should be one TERM entry for each termtype that is colorizable
TERM Eterm
TERM ansi
TERM color-xterm
TERM con132x25
TERM con132x30
TERM con132x43
TERM con132x60
TERM con80x25
TERM con80x28
TERM con80x30
TERM con80x43
TERM con80x50
TERM con80x60
TERM cons25
TERM console
TERM cygwin
TERM dtterm
TERM eterm-color
TERM gnome
TERM gnome-256color
TERM hurd
TERM jfbterm
TERM konsole
TERM kterm
TERM linux
TERM linux-c
TERM mach-color
TERM mach-gnu-color
TERM mlterm
TERM putty
TERM putty-256color
TERM rxvt
TERM rxvt-256color
TERM rxvt-cygwin
TERM rxvt-cygwin-native
TERM rxvt-unicode
TERM rxvt-unicode-256color
TERM rxvt-unicode256
TERM screen
TERM screen-256color
TERM screen-256color-bce
TERM screen-bce
TERM screen-w
TERM screen.Eterm
TERM screen.rxvt
TERM screen.linux
TERM st
TERM st-256color
TERM terminator
TERM vt100
TERM xterm
TERM xterm-16color
TERM xterm-256color
TERM xterm-88color
TERM xterm-color
TERM xterm-debian
# Below are the color init strings for the basic file types. A color init
# string consists of one or more of the following numeric codes:
# Attribute codes:
# 00=none 01=bold 04=underscore 05=blink 07=reverse 08=concealed
# Text color codes:
# 30=black 31=red 32=green 33=yellow 34=blue 35=magenta 36=cyan 37=white
# Background color codes:
# 40=black 41=red 42=green 43=yellow 44=blue 45=magenta 46=cyan 47=white
#NORMAL 00 # no color code at all
#FILE 00 # regular file: use no color at all
RESET 0 # reset to "normal" color
DIR 01;34 # directory
LINK 01;36 # symbolic link. (If you set this to 'target' instead of a
# numerical value, the color is as for the file pointed to.)
MULTIHARDLINK 00 # regular file with more than one link
FIFO 40;33 # pipe
SOCK 01;35 # socket
DOOR 01;35 # door
BLK 40;33;01 # block device driver
CHR 40;33;01 # character device driver
ORPHAN 01;05;37;41 # orphaned syminks
MISSING 01;05;37;41 # ... and the files they point to
SETUID 37;41 # file that is setuid (u+s)
SETGID 30;43 # file that is setgid (g+s)
CAPABILITY 30;41 # file with capability
STICKY_OTHER_WRITABLE 30;42 # dir that is sticky and other-writable (+t,o+w)
OTHER_WRITABLE 34;42 # dir that is other-writable (o+w) and not sticky
STICKY 37;44 # dir with the sticky bit set (+t) and not other-writable
# This is for files with execute permission:
EXEC 01;32
# List any file extensions like '.gz' or '.tar' that you would like ls
# to colorize below. Put the extension, a space, and the color init string.
# (and any comments you want to add after a '#')
# If you use DOS-style suffixes, you may want to uncomment the following:
#.cmd 01;32 # executables (bright green)
#.exe 01;32
#.com 01;32
#.btm 01;32
#.bat 01;32
# Or if you want to colorize scripts even if they do not have the
# executable bit actually set.
#.sh 01;32
#.csh 01;32
# archives or compressed (bright red)
.tar 01;31
.tgz 01;31
.arc 01;31
.arj 01;31
.taz 01;31
.lha 01;31
.lz4 01;31
.lzh 01;31
.lzma 01;31
.tlz 01;31
.txz 01;31
.tzo 01;31
.t7z 01;31
.zip 01;31
.z 01;31
.Z 01;31
.dz 01;31
.gz 01;31
.lrz 01;31
.lz 01;31
.lzo 01;31
.xz 01;31
.bz2 01;31
.bz 01;31
.tbz 01;31
.tbz2 01;31
.tz 01;31
.deb 01;31
.rpm 01;31
.jar 01;31
.war 01;31
.ear 01;31
.sar 01;31
.rar 01;31
.alz 01;31
.ace 01;31
.zoo 01;31
.cpio 01;31
.7z 01;31
.rz 01;31
.cab 01;31
# image formats
.jpg 01;35
.jpeg 01;35
.gif 01;35
.bmp 01;35
.pbm 01;35
.pgm 01;35
.ppm 01;35
.tga 01;35
.xbm 01;35
.xpm 01;35
.tif 01;35
.tiff 01;35
.png 01;35
.svg 01;35
.svgz 01;35
.mng 01;35
.pcx 01;35
.mov 01;35
.mpg 01;35
.mpeg 01;35
.m2v 01;35
.mkv 01;35
.webm 01;35
.ogm 01;35
.mp4 01;35
.m4v 01;35
.mp4v 01;35
.vob 01;35
.qt 01;35
.nuv 01;35
.wmv 01;35
.asf 01;35
.rm 01;35
.rmvb 01;35
.flc 01;35
.avi 01;35
.fli 01;35
.flv 01;35
.gl 01;35
.dl 01;35
.xcf 01;35
.xwd 01;35
.yuv 01;35
.cgm 01;35
.emf 01;35
# http://wiki.xiph.org/index.php/MIME_Types_and_File_Extensions
.axv 01;35
.anx 01;35
.ogv 01;35
.ogx 01;35
# Document files
.pdf 00;32
.ps 00;32
.txt 00;32
.patch 00;32
.diff 00;32
.log 00;32
.tex 00;32
.doc 00;32
# audio formats
.aac 00;36
.au 00;36
.flac 00;36
.m4a 00;36
.mid 00;36
.midi 00;36
.mka 00;36
.mp3 00;36
.mpc 00;36
.ogg 00;36
.ra 00;36
.wav 00;36
# http://wiki.xiph.org/index.php/MIME_Types_and_File_Extensions
.axa 00;36
.oga 00;36
.spx 00;36
.xspf 00;36

View file

@ -0,0 +1,47 @@
{
config,
pkgs,
...
}: let
user = config.pub-solar.user;
xdg = config.home-manager.users."${user.name}".xdg;
in '' [user]
${
if user.email != null
then "email = ${user.email}"
else ""
}
${
if user.fullName != null
then "name = ${user.fullName}"
else ""
}
${
if user.gpgKeyId != null
then "signingkey = ${user.gpgKeyId}"
else ""
}
[core]
editor = /etc/profiles/per-user/${config.pub-solar.user.name}/bin/nvim
excludesFile = /home/${config.pub-solar.user.name}/.config/git/global_gitignore
[alias]
pol = pull
ack = -c color.grep.linenumber=\"bold yellow\"\n -c color.grep.filename=\"bold green\"\n -c color.grep.match=\"reverse yellow\"\n grep --break --heading --line-number
# define command which will be used when "nvim"is set as a merge tool
[mergetool]
prompt = false
[merge]
tool = nvim
[mergetool "nvim"]
cmd = /etc/profiles/per-user/${config.pub-solar.user.name}/bin/nvim -f -c \"Gdiffsplit!\" \"$MERGED\"
[commit]
gpgsign = true
template = ${xdg.configHome}/git/gitmessage
[tag]
gpgsign = true
[init]
defaultBranch = main
[pull]
rebase = false''

View file

@ -0,0 +1,32 @@
{
config,
pkgs,
...
}: let
user = config.pub-solar.user;
xdg = config.home-manager.users."${user.name}".xdg;
in ''
# What happened?
#
# fix feat build chore ci docs style refactor perf test
#
# type!(optional scope): <summary> --------------#
#
# ^\n
# What exactly was done and why? --------------------------------------#
#
# ^\n
#
# Any issue numbers or links?
#
# Ref: #123
# ^\n
#
# Co-authored-by: Example Name <email@example.com>
''

View file

@ -0,0 +1,6 @@
{
config,
pkgs,
...
}: let
in ''tags''

View file

@ -0,0 +1,198 @@
# Configuration file for libinput-gestures.
# Mark Blakeney, Sep 2015
#
# The default configuration file exists at /etc/libinput-gestures.conf
# but a user can create a personal custom configuration file at
# ~/.config/libinput-gestures.conf.
#
# Lines starting with '#' and blank lines are ignored. Currently
# "gesture" and "device" configuration keywords are supported as
# described below. The keyword can optionally be appended with a ":" (to
# maintain compatibility with original format configuration files).
#
# Each gesture line has 3 [or 4] arguments separated by whitespace:
#
# action motion [finger_count] command
#
# where action and motion is either:
# swipe up
# swipe down
# swipe left
# swipe right
# swipe left_up
# swipe left_down
# swipe right_up
# swipe right_down
# pinch in
# pinch out
# pinch clockwise
# pinch anticlockwise
#
# command is the remainder of the line and is any valid shell command +
# arguments.
#
# finger_count is a single numeric digit and is optional (and is
# typically 3 or 4). If specified then the command is executed when
# exactly that number of fingers is used in the gesture. If not
# specified then the command is executed when that gesture is executed
# with any number of fingers. Gesture lines specified with finger_count
# have priority over the same gesture specified without any
# finger_count.
#
# Typically command will be xdotool, or wmctrl. See "man xdotool" for
# the many things you can action with that tool. Note that unfortunately
# xdotool does not work with native Wayland clients.
###############################################################################
# SWIPE GESTURES:
###############################################################################
# Note the default is an "internal" command that uses wmctrl to switch
# workspaces and, unlike xdotool, works on both Xorg and Wayland (via
# XWayland). It also can be configured for vertical and horizontal
# switching over tabular workspaces, as per the example below. You can
# also add "-w" to the internal command to allow wrapping workspaces.
# Move to next workspace (works for GNOME/KDE/etc on Wayland and Xorg)
#gesture swipe up _internal ws_up
# NOTE ABOUT FINGER COUNT:
# The above command will configure this command for all fingers (i.e. 3
# for 4) but to configure it for 3 fingers only, change it to:
# gesture swipe up 3 _internal ws_up
# Then you can configure something else for 4 fingers or leave 4 fingers
# unconfigured. You can configure an explicit finger count like this for
# all example commands in this configuration file.
#
gesture swipe up 3 ydotool key Super_L+Down
gesture swipe up 4 ydotool key Super_L+Ctrl+Right
# Move to prev workspace (works for GNOME/KDE/etc on Wayland and Xorg)
#gesture swipe down _internal ws_down
gesture swipe down 3 ydotool key Super_L+Up
gesture swipe down 4 ydotool key Super_L+Ctrl+Left
# Browser go forward (works only for Xorg, and Xwayland clients)
gesture swipe left 3 ydotool key ctrl+]
# Browser go back (works only for Xorg, and Xwayland clients)
gesture swipe right 3 ydotool key ctrl+[
# NOTE: If you don't use "natural" scrolling direction for your touchpad
# then you may want to swap the above default left/right and up/down
# configurations.
# Optional extended swipe gestures, e.g. for browser tab navigation:
#
# Jump to next open browser tab
#gesture swipe right_up xdotool key control+Tab
#gesture swipe right_up xdotool key control+Next
gesture swipe right_up ydotool key ctrl+PageDown
#
# Jump to previous open browser tab
#gesture swipe left_up xdotool key control+shift+Tab
gesture swipe left_up ydotool key ctrl+PageUp
#
# Close current browser tab
# gesture swipe left_down xdotool key control+w
#
# Reopen and jump to last closed browser tab
# gesture swipe right_down xdotool key control+shift+t
# Example of 8 static workspaces, e.g. using KDE virtual-desktops,
# arranged in 2 rows of 4 columns across using swipe up/down/left/right
# to navigate in fixed planes. You can also add the "-w/--wrap" option
# to allow wrapping in any direction. You must configure your virtual
# desktops with the same column dimension.
# gesture swipe up _internal --cols 4 ws_up
# gesture swipe down _internal --cols 4 ws_down
# gesture swipe left _internal --cols 4 ws_left
# gesture swipe right _internal --cols 4 ws_right
#
# Example of 16 static workspaces, e.g. using KDE virtual-desktops,
# arranged in 4 rows of 4 columns across using swipe up/down/left/right
# to navigate in fixed planes, and also using swipe
# left_up/left_down/right_up/right_down to navigate diagonally. You can
# also add the "-w/--wrap" option to allow wrapping in any direction
# and/or diagonally. You must configure your virtual desktops with the
# same column dimension.
# gesture swipe up _internal --cols 4 ws_up
# gesture swipe down _internal --cols 4 ws_down
# gesture swipe left _internal --cols 4 ws_left
# gesture swipe right _internal --cols 4 ws_right
# gesture swipe left_up _internal --cols 4 ws_left_up
# gesture swipe left_down _internal --cols 4 ws_left_down
# gesture swipe right_up _internal --cols 4 ws_right_up
# gesture swipe right_down _internal --cols 4 ws_right_down
# Example virtual desktop switching for Ubuntu Unity/Compiz. The
# _internal command does not work for Compiz but you can explicitly
# configure the swipe commands to work for a Compiz virtual 2
# dimensional desktop as follows:
# gesture swipe up xdotool key ctrl+alt+Up
# gesture swipe down xdotool key ctrl+alt+Down
# gesture swipe left xdotool key ctrl+alt+Left
# gesture swipe right xdotool key ctrl+alt+Right
# Example to change audio volume:
# Note this only works on an Xorg desktop (not Wayland).
# gesture swipe up xdotool key XF86AudioRaiseVolume
# gesture swipe down xdotool key XF86AudioLowerVolume
###############################################################################
# PINCH GESTURES:
###############################################################################
# GNOME SHELL open/close overview (works for GNOME on Xorg only)
gesture pinch in ydotool key ctrl+-
gesture pinch out ydotool key ctrl+shift+=
# KDE Plasma open/close overview
# gesture pinch in xdotool key ctrl+F9
# gesture pinch out xdotool key ctrl+F9
# GNOME SHELL open/close overview (works for GNOME on Wayland and Xorg)
# Note since GNOME 3.24 on Wayland this is implemented natively so no
# real point configuring for Wayland.
# gesture pinch in dbus-send --session --type=method_call --dest=org.gnome.Shell /org/gnome/Shell org.gnome.Shell.Eval string:'Main.overview.toggle();'
# gesture pinch out dbus-send --session --type=method_call --dest=org.gnome.Shell /org/gnome/Shell org.gnome.Shell.Eval string:'Main.overview.toggle();'
# Optional extended pinch gestures:
# gesture pinch clockwise <whatever command>
# gesture pinch anticlockwise <whatever command>
###############################################################################
# This application normally determines your touchpad device
# automatically. Some users may have multiple touchpads but by default
# we use only the first one found. However, you can choose to specify
# the explicit device name to use. Run "libinput list-devices" to work
# out the name of your device (from the "Device:" field). Then add a
# device line specifying that name, e.g:
#
# device DLL0665:01 06CB:76AD Touchpad
#
# If the device name starts with a '/' then it is instead considered as
# the explicit device path although since device paths can change
# through reboots this is best to be a symlink. E.g. instead of specifying
# /dev/input/event12, use the corresponding full path link under
# /dev/input/by-path/ or /dev/input/by-id/.
#
# You can choose to use ALL touchpad devices by setting the device name
# to "all". E.g. Do this if you have multiple touchpads which you want
# to use in parallel. This reduces performance slightly so only set this
# if you have to.
#
# device all
###############################################################################
# You can set a minimum travel distance threshold before swipe gestures
# are actioned using the swipe_threshold configuration command.
# Specify this value in dots. The default is 0.
# E.g. set it to 100 dots with "swipe_threshold 100".
# swipe_threshold 0
###############################################################################
# You can set a timeout on gestures from start to end. The default is
# the value commented below. It can be any value in float secs >= 0.
# 0 = no timeout. E.g. set it to 2 secs with "timeout 2".
# timeout 1.5

View file

@ -0,0 +1,22 @@
padding=10
margin=5,5,0
default-timeout=5000
## Base16 Burn
# Author: Benjamin Bädorf
#
# You can use these variables anywhere in the mako configuration file.
background-color=#1a181a
text-color=#e3e1e4
border-color=#ff5f5f
[urgency=low]
background-color=#1a181a
text-color=#e3e1e4
border-color=#ff5f5f
[urgency=high]
background-color=#ff5f5f
text-color=#1a181a
border-color=#1a181a

View file

View file

@ -0,0 +1,132 @@
# base16-mutt: base16-shell support for mutt
#
# These depend on mutt compiled with s-lang, not ncurses. Check by running `mutt -v`
# Details this configuration may be found in the mutt manual:
# §3 Patterns <http://www.mutt.org/doc/manual/#patterns>
# §9 Using color and mono video attributes <http://www.mutt.org/doc/manual/#color>
# https://www.neomutt.org/guide/configuration.html#color
# base00 : color00 - Default Background
# base01 : color18 - Lighter Background (Used for status bars)
# base02 : color19 - Selection Background
# base03 : color08 - Comments, Invisibles, Line Highlighting
# base04 : color20 - Dark Foreground (Used for status bars)
# base05 : color07 - Default Foreground, Caret, Delimiters, Operators
# base06 : color21 - Light Foreground (Not often used)
# base07 : color15 - Light Background (Not often used)
# base08 : color01 - Index Item: Deleted.
# base09 : color16 - Message: URL.
# base0A : color03 - Search Text Background. Message: Bold.
# base0B : color02 - Message: Code. Index Item: Tagged.
# base0C : color06 - Message: Subject, Quotes. Index Item: Trusted.
# base0D : color04 - Message: Headings.
# base0E : color05 - Message: Italic, Underline. Index Item: Flagged.
# base0F : color17 - Deprecated, Opening/Closing Embedded Language Tags e.g.
## Base
color normal color07 color00 # softer, bold
## Weak
color tilde color08 color00 # `~` padding at the end of pager
color attachment color08 color00
color tree color08 color00 # arrow in threads
color signature color08 color00
color markers color08 color00 # `+` wrap indicator in pager
## Strong
color bold color21 color00
color underline color21 color00
## Highlight
color error color01 color00
color message color02 color00 # informational messages
color search color00 color01
color status color01 color18
color indicator color03 color19 # inverse, brighter
# Message Index ----------------------------------------------------------------
## Weak
color index color08 color00 "~R" # read messages
color index color08 color00 "~d >45d" # older than 45 days
color index color08 color00 "~v~(!~N)" # collapsed thread with no unread
color index color08 color00 "~Q" # messages that have been replied to
## Strong
color index color01 color00 "(~U|~N|~O)" # unread, new, old messages
color index color01 color00 "~v~(~U|~N|~O)" # collapsed thread with unread
## Highlight
### Trusted
color index color06 color00 "~g" # PGP signed messages
color index color06 color00 "~G" # PGP encrypted messages
### Odd
color index color01 color00 "~E" # past Expires: header date
color index color01 color00 "~=" # duplicated
color index color01 color00 "~S" # marked by Supersedes: header
### Flagged
color index color05 color00 "~F" # flagged messages
color index color02 color00 "~v~(~F)" # collapsed thread with flagged inside
# Selection
color index color02 color18 "~T" # tagged messages
color index color01 color18 "~D" # deleted messages
### Message Headers ----------------------------------------------------
# Base
color hdrdefault color07 color00
color header color07 color00 "^"
# Strong
color header color21 color00 "^(From)"
# Highlight
color header color04 color00 "^(Subject)"
### Message Body -------------------------------------------------------
# When possible, these regular expressions attempt to match http://spec.commonmark.org/
## Weak
# ~~~ Horizontal rules ~~~
color body color08 color00 "([[:space:]]*[-+=#*~_]){3,}[[:space:]]*"
## Strong
# *Bold* span
color body color03 color00 "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
# _Underline_ span
color body color05 color00 "(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
# /Italic/ span (Sometimes gets directory names)
color body color05 color00 "(^|[[:space:][:punct:]])/[^/]+/([[:space:][:punct:]]|$)"
# ATX headers
color body color04 color00 "^[[:space:]]{0,3}#+[[:space:]].*$"
## Highlight
# `Code` span
color body color02 color00 "(^|[[:space:][:punct:]])\`[^\`]+\`([[:space:][:punct:]]|$)"
# Indented code block
color body color02 color00 "^[[:space:]]{4,}.*$"
# URLs
color body color16 color00 "([a-z][a-z0-9+-]*://(((([a-z0-9_.!~*'();:&=+$,-]|%[0-9a-f][0-9a-f])*@)?((([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?|[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+)(:[0-9]+)?)|([a-z0-9_.!~*'()$,;:@&=+-]|%[0-9a-f][0-9a-f])+)(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?(#([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?|(www|ftp)\\.(([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?(:[0-9]+)?(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?(#([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?)[^].,:;!)? \t\r\n<>\"]"
# Email addresses
color body color16 color00 "((@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\]),)*@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\]):)?[0-9a-z_.+%$-]+@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\])"
# Emoticons ;-P
color body black yellow "[;:][-o]?[})>{(<|P]"
# PGP
color body color21 color01 "(BAD signature)"
color body color21 color01 "^gpg: BAD signature from.*"
color body color21 color04 "(Good signature)"
color body color21 color04 "^gpg: Good signature .*"
color body color04 color00 "^gpg: "
## Quotation blocks
color quoted color06 color00
color quoted1 color02 color00
color quoted2 color03 color00
color quoted3 color16 color00
color quoted4 color01 color00
color quoted5 color17 color00
color quoted6 color05 color00
color quoted7 color04 color00
# vi: ft=muttrc

View file

@ -0,0 +1 @@
text/html; w3m -I %{charset} -T text/html; copiousoutput;

View file

@ -0,0 +1,104 @@
# vim: filetype=muttrc
source $XDG_CONFIG_HOME/mutt/base16.muttrc
source $XDG_CONFIG_HOME/mutt/accounts.muttrc
set editor = `echo \$EDITOR`
set sidebar_visible = yes
set sidebar_width = 50
set sidebar_format = "%B%?F? [%F]?%* %?N?%N/?%S"
set sendmail_wait = 0
set mail_check_stats
set crypt_use_gpgme=yes
set crypt_autosign=yes
set crypt_verify_sig=yes
set crypt_replysign=yes
set crypt_replyencrypt=yes
set crypt_replysignencrypted=yes
set crypt_autoencrypt=yes
set pgp_check_gpg_decrypt_status_fd
set pgp_use_gpg_agent=yes
set pgp_self_encrypt=yes
# Store message headers locally to speed things up.
# If hcache is a folder, Mutt will create sub cache folders for each account which may speeds things up even more.
set header_cache = $XDG_CACHE_HOME/mutt
# Store messages locally to speed things up, like searching message bodies.
# Can be the same folder as header_cache.
# This will cost important disk usage according to your e-mail amount.
set message_cachedir = $XDG_CACHE_HOME/mutt
set imap_check_subscribed
# Allow Mutt to open a new IMAP connection automatically.
unset imap_passive
# Keep the IMAP connection alive by polling intermittently (time in seconds).
set imap_keepalive = 300
# How often to check for new mail (time in seconds).
set mail_check = 120
set askcc
set askbcc
set date_format="!%d.%m.%Y %H:%M"
set index_format="%4C %Z %D %4c %20.20L %s"
#------------------------------------------------------------
# Vi Key Bindings
#------------------------------------------------------------
# Moving around
bind generic g noop
bind generic gg first-entry
bind generic,index G last-entry
bind generic,index i previous-entry
bind generic,index k next-entry
bind pager,index d noop
bind pager,index dd delete-message
bind pager i previous-line
bind pager k next-line
bind pager I previous-entry
bind pager K next-entry
bind pager r noop
bind pager rr reply
bind pager ra group-reply
bind pager rn group-chat-reply
bind pager rl list-reply
# Threads
bind browser,pager,index N search-opposite
bind pager,index dT delete-thread
bind pager,index dt delete-subthread
bind pager,index g noop
bind pager,index gt next-thread
bind pager,index gT previous-thread
bind index za collapse-thread
bind index zA collapse-all # Missing :folddisable/foldenable
# Enable URL opening
macro index,pager \cb "<pipe-message> urlscan<Enter>" "call urlscan to extract URLs out of a message"
macro attach,compose \cb "<pipe-entry> urlscan<Enter>" "call urlscan to extract URLs out of a message"
# Translate markdown to html
macro compose \e5 "F pandoc -s -f markdown -t html \ny^T^Utext/html; charset=utf-8\n"
set wait_key=no
# Save to ~/Downloads by default
macro attach D "<save-entry><bol>~/Downloads/<eol>" "Save to Downloads"
set mailcap_path = $XDG_CONFIG_HOME/mutt/mailcap
# HTML emails
auto_view text/html # view html automatically
alternative_order text/plain text/enriched text/html # save html for last

View file

@ -0,0 +1,9 @@
#! /usr/bin/env python2
import os
import subprocess
def get_env(key):
return os.getenv(key)
def get_secret(*attributes):
return subprocess.check_output(["secret-tool", "lookup"] + list(attributes))

View file

@ -0,0 +1,15 @@
# This file is written by xdg-user-dirs-update
# If you want to change or add directories, just edit the line you're
# interested in. All local changes will be retained on the next run.
# Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped
# homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an
# absolute path. No other format is supported.
XDG_DESKTOP_DIR="$HOME/"
XDG_DOWNLOAD_DIR="$HOME/Downloads"
XDG_TEMPLATES_DIR="$HOME/Templates"
XDG_PUBLICSHARE_DIR="$HOME/Public"
XDG_DOCUMENTS_DIR="$HOME/"
XDG_MUSIC_DIR="$HOME/"
XDG_PICTURES_DIR="$HOME/"
XDG_VIDEOS_DIR="$HOME/"

View file

@ -0,0 +1 @@
en_US

View file

@ -0,0 +1,23 @@
/*
*
* Base16 Burn
* Author: Benjamin Bädorf
*
*/
@define-color base00 #1a181a;
@define-color base01 #2d2a2e;
@define-color base02 #303030;
@define-color base03 #949494;
@define-color base04 #d3d1d4;
@define-color base05 #e3e1e4;
@define-color base06 #303030;
@define-color base07 #ff5f5f;
@define-color base08 #f85e84;
@define-color base09 #df5923;
@define-color base0A #e5c463;
@define-color base0B #9ecd6f;
@define-color base0C #ef9062;
@define-color base0D #7accd7;
@define-color base0E #ab9df2;
@define-color base0F #d70000;

View file

@ -0,0 +1,116 @@
{
"layer": "top", // Waybar at top layer
// "position": "bottom", // Waybar position (top|bottom|left|right)
"height": 26, // Waybar height
"modules-left": ["sway/workspaces", "sway/mode"],
//"modules-center": ["mpd"],
"modules-right": ["sway/language", "pulseaudio", "network", "idle_inhibitor", "battery", "clock", "tray"],
"sway/workspaces": {
"disable-scroll": true
},
"sway/mode": {
"tooltip": false,
"format": "{}"
},
"sway/window": {
"tooltip": false,
"max-length": 96
},
"sway/language": {
"format": "{}",
"max-length": 50
},
"tray": {
"icon-size": 21,
"spacing": 10
},
"clock": {
"tooltip-format": "<tt><small>{calendar}</small></tt>",
"format-alt": "{:%a %d. %h %H:%M}",
//"on-scroll": {
// "calendar": 1
//}
"calendar": {
"mode-mon-col" : 3,
"on-scroll": -1,
"on-click-right": "mode",
"format": {
"months": "<span color='#ffead3'><b>{}</b></span>",
"days": "<span color='#ecc6d9'><b>{}</b></span>",
"weekdays": "<span color='#ffcc66'><b>{}</b></span>",
"today": "<span color='#ff6699'><b><u>{}</u></b></span>"
},
},
},
"backlight": {
// "device": "acpi_video1",
"tooltip": true,
"tooltip-format": "Brightness: <big>{percent}%</big>",
"format": "<span font='10'>{icon}</span>",
"format-icons": ["", ""]
},
"cpu": {
"format": "{}% "
},
"memory": {
"format": "{}% "
},
"idle_inhibitor": {
"format": "<span font='10'>{icon} </span>",
"format-icons": {
"activated": "",
"deactivated": ""
}
},
"battery": {
"tooltip": false,
"states": {
"critical": 25
},
"full-at": 84,
"format": "<span font='10'>{icon}</span> {capacity}%",
"format-full": "<span font='10'>{icon}</span>",
"format-icons": ["", "", "", "", ""],
},
"network": {
"interval": 3,
"tooltip": true,
//"interface": "wlp4s0", // (Optional) To force the use of this interface   \uF2E7,
"format-wifi": "<span font='10'></span> \uf062 {bandwidthUpBits} | \uf063 {bandwidthDownBits}",
"format-ethernet": "<span font='10'></span> \uf062 {bandwidthUpBits} | \uf063 {bandwidthDownBits}",
"format-disconnected": "",
"tooltip-format-wifi": "{essid} ({signalStrength}%)  {ipaddr}",
"tooltip-format-ethernet": "{ifname}  {ipaddr}"
},
//\ue04f{volume}%
"pulseaudio": {
"tooltip": false,
"format": "{volume}% <span font='10'>{icon}</span>",
"format-bluetooth": "{volume}% <span font='10'>{icon}</span>",
"format-muted": "",
"on-click": "pavucontrol",
"format-alt": "{volume}% <span font='10'>{icon}</span>",
"format-icons": {
"headphones": "",
"handsfree": "",
"headset": "",
"phone": "",
"portable": "",
"car": "",
"default": ["","", ""]
}
},
"mpd": {
"format": "{artist} - {title} <span color=\"#999999\">[<span color=\"#ffffff\">{elapsedTime:%M:%S}</span> / {totalTime:%M:%S}]</span>",
"format-disconnected": "",
"format-stopped": "",
"interval": 1,
"state-icons": {
"paused": "",
"playing": ""
},
"tooltip-format": "MPD (connected)",
"tooltip-format-disconnected": "MPD (disconnected)"
}
}

View file

@ -0,0 +1,78 @@
@import "./colorscheme.css";
* {
min-height: 0;
border: none;
}
window#waybar {
font-family: Hack, FontAwesome;
font-weight: 500;
font-size: 14px;
background: rgba(11, 12, 13, 0.90);
border-bottom: 1px solid rgba(0, 0, 2, 0.53);
color: @base04;
}
#workspaces button {
font-size: 14px;
box-shadow: none;
text-shadow: none;
padding: 0px 3px 0px 3px;
color: @base04;
}
#workspaces button.focused {
color: #f85e84;
color: @base07;
/* margin: 2px 0px 2px 0px; */
}
#workspaces button:hover {
background: rgba(255, 255, 255, 0.00);
/* margin: 2px 0px 2px 0px; */
}
#clock, #backlight, #battery, #cpu, #memory, #network, #pulseaudio, #custom-spotify, #tray, #mode {
font-size: 14px;
margin: 0px 10px 0px 5px;
}
#pulseaudio {
/* border-top: 1px solid transparent; */
font-size: 12px;
margin-left: 15px;
}
#battery {
font-size: 12px;
}
#battery.critical {
color: @base07;
}
#battery.charging {
color: @base0B;
}
#battery.full {
margin: 0px 0px 0px 0px;
}
#network {
border-top: 1px solid transparent;
}
#network.disconnected {
margin: 0px 0px 0px 0px;
color: rgba(75, 81, 98, 0);
}
#pulseaudio.muted {
margin: 0px 0px 0px 0px;
color: rgba(75, 81, 98, 0);
}

View file

@ -0,0 +1,8 @@
! Swap Caps_Lock and Control_L
!
remove Lock = Caps_Lock
remove Control = Control_L
!keysym Control_L = Caps_Lock
keysym Caps_Lock = Control_L
add Lock = Caps_Lock
add Control = Control_L

View file

@ -0,0 +1,18 @@
Gtk/ButtonImages 1
Gtk/CanChangeAccels 1
Gtk/CursorThemeName "default"
Gtk/CursorThemeSize 0
Gtk/EnableEventSounds 0
Gtk/EnableInputFeedbackSounds 0
Gtk/FontName "Lato"
Gtk/ThemeName "Matcha-dark-aliz"
Gtk/IconThemeName "Papirus-Adapta-Nokto-Maia"
Gtk/MenuBarAccel "F10"
Gtk/MenuImages 1
Gtk/ToolbarIconSize 3
Gtk/ToolbarStyle "icons"
Xft/Antialias 1
Xft/DPI 102400
Xft/Hinting 1
Xft/HintStyle "hintslight"
Xft/RGBA "rgb"

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,126 @@
#!/bin/sh
# base16-shell (https://github.com/chriskempson/base16-shell)
# Base16 Shell template by Chris Kempson (http://chriskempson.com)
# Burn scheme by Benjamin Bädorf
color00="1a/18/1a" # Base 00 - Black
color01="f8/5e/84" # Base 08 - Red
color02="9e/cd/6f" # Base 0B - Green
color03="e5/c4/63" # Base 0A - Yellow
color04="7a/cc/d7" # Base 0D - Blue
color05="ab/9d/f2" # Base 0E - Magenta
color06="ef/90/62" # Base 0C - Cyan
color07="e3/e1/e4" # Base 05 - White
color08="94/94/94" # Base 03 - Bright Black
color09=$color01 # Base 08 - Bright Red
color10=$color02 # Base 0B - Bright Green
color11=$color03 # Base 0A - Bright Yellow
color12=$color04 # Base 0D - Bright Blue
color13=$color05 # Base 0E - Bright Magenta
color14=$color06 # Base 0C - Bright Cyan
color15="ff/5f/5f" # Base 07 - Bright White
color16="df/59/23" # Base 09
color17="d7/00/00" # Base 0F
color18="2d/2a/2e" # Base 01
color19="30/30/30" # Base 02
color20="d3/d1/d4" # Base 04
color21="30/30/30" # Base 06
color_foreground="e3/e1/e4" # Base 05
color_background="1a/18/1a" # Base 00
if [ -n "$TMUX" ]; then
# Tell tmux to pass the escape sequences through
# (Source: http://permalink.gmane.org/gmane.comp.terminal-emulators.tmux.user/1324)
put_template() { printf '\033Ptmux;\033\033]4;%d;rgb:%s\033\033\\\033\\' $@; }
put_template_var() { printf '\033Ptmux;\033\033]%d;rgb:%s\033\033\\\033\\' $@; }
put_template_custom() { printf '\033Ptmux;\033\033]%s%s\033\033\\\033\\' $@; }
elif [ "${TERM%%[-.]*}" = "screen" ]; then
# GNU screen (screen, screen-256color, screen-256color-bce)
put_template() { printf '\033P\033]4;%d;rgb:%s\007\033\\' $@; }
put_template_var() { printf '\033P\033]%d;rgb:%s\007\033\\' $@; }
put_template_custom() { printf '\033P\033]%s%s\007\033\\' $@; }
elif [ "${TERM%%-*}" = "linux" ]; then
put_template() { [ $1 -lt 16 ] && printf "\e]P%x%s" $1 $(echo $2 | sed 's/\///g'); }
put_template_var() { true; }
put_template_custom() { true; }
else
put_template() { printf '\033]4;%d;rgb:%s\033\\' $@; }
put_template_var() { printf '\033]%d;rgb:%s\033\\' $@; }
put_template_custom() { printf '\033]%s%s\033\\' $@; }
fi
# 16 color space
put_template 0 $color00
put_template 1 $color01
put_template 2 $color02
put_template 3 $color03
put_template 4 $color04
put_template 5 $color05
put_template 6 $color06
put_template 7 $color07
put_template 8 $color08
put_template 9 $color09
put_template 10 $color10
put_template 11 $color11
put_template 12 $color12
put_template 13 $color13
put_template 14 $color14
put_template 15 $color15
# 256 color space
put_template 16 $color16
put_template 17 $color17
put_template 18 $color18
put_template 19 $color19
put_template 20 $color20
put_template 21 $color21
# foreground / background / cursor color
if [ -n "$ITERM_SESSION_ID" ]; then
# iTerm2 proprietary escape codes
put_template_custom Pg e3e1e4 # foreground
put_template_custom Ph 1a181a # background
put_template_custom Pi e3e1e4 # bold color
put_template_custom Pj 303030 # selection color
put_template_custom Pk e3e1e4 # selected text color
put_template_custom Pl e3e1e4 # cursor
put_template_custom Pm 1a181a # cursor text
else
put_template_var 10 $color_foreground
if [ "$BASE16_SHELL_SET_BACKGROUND" != false ]; then
put_template_var 11 $color_background
if [ "${TERM%%-*}" = "rxvt" ]; then
put_template_var 708 $color_background # internal border (rxvt)
fi
fi
put_template_custom 12 ";7" # cursor (reverse video)
fi
# clean up
unset -f put_template
unset -f put_template_var
unset -f put_template_custom
unset color00
unset color01
unset color02
unset color03
unset color04
unset color05
unset color06
unset color07
unset color08
unset color09
unset color10
unset color11
unset color12
unset color13
unset color14
unset color15
unset color16
unset color17
unset color18
unset color19
unset color20
unset color21
unset color_foreground
unset color_background

75
modules/user/.xinitrc Normal file
View file

@ -0,0 +1,75 @@
#!/bin/sh
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)
userresources=$HOME/.Xresources
usermodmap=$HOME/.config/xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap
DEFAULT_SESSION='i3 --shmlog-size 0'
xset -b
if [ -d $HOME/.fonts ]; then
xset +fp $HOME/.fonts
xset fp rehash
fi
# merge in defaults and keymaps
if [ -f $sysresources ]; then
xrdb -merge $sysresources
fi
if [ -f $sysmodmap ]; then
xmodmap $sysmodmap
fi
if [ -f "$userresources" ]; then
xrdb -merge "$userresources"
fi
if [ -f "$usermodmap" ]; then
xmodmap "$usermodmap"
fi
# start some nice programs
if [ -d /etc/X11/xinit/xinitrc.d ] ; then
for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
[ -x "$f" ] && . "$f"
done
unset f
fi
get_session(){
local dbus_args=(--sh-syntax --exit-with-session)
case $1 in
awesome) dbus_args+=(awesome) ;;
bspwm) dbus_args+=(bspwm-session) ;;
budgie) dbus_args+=(budgie-desktop) ;;
cinnamon) dbus_args+=(cinnamon-session) ;;
deepin) dbus_args+=(startdde) ;;
enlightenment) dbus_args+=(enlightenment_start) ;;
fluxbox) dbus_args+=(startfluxbox) ;;
gnome) dbus_args+=(gnome-session) ;;
i3|i3wm) dbus_args+=(i3 --shmlog-size 0) ;;
jwm) dbus_args+=(jwm) ;;
kde) dbus_args+=(startkde) ;;
lxde) dbus_args+=(startlxde) ;;
lxqt) dbus_args+=(lxqt-session) ;;
mate) dbus_args+=(mate-session) ;;
xfce) dbus_args+=(xfce4-session) ;;
openbox) dbus_args+=(openbox-session) ;;
*) dbus_args+=($DEFAULT_SESSION) ;;
esac
echo "dbus-launch ${dbus_args[*]}"
}
exec $(get_session)
xset r rate 660 25

View file

@ -20,6 +20,7 @@ in {
# paths it should manage.
home.username = psCfg.user.name;
home.homeDirectory = "/home/${psCfg.user.name}";
home.stateVersion = "22.11";
home.packages = with pkgs; [];

8
overlays/default.nix Normal file
View file

@ -0,0 +1,8 @@
[
(import ../pkgs)
(import ./blesh.nix)
(import ./manix.nix)
(import ./rnix-lsp.nix)
(import ./neovim-plugins.nix)
(import ./signal-desktop.nix)
]

View file

@ -2,7 +2,7 @@
config,
pkgs,
lib,
self,
flake,
...
}:
with lib; let
@ -10,13 +10,13 @@ with lib; let
xdg = config.home-manager.users."${psCfg.user.name}".xdg;
in {
age.secrets."cat-test.ovpn" = {
file = "${self}/secrets/cat-test.ovpn";
file = "${flake.self}/secrets/cat-test.ovpn";
mode = "700";
owner = psCfg.user.name;
};
age.secrets.".fwknoprc" = {
file = "${self}/secrets/.fwknoprc";
file = "${flake.self}/secrets/.fwknoprc";
mode = "600";
};

View file

@ -1,8 +1,8 @@
{
self,
config,
pkgs,
lib,
flake,
...
}: let
psCfg = config.pub-solar;
@ -16,7 +16,7 @@ in {
services.yubikey-agent.enable = true;
age.secrets.b12f-env-secrets = {
file = "${self}/secrets/b12f-env-secrets";
file = "${flake.self}/secrets/b12f-env-secrets";
mode = "400";
owner = psCfg.user.name;
};

View file

@ -2,7 +2,7 @@
config,
pkgs,
lib,
self,
flake,
...
}:
with lib; let
@ -117,7 +117,7 @@ in {
};
age.secrets."mopidy.conf" = {
file = "${self}/secrets/mopidy.conf";
file = "${flake.self}/secrets/mopidy.conf";
mode = "700";
owner = "b12f";
};

9
users/default.nix Normal file
View file

@ -0,0 +1,9 @@
{
flake = {
nixosModules = rec {
root = import ./root;
b12f = import ./b12f;
yule = import ./yule;
};
};
}