Compare commits
19 Commits
Author | SHA1 | Date | |
---|---|---|---|
200907c6c4 | |||
980952738f | |||
a5bbcb163c | |||
8200fc8758 | |||
b4177e3dee | |||
2d114632c2 | |||
ed1b7dc0a5 | |||
3727fc359b | |||
9cfe373129 | |||
f6905d27e8 | |||
8eb7008aeb | |||
c4b963cd7e | |||
9ddd8edd1f | |||
de8855153e | |||
dccfcaca64 | |||
f809873243 | |||
02d29fb799 | |||
0da2b3060f | |||
183490c955 |
4
.git-crypt/.gitattributes
vendored
4
.git-crypt/.gitattributes
vendored
|
@ -1,4 +0,0 @@
|
|||
# Do not edit this file. To specify the files to encrypt, create your own
|
||||
# .gitattributes file in the directory where your files are.
|
||||
* !filter !diff
|
||||
*.gpg binary
|
Binary file not shown.
2
.gitattributes
vendored
2
.gitattributes
vendored
|
@ -1,2 +0,0 @@
|
|||
secrets/** filter=git-crypt diff=git-crypt
|
||||
.gitattributes !filter !diff
|
28
cafe/gitea.nix
Normal file
28
cafe/gitea.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{ config, pkgs, ... }:
|
||||
{
|
||||
|
||||
services.gitea = {
|
||||
enable = true;
|
||||
appName = "My awesome Gitea server"; # Give the site a name
|
||||
database = {
|
||||
type = "sqlite3";
|
||||
};
|
||||
settings.server = {
|
||||
DOMAIN = "localhost";
|
||||
ROOT_URL = "http://localhost/";
|
||||
HTTP_PORT = 3001;
|
||||
};
|
||||
};
|
||||
|
||||
# [CONTAINER]
|
||||
boot.isContainer = true;
|
||||
|
||||
# [NETWORK]
|
||||
networking.hostName = "gitea";
|
||||
networking.useDHCP = false;
|
||||
networking.firewall.enable = true;
|
||||
networking.firewall.allowedTCPPorts = [ 3001 ];
|
||||
networking.firewall.allowedUDPPorts = [ ];
|
||||
|
||||
system.stateVersion = "23.11";
|
||||
}
|
62
cafe/host.nix
Normal file
62
cafe/host.nix
Normal file
|
@ -0,0 +1,62 @@
|
|||
{ pkgs, ... }:
|
||||
let gitea = {
|
||||
host = "10.10.0.1";
|
||||
local = "10.10.0.2";
|
||||
};
|
||||
in
|
||||
{
|
||||
# [CONTAINERS]
|
||||
containers.gitea = {
|
||||
autoStart = true;
|
||||
ephemeral = true;
|
||||
privateNetwork = true;
|
||||
hostAddress = gitea.host;
|
||||
localAddress = gitea.local;
|
||||
config = ./gitea.nix;
|
||||
};
|
||||
|
||||
# [NGINX]
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
recommendedProxySettings = true;
|
||||
virtualHosts = {
|
||||
"localhost" = {
|
||||
locations."/".proxyPass = "http://${gitea.local}:3001";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# [NETWORK]
|
||||
networking.firewall.allowedTCPPorts = [ 80 ];
|
||||
networking.firewall.allowedUDPPorts = [ ];
|
||||
|
||||
# VM test user
|
||||
users.users.test.isSystemUser = true ;
|
||||
users.users.test.initialPassword = "test";
|
||||
users.users.test.group = "test";
|
||||
users.groups.test = {};
|
||||
|
||||
console = {
|
||||
useXkbConfig = true;
|
||||
};
|
||||
|
||||
services.xserver = {
|
||||
xkb = {
|
||||
layout = "fox,sus";
|
||||
options = "ctrl:nocaps";
|
||||
extraLayouts.sus = {
|
||||
description = "Swedish US";
|
||||
languages = [ "se" ];
|
||||
symbolsFile = ../shared/sus.xkb;
|
||||
};
|
||||
extraLayouts.fox = {
|
||||
description = "Layout suitable to be used by a fox";
|
||||
languages = [ "se" ];
|
||||
symbolsFile = ../shared/fox.xkb;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
system.stateVersion = "23.11";
|
||||
|
||||
}
|
59
computational/configuration.nix
Normal file
59
computational/configuration.nix
Normal file
|
@ -0,0 +1,59 @@
|
|||
{ config, pkgs, ... }:
|
||||
{
|
||||
# [HARDWARE]
|
||||
imports =
|
||||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
driSupport32Bit = true;
|
||||
};
|
||||
|
||||
# [BOOT]
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.swraid.enable = true;
|
||||
boot.swraid.mdadmConf = ''
|
||||
ARRAY /dev/md/deppyPC:0 level=raid0 num-devices=2 metadata=1.2 name=deppyPC:0 UUID=ba6fef6e:972796a3:a331c87a:2d973f91
|
||||
devices=/dev/sda1,/dev/sdb1
|
||||
'';
|
||||
|
||||
# [AUDIO]
|
||||
environment.etc."pipewire/media-session.d/alsa-monitor.con".text = ''
|
||||
enabled = true
|
||||
|
||||
rules = {
|
||||
{
|
||||
matches = [
|
||||
{
|
||||
node.name = "alsa_output.usb-SMSL_SMSL_USB_AUDIO-00.analog-stereo"
|
||||
}
|
||||
]
|
||||
|
||||
actions = {
|
||||
update-props = {
|
||||
audio.format = "S32_LE"
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
'';
|
||||
|
||||
environment.etc."pipewire/pipewire.conf".text = builtins.readFile ./pipewire.conf;
|
||||
|
||||
|
||||
# [DESKTOP / XORG / WAYLAND]
|
||||
services.xserver = {
|
||||
desktopManager.plasma5.enable = true;
|
||||
displayManager.startx.enable = true;
|
||||
};
|
||||
|
||||
|
||||
# [NETWORKING]
|
||||
networking.hostName = "computational";
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
system.stateVersion = "23.11";
|
||||
}
|
308
computational/pipewire.conf
Normal file
308
computational/pipewire.conf
Normal file
|
@ -0,0 +1,308 @@
|
|||
context.properties = {
|
||||
## Configure properties in the system.
|
||||
#library.name.system = support/libspa-support
|
||||
#context.data-loop.library.name.system = support/libspa-support
|
||||
#support.dbus = true
|
||||
#link.max-buffers = 64
|
||||
link.max-buffers = 16 # version < 3 clients can't handle more
|
||||
#mem.warn-mlock = false
|
||||
#mem.allow-mlock = true
|
||||
#mem.mlock-all = false
|
||||
#clock.power-of-two-quantum = true
|
||||
#log.level = 2
|
||||
#cpu.zero.denormals = false
|
||||
|
||||
core.daemon = true # listening for socket connections
|
||||
core.name = pipewire-0 # core name and socket name
|
||||
|
||||
## Properties for the DSP configuration.
|
||||
# default.clock.rate = 48000
|
||||
default.clock.allowed-rates = [ 44100 48000 88200 96000, 176400 192000 352800 384000 705600 768000 ]
|
||||
default.clock.quantum = 1024
|
||||
default.clock.min-quantum = 128
|
||||
default.clock.max-quantum = 2048
|
||||
#default.clock.quantum-limit = 8192
|
||||
#default.video.width = 640
|
||||
#default.video.height = 480
|
||||
#default.video.rate.num = 25
|
||||
#default.video.rate.denom = 1
|
||||
#
|
||||
#settings.check-quantum = false
|
||||
#settings.check-rate = false
|
||||
#
|
||||
# These overrides are only applied when running in a vm.
|
||||
vm.overrides = {
|
||||
default.clock.min-quantum = 1024
|
||||
}
|
||||
|
||||
# keys checked below to disable module loading
|
||||
module.x11.bell = true
|
||||
# enables autoloading of access module, when disabled an alternative
|
||||
# access module needs to be loaded.
|
||||
module.access = true
|
||||
# enables autoloading of module-jackdbus-detect
|
||||
module.jackdbus-detect = true
|
||||
}
|
||||
|
||||
context.spa-libs = {
|
||||
#<factory-name regex> = <library-name>
|
||||
#
|
||||
# Used to find spa factory names. It maps an spa factory name
|
||||
# regular expression to a library name that should contain
|
||||
# that factory.
|
||||
#
|
||||
audio.convert.* = audioconvert/libspa-audioconvert
|
||||
avb.* = avb/libspa-avb
|
||||
api.alsa.* = alsa/libspa-alsa
|
||||
api.v4l2.* = v4l2/libspa-v4l2
|
||||
api.libcamera.* = libcamera/libspa-libcamera
|
||||
api.bluez5.* = bluez5/libspa-bluez5
|
||||
api.vulkan.* = vulkan/libspa-vulkan
|
||||
api.jack.* = jack/libspa-jack
|
||||
support.* = support/libspa-support
|
||||
#videotestsrc = videotestsrc/libspa-videotestsrc
|
||||
#audiotestsrc = audiotestsrc/libspa-audiotestsrc
|
||||
}
|
||||
|
||||
context.modules = [
|
||||
#{ name = <module-name>
|
||||
# ( args = { <key> = <value> ... } )
|
||||
# ( flags = [ ( ifexists ) ( nofail ) ] )
|
||||
# ( condition = [ { <key> = <value> ... } ... ] )
|
||||
#}
|
||||
#
|
||||
# Loads a module with the given parameters.
|
||||
# If ifexists is given, the module is ignored when it is not found.
|
||||
# If nofail is given, module initialization failures are ignored.
|
||||
# If condition is given, the module is loaded only when the context
|
||||
# properties all match the match rules.
|
||||
#
|
||||
|
||||
# Uses realtime scheduling to boost the audio thread priorities. This uses
|
||||
# RTKit if the user doesn't have permission to use regular realtime
|
||||
# scheduling. You can also clamp utilisation values to improve scheduling
|
||||
# on embedded and heterogeneous systems, e.g. Arm big.LITTLE devices.
|
||||
{ name = libpipewire-module-rt
|
||||
args = {
|
||||
nice.level = -11
|
||||
#rt.prio = 88
|
||||
#rt.time.soft = -1
|
||||
#rt.time.hard = -1
|
||||
#uclamp.min = 0
|
||||
#uclamp.max = 1024
|
||||
}
|
||||
flags = [ ifexists nofail ]
|
||||
}
|
||||
|
||||
# The native communication protocol.
|
||||
{ name = libpipewire-module-protocol-native
|
||||
args = {
|
||||
# List of server Unix sockets, and optionally permissions
|
||||
#sockets = [ { name = "pipewire-0" }, { name = "pipewire-0-manager" } ]
|
||||
}
|
||||
}
|
||||
|
||||
# The profile module. Allows application to access profiler
|
||||
# and performance data. It provides an interface that is used
|
||||
# by pw-top and pw-profiler.
|
||||
{ name = libpipewire-module-profiler }
|
||||
|
||||
# Allows applications to create metadata objects. It creates
|
||||
# a factory for Metadata objects.
|
||||
{ name = libpipewire-module-metadata }
|
||||
|
||||
# Creates a factory for making devices that run in the
|
||||
# context of the PipeWire server.
|
||||
{ name = libpipewire-module-spa-device-factory }
|
||||
|
||||
# Creates a factory for making nodes that run in the
|
||||
# context of the PipeWire server.
|
||||
{ name = libpipewire-module-spa-node-factory }
|
||||
|
||||
# Allows creating nodes that run in the context of the
|
||||
# client. Is used by all clients that want to provide
|
||||
# data to PipeWire.
|
||||
{ name = libpipewire-module-client-node }
|
||||
|
||||
# Allows creating devices that run in the context of the
|
||||
# client. Is used by the session manager.
|
||||
{ name = libpipewire-module-client-device }
|
||||
|
||||
# The portal module monitors the PID of the portal process
|
||||
# and tags connections with the same PID as portal
|
||||
# connections.
|
||||
{ name = libpipewire-module-portal
|
||||
flags = [ ifexists nofail ]
|
||||
}
|
||||
|
||||
# The access module can perform access checks and block
|
||||
# new clients.
|
||||
{ name = libpipewire-module-access
|
||||
args = {
|
||||
# Socket-specific access permissions
|
||||
#access.socket = { pipewire-0 = "default", pipewire-0-manager = "unrestricted" }
|
||||
|
||||
# Deprecated legacy mode (not socket-based),
|
||||
# for now enabled by default if access.socket is not specified
|
||||
#access.legacy = true
|
||||
}
|
||||
condition = [ { module.access = true } ]
|
||||
}
|
||||
|
||||
# Makes a factory for wrapping nodes in an adapter with a
|
||||
# converter and resampler.
|
||||
{ name = libpipewire-module-adapter }
|
||||
|
||||
# Makes a factory for creating links between ports.
|
||||
{ name = libpipewire-module-link-factory }
|
||||
|
||||
# Provides factories to make session manager objects.
|
||||
{ name = libpipewire-module-session-manager }
|
||||
|
||||
# Use libcanberra to play X11 Bell
|
||||
{ name = libpipewire-module-x11-bell
|
||||
args = {
|
||||
#sink.name = ""
|
||||
#sample.name = "bell-window-system"
|
||||
#x11.display = null
|
||||
#x11.xauthority = null
|
||||
}
|
||||
flags = [ ifexists nofail ]
|
||||
condition = [ { module.x11.bell = true } ]
|
||||
}
|
||||
{ name = libpipewire-module-jackdbus-detect
|
||||
args = {
|
||||
#jack.library = libjack.so.0
|
||||
#jack.server = null
|
||||
#jack.client-name = PipeWire
|
||||
#jack.connect = true
|
||||
#tunnel.mode = duplex # source|sink|duplex
|
||||
source.props = {
|
||||
#audio.channels = 2
|
||||
#midi.ports = 1
|
||||
#audio.position = [ FL FR ]
|
||||
# extra sink properties
|
||||
}
|
||||
sink.props = {
|
||||
#audio.channels = 2
|
||||
#midi.ports = 1
|
||||
#audio.position = [ FL FR ]
|
||||
# extra sink properties
|
||||
}
|
||||
}
|
||||
flags = [ ifexists nofail ]
|
||||
condition = [ { module.jackdbus-detect = true } ]
|
||||
}
|
||||
]
|
||||
|
||||
context.objects = [
|
||||
#{ factory = <factory-name>
|
||||
# ( args = { <key> = <value> ... } )
|
||||
# ( flags = [ ( nofail ) ] )
|
||||
# ( condition = [ { <key> = <value> ... } ... ] )
|
||||
#}
|
||||
#
|
||||
# Creates an object from a PipeWire factory with the given parameters.
|
||||
# If nofail is given, errors are ignored (and no object is created).
|
||||
# If condition is given, the object is created only when the context properties
|
||||
# all match the match rules.
|
||||
#
|
||||
#{ factory = spa-node-factory args = { factory.name = videotestsrc node.name = videotestsrc node.description = videotestsrc "Spa:Pod:Object:Param:Props:patternType" = 1 } }
|
||||
#{ factory = spa-device-factory args = { factory.name = api.jack.device foo=bar } flags = [ nofail ] }
|
||||
#{ factory = spa-device-factory args = { factory.name = api.alsa.enum.udev } }
|
||||
#{ factory = spa-node-factory args = { factory.name = api.alsa.seq.bridge node.name = Internal-MIDI-Bridge } }
|
||||
#{ factory = adapter args = { factory.name = audiotestsrc node.name = my-test node.description = audiotestsrc } }
|
||||
#{ factory = spa-node-factory args = { factory.name = api.vulkan.compute.source node.name = my-compute-source } }
|
||||
|
||||
# A default dummy driver. This handles nodes marked with the "node.always-driver"
|
||||
# property when no other driver is currently active. JACK clients need this.
|
||||
{ factory = spa-node-factory
|
||||
args = {
|
||||
factory.name = support.node.driver
|
||||
node.name = Dummy-Driver
|
||||
node.group = pipewire.dummy
|
||||
priority.driver = 20000
|
||||
#clock.id = monotonic # realtime | tai | monotonic-raw | boottime
|
||||
#clock.name = "clock.system.monotonic"
|
||||
}
|
||||
}
|
||||
{ factory = spa-node-factory
|
||||
args = {
|
||||
factory.name = support.node.driver
|
||||
node.name = Freewheel-Driver
|
||||
priority.driver = 19000
|
||||
node.group = pipewire.freewheel
|
||||
node.freewheel = true
|
||||
}
|
||||
}
|
||||
|
||||
# This creates a new Source node. It will have input ports
|
||||
# that you can link, to provide audio for this source.
|
||||
#{ factory = adapter
|
||||
# args = {
|
||||
# factory.name = support.null-audio-sink
|
||||
# node.name = "my-mic"
|
||||
# node.description = "Microphone"
|
||||
# media.class = "Audio/Source/Virtual"
|
||||
# audio.position = "FL,FR"
|
||||
# }
|
||||
#}
|
||||
|
||||
# This creates a single PCM source device for the given
|
||||
# alsa device path hw:0. You can change source to sink
|
||||
# to make a sink in the same way.
|
||||
#{ factory = adapter
|
||||
# args = {
|
||||
# factory.name = api.alsa.pcm.source
|
||||
# node.name = "alsa-source"
|
||||
# node.description = "PCM Source"
|
||||
# media.class = "Audio/Source"
|
||||
# api.alsa.path = "hw:0"
|
||||
# api.alsa.period-size = 1024
|
||||
# api.alsa.headroom = 0
|
||||
# api.alsa.disable-mmap = false
|
||||
# api.alsa.disable-batch = false
|
||||
# audio.format = "S16LE"
|
||||
# audio.rate = 48000
|
||||
# audio.channels = 2
|
||||
# audio.position = "FL,FR"
|
||||
# }
|
||||
#}
|
||||
|
||||
# Use the metadata factory to create metadata and some default values.
|
||||
#{ factory = metadata
|
||||
# args = {
|
||||
# metadata.name = my-metadata
|
||||
# metadata.values = [
|
||||
# { key = default.audio.sink value = { name = somesink } }
|
||||
# { key = default.audio.source value = { name = somesource } }
|
||||
# ]
|
||||
# }
|
||||
#}
|
||||
]
|
||||
|
||||
context.exec = [
|
||||
#{ path = <program-name>
|
||||
# ( args = "<arguments>" )
|
||||
# ( condition = [ { <key> = <value> ... } ... ] )
|
||||
#}
|
||||
#
|
||||
# Execute the given program with arguments.
|
||||
# If condition is given, the program is executed only when the context
|
||||
# properties all match the match rules.
|
||||
#
|
||||
# You can optionally start the session manager here,
|
||||
# but it is better to start it as a systemd service.
|
||||
# Run the session manager with -h for options.
|
||||
#
|
||||
#{ path = "/nix/store/n5azqf4qgng00pzdw0xzg7dqjfvsfcgs-pipewire-0.3.85/bin/pipewire-media-session" args = ""
|
||||
# condition = [ { exec.session-manager = null } { exec.session-manager = true } ] }
|
||||
#
|
||||
# You can optionally start the pulseaudio-server here as well
|
||||
# but it is better to start it as a systemd service.
|
||||
# It can be interesting to start another daemon here that listens
|
||||
# on another address with the -a option (eg. -a tcp:4713).
|
||||
#
|
||||
#{ path = "/nix/store/n5azqf4qgng00pzdw0xzg7dqjfvsfcgs-pipewire-0.3.85/bin/pipewire" args = "-c pipewire-pulse.conf"
|
||||
# condition = [ { exec.pipewire-pulse = null } { exec.pipewire-pulse = true } ] }
|
||||
]
|
200
flake.lock
200
flake.lock
|
@ -2,22 +2,22 @@
|
|||
"nodes": {
|
||||
"agda": {
|
||||
"inputs": {
|
||||
"flake-parts": "flake-parts",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1723809509,
|
||||
"narHash": "sha256-aC0Vc/YV+rodv1qG839rqNFBqoqy/AkgvLdHxymCIu4=",
|
||||
"lastModified": 1701366566,
|
||||
"narHash": "sha256-B8Jmjld0gGbkVO08GsovVqrUXCs8VfJ8UdM3sjHnzgM=",
|
||||
"owner": "agda",
|
||||
"repo": "agda",
|
||||
"rev": "df1a26d96683ebb06aa8476e4af6bbeddf23efbe",
|
||||
"rev": "4293e0a94d15acac915ab9088b2ec028f78d14a9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "agda",
|
||||
"ref": "v2.7.0",
|
||||
"ref": "v2.6.4.1",
|
||||
"repo": "agda",
|
||||
"type": "github"
|
||||
}
|
||||
|
@ -25,17 +25,17 @@
|
|||
"cornelis": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-utils": "flake-utils",
|
||||
"flake-utils": "flake-utils_2",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1715930772,
|
||||
"narHash": "sha256-gP32IWxjIApK0jxQn3Xorul5SXtMS2tq+K8Wj8afHgg=",
|
||||
"lastModified": 1712595875,
|
||||
"narHash": "sha256-KaAhKeESwOQ0R0vxeAO/CDPiPimiemoARyr0uIVTQ4w=",
|
||||
"owner": "isovector",
|
||||
"repo": "cornelis",
|
||||
"rev": "06d6020eed1a3520bb2887337dd5b27b1755968b",
|
||||
"rev": "9d3347e7d8589a28bcdd283001367d60bacf6b05",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -60,25 +60,22 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": "nixpkgs-lib"
|
||||
},
|
||||
"flake-utils": {
|
||||
"locked": {
|
||||
"lastModified": 1722555600,
|
||||
"narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "8471fe90ad337a8074e957b69ca4d0089218391d",
|
||||
"lastModified": 1678901627,
|
||||
"narHash": "sha256-U02riOqrKKzwjsxc/400XnElV+UtPUQWpANPlyazjH0=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "93a2b84fc4b70d9e089d029deacc3583435c2ed6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"flake-utils_2": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
|
@ -96,39 +93,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils_2": {
|
||||
"inputs": {
|
||||
"systems": "systems_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1710146030,
|
||||
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils_3": {
|
||||
"locked": {
|
||||
"lastModified": 1678901627,
|
||||
"narHash": "sha256-U02riOqrKKzwjsxc/400XnElV+UtPUQWpANPlyazjH0=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "93a2b84fc4b70d9e089d029deacc3583435c2ed6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
@ -136,137 +100,97 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1718530513,
|
||||
"narHash": "sha256-BmO8d0r+BVlwWtMLQEYnwmngqdXIuyFzMwvmTcLMee8=",
|
||||
"lastModified": 1712386041,
|
||||
"narHash": "sha256-dA82pOMQNnCJMAsPG7AXG35VmCSMZsJHTFlTHizpKWQ=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "a1fddf0967c33754271761d91a3d921772b30d0e",
|
||||
"rev": "d6bb9f934f2870e5cbc5b94c79e9db22246141ff",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "release-24.05",
|
||||
"ref": "release-23.11",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1728909085,
|
||||
"narHash": "sha256-WLxED18lodtQiayIPDE5zwAfkPJSjHJ35UhZ8h3cJUg=",
|
||||
"lastModified": 1712588820,
|
||||
"narHash": "sha256-y31s5idk3jMJMAVE4Ud9AdI7HT3CgTAeMTJ0StqKN7Y=",
|
||||
"owner": "NixOs",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "c0b1da36f7c34a7146501f684e9ebdf15d2bebf8",
|
||||
"rev": "d272ca50d1f7424fbfcd1e6f1c9e01d92f6da167",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOs",
|
||||
"ref": "nixos-24.05",
|
||||
"ref": "nixos-23.11",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-lib": {
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1722555339,
|
||||
"narHash": "sha256-uFf2QeW7eAHlYXuDktm9c25OxOyCoUOQmh5SZ9amE5Q=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
|
||||
}
|
||||
},
|
||||
"nixpkgs-unstable": {
|
||||
"locked": {
|
||||
"lastModified": 1728888510,
|
||||
"narHash": "sha256-nsNdSldaAyu6PE3YUA+YQLqUDJh+gRbBooMMekZJwvI=",
|
||||
"owner": "NixOs",
|
||||
"lastModified": 1711703276,
|
||||
"narHash": "sha256-iMUFArF0WCatKK6RzfUJknjem0H9m4KgorO/p3Dopkk=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "a3c0b3b21515f74fd2665903d4ce6bc4dc81c77c",
|
||||
"rev": "d8fe5e6c92d0d190646fb9f1056741a229980089",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOs",
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixprof": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils_3",
|
||||
"nixpkgs": [
|
||||
"nixpkgs-unstable"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1680079910,
|
||||
"narHash": "sha256-8KH3mZZVNB9rf42jSsllsJcs06JVxzgYkvmGgbSkMlI=",
|
||||
"owner": "Kha",
|
||||
"repo": "nixprof",
|
||||
"rev": "8a36221436d1a0f336ba8432dd8ffebbb82c3b29",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Kha",
|
||||
"repo": "nixprof",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"plasma-manager": {
|
||||
"inputs": {
|
||||
"home-manager": [
|
||||
"home-manager"
|
||||
],
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1724556439,
|
||||
"narHash": "sha256-gPR3sxkKxISUvydnqoj54znpUkK8av/HVFuFJuYUw3w=",
|
||||
"owner": "nix-community",
|
||||
"repo": "plasma-manager",
|
||||
"rev": "5c97fe8af2a2e561f14195ed357d8c451fdbff4c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "trunk",
|
||||
"repo": "plasma-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"agda": "agda",
|
||||
"cornelis": "cornelis",
|
||||
"flake-utils": "flake-utils_2",
|
||||
"home-manager": "home-manager",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||
"nixprof": "nixprof",
|
||||
"plasma-manager": "plasma-manager"
|
||||
"ssbm-nix": "ssbm-nix"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"slippi-desktop": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"lastModified": 1711346593,
|
||||
"narHash": "sha256-WWgGRT58w1a4UcEe924hqa4ZVodQtsbXC44aCOEj528=",
|
||||
"owner": "project-slippi",
|
||||
"repo": "slippi-desktop-app",
|
||||
"rev": "02f3f007cd03c6e2b0da57db65c90646efc04a86",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"owner": "project-slippi",
|
||||
"repo": "slippi-desktop-app",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_2": {
|
||||
"ssbm-nix": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"slippi-desktop": "slippi-desktop"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1712071998,
|
||||
"narHash": "sha256-k95NCkXJ61PGMFuqyMtfvP3yTLozED/7DkN+lBWK0gs=",
|
||||
"owner": "lytedev",
|
||||
"repo": "ssbm-nix",
|
||||
"rev": "eff966a97287d1d86b189d59a14bf744d86836b0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lytedev",
|
||||
"repo": "ssbm-nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
|
|
183
flake.nix
183
flake.nix
|
@ -1,139 +1,82 @@
|
|||
{
|
||||
|
||||
description = "My various NixOS configurations";
|
||||
description = "My various NixOs configurations";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOs/nixpkgs/nixos-24.05";
|
||||
nixpkgs-unstable.url = "github:NixOs/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager/release-24.05";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
agda = {
|
||||
url = "github:agda/agda/v2.7.0";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
cornelis = {
|
||||
url = "github:isovector/cornelis/";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
nixprof = {
|
||||
url = "github:Kha/nixprof";
|
||||
inputs.nixpkgs.follows = "nixpkgs-unstable";
|
||||
};
|
||||
plasma-manager = {
|
||||
url = "github:nix-community/plasma-manager/trunk";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
inputs.home-manager.follows = "home-manager";
|
||||
};
|
||||
nixpkgs.url = "github:NixOs/nixpkgs/nixos-23.11";
|
||||
home-manager.url = "github:nix-community/home-manager/release-23.11";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
agda.url = "github:agda/agda/v2.6.4.1";
|
||||
agda.inputs.nixpkgs.follows = "nixpkgs";
|
||||
cornelis.url = "github:isovector/cornelis/";
|
||||
cornelis.inputs.nixpkgs.follows = "nixpkgs";
|
||||
ssbm-nix.url = "github:lytedev/ssbm-nix";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, nixpkgs-unstable, home-manager, agda, cornelis, plasma-manager, flake-utils, nixprof }:
|
||||
outputs = { self, nixpkgs, home-manager, agda, cornelis, ssbm-nix }:
|
||||
let nix-config-module =
|
||||
{
|
||||
nix.registry.nixpkgs.flake = nixpkgs;
|
||||
nix.registry.unstable.flake = nixpkgs-unstable;
|
||||
system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev;
|
||||
};
|
||||
home-module =
|
||||
system: config: {
|
||||
rachel-home-module =
|
||||
({ pkgs, ... }:
|
||||
let system = pkgs.stdenv.system;
|
||||
in {
|
||||
home-manager = {
|
||||
sharedModules = [ plasma-manager.homeManagerModules.plasma-manager ];
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
users.${config.user} = import ./home-manager/all.nix {
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
unstable = import nixpkgs-unstable {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
extra = {
|
||||
agda = agda.packages.${system}.default;
|
||||
users.rachel = import ./home/rachel.nix {
|
||||
pkgs = pkgs;
|
||||
agda = agda.packages.${system}.Agda;
|
||||
cornelis = cornelis.packages.${system}.cornelis;
|
||||
cornelis-vim = cornelis.packages.${system}.cornelis-vim;
|
||||
rc2nix = plasma-manager.packages.${system}.rc2nix;
|
||||
nixprof = nixprof.packages.${system}.nixprof;
|
||||
sax2nf = self.packages.${system}.sax2nf;
|
||||
bqn-vim = self.packages.${system}.bqn-vim;
|
||||
bqn-nvim = self.packages.${system}.bqn-nvim;
|
||||
shell-menu = self.packages.${system}.shell-menu;
|
||||
pash = self.packages.${system}.pash;
|
||||
cpypsk = self.packages.${system}.cpypsk;
|
||||
renoise = self.packages.${system}.renoise;
|
||||
wall = self.packages.${system}.wall;
|
||||
protonmail-desktop = self.packages.${system}.protonmail-desktop;
|
||||
eyezoom = self.packages.${system}.eyezoom;
|
||||
};
|
||||
inherit config;
|
||||
slippi-netplay = ssbm-nix.packages.${system}.slippi-netplay;
|
||||
};
|
||||
};
|
||||
};
|
||||
user-system = import ./nixos/shared/user-system.nix;
|
||||
graphical = import ./nixos/shared/graphical.nix;
|
||||
graphical-with-conf = base: system: config: [
|
||||
nix-config-module
|
||||
home-manager.nixosModules.home-manager
|
||||
base
|
||||
(user-system system config)
|
||||
(graphical system config)
|
||||
(home-module system config)
|
||||
];
|
||||
in {
|
||||
|
||||
nixosConfigurations.lambda = nixpkgs.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = graphical-with-conf ./nixos/lambda/configuration.nix system {
|
||||
user = "rachel";
|
||||
steam = true;
|
||||
mcsr = false;
|
||||
i3-plasma = true;
|
||||
};
|
||||
};
|
||||
|
||||
nixosConfigurations.transient = nixpkgs.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = graphical-with-conf ./nixos/transient/configuration.nix system {
|
||||
user = "rachel";
|
||||
steam = true;
|
||||
mcsr = false;
|
||||
i3-plasma = true;
|
||||
};
|
||||
};
|
||||
|
||||
nixosConfigurations.computational = nixpkgs.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = graphical-with-conf ./nixos/computational/configuration.nix system {
|
||||
user = "rachel";
|
||||
steam = true;
|
||||
mcsr = true;
|
||||
i3-plasma = false;
|
||||
};
|
||||
};
|
||||
|
||||
keyboardLayouts.fox = ./resources/fox.xkb;
|
||||
keyboardLayouts.sus = ./resources/fox.xkb;
|
||||
|
||||
} // flake-utils.lib.eachDefaultSystem (system:
|
||||
let pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
in {
|
||||
packages = rec {
|
||||
bqn-vim = import ./pkgs/bqn-vim.nix { inherit pkgs; };
|
||||
bqn-nvim = import ./pkgs/bqn-nvim.nix { inherit pkgs; };
|
||||
sax2nf = import ./pkgs/sax2nf.nix { inherit pkgs; };
|
||||
shell-menu = import ./pkgs/shell-menu.nix { inherit pkgs; };
|
||||
pash = import ./pkgs/pash.nix { inherit pkgs; };
|
||||
cpypsk = import ./pkgs/cpypsk.nix { inherit pkgs pash; };
|
||||
renoise = import ./pkgs/renoise.nix { inherit pkgs; };
|
||||
wall = import ./pkgs/wall.nix { inherit pkgs; };
|
||||
protonmail-desktop = import ./pkgs/protonmail-desktop.nix { inherit pkgs; };
|
||||
eyezoom = import ./pkgs/eyezoom.nix { inherit pkgs; };
|
||||
};
|
||||
});
|
||||
}
|
||||
);
|
||||
in rec {
|
||||
|
||||
nixosConfigurations.lambda = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
nix-config-module
|
||||
ssbm-nix.nixosModule
|
||||
./lambda/configuration.nix
|
||||
./shared/desktop.nix
|
||||
home-manager.nixosModules.home-manager
|
||||
rachel-home-module
|
||||
];
|
||||
};
|
||||
|
||||
nixosConfigurations.computational = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
nix-config-module
|
||||
ssbm-nix.nixosModule
|
||||
./computational/configuration.nix
|
||||
./shared/desktop.nix
|
||||
home-manager.nixosModules.home-manager
|
||||
rachel-home-module
|
||||
];
|
||||
};
|
||||
|
||||
nixosConfigurations.cafe = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
nix-config-module
|
||||
./cafe/host.nix
|
||||
];
|
||||
|
||||
virtualisation.forwardPorts = [
|
||||
{ from = "host"; host.port = 80; guest.port = 8080; }
|
||||
];
|
||||
|
||||
};
|
||||
|
||||
keyboardLayouts.fox = ./shared/fox.xkb;
|
||||
|
||||
fonts.sax2nf = import ./shared/sax2nf.nix { pkgs = nixpkgs.legacyPackages.x86_64-linux; };
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,27 +0,0 @@
|
|||
{ pkgs, unstable, extra, config, ... }:
|
||||
let common = rec {
|
||||
username = config.user;
|
||||
homeDir = "/home/${username}";
|
||||
};
|
||||
in {
|
||||
imports = builtins.map (x: import x { inherit pkgs unstable extra common config; }) ([
|
||||
./applications.nix
|
||||
./fetch.nix
|
||||
./git.nix
|
||||
./gpg.nix
|
||||
./hm-settings.nix
|
||||
./launcher.nix
|
||||
./media.nix
|
||||
./neovim.nix
|
||||
./plasma.nix
|
||||
./shell.nix
|
||||
./ssh.nix
|
||||
./terminal.nix
|
||||
./tmux.nix
|
||||
./xdg-dirs.nix
|
||||
./xinitrc.nix
|
||||
] ++ (if config.i3-plasma then [
|
||||
./i3.nix
|
||||
./picom.nix
|
||||
] else []));
|
||||
}
|
|
@ -1,89 +0,0 @@
|
|||
{ pkgs, unstable, extra, config, ... }:
|
||||
{
|
||||
home.packages = (with pkgs; [
|
||||
unzip
|
||||
zip
|
||||
xz
|
||||
gzip
|
||||
bzip2
|
||||
p7zip
|
||||
usbutils
|
||||
pciutils
|
||||
nettools
|
||||
nmap
|
||||
arp-scan
|
||||
julia-bin
|
||||
(python3.withPackages (ps: with ps; [
|
||||
ipython
|
||||
matplotlib
|
||||
numpy
|
||||
scipy
|
||||
]))
|
||||
ghc
|
||||
haskell-language-server
|
||||
firefox
|
||||
gnupg
|
||||
discord
|
||||
dig
|
||||
xxd
|
||||
slack
|
||||
imagemagick
|
||||
ffmpeg
|
||||
yt-dlp
|
||||
libreoffice
|
||||
pass
|
||||
protonvpn-gui
|
||||
thunderbird
|
||||
tidal-hifi
|
||||
signal-desktop
|
||||
transmission-gtk
|
||||
xclip
|
||||
clinfo
|
||||
glxinfo
|
||||
vulkan-tools
|
||||
obs-studio
|
||||
file
|
||||
gimp
|
||||
bat
|
||||
steam
|
||||
steam-run
|
||||
rmapi
|
||||
lutris
|
||||
texlive.combined.scheme-full
|
||||
zulip
|
||||
rink
|
||||
typst
|
||||
ttyper
|
||||
idris2
|
||||
graalvm-ce
|
||||
vimv
|
||||
lean4
|
||||
remmina
|
||||
git-crypt
|
||||
vcv-rack
|
||||
nix-index
|
||||
kdenlive
|
||||
solaar
|
||||
fzf
|
||||
bottom
|
||||
virt-manager-qt
|
||||
wmctrl
|
||||
]) ++ [
|
||||
extra.agda
|
||||
unstable.zoom-us
|
||||
extra.sax2nf
|
||||
extra.cornelis
|
||||
unstable.kicad
|
||||
extra.renoise
|
||||
extra.nixprof
|
||||
extra.protonmail-desktop
|
||||
extra.pash
|
||||
]
|
||||
++ (if config.i3-plasma then [
|
||||
pkgs.i3
|
||||
pkgs.xwallpaper
|
||||
] else [])
|
||||
++ (if config.mcsr then [
|
||||
pkgs.prismlauncher
|
||||
] else []);
|
||||
}
|
|
@ -1,46 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.hyfetch = {
|
||||
enable = true;
|
||||
settings = {
|
||||
preset = "lesbian";
|
||||
mode = "rgb";
|
||||
color_align = {
|
||||
mode = "horizontal";
|
||||
};
|
||||
};
|
||||
};
|
||||
programs.fastfetch = {
|
||||
enable = true;
|
||||
settings = {
|
||||
logo = {
|
||||
type = "kitty-direct";
|
||||
source = ../resources/fetch.png;
|
||||
width = 32;
|
||||
height = 16;
|
||||
padding = {
|
||||
top = 1;
|
||||
left = 2;
|
||||
right = 0;
|
||||
};
|
||||
};
|
||||
modules = [
|
||||
"break"
|
||||
"title"
|
||||
"break"
|
||||
{ type = "host"; format = "{3}"; }
|
||||
{ type = "os"; format = "{2}"; }
|
||||
"de"
|
||||
{ type = "wm"; format = "{2}"; }
|
||||
"shell"
|
||||
"kernel"
|
||||
{ type = "cpu"; format = "{1}"; }
|
||||
{ type = "gpu"; format = "{1} {2}"; }
|
||||
{ type = "terminal"; format = "{5}"; }
|
||||
"terminalfont"
|
||||
"break"
|
||||
"colors"
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userName = "Rachel Lambda Samuelsson";
|
||||
userEmail = "depsterr@protonmail.com";
|
||||
extraConfig = {
|
||||
init.defaultBranch = "master";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
services.gpg-agent = {
|
||||
enable = true;
|
||||
pinentryPackage = pkgs.pinentry-qt;
|
||||
};
|
||||
}
|
|
@ -1,8 +0,0 @@
|
|||
{ common, ... }:
|
||||
{
|
||||
home = {
|
||||
username = common.username;
|
||||
homeDirectory = common.homeDir;
|
||||
stateVersion = "24.05";
|
||||
};
|
||||
}
|
|
@ -1,124 +0,0 @@
|
|||
{ extra, config, ... }:
|
||||
{
|
||||
home.file.".config/i3/config".text = ''
|
||||
# i3 config file (v4)
|
||||
|
||||
gaps inner 10px
|
||||
gaps outer 5px
|
||||
default_border pixel 3
|
||||
|
||||
bindsym Mod4+r exec --no-startup-id rofi -show drun
|
||||
bindsym Mod4+p exec --no-startup-id ${extra.cpypsk}
|
||||
bindsym Mod4+Return exec --no-startup-id wezterm
|
||||
bindsym Mod4+BackSpace exec --no-startup-id firefox
|
||||
bindsym --release Mod4+s exec --no-startup-id slock
|
||||
''
|
||||
+
|
||||
(if config.mcsr then ''
|
||||
bindsym Mod1+Prior exec --no-startup-id ${extra.eyezoom} eye
|
||||
bindsym Mod1+Next exec --no-startup-id ${extra.eyezoom} default
|
||||
bindsym Mod1+Home exec --no-startup-id ${extra.eyezoom} wide
|
||||
bindsym Mod1+End exec --no-startup-id ${extra.eyezoom} thin
|
||||
'' else "")
|
||||
+
|
||||
''
|
||||
# class border backgr. text indicator child_border
|
||||
client.focused #d79921 #d79921 #d79921 #d79921 #d79921
|
||||
client.focused_inactive #d79921 #d79921 #d79921 #d79921 #d79921
|
||||
client.unfocused #b57614 #b57614 #b57614 #b57614 #b57614
|
||||
client.urgent #cc241d #cc241d #cc241d #cc241d #cc241d
|
||||
|
||||
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +5%
|
||||
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -5%
|
||||
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle
|
||||
bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle
|
||||
|
||||
floating_modifier Mod4
|
||||
|
||||
tiling_drag modifier titlebar
|
||||
|
||||
bindsym Mod4+Shift+q kill
|
||||
bindsym Mod4+Shift+r restart
|
||||
|
||||
bindsym Mod4+t split toggle
|
||||
|
||||
bindsym Mod4+f fullscreen toggle
|
||||
|
||||
set $ws1 "1"
|
||||
set $ws2 "2"
|
||||
set $ws3 "3"
|
||||
set $ws4 "4"
|
||||
set $ws5 "5"
|
||||
set $ws6 "6"
|
||||
set $ws7 "7"
|
||||
set $ws8 "8"
|
||||
set $ws9 "9"
|
||||
|
||||
# switch to workspace
|
||||
bindsym Mod4+1 workspace number $ws1
|
||||
bindsym Mod4+2 workspace number $ws2
|
||||
bindsym Mod4+3 workspace number $ws3
|
||||
bindsym Mod4+4 workspace number $ws4
|
||||
bindsym Mod4+5 workspace number $ws5
|
||||
bindsym Mod4+6 workspace number $ws6
|
||||
bindsym Mod4+7 workspace number $ws7
|
||||
bindsym Mod4+8 workspace number $ws8
|
||||
bindsym Mod4+9 workspace number $ws9
|
||||
|
||||
# move focused container to workspace
|
||||
bindsym Mod4+Shift+1 move container to workspace number $ws1
|
||||
bindsym Mod4+Shift+2 move container to workspace number $ws2
|
||||
bindsym Mod4+Shift+3 move container to workspace number $ws3
|
||||
bindsym Mod4+Shift+4 move container to workspace number $ws4
|
||||
bindsym Mod4+Shift+5 move container to workspace number $ws5
|
||||
bindsym Mod4+Shift+6 move container to workspace number $ws6
|
||||
bindsym Mod4+Shift+7 move container to workspace number $ws7
|
||||
bindsym Mod4+Shift+8 move container to workspace number $ws8
|
||||
bindsym Mod4+Shift+9 move container to workspace number $ws9
|
||||
|
||||
bindsym Mod4+h focus left
|
||||
bindsym Mod4+j focus down
|
||||
bindsym Mod4+k focus up
|
||||
bindsym Mod4+l focus right
|
||||
|
||||
bindsym Mod4+Shift+h move left
|
||||
bindsym Mod4+Shift+j move down
|
||||
bindsym Mod4+Shift+k move up
|
||||
bindsym Mod4+Shift+l move right
|
||||
|
||||
bindsym Mod4+Control+h resize grow left
|
||||
bindsym Mod4+Control+j resize grow down
|
||||
bindsym Mod4+Control+k resize grow up
|
||||
bindsym Mod4+Control+l resize grow right
|
||||
|
||||
# plasma stuff
|
||||
exec --no-startup-id wmctrl -c Plasma
|
||||
for_window [title="Desktop @*"] kill; floating enable; border none
|
||||
|
||||
exec --no-startup-id picom -b
|
||||
|
||||
for_window [class="plasmashell"] floating enable
|
||||
for_window [class="Kmix"] floating enable; border none
|
||||
for_window [class="systemsettings"] floating enable
|
||||
for_window [class="spectacle"] floating enable
|
||||
for_window [class="kruler"] floating enable; border none
|
||||
for_window [class="Plasma"] floating enable; border none
|
||||
for_window [class="Klipper"] floating enable; border none
|
||||
for_window [class="krunner"] floating enable; border none
|
||||
for_window [class="Plasmoidviewer"] floating enable; border none
|
||||
for_window [title="plasma-desktop"] floating enable; border none
|
||||
for_window [class="plasmashell" window_type="notification"] floating enable, border none
|
||||
no_focus [class="plasmashell" window_type="notification"]
|
||||
|
||||
for_window [window_role="pop-up"] floating enable
|
||||
for_window [window_role="bubble"] floating enable
|
||||
for_window [window_role="task_dialog"] floating enable
|
||||
for_window [window_role="Preferences"] floating enable
|
||||
for_window [window_role="About"] floating enable
|
||||
for_window [window_type="dialog"] floating enable
|
||||
for_window [window_type="menu"] floating enable
|
||||
for_window [instance="__scratchpad"] floating enable
|
||||
|
||||
exec --no-startup-id xwallpaper --focus ${extra.wall}
|
||||
'';
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.rofi = {
|
||||
enable = true;
|
||||
theme = ../resources/rofi-theme/spotlight-dark.rasi;
|
||||
};
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.mpv = {
|
||||
enable = true;
|
||||
config = {
|
||||
hwdec = "auto-safe";
|
||||
vo = "gpu";
|
||||
profile = "gpu-hq";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,189 +0,0 @@
|
|||
{ pkgs, extra, ... }:
|
||||
{
|
||||
programs.neovim = {
|
||||
defaultEditor = true;
|
||||
enable = true;
|
||||
vimAlias = true;
|
||||
extraLuaConfig = ''
|
||||
require('Comment').setup()
|
||||
require('nvim-surround').setup()
|
||||
require('numb').setup()
|
||||
local lspcfg = require('lspconfig')
|
||||
lspcfg.typst_lsp.setup({
|
||||
cmd = { '${pkgs.typst-lsp}/bin/typst-lsp' },
|
||||
})
|
||||
lspcfg.rust_analyzer.setup({})
|
||||
lspcfg.hls.setup({})
|
||||
lspcfg.pyright.setup({
|
||||
cmd = { '${pkgs.nodePackages.pyright}/bin/pyright-langserver', '--stdio' },
|
||||
})
|
||||
lspcfg.nixd.setup({
|
||||
cmd = { '${pkgs.nixd}/bin/nixd' },
|
||||
})
|
||||
lspcfg.ltex.setup({
|
||||
cmd = { '${pkgs.ltex-ls}/bin/ltex-ls' },
|
||||
settings = {
|
||||
ltex = {
|
||||
language = 'auto'
|
||||
}
|
||||
}
|
||||
})
|
||||
lspcfg.clangd.setup({
|
||||
cmd = { '${pkgs.clang-tools}/bin/clangd' },
|
||||
})
|
||||
lspcfg.ocamllsp.setup({})
|
||||
lspcfg.purescriptls.setup({})
|
||||
lspcfg.volar.setup({})
|
||||
lspcfg.tsserver.setup({
|
||||
init_options = {
|
||||
plugins = {
|
||||
{
|
||||
name = "@vue/typescript-plugin",
|
||||
location = "node_modules/@vue/typescript-plugin",
|
||||
languages = {"javascript", "typescript", "vue"},
|
||||
},
|
||||
},
|
||||
},
|
||||
filetypes = {
|
||||
"javascript",
|
||||
"typescript",
|
||||
"vue",
|
||||
},
|
||||
})
|
||||
require('orgmode').setup({})
|
||||
require('lean').setup({
|
||||
mappings = true,
|
||||
})
|
||||
require('lualine').setup {
|
||||
options = {
|
||||
icons_enabled = true,
|
||||
theme = 'gruvbox',
|
||||
component_separators = { left = "", right = ""},
|
||||
section_separators = { left = "", right = ""},
|
||||
always_divide_middle = true,
|
||||
globalstatus = false,
|
||||
refresh = {
|
||||
statusline = 1000,
|
||||
tabline = 1000,
|
||||
winbar = 1000,
|
||||
}
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {'mode'},
|
||||
lualine_b = { {
|
||||
'diagnostics',
|
||||
always_visible = true,
|
||||
on_click = function(n,b,m)
|
||||
vim.diagnostic.goto_next()
|
||||
end
|
||||
} },
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'encoding', 'filetype'},
|
||||
lualine_y = {'progress'},
|
||||
lualine_z = {'location'}
|
||||
},
|
||||
inactive_sections = {
|
||||
lualine_a = {},
|
||||
lualine_b = {},
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'location'},
|
||||
lualine_y = {},
|
||||
lualine_z = {}
|
||||
},
|
||||
}
|
||||
|
||||
vim.api.nvim_create_autocmd('LspAttach', {
|
||||
callback = function(args)
|
||||
local opts = { buffer = args.buf }
|
||||
vim.keymap.set('n', 'K', vim.lsp.buf.hover, opts)
|
||||
vim.keymap.set('n', '<localleader>r', vim.lsp.buf.rename, opts)
|
||||
vim.keymap.set('n', '<localleader>a', vim.lsp.buf.code_action, opts)
|
||||
vim.keymap.set('n', '<localleader>gd', vim.lsp.buf.definition, opts)
|
||||
vim.keymap.set('n', '<localleader>gi', vim.lsp.buf.implementation, opts)
|
||||
vim.keymap.set('n', '<localleader>gr', vim.lsp.buf.references, opts)
|
||||
vim.keymap.set('n', '<localleader>e', vim.diagnostic.open_float, opts)
|
||||
vim.keymap.set('n', '<localleader>n', vim.diagnostic.goto_next, opts)
|
||||
vim.keymap.set('n', '<localleader>N', vim.diagnostic.goto_prev, opts)
|
||||
vim.keymap.set('i', '<C-n>', vim.lsp.omnifunc, opts)
|
||||
end,
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd({ "BufNew"
|
||||
, "TextChanged"
|
||||
, "TextChangedI"
|
||||
, "TextChangedP"
|
||||
, "TextChangedT"
|
||||
}, {
|
||||
callback = function(args)
|
||||
vim.diagnostic.disable(args.buf)
|
||||
end
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd({"BufWrite"}, {
|
||||
callback = function(args)
|
||||
vim.diagnostic.enable(args.buf)
|
||||
end
|
||||
})
|
||||
'';
|
||||
extraConfig = ''
|
||||
set rnu nu
|
||||
set ts=2 sw=2 expandtab
|
||||
set clipboard=unnamedplus
|
||||
set laststatus=3 noshowmode
|
||||
set signcolumn=no
|
||||
set linebreak
|
||||
let g:cornelis_use_global_binary = 1
|
||||
set conceallevel=2 concealcursor=nc
|
||||
colorscheme gruvbox
|
||||
hi Normal guibg=NONE ctermbg=NONE
|
||||
|
||||
let maplocalleader="!"
|
||||
let g:bqn_prefix_key="!"
|
||||
runtime agda-input.vim
|
||||
call cornelis#bind_input(" ", "!")
|
||||
call cornelis#bind_input("exc", "!")
|
||||
|
||||
inoremap <C-Space> <Esc>
|
||||
|
||||
nnoremap j gj
|
||||
nnoremap k gk
|
||||
nnoremap gj j
|
||||
nnoremap gk k
|
||||
|
||||
au BufRead,BufNewFile *.agda call AgdaFiletype()
|
||||
au BufRead,BufNewFile *.lagda.* call AgdaFiletype()
|
||||
function! AgdaFiletype()
|
||||
nnoremap <buffer> <localleader>l :CornelisLoad<CR>
|
||||
nnoremap <buffer> <localleader>r :CornelisRefine<CR>
|
||||
nnoremap <buffer> <localleader>c :CornelisMakeCase<CR>
|
||||
nnoremap <buffer> <localleader>, :CornelisTypeContext<CR>
|
||||
nnoremap <buffer> <localleader>. :CornelisTypeContextInfer<CR>
|
||||
nnoremap <buffer> <localleader>d :CornelisTypeInfer<CR>
|
||||
nnoremap <buffer> <localleader>s :CornelisSolve<CR>
|
||||
nnoremap <buffer> <localleader>a :CornelisAuto<CR>
|
||||
nnoremap <buffer> gd :CornelisGoToDefinition<CR>
|
||||
nnoremap <buffer> <localleader>b :CornelisPrevGoal<CR>
|
||||
nnoremap <buffer> <localleader>f :CornelisNextGoal<CR>
|
||||
nnoremap <buffer> <localleader>u :CornelisIgnoreAbstract<CR>
|
||||
nnoremap <buffer> <localleader><space> :CornelisGive<CR>
|
||||
endfunction
|
||||
'';
|
||||
plugins = (with pkgs.vimPlugins; [
|
||||
nvim-surround
|
||||
comment-nvim
|
||||
vimtex
|
||||
gruvbox-nvim
|
||||
nvim-lspconfig
|
||||
idris2-vim
|
||||
numb-nvim
|
||||
typst-vim
|
||||
orgmode
|
||||
lean-nvim
|
||||
lualine-nvim
|
||||
]) ++ [
|
||||
extra.cornelis-vim
|
||||
extra.bqn-vim
|
||||
extra.bqn-nvim
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
services.picom = {
|
||||
enable = true;
|
||||
backend = "glx";
|
||||
settings.refresh-rate = "144";
|
||||
vSync = false;
|
||||
};
|
||||
}
|
|
@ -1,143 +0,0 @@
|
|||
{ extra, config, ... }:
|
||||
{
|
||||
programs.plasma = {
|
||||
enable = true;
|
||||
overrideConfig = true;
|
||||
|
||||
workspace = {
|
||||
lookAndFeel = "org.kde.breezedark.desktop";
|
||||
} // (if config.i3-plasma then {} else {
|
||||
wallpaper = "${extra.wall}";
|
||||
});
|
||||
|
||||
kscreenlocker = {
|
||||
appearance.wallpaper = "${extra.wall}";
|
||||
};
|
||||
|
||||
hotkeys.commands = if config.i3-plasma then {} else ({
|
||||
"launch-terminal" = {
|
||||
name = "Launch terminal";
|
||||
key = "Meta+Return";
|
||||
command = "wezterm";
|
||||
};
|
||||
|
||||
|
||||
"cpypsk" = {
|
||||
name = "Launch cpypsk";
|
||||
key = "Meta+p";
|
||||
command = "${extra.cpypsk}";
|
||||
};
|
||||
} // (if config.mcsr then {
|
||||
"eye" = {
|
||||
name = "eye zoom";
|
||||
key = "Alt+PgUp";
|
||||
command = "${extra.eyezoom} eye";
|
||||
};
|
||||
|
||||
"default" = {
|
||||
name = "default zoom";
|
||||
key = "Alt+PgDown";
|
||||
command = "${extra.eyezoom} default";
|
||||
};
|
||||
|
||||
"thin" = {
|
||||
name = "thin zoom";
|
||||
key = "Alt+End";
|
||||
command = "${extra.eyezoom} tiktok";
|
||||
};
|
||||
|
||||
"wide" = {
|
||||
name = "wide zoom";
|
||||
key = "Alt+Home";
|
||||
command = "${extra.eyezoom} wide";
|
||||
};
|
||||
} else {}));
|
||||
|
||||
fonts = {
|
||||
general = {
|
||||
family = "SAX2 Nerd Font";
|
||||
pointSize = 10;
|
||||
};
|
||||
};
|
||||
|
||||
powerdevil = {
|
||||
AC.whenLaptopLidClosed = "hibernate";
|
||||
battery.whenLaptopLidClosed = "hibernate";
|
||||
lowBattery.whenLaptopLidClosed = "hibernate";
|
||||
};
|
||||
|
||||
panels = [
|
||||
{
|
||||
location = if config.i3-plasma then "top" else "bottom";
|
||||
floating = true;
|
||||
height = if config.i3-plasma then 36 else 44;
|
||||
widgets = let
|
||||
clock = {
|
||||
digitalClock = {
|
||||
calendar.firstDayOfWeek = "monday";
|
||||
time.format = "24h";
|
||||
};
|
||||
};
|
||||
spacer = {
|
||||
name = "org.kde.plasma.panelspacer";
|
||||
config = { General.expanding = true; };
|
||||
};
|
||||
nolaunchtasks = {
|
||||
name = "org.kde.plasma.icontasks";
|
||||
config = { General.launchers = [ ]; };
|
||||
};
|
||||
launchtasks = {
|
||||
name = "org.kde.plasma.icontasks";
|
||||
config = {
|
||||
General.launchers = [
|
||||
"applications:thunderbird.desktop"
|
||||
"applications:org.wezfurlong.wezterm.desktop"
|
||||
"applications:firefox.desktop"
|
||||
"applications:discord.desktop"
|
||||
];
|
||||
};
|
||||
};
|
||||
kickoff = {
|
||||
name = "org.kde.plasma.kickoff";
|
||||
config = {
|
||||
General.icon = "nix-snowflake-white";
|
||||
};
|
||||
};
|
||||
systray = {
|
||||
systemTray.items = {
|
||||
shown = [
|
||||
"org.kde.plasma.battery"
|
||||
"org.kde.plasma.bluetooth"
|
||||
"org.kde.plasma.networkmanagement"
|
||||
"org.kde.plasma.volume"
|
||||
];
|
||||
};
|
||||
};
|
||||
in if config.i3-plasma then [
|
||||
clock
|
||||
spacer
|
||||
nolaunchtasks
|
||||
systray
|
||||
] else [
|
||||
kickoff
|
||||
launchtasks
|
||||
systray
|
||||
clock
|
||||
];
|
||||
}
|
||||
];
|
||||
|
||||
configFile."kcminputrc" = {
|
||||
"Mouse"."X11LibInputXAccelProfileFlat" = true;
|
||||
"Mouse"."XLbInptPointerAcceleration" = 0;
|
||||
};
|
||||
|
||||
configFile."startkderc" = if config.i3-plasma then {
|
||||
"General"."systemdBoot" = false; # needed to use i3 in place of KWin
|
||||
} else {};
|
||||
};
|
||||
|
||||
home.packages = [
|
||||
extra.rc2nix
|
||||
];
|
||||
}
|
|
@ -1,85 +0,0 @@
|
|||
{ pkgs, common, ... }:
|
||||
{
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
enableCompletion = false; # manage completions ourself
|
||||
dotDir = ".config/zsh";
|
||||
history.share = false;
|
||||
shellAliases = {
|
||||
x = "startx";
|
||||
rm = "rm -i";
|
||||
cal = "cal -m";
|
||||
ls = "${pkgs.eza}/bin/eza --icons --color --git-repos";
|
||||
cd = "z";
|
||||
};
|
||||
envExtra = ''
|
||||
PROMPT=$'%B%n%b@%B%m%b: %~\nλ '
|
||||
export BROWSER=firefox
|
||||
export XINITRC="${common.homeDir}/bin/xinitrc"
|
||||
export XAUTHORITY="${common.homeDir}/.local/share/Xauthority"
|
||||
export PASH_KEYID="3E4A909C8FEF6E3783699C79DFC26EF8EDAD6D71"
|
||||
export QT_AUTO_SCREEN_FACTOR=1
|
||||
export PATH="${common.homeDir}/bin:$PATH"
|
||||
'';
|
||||
sessionVariables = {
|
||||
DIRENV_LOG_FORMAT = "";
|
||||
};
|
||||
initExtra = ''
|
||||
autoload -Uz compinit
|
||||
|
||||
compinit -C
|
||||
(exec compinit &)
|
||||
|
||||
_comp_options+=(globdots)
|
||||
|
||||
setopt autocd
|
||||
setopt noautomenu
|
||||
setopt nomenucomplete
|
||||
setopt TRANSIENT_RPROMPT
|
||||
|
||||
nix-subcommand() {
|
||||
cmd="$1"
|
||||
shift
|
||||
pkgs=()
|
||||
for pkg in "$@"; do
|
||||
shift
|
||||
[ "$pkg" = -- ] && break
|
||||
[ "$pkg" = "''${pkg##*#}" ] && pkg="nixpkgs#$pkg"
|
||||
pkgs+="$pkg"
|
||||
done
|
||||
export NIXPKGS_ALLOW_UNFREE=1 NIXPKGS_ALLOW_BROKEN=1
|
||||
nix "$cmd" --impure "''${pkgs[@]}" -- "$@"
|
||||
}
|
||||
|
||||
shell() { nix-subcommand "shell" "$@" }
|
||||
run() { nix-subcommand "run" "$@" }
|
||||
build() { nix-subcommand "build" "$@" }
|
||||
|
||||
KEYTIMEOUT=1
|
||||
MODE_INDICATOR_VICMD='%K{10}%F{8}%B NORMAL %k%f%b'
|
||||
MODE_INDICATOR_REPLACE='%K{9}%F{8}%B REPLACE %k%f%b'
|
||||
MODE_INDICATOR_SEARCH='%K{13}%F{8}%B SEARCH %k%f%b'
|
||||
MODE_INDICATOR_VISUAL='%K{12}%F{8}%B VISUAL %k%f%b'
|
||||
MODE_INDICATOR_VLINE='%K{12}%F{8}%B V-LINE %k%f%b'
|
||||
'';
|
||||
plugins = [
|
||||
{
|
||||
name = "zsh-vim-mode";
|
||||
file = "zsh-vim-mode.plugin.zsh";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "softmoth";
|
||||
repo = "zsh-vim-mode";
|
||||
rev = "1f9953b7d6f2f0a8d2cb8e8977baa48278a31eab";
|
||||
sha256 = "sha256-a+6EWMRY1c1HQpNtJf5InCzU7/RphZjimLdXIXbO6cQ=";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
programs.zoxide = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
|
@ -1,39 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.ssh = {
|
||||
enable = true;
|
||||
matchBlocks = {
|
||||
remarkable = {
|
||||
hostname = "10.11.99.1";
|
||||
user = "root";
|
||||
};
|
||||
lazarus = {
|
||||
hostname = "rachel.cafe";
|
||||
user = "deppy";
|
||||
};
|
||||
zelda = {
|
||||
hostname = "zelda.dhack.se";
|
||||
user = "dhack";
|
||||
};
|
||||
link = {
|
||||
hostname = "link.dhack.se";
|
||||
user = "dhack";
|
||||
};
|
||||
medli = {
|
||||
hostname = "pub.dhack.se";
|
||||
user = "hacke";
|
||||
port = 222;
|
||||
};
|
||||
makar = {
|
||||
hostname = "pub.dhack.se";
|
||||
user = "root";
|
||||
port = 223;
|
||||
};
|
||||
ganon = {
|
||||
hostname = "ganon.dhack.se";
|
||||
user = "lambda";
|
||||
port = 222;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.wezterm = {
|
||||
enable = true;
|
||||
enableBashIntegration = false;
|
||||
enableZshIntegration = false;
|
||||
extraConfig = builtins.readFile ./wezterm.lua;
|
||||
};
|
||||
}
|
|
@ -1,56 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
clock24 = true;
|
||||
escapeTime = 0;
|
||||
keyMode = "vi";
|
||||
mouse = false;
|
||||
shortcut = "a";
|
||||
extraConfig = ''
|
||||
bind h split -hb -c '#{pane_current_path}'
|
||||
bind j split -v -c '#{pane_current_path}'
|
||||
bind k split -vb -c '#{pane_current_path}'
|
||||
bind l split -h -c '#{pane_current_path}'
|
||||
|
||||
is_vim="ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?\.?(view|n?vim?x?)(-wrapped)?(diff)?$'"
|
||||
|
||||
bind-key -n 'C-h' if-shell "$is_vim" 'send-keys C-h' 'select-pane -L'
|
||||
bind-key -n 'C-j' if-shell "$is_vim" 'send-keys C-j' 'select-pane -D'
|
||||
bind-key -n 'C-k' if-shell "$is_vim" 'send-keys C-k' 'select-pane -U'
|
||||
bind-key -n 'C-l' if-shell "$is_vim" 'send-keys C-l' 'select-pane -R'
|
||||
|
||||
bind-key -T copy-mode-vi 'C-h' select-pane -L
|
||||
bind-key -T copy-mode-vi 'C-j' select-pane -D
|
||||
bind-key -T copy-mode-vi 'C-k' select-pane -U
|
||||
bind-key -T copy-mode-vi 'C-l' select-pane -R
|
||||
|
||||
bind -n 'M-h' if-shell "$is_vim" 'send-keys M-h' 'resize-pane -L 1'
|
||||
bind -n 'M-j' if-shell "$is_vim" 'send-keys M-j' 'resize-pane -D 1'
|
||||
bind -n 'M-k' if-shell "$is_vim" 'send-keys M-k' 'resize-pane -U 1'
|
||||
bind -n 'M-l' if-shell "$is_vim" 'send-keys M-l' 'resize-pane -R 1'
|
||||
|
||||
bind-key -T copy-mode-vi M-h resize-pane -L 1
|
||||
bind-key -T copy-mode-vi M-j resize-pane -D 1
|
||||
bind-key -T copy-mode-vi M-k resize-pane -U 1
|
||||
bind-key -T copy-mode-vi M-l resize-pane -R 1
|
||||
|
||||
set -g pane-border-style bg=default
|
||||
set -g pane-border-style fg="#1D1F21"
|
||||
set -g pane-active-border-style bg=default
|
||||
set -g pane-active-border-style fg="#333333"
|
||||
|
||||
set-option -g status on
|
||||
set-option -g status-style bg=default
|
||||
set-option -g status-style fg="#ef7627"
|
||||
set-option -g status-interval 2
|
||||
set-option -g status-justify "centre"
|
||||
set-option -g status-right " λ "
|
||||
|
||||
set -g status-interval 1
|
||||
set-window-option -g window-status-separator "-"
|
||||
set-window-option -g window-status-current-format " #[fg=#b55690 bold]!![ #{b:pane_current_path}/ ] #{b:window_index} $ #{b:pane_current_command}!! "
|
||||
set-window-option -g window-status-format " #{b:window_index} [ #{b:pane_current_path}/ ] #{b:pane_current_command} "
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,95 +0,0 @@
|
|||
local wezterm = require 'wezterm'
|
||||
local config = wezterm.config_builder()
|
||||
|
||||
act = wezterm.action
|
||||
|
||||
config.color_scheme = 'Gruvbox dark, hard (base16)'
|
||||
config.use_fancy_tab_bar = false
|
||||
config.hide_tab_bar_if_only_one_tab = true
|
||||
config.force_reverse_video_cursor = true
|
||||
|
||||
config.window_padding = {
|
||||
left = 4,
|
||||
right = 4,
|
||||
top = 4,
|
||||
bottom = 4,
|
||||
}
|
||||
|
||||
config.inactive_pane_hsb = {
|
||||
saturation = 0.9,
|
||||
brightness = 0.8,
|
||||
}
|
||||
|
||||
config.window_background_opacity = 0.95
|
||||
config.colors = { tab_bar = { background = 'rgba(29, 32, 33, 95%)' } }
|
||||
|
||||
|
||||
font = wezterm.font_with_fallback {
|
||||
'SAX2 Nerd Font',
|
||||
'Fira Code',
|
||||
'Noto Mono',
|
||||
}
|
||||
|
||||
config.font = font
|
||||
|
||||
config.font_rules = {
|
||||
{
|
||||
italic = true,
|
||||
font = font,
|
||||
}
|
||||
}
|
||||
|
||||
config.adjust_window_size_when_changing_font_size = false
|
||||
|
||||
config.leader = { key = 'a', mods = 'CTRL', timeout_milliseconds = 700 }
|
||||
|
||||
config.keys = {
|
||||
{
|
||||
key = 'a',
|
||||
mods = 'LEADER|CTRL',
|
||||
action = act.SendKey { key = 'a', mods = 'CTRL' },
|
||||
},
|
||||
{
|
||||
key = 'c',
|
||||
mods = 'LEADER',
|
||||
action = act.SpawnTab "CurrentPaneDomain",
|
||||
},
|
||||
{
|
||||
key = 'n',
|
||||
mods = 'LEADER',
|
||||
action = act.ActivateTabRelative(1),
|
||||
},
|
||||
{
|
||||
key = 'p',
|
||||
mods = 'LEADER',
|
||||
action = act.ActivateTabRelative(-1),
|
||||
},
|
||||
}
|
||||
|
||||
for i = 1, 8 do
|
||||
table.insert(config.keys, {
|
||||
key = tostring(i),
|
||||
mods = 'ALT',
|
||||
action = act.ActivateTab(i - 1),
|
||||
})
|
||||
end
|
||||
|
||||
for key, dir in pairs({ h = 'Left', j = 'Down', k = 'Up', l = 'Right' }) do
|
||||
table.insert(config.keys, {
|
||||
key = key,
|
||||
mods = 'ALT',
|
||||
action = act.AdjustPaneSize { dir, 1 },
|
||||
})
|
||||
table.insert(config.keys, {
|
||||
key = key,
|
||||
mods = 'CTRL',
|
||||
action = act.ActivatePaneDirection(dir),
|
||||
})
|
||||
table.insert(config.keys, {
|
||||
key = key,
|
||||
mods = 'LEADER',
|
||||
action = act.SplitPane { direction = dir },
|
||||
})
|
||||
end
|
||||
|
||||
return config
|
|
@ -1,15 +0,0 @@
|
|||
{ common, ... }:
|
||||
{
|
||||
xdg.userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
desktop = "${common.homeDir}";
|
||||
documents = "${common.homeDir}/doc";
|
||||
download = "${common.homeDir}/dwn";
|
||||
music = "${common.homeDir}/music";
|
||||
pictures = "${common.homeDir}/img";
|
||||
publicShare = "${common.homeDir}/srv";
|
||||
templates = "${common.homeDir}/doc/templates";
|
||||
videos = "${common.homeDir}/vid";
|
||||
};
|
||||
}
|
|
@ -1,29 +0,0 @@
|
|||
{ extra, config, ... }:
|
||||
{
|
||||
home.file."bin/xinitrc" = {
|
||||
executable = true;
|
||||
text = ''
|
||||
#!/bin/sh -e
|
||||
cd "$HOME"
|
||||
|
||||
if test -z "$DBUS_SESSION_BUS_ADDRESS"; then
|
||||
eval $(dbus-launch --exit-with-session --sh-syntax)
|
||||
fi
|
||||
systemctl --user import-environment DISPLAY XAUTHORITY
|
||||
|
||||
if command -v dbus-update-activation-environment >/dev/null 2>&1; then
|
||||
dbus-update-activation-environment DISPLAY XAUTHORITY
|
||||
fi
|
||||
|
||||
''
|
||||
+
|
||||
(if config.i3-plasma then ''
|
||||
xwallpaper --focus ${extra.wall}
|
||||
export KDEWM=i3
|
||||
'' else "")
|
||||
+
|
||||
''
|
||||
exec startplasma-x11
|
||||
'';
|
||||
};
|
||||
}
|
6
home/berry_config
Executable file
6
home/berry_config
Executable file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
berryc resize_button 3
|
||||
berryc resize_mask mod4
|
||||
berryc set_font "SAX2 Nerd Font"
|
||||
berryc edge_gap 0 40 0 0
|
10
home/light.sh
Normal file
10
home/light.sh
Normal file
|
@ -0,0 +1,10 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
msgTag="lightdunst"
|
||||
|
||||
brightnessctl set "$1"
|
||||
|
||||
light="$(brightnessctl -m | cut -d, -f4)"
|
||||
dunstify -a "changeLight" -u low \
|
||||
-h string:x-dunst-stack-tag:$msgTag \
|
||||
-h int:value:"$light" "Brightness: $light"
|
97
home/polybar.ini
Normal file
97
home/polybar.ini
Normal file
|
@ -0,0 +1,97 @@
|
|||
[bar/bar]
|
||||
modules-right = tray pulseaudio battery date
|
||||
modules-left = ewmh
|
||||
modules-center = polywin
|
||||
padding-right = 15px
|
||||
padding-left = 10px
|
||||
bottom = true
|
||||
height = 40px
|
||||
background = #99000000
|
||||
font-0 = "SAX2 Nerd Font:size=16;3"
|
||||
enable-ipc = true
|
||||
|
||||
[module/date]
|
||||
type = internal/date
|
||||
date = %Y-%m-%d
|
||||
time = %H:%M
|
||||
label = %date% %time%
|
||||
label-padding-left = 5px
|
||||
|
||||
[module/ewmh]
|
||||
type = internal/xworkspaces
|
||||
|
||||
backgound-color = #999999
|
||||
|
||||
pin-workspaces = true
|
||||
enable-click = true
|
||||
|
||||
icon-0 = 0; ◉
|
||||
icon-1 = 1; ◉
|
||||
icon-2 = 2; ◉
|
||||
icon-3 = 3; ◉
|
||||
icon-default =
|
||||
|
||||
label-active = %icon%
|
||||
label-occupied = %icon%
|
||||
label-empty = %icon%
|
||||
|
||||
label-active-padding = 0.7
|
||||
label-occupied-padding = 0.7
|
||||
label-empty-padding = 0.7
|
||||
|
||||
label-active-foreground = #fff
|
||||
label-occupied-foreground = #999
|
||||
label-empty-foreground = #999
|
||||
|
||||
[module/battery]
|
||||
type = internal/battery
|
||||
|
||||
full-at = 99
|
||||
|
||||
low-at = 10
|
||||
|
||||
battery = BAT0
|
||||
adapter = AC
|
||||
|
||||
poll-interval = 5
|
||||
|
||||
format-full = <ramp-capacity>
|
||||
format-charging = <ramp-capacity>
|
||||
format-discharging = <ramp-capacity>
|
||||
|
||||
format-full-padding = 15px
|
||||
format-charging-padding = 15px
|
||||
format-discharging-padding = 15px
|
||||
|
||||
ramp-capacity-0 =
|
||||
ramp-capacity-1 =
|
||||
ramp-capacity-2 =
|
||||
ramp-capacity-3 =
|
||||
ramp-capacity-4 =
|
||||
|
||||
[module/pulseaudio]
|
||||
type = internal/pulseaudio
|
||||
|
||||
use-ui-max = false
|
||||
format-volume = <ramp-volume>
|
||||
|
||||
label-muted =
|
||||
|
||||
; Only applies if <ramp-volume> is used
|
||||
ramp-volume-0 =
|
||||
ramp-volume-1 =
|
||||
ramp-volume-2 =
|
||||
|
||||
[module/tray]
|
||||
type = internal/tray
|
||||
|
||||
format-margin = 8px
|
||||
tray-spacing = 8px
|
||||
|
||||
[module/polywin]
|
||||
type = custom/script
|
||||
exec = ~/.config/polybar/scripts/polywin.sh
|
||||
format = <label>
|
||||
label = %output%
|
||||
label-padding = 1
|
||||
interval = 1
|
701
home/rachel.nix
Normal file
701
home/rachel.nix
Normal file
|
@ -0,0 +1,701 @@
|
|||
{ pkgs, cornelis, cornelis-vim, agda, slippi-netplay, ... }:
|
||||
let username = "rachel";
|
||||
homeDir = "/home/${username}";
|
||||
SAX2NF = import ../shared/sax2nf.nix { inherit pkgs; };
|
||||
hpkgs = pkgs.haskellPackages;
|
||||
hls_wrapper = pkgs.writeScript "hls" ''
|
||||
export PATH="${hpkgs.haskell-language-server}/bin:$PATH"
|
||||
exec ${hpkgs.haskell-language-server}/bin/haskell-language-server-wrapper "$@"
|
||||
'';
|
||||
rzk = hpkgs.rzk;
|
||||
vol = pkgs.writeScript "vol" (builtins.readFile ./vol.sh);
|
||||
light = pkgs.writeScript "light" (builtins.readFile ./light.sh);
|
||||
in rec {
|
||||
home = {
|
||||
username = username;
|
||||
homeDirectory = homeDir;
|
||||
packages = with pkgs; [
|
||||
unzip
|
||||
zip
|
||||
xz
|
||||
gzip
|
||||
bzip2
|
||||
p7zip
|
||||
usbutils
|
||||
pciutils
|
||||
nettools
|
||||
nmap
|
||||
arp-scan
|
||||
julia-bin
|
||||
(python3.withPackages (ps: with ps; [
|
||||
ipython
|
||||
matplotlib
|
||||
numpy
|
||||
scipy
|
||||
]))
|
||||
hpkgs.ghc
|
||||
firefox
|
||||
gnupg
|
||||
agda
|
||||
discord
|
||||
dig
|
||||
xxd
|
||||
zoom-us
|
||||
slack
|
||||
imagemagick
|
||||
ffmpeg
|
||||
sl
|
||||
cowsay
|
||||
lolcat
|
||||
fortune
|
||||
banner
|
||||
yt-dlp
|
||||
libreoffice
|
||||
protonmail-bridge
|
||||
pass
|
||||
protonvpn-cli_2
|
||||
thunderbird
|
||||
tidal-hifi
|
||||
signal-desktop
|
||||
transmission-gtk
|
||||
xclip
|
||||
clinfo
|
||||
glxinfo
|
||||
vulkan-tools
|
||||
obs-studio
|
||||
file
|
||||
gimp
|
||||
SAX2NF
|
||||
twemoji-color-font
|
||||
bat
|
||||
steam
|
||||
steam-run
|
||||
rmapi
|
||||
lutris
|
||||
texlive.combined.scheme-full
|
||||
cornelis
|
||||
zulip
|
||||
rink
|
||||
sage
|
||||
typst
|
||||
ttyper
|
||||
idris2
|
||||
prismlauncher
|
||||
vimv
|
||||
rzk
|
||||
whalebird
|
||||
lean4
|
||||
slippi-netplay
|
||||
xwallpaper
|
||||
blueberry
|
||||
pulseaudio
|
||||
brightnessctl
|
||||
maim
|
||||
];
|
||||
file.".config/berry/autostart" = {
|
||||
source = ./berry_config;
|
||||
};
|
||||
file.".config/polybar/scripts/polywin.sh" = {
|
||||
source = pkgs.writeScript "polywin.sh" ''
|
||||
PATH="$PATH:${pkgs.lib.makeBinPath [
|
||||
pkgs.wmctrl
|
||||
pkgs.gawk
|
||||
pkgs.coreutils-full
|
||||
]}"
|
||||
current_display=$(wmctrl -d 2>/dev/null |awk '/*/ {print $1}')
|
||||
|
||||
out=$(
|
||||
wmctrl -lx 2>/dev/null |
|
||||
awk -v current_display="$current_display" '{
|
||||
if ($2==current_display) {
|
||||
split($3,window_title,".")
|
||||
printf "%s ", "["tolower(window_title[2])"]"
|
||||
}
|
||||
}'
|
||||
)
|
||||
|
||||
# workaround for clearing on empty output
|
||||
printf '%s\n' "$out"
|
||||
'';
|
||||
executable = true;
|
||||
};
|
||||
stateVersion = "23.11";
|
||||
};
|
||||
|
||||
xdg.userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
desktop = "${homeDir}";
|
||||
documents = "${homeDir}/doc";
|
||||
download = "${homeDir}/dwn";
|
||||
music = "${homeDir}/music";
|
||||
pictures = "${homeDir}/img";
|
||||
publicShare = "${homeDir}/srv";
|
||||
templates = "${homeDir}/doc/templates";
|
||||
videos = "${homeDir}/vid";
|
||||
};
|
||||
|
||||
programs = {
|
||||
bash = {
|
||||
enable = true;
|
||||
enableCompletion = false;
|
||||
historyFile = "/dev/null";
|
||||
sessionVariables = {
|
||||
PS1 ="\\033[1m\\u\\033[0m@\\033[1m\\h\\033[0m: \\w\nλ ";
|
||||
BROWSER = "firefox";
|
||||
XINITRC = "${homeDir}/bin/xinitrc";
|
||||
XAUTHORITY = "${homeDir}/.local/share/Xauthority";
|
||||
PASH_KEYID = "3E4A909C8FEF6E3783699C79DFC26EF8EDAD6D71";
|
||||
QT_AUTO_SCREEN_FACTOR = 1;
|
||||
PATH = "${homeDir}/bin:$PATH";
|
||||
};
|
||||
shellAliases = {
|
||||
x = "startx";
|
||||
rm = "rm -i";
|
||||
cal = "cal -m";
|
||||
};
|
||||
initExtra = ''
|
||||
source ~/.profile
|
||||
set -o vi
|
||||
|
||||
norm_name() {
|
||||
ret="$1"
|
||||
[ "$ret" = "''${ret#*\#}" ] && ret="nixpkgs#$ret"
|
||||
printf '%s\n' "$ret"
|
||||
}
|
||||
|
||||
run() {
|
||||
prog="$1"
|
||||
shift
|
||||
nix run "$(norm_name $prog)" "$@"
|
||||
}
|
||||
|
||||
shell() {
|
||||
i=0
|
||||
while [ $i -lt $# ]; do
|
||||
prog="$1"
|
||||
shift
|
||||
set -- "$@" "$(norm_name $prog)"
|
||||
: $(( i++ ))
|
||||
done
|
||||
nix shell "$@"
|
||||
}
|
||||
'';
|
||||
};
|
||||
|
||||
mpv = {
|
||||
enable = true;
|
||||
config = {
|
||||
hwdec = "auto-safe";
|
||||
vo = "gpu";
|
||||
profile = "gpu-hq";
|
||||
};
|
||||
};
|
||||
|
||||
rofi = {
|
||||
enable = true;
|
||||
theme = "gruvbox-dark-soft";
|
||||
};
|
||||
|
||||
git = {
|
||||
enable = true;
|
||||
userName = "Rachel Lambda Samuelsson";
|
||||
userEmail = "depsterr@protonmail.com";
|
||||
extraConfig = {
|
||||
init.defaultBranch = "master";
|
||||
};
|
||||
};
|
||||
|
||||
neovim = {
|
||||
defaultEditor = true;
|
||||
enable = true;
|
||||
vimAlias = true;
|
||||
extraLuaConfig = ''
|
||||
require('tmux').setup({ copy_sync = { redirect_to_clipboard = true } });
|
||||
require('Comment').setup()
|
||||
require('nvim-surround').setup()
|
||||
require('numb').setup()
|
||||
local lspcfg = require('lspconfig')
|
||||
lspcfg.typst_lsp.setup({
|
||||
cmd = { '${pkgs.typst-lsp}/bin/typst-lsp' },
|
||||
})
|
||||
lspcfg.rust_analyzer.setup({})
|
||||
lspcfg.hls.setup({
|
||||
cmd = { '${hls_wrapper}', 'lsp' },
|
||||
})
|
||||
lspcfg.pyright.setup({
|
||||
cmd = { '${pkgs.nodePackages.pyright}/bin/pyright-langserver', '--stdio' },
|
||||
})
|
||||
lspcfg.nixd.setup({
|
||||
cmd = { '${pkgs.nixd}/bin/nixd' },
|
||||
})
|
||||
lspcfg.ltex.setup({
|
||||
cmd = { '${pkgs.ltex-ls}/bin/ltex-ls' },
|
||||
filetypes = { 'bib', 'gitcommit', 'markdown', 'plaintext', 'tex', 'pandoc', 'typst' },
|
||||
settings = {
|
||||
ltex = {
|
||||
language = 'en-US'
|
||||
}
|
||||
}
|
||||
})
|
||||
lspcfg.clangd.setup({
|
||||
cmd = { '${pkgs.clang-tools}/bin/clangd' },
|
||||
})
|
||||
lspcfg.ocamllsp.setup({})
|
||||
require('orgmode').setup_ts_grammar()
|
||||
require('nvim-treesitter.configs').setup({
|
||||
highlight = {
|
||||
enable = true,
|
||||
disable = { "c", "lua" },
|
||||
additional_vim_regex_highlighting = {'org'},
|
||||
},
|
||||
})
|
||||
require('orgmode').setup({})
|
||||
require('lean').setup({
|
||||
mappings = true,
|
||||
})
|
||||
require('lualine').setup {
|
||||
options = {
|
||||
icons_enabled = true,
|
||||
theme = 'gruvbox',
|
||||
component_separators = { left = "", right = ""},
|
||||
section_separators = { left = "", right = ""},
|
||||
always_divide_middle = true,
|
||||
globalstatus = false,
|
||||
refresh = {
|
||||
statusline = 1000,
|
||||
tabline = 1000,
|
||||
winbar = 1000,
|
||||
}
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {'mode'},
|
||||
lualine_b = { {
|
||||
'diagnostics',
|
||||
always_visible = true,
|
||||
on_click = function(n,b,m)
|
||||
vim.diagnostic.goto_next()
|
||||
end
|
||||
} },
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'encoding', 'filetype'},
|
||||
lualine_y = {'progress'},
|
||||
lualine_z = {'location'}
|
||||
},
|
||||
inactive_sections = {
|
||||
lualine_a = {},
|
||||
lualine_b = {},
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'location'},
|
||||
lualine_y = {},
|
||||
lualine_z = {}
|
||||
},
|
||||
}
|
||||
|
||||
vim.api.nvim_create_autocmd('LspAttach', {
|
||||
callback = function(args)
|
||||
local opts = { buffer = args.buf }
|
||||
vim.keymap.set('n', 'K', vim.lsp.buf.hover, opts)
|
||||
vim.keymap.set('n', '<localleader>r', vim.lsp.buf.rename, opts)
|
||||
vim.keymap.set('n', '<localleader>a', vim.lsp.buf.code_action, opts)
|
||||
vim.keymap.set('n', '<localleader>gd', vim.lsp.buf.definition, opts)
|
||||
vim.keymap.set('n', '<localleader>gi', vim.lsp.buf.implementation, opts)
|
||||
vim.keymap.set('n', '<localleader>gr', vim.lsp.buf.references, opts)
|
||||
vim.keymap.set('n', '<localleader>e', vim.diagnostic.open_float, opts)
|
||||
vim.keymap.set('n', '<localleader>n', vim.diagnostic.goto_next, opts)
|
||||
vim.keymap.set('n', '<localleader>N', vim.diagnostic.goto_prev, opts)
|
||||
vim.keymap.set('i', '<C-n>', vim.lsp.omnifunc, opts)
|
||||
end,
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd({ "BufNew"
|
||||
, "TextChanged"
|
||||
, "TextChangedI"
|
||||
, "TextChangedP"
|
||||
, "TextChangedT"
|
||||
}, {
|
||||
callback = function(args)
|
||||
vim.diagnostic.disable(args.buf)
|
||||
end
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd({"BufWrite"}, {
|
||||
callback = function(args)
|
||||
vim.diagnostic.enable(args.buf)
|
||||
end
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd({"BufRead", "BufNewFile"}, {
|
||||
pattern = { "*.rzk" },
|
||||
callback = function(arg)
|
||||
vim.lsp.start({
|
||||
name = 'rzk-lsp',
|
||||
cmd = { "${rzk}/bin/rzk", "lsp" },
|
||||
root_dir = vim.fs.dirname(vim.fs.find('rzk.yaml', { upward = true })[1]),
|
||||
})
|
||||
end
|
||||
})
|
||||
'';
|
||||
extraConfig = ''
|
||||
set rnu nu
|
||||
set ts=2 sw=2 expandtab
|
||||
set clipboard=unnamedplus
|
||||
set laststatus=3 noshowmode
|
||||
set signcolumn=no
|
||||
set linebreak
|
||||
let g:cornelis_use_global_binary = 1
|
||||
set conceallevel=2 concealcursor=nc
|
||||
colorscheme gruvbox
|
||||
hi Normal guibg=NONE ctermbg=NONE
|
||||
|
||||
let maplocalleader="!"
|
||||
let g:bqn_prefix_key="!"
|
||||
runtime agda-input.vim
|
||||
call cornelis#bind_input(" ", "!")
|
||||
call cornelis#bind_input("exc", "!")
|
||||
|
||||
inoremap <C-Space> <Esc>
|
||||
|
||||
nnoremap j gj
|
||||
nnoremap k gk
|
||||
nnoremap gj j
|
||||
nnoremap gk k
|
||||
|
||||
au BufRead,BufNewFile *.agda call AgdaFiletype()
|
||||
au BufRead,BufNewFile *.lagda.* call AgdaFiletype()
|
||||
function! AgdaFiletype()
|
||||
nnoremap <buffer> <C-c><C-l> :CornelisLoad<CR>
|
||||
nnoremap <buffer> <C-c><C-r> :CornelisRefine<CR>
|
||||
nnoremap <buffer> <C-c><C-c> :CornelisMakeCase<CR>
|
||||
nnoremap <buffer> <C-c>, :CornelisTypeContext<CR>
|
||||
nnoremap <buffer> <C-c>. :CornelisTypeContextInfer<CR>
|
||||
nnoremap <buffer> <C-c><C-d> :CornelisTypeInfer<CR>
|
||||
nnoremap <buffer> <C-c><C-s> :CornelisSolve<CR>
|
||||
nnoremap <buffer> <C-c><C-a> :CornelisAuto<CR>
|
||||
nnoremap <buffer> gd :CornelisGoToDefinition<CR>
|
||||
nnoremap <buffer> <C-c><C-b> :CornelisPrevGoal<CR>
|
||||
nnoremap <buffer> <C-c><C-f> :CornelisNextGoal<CR>
|
||||
nnoremap <buffer> <C-c><C-u> :CornelisIgnoreAbstract<CR>
|
||||
nnoremap <buffer> <C-c><space> :CornelisGive<CR>
|
||||
endfunction
|
||||
'';
|
||||
plugins = let
|
||||
bqn-vim = pkgs.vimUtils.buildVimPlugin {
|
||||
name = "bqn-vim";
|
||||
src = "${pkgs.fetchFromGitHub {
|
||||
owner = "mlochbaum";
|
||||
repo = "BQN";
|
||||
rev = "f4b09b675386c789c8296c96874871916a3abdcf";
|
||||
hash = "sha256-rvsageS5sYF9QvWuoRutjx5i0ngrfhGvIPRO834pwwM=";
|
||||
}}/editors/vim";
|
||||
};
|
||||
bqn-nvim = pkgs.vimUtils.buildVimPlugin {
|
||||
name = "bqn-nvim";
|
||||
src = pkgs.fetchFromSourcehut {
|
||||
owner = "~detegr";
|
||||
repo = "nvim-bqn";
|
||||
rev = "52d8b49f3ebc32d340e2e2b8dba1f6bbd1873b78";
|
||||
hash = "sha256-5wITedTuUn9BKLqmQtPWeFNOa8dXfPIRpUvPSkNJcas=";
|
||||
};
|
||||
};
|
||||
in
|
||||
with pkgs.vimPlugins; [
|
||||
nvim-surround
|
||||
comment-nvim
|
||||
vimtex
|
||||
gruvbox-nvim
|
||||
tmux-nvim
|
||||
cornelis-vim
|
||||
nvim-lspconfig
|
||||
idris2-vim
|
||||
numb-nvim
|
||||
typst-vim
|
||||
orgmode
|
||||
(nvim-treesitter.withPlugins (p: with p; [
|
||||
org
|
||||
]))
|
||||
vim-obsession
|
||||
lean-nvim
|
||||
bqn-vim
|
||||
bqn-nvim
|
||||
lualine-nvim
|
||||
];
|
||||
};
|
||||
|
||||
tmux = {
|
||||
enable = true;
|
||||
clock24 = true;
|
||||
escapeTime = 0;
|
||||
keyMode = "vi";
|
||||
mouse = false;
|
||||
shortcut = "a";
|
||||
extraConfig = ''
|
||||
bind h split -hb -c '#{pane_current_path}'
|
||||
bind j split -v -c '#{pane_current_path}'
|
||||
bind k split -vb -c '#{pane_current_path}'
|
||||
bind l split -h -c '#{pane_current_path}'
|
||||
|
||||
is_vim="ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?\.?(view|n?vim?x?)(-wrapped)?(diff)?$'"
|
||||
|
||||
bind-key -n 'C-h' if-shell "$is_vim" 'send-keys C-h' 'select-pane -L'
|
||||
bind-key -n 'C-j' if-shell "$is_vim" 'send-keys C-j' 'select-pane -D'
|
||||
bind-key -n 'C-k' if-shell "$is_vim" 'send-keys C-k' 'select-pane -U'
|
||||
bind-key -n 'C-l' if-shell "$is_vim" 'send-keys C-l' 'select-pane -R'
|
||||
|
||||
bind-key -T copy-mode-vi 'C-h' select-pane -L
|
||||
bind-key -T copy-mode-vi 'C-j' select-pane -D
|
||||
bind-key -T copy-mode-vi 'C-k' select-pane -U
|
||||
bind-key -T copy-mode-vi 'C-l' select-pane -R
|
||||
|
||||
bind -n 'M-h' if-shell "$is_vim" 'send-keys M-h' 'resize-pane -L 1'
|
||||
bind -n 'M-j' if-shell "$is_vim" 'send-keys M-j' 'resize-pane -D 1'
|
||||
bind -n 'M-k' if-shell "$is_vim" 'send-keys M-k' 'resize-pane -U 1'
|
||||
bind -n 'M-l' if-shell "$is_vim" 'send-keys M-l' 'resize-pane -R 1'
|
||||
|
||||
bind-key -T copy-mode-vi M-h resize-pane -L 1
|
||||
bind-key -T copy-mode-vi M-j resize-pane -D 1
|
||||
bind-key -T copy-mode-vi M-k resize-pane -U 1
|
||||
bind-key -T copy-mode-vi M-l resize-pane -R 1
|
||||
|
||||
set -g pane-border-style bg=default
|
||||
set -g pane-border-style fg="#1D1F21"
|
||||
set -g pane-active-border-style bg=default
|
||||
set -g pane-active-border-style fg="#333333"
|
||||
|
||||
set-option -g status on
|
||||
set-option -g status-style bg=default
|
||||
set-option -g status-style fg="#ef7627"
|
||||
set-option -g status-interval 2
|
||||
set-option -g status-justify "centre"
|
||||
set-option -g status-right " λ "
|
||||
|
||||
set -g status-interval 1
|
||||
set-window-option -g window-status-separator "-"
|
||||
set-window-option -g window-status-current-format " #[fg=#b55690 bold]!![ #{b:pane_current_path}/ ] #{b:window_index} $ #{b:pane_current_command}!! "
|
||||
set-window-option -g window-status-format " #{b:window_index} [ #{b:pane_current_path}/ ] #{b:pane_current_command} "
|
||||
|
||||
set -g @resurrect-strategy-nvim 'session'
|
||||
set -g @resurrect-capture-pane-contents 'on'
|
||||
'';
|
||||
plugins = with pkgs.tmuxPlugins; [
|
||||
resurrect
|
||||
];
|
||||
};
|
||||
|
||||
hyfetch = {
|
||||
enable = true;
|
||||
settings = {
|
||||
preset = "lesbian";
|
||||
mode = "rgb";
|
||||
color_align = {
|
||||
mode = "horizontal";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
|
||||
alacritty = {
|
||||
enable = true;
|
||||
settings = {
|
||||
window = {
|
||||
padding.x = 5;
|
||||
padding.y = 5;
|
||||
decoration = "none";
|
||||
};
|
||||
dynamic_title = false;
|
||||
mouse_hide_when_typing = true;
|
||||
draw_bold_text_with_bright_colors = false;
|
||||
scrolling.history = 0;
|
||||
font = {
|
||||
normal.family = "SAX2 Nerd Font";
|
||||
size = 8;
|
||||
};
|
||||
colors = {
|
||||
background = "#1d1f21";
|
||||
foreground = "#c5c8c6";
|
||||
};
|
||||
shell.program =
|
||||
let tmux-menu = pkgs.writeScript "tmux-menu" ''
|
||||
s="$(tmux ls 2>/dev/null)"
|
||||
[ "$s" ] && s="$s
|
||||
"
|
||||
c=$(${pkgs.fzf}/bin/fzf -1 <<-EOF
|
||||
''${s}New Session
|
||||
Raw Shell
|
||||
EOF
|
||||
) || exit
|
||||
case "$c" in
|
||||
"New Session")
|
||||
read -p "Name? " -r n
|
||||
${pkgs.tmux}/bin/tmux new -s "$n" ;;
|
||||
"Raw Shell")
|
||||
${pkgs.bash}/bin/bash --login ;;
|
||||
*)
|
||||
${pkgs.tmux}/bin/tmux attach-session -t "''${c%%:*}" ;;
|
||||
esac
|
||||
''; in "${tmux-menu}";
|
||||
};
|
||||
};
|
||||
|
||||
ssh = {
|
||||
enable = true;
|
||||
matchBlocks = {
|
||||
remarkable = {
|
||||
hostname = "10.11.99.1";
|
||||
user = "root";
|
||||
};
|
||||
lazarus = {
|
||||
hostname = "rachel.cafe";
|
||||
user = "deppy";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
autorandr = {
|
||||
enable = true;
|
||||
hooks.postswitch = {
|
||||
wall = "xwallpaper --zoom \"$HOME\"/img/wallpaper";
|
||||
bar = "systemctl restart --user polybar";
|
||||
};
|
||||
profiles = {
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
gpg-agent = {
|
||||
enable = true;
|
||||
pinentryFlavor = "qt";
|
||||
};
|
||||
|
||||
sxhkd = {
|
||||
enable = true;
|
||||
package = pkgs.sxhkd;
|
||||
extraOptions = [ "-m 1" ];
|
||||
keybindings = {
|
||||
"super + Return" = "alacritty";
|
||||
"super + BackSpace" = "firefox";
|
||||
"super + r" = "rofi -show drun";
|
||||
"super + p" = "cpypsk";
|
||||
"super + l" = "betterlockscreen -l";
|
||||
"super + q" = "berryc window_close";
|
||||
"super + Left" = "berryc snap_left";
|
||||
"super + Right" = "berryc snap_right";
|
||||
"super + m" = "berryc window_monocle";
|
||||
"super + {1,2,3,4}" = "berryc switch_workspace {0,1,2,3}";
|
||||
"super + shift + {1,2,3,4}" = "berryc send_to_workspace {0,1,2,3}";
|
||||
"super + f" = "berryc fullscreen_state";
|
||||
"alt + Tab" = "berryc cycle_focus";
|
||||
"~button1" = "berryc pointer_focus";
|
||||
"~button2" = "berryc pointer_focus";
|
||||
"~button3" = "berryc pointer_focus";
|
||||
"~Escape" = "dunstctl close-all";
|
||||
"Print" = "maim -s ~/img/scrot/$(date +%s).png";
|
||||
"XF86AudioMute" = "${vol} mute";
|
||||
"XF86AudioRaiseVolume" = "${vol} +5%";
|
||||
"XF86AudioLowerVolume" = "${vol} -5%";
|
||||
"XF86MonBrightnessUp" = "${light} 5%+";
|
||||
"XF86MonBrightnessDown" = "${light} 5%-";
|
||||
};
|
||||
};
|
||||
|
||||
polybar = {
|
||||
enable = true;
|
||||
config = ./polybar.ini;
|
||||
script = "polybar bar &";
|
||||
package = pkgs.polybarFull;
|
||||
};
|
||||
|
||||
picom = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
dunst = {
|
||||
enable = true;
|
||||
settings = {
|
||||
volume = {
|
||||
appname = "changeVolume";
|
||||
history_ignore = "yes";
|
||||
};
|
||||
light = {
|
||||
appname = "changeLight";
|
||||
history_ignore = "yes";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
redshift = {
|
||||
enable = true;
|
||||
latitude = "57.70";
|
||||
longitude = "11.97";
|
||||
};
|
||||
|
||||
network-manager-applet.enable = true;
|
||||
blueman-applet.enable = true;
|
||||
betterlockscreen.enable = true;
|
||||
gnome-keyring.enable = true;
|
||||
autorandr.enable = true;
|
||||
|
||||
};
|
||||
|
||||
xsession = {
|
||||
enable = true;
|
||||
initExtra = ''
|
||||
xwallpaper --zoom "$HOME"/img/wallpaper
|
||||
'';
|
||||
scriptPath = "bin/xinitrc";
|
||||
windowManager.command = "${pkgs.berry}/bin/berry";
|
||||
};
|
||||
|
||||
systemd.user= {
|
||||
timers = {
|
||||
battery-check = {
|
||||
Unit.Description = "Warn at low battery levels";
|
||||
Timer = {
|
||||
OnBootSec = "1min";
|
||||
OnUnitActiveSec = "30s";
|
||||
Unit = "battery-check.service";
|
||||
};
|
||||
Install.WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
};
|
||||
services = {
|
||||
battery-check = {
|
||||
Unit.Description = "Warn at low battery levels";
|
||||
Service = let batMon = pkgs.writeShellScript "batMon" ''
|
||||
PATH="$PATH:${pkgs.lib.makeBinPath [
|
||||
pkgs.acpi
|
||||
pkgs.dunst
|
||||
pkgs.gnugrep
|
||||
pkgs.gawk
|
||||
pkgs.systemd
|
||||
]}"
|
||||
acpi -b | grep "Battery 0" | awk -F'[,:%]' '{print $2, $3}' | {
|
||||
read -r status capacity
|
||||
|
||||
if [ "$status" = Discharging -a "$capacity" -le 2 ]; then
|
||||
dunstify -u critical -a batMon \
|
||||
-h string:x-dunst-stack-tag:batMon \
|
||||
-h int:value:"$capacity" "Battery Critical: ''${capacity}%
|
||||
Hibernating"
|
||||
sleep 5
|
||||
systemctl hibernate
|
||||
elif [ "$status" = Discharging -a "$capacity" -le 5 ]; then
|
||||
dunstify -u critical -a batMon \
|
||||
-h string:x-dunst-stack-tag:batMon \
|
||||
-h int:value:"$capacity" "Battery Critical: ''${capacity}%"
|
||||
fi
|
||||
}
|
||||
'';
|
||||
in {
|
||||
ExecStart = "${batMon}";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
}
|
23
home/vol.sh
Normal file
23
home/vol.sh
Normal file
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
msgTag="voldunst"
|
||||
|
||||
case "$1" in
|
||||
mute)
|
||||
pactl set-sink-mute @DEFAULT_SINK@ toggle > /dev/null
|
||||
;;
|
||||
*)
|
||||
pactl set-sink-volume @DEFAULT_SINK@ "$1" > /dev/null
|
||||
;;
|
||||
esac
|
||||
|
||||
volume="$(pactl get-sink-volume @DEFAULT_SINK@ | head -1 | awk '{ print $5 }')"
|
||||
mute="$(pactl get-sink-mute @DEFAULT_SINK@ | cut -d' ' -f2)"
|
||||
if [[ $volume == "0%" || "$mute" == "yes" ]]; then
|
||||
dunstify -a "changeVolume" -u low \
|
||||
-h string:x-dunst-stack-tag:$msgTag "Volume muted"
|
||||
else
|
||||
dunstify -a "changeVolume" -u low \
|
||||
-h string:x-dunst-stack-tag:$msgTag \
|
||||
-h int:value:"$volume" "Volume: ${volume}"
|
||||
fi
|
|
@ -5,7 +5,6 @@
|
|||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
|
@ -20,6 +19,7 @@
|
|||
];
|
||||
};
|
||||
hardware.bluetooth.enable = true;
|
||||
services.blueman.enable = true;
|
||||
services.logind = {
|
||||
lidSwitch = "hibernate";
|
||||
lidSwitchDocked = "ignore";
|
||||
|
@ -28,6 +28,34 @@
|
|||
services.udev.extraRules = ''
|
||||
KERNEL=="0000:00:14.0", SUBSYSTEM=="pci", ATTR{power/wakeup}="disabled"
|
||||
'';
|
||||
services.tlp = {
|
||||
enable = true;
|
||||
settings = {
|
||||
TLP_DEFAULT_MODE = "BAT";
|
||||
DISK_IDLE_SECS_ON_AC = 0;
|
||||
DISK_IDLE_SECS_ON_BAT = 5;
|
||||
MAX_LOST_WORK_SECS_ON_AC = 15;
|
||||
MAX_LOST_WORK_SECS_ON_BAT = 120;
|
||||
CPU_SCALING_GOVERNOR_ON_AC = "auto";
|
||||
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
|
||||
CPU_SCALING_MIN_FREQ_ON_AC = 400000;
|
||||
CPU_SCALING_MAX_FREQ_ON_AC = 4700000;
|
||||
CPU_SCALING_MIN_FREQ_ON_BAT = 400000;
|
||||
CPU_SCALING_MAX_FREQ_ON_BAT = 2700000;
|
||||
CPU_ENERGY_PERF_POLICY_ON_AC = "balance_performance";
|
||||
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
|
||||
CPU_MIN_PERF_ON_AC = 0;
|
||||
CPU_MAX_PERF_ON_AC = 100;
|
||||
CPU_MIN_PERF_ON_BAT = 0;
|
||||
CPU_MAX_PERF_ON_BAT = 30;
|
||||
CPU_BOOST_ON_AC = 1;
|
||||
CPU_BOOST_ON_BAT = 0;
|
||||
SCHED_POWERSAVE_ON_AC = 0;
|
||||
SCHED_POWERSAVE_ON_BAT = 1;
|
||||
NMI_WATCHDOG = 0;
|
||||
DISK_DEVICES = "nvme0n1";
|
||||
};
|
||||
};
|
||||
|
||||
# [BOOT / DISK ENCRYPTION]
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
@ -36,7 +64,7 @@
|
|||
device = "nodev";
|
||||
efiSupport = true;
|
||||
enableCryptodisk = true;
|
||||
theme = ../../resources/grub-theme;
|
||||
theme = ../shared/sayonara;
|
||||
};
|
||||
|
||||
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||
|
@ -52,6 +80,7 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
boot.kernelParams = [ "i915.enable_dpcd_backlight=1" ];
|
||||
|
||||
# [NETWORKING]
|
||||
networking.hostName = "lambda";
|
||||
|
@ -62,5 +91,12 @@
|
|||
wifi.macAddress = "random";
|
||||
};
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
# [DESKTOP / XORG / WAYLAND]
|
||||
services.xserver = {
|
||||
windowManager.berry.enable = true;
|
||||
displayManager.startx.enable = true;
|
||||
dpi = 144;
|
||||
};
|
||||
|
||||
system.stateVersion = "23.11";
|
||||
}
|
|
@ -1,74 +0,0 @@
|
|||
{ config, pkgs, ... }:
|
||||
{
|
||||
# [HARDWARE]
|
||||
imports =
|
||||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
driSupport32Bit = true;
|
||||
};
|
||||
|
||||
# [BOOT]
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.swraid.enable = true;
|
||||
boot.swraid.mdadmConf = ''
|
||||
ARRAY /dev/md/deppyPC:0 level=raid0 num-devices=2 metadata=1.2 name=deppyPC:0 UUID=ba6fef6e:972796a3:a331c87a:2d973f91
|
||||
devices=/dev/sda1,/dev/sdb1
|
||||
'';
|
||||
|
||||
# [AUDIO]
|
||||
services.pipewire.wireplumber.extraConfig = {
|
||||
"alsa-monitor.conf" = {
|
||||
enabled = true;
|
||||
|
||||
rules = [
|
||||
{
|
||||
matches = [
|
||||
{
|
||||
"node.name" = "alsa_output.usb-SMSL_SMSL_USB_AUDIO-00.analog-stereo";
|
||||
}
|
||||
];
|
||||
actions = {
|
||||
update-props = {
|
||||
audio.format = "S32_LE";
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
services.pipewire.extraConfig.pipewire = {
|
||||
"10-clock-rate" = {
|
||||
"context.properties" = {
|
||||
"default.clock.allowed-rates" = [ 44100 48000 88200 96000 176400 192000 352800 384000 705600 768000 ];
|
||||
"default.clock.quantum" = 1024;
|
||||
"default.clock.min-quantum" = 128;
|
||||
"default.clock.max-quantum" = 2048;
|
||||
};
|
||||
};
|
||||
"11-upmix" = {
|
||||
"stream.properties" = {
|
||||
"channel.upmix" = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# [Fix KWIN locking to 60Hz]
|
||||
environment.sessionVariables = {
|
||||
KWIN_X11_NO_SYNC_TO_VBLANK = 1;
|
||||
KWIN_X11_REFRESH_RATE = 144000;
|
||||
KWIN_X11_FORCE_SOFTWARE_VSYNC = 1;
|
||||
};
|
||||
|
||||
# [NETWORKING]
|
||||
networking.hostName = "computational";
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
}
|
|
@ -1,48 +0,0 @@
|
|||
system: config: { pkgs, ... }:
|
||||
{
|
||||
# [DESKTOP / XORG / WAYLAND]
|
||||
services.libinput = {
|
||||
enable = true;
|
||||
touchpad = {
|
||||
naturalScrolling = true;
|
||||
accelProfile = "flat" ;
|
||||
tapping = false;
|
||||
};
|
||||
};
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
displayManager.startx.enable = true;
|
||||
};
|
||||
services.desktopManager.plasma6.enable = true;
|
||||
programs.slock.enable = config.i3-plasma;
|
||||
|
||||
# [SOUND]
|
||||
sound.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
|
||||
alsa = {
|
||||
enable = true;
|
||||
support32Bit = true;
|
||||
};
|
||||
|
||||
pulse.enable = true;
|
||||
|
||||
jack.enable = true;
|
||||
|
||||
wireplumber.enable = true;
|
||||
};
|
||||
|
||||
programs.virt-manager.enable = true;
|
||||
virtualisation.libvirtd.enable = true;
|
||||
|
||||
programs.gamemode = {
|
||||
enable = config.steam;
|
||||
settings.general.renice = 20;
|
||||
};
|
||||
programs.steam.enable = config.steam;
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
hardware.logitech.wireless.enable = true;
|
||||
}
|
|
@ -1,43 +0,0 @@
|
|||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page, on
|
||||
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
|
||||
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
# HW
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
driSupport32Bit = true;
|
||||
extraPackages = with pkgs; [
|
||||
intel-ocl
|
||||
intel-compute-runtime
|
||||
intel-media-driver
|
||||
vaapiIntel
|
||||
vaapiVdpau
|
||||
libvdpau-va-gl
|
||||
];
|
||||
};
|
||||
hardware.bluetooth.enable = true;
|
||||
|
||||
# Use the systemd-boot EFI boot loader.
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
networking.hostName = "transient";
|
||||
networking.networkmanager = {
|
||||
enable = true;
|
||||
wifi.powersave = true;
|
||||
wifi.scanRandMacAddress = true;
|
||||
wifi.macAddress = "random";
|
||||
};
|
||||
|
||||
system.stateVersion = "24.05"; # Did you read the comment?
|
||||
}
|
||||
|
|
@ -1,41 +0,0 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/b8c4fa67-322b-46a7-9fe9-8dc5d020f891";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/A4F2-F615";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0022" "dmask=0022" ];
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/dc2f5eb3-3447-4ae6-adc9-790adee78555"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp0s31f6.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.vimUtils.buildVimPlugin {
|
||||
name = "bqn-nvim";
|
||||
src = pkgs.fetchFromSourcehut {
|
||||
owner = "~detegr";
|
||||
repo = "nvim-bqn";
|
||||
rev = "52d8b49f3ebc32d340e2e2b8dba1f6bbd1873b78";
|
||||
hash = "sha256-5wITedTuUn9BKLqmQtPWeFNOa8dXfPIRpUvPSkNJcas=";
|
||||
};
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.vimUtils.buildVimPlugin {
|
||||
name = "bqn-vim";
|
||||
src = "${pkgs.fetchFromGitHub {
|
||||
owner = "mlochbaum";
|
||||
repo = "BQN";
|
||||
rev = "f4b09b675386c789c8296c96874871916a3abdcf";
|
||||
hash = "sha256-rvsageS5sYF9QvWuoRutjx5i0ngrfhGvIPRO834pwwM=";
|
||||
}}/editors/vim";
|
||||
}
|
|
@ -1,13 +0,0 @@
|
|||
{ pkgs, pash, ... }:
|
||||
pkgs.writeScript "cpypsk" ''
|
||||
#!/bin/sh
|
||||
|
||||
D="''${PASH_DIR:-$HOME/.local/share/pash}"
|
||||
D="''${D%/}"
|
||||
|
||||
for f in "$D"/*.gpg; do
|
||||
n="''${f#$D/}"
|
||||
n="''${n%.gpg}"
|
||||
printf '%s\n' "$n"
|
||||
done | ${pkgs.rofi}/bin/rofi -dmenu | xargs ${pash}/bin/pash copy
|
||||
''
|
|
@ -1,44 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.writeScript "eyezoom" ''
|
||||
arg="$1"
|
||||
|
||||
set -- $(
|
||||
${pkgs.xorg.xrandr}/bin/xrandr |
|
||||
${pkgs.gawk}/bin/awk -F "[x+ ]" '/primary/ { print $4" "$5" "$6" "$7 }'
|
||||
)
|
||||
|
||||
W="$1"
|
||||
H="$2"
|
||||
offx="$3"
|
||||
offy="$4"
|
||||
|
||||
ZH=16384
|
||||
ZW=1920
|
||||
|
||||
WDIV=4
|
||||
|
||||
WIDEDIV=2
|
||||
|
||||
mouse="pointer:pulsar X2H Mini"
|
||||
normalaccel=0
|
||||
zoomaccel=-0.9
|
||||
|
||||
case "$arg" in
|
||||
eye)
|
||||
${pkgs.wmctrl}/bin/wmctrl -R ':ACTIVE:' -e 0,$(( offx - (ZW / 2) + (W / 2) )),$(( offy - (ZH / 2) + (H / 2) )),$ZW,$ZH
|
||||
xinput set-prop "$mouse" "libinput Accel Speed" $zoomaccel
|
||||
;;
|
||||
tiktok)
|
||||
${pkgs.wmctrl}/bin/wmctrl -R ':ACTIVE:' -e 0,$(( offx - ((W/WDIV)/2) + (W/2))),$offy,$((W/WDIV)),$H
|
||||
xinput set-prop "$mouse" "libinput Accel Speed" $normalaccel
|
||||
;;
|
||||
wide)
|
||||
${pkgs.wmctrl}/bin/wmctrl -R ':ACTIVE:' -e 0,$offx,$(( offy - ((H / WIDEDIV) / 2) + (H / 2) )),$W,$((H/WIDEDIV))
|
||||
xinput set-prop "$mouse" "libinput Accel Speed" $normalaccel
|
||||
;;
|
||||
*)
|
||||
${pkgs.wmctrl}/bin/wmctrl -R ':ACTIVE:' -e 0,$offx,$offy,$W,$H
|
||||
xinput set-prop "$mouse" "libinput Accel Speed" $normalaccel
|
||||
;;
|
||||
esac
|
||||
''
|
|
@ -1,15 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.stdenv.mkDerivation {
|
||||
name = "pash";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "rachelambda";
|
||||
repo = "pash";
|
||||
rev = "5fa05003ec63256dce2d6071a33f254439096e94";
|
||||
hash = "sha256-AFAvtLWMWRSdRxZB3Mo9U9TD/x0s4m8tZMt7M3tRVlM=";
|
||||
};
|
||||
phases = [ "installPhase" ];
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
install -Dm755 $src/pash $out/bin/pash
|
||||
'';
|
||||
}
|
|
@ -1,63 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
let mainProgram = "proton-mail";
|
||||
srcHashes = {
|
||||
universal-darwin = "sha256-JfZwHFp0aZtHcbP7tyG7uqFs2w+LWKfnfyuxxpxDJZ8=";
|
||||
x86_64-linux = "sha256-En5vkTHYtwN6GMgbtyhzsPqknOPRO9KlTqZfbBFaIFQ=";
|
||||
};
|
||||
in
|
||||
pkgs.stdenv.mkDerivation rec {
|
||||
pname = mainProgram;
|
||||
version = "1.0.5";
|
||||
nativeBuildInputs = [
|
||||
pkgs.makeWrapper
|
||||
]
|
||||
++ pkgs.lib.optional pkgs.stdenv.isLinux pkgs.dpkg
|
||||
++ pkgs.lib.optional pkgs.stdenv.isDarwin pkgs.unzip;
|
||||
src = pkgs.fetchurl {
|
||||
url =
|
||||
if pkgs.stdenv.isDarwin then
|
||||
"https://github.com/ProtonMail/inbox-desktop/releases/download/${version}/Proton.Mail-darwin-universal-${version}.zip"
|
||||
else
|
||||
"https://github.com/ProtonMail/inbox-desktop/releases/download/${version}/proton-mail_${version}_amd64.deb";
|
||||
sha256 =
|
||||
{
|
||||
x86_64-linux = srcHashes.x86_64-linux;
|
||||
x86_64-darwin = srcHashes.universal-darwin;
|
||||
aarch64-darwin = srcHashes.universal-darwin;
|
||||
}
|
||||
.${pkgs.stdenv.hostPlatform.system} or (throw "unsupported system ${pkgs.stdenv.hostPlatform.system}");
|
||||
};
|
||||
|
||||
sourceRoot = pkgs.lib.optionalString pkgs.stdenv.isDarwin ".";
|
||||
|
||||
dontConfigure = true;
|
||||
dontBuild = true;
|
||||
|
||||
installPhase =
|
||||
let
|
||||
darwin = ''
|
||||
mkdir -p $out/{Applications,bin}
|
||||
cp -r "Proton Mail.app" $out/Applications/
|
||||
makeWrapper $out/Applications/"Proton Mail.app"/Contents/MacOS/Proton\ Mail $out/bin/protonmail-desktop
|
||||
'';
|
||||
linux = ''
|
||||
runHook preInstall
|
||||
mkdir -p $out
|
||||
cp -r usr/share/ $out/
|
||||
cp -r usr/lib/ $out/
|
||||
'';
|
||||
|
||||
in
|
||||
''
|
||||
runHook preInstall
|
||||
|
||||
${if pkgs.stdenv.isDarwin then darwin else linux}
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
preFixup = pkgs.lib.optionalString pkgs.stdenv.isLinux ''
|
||||
makeWrapper ${pkgs.steam-run}/bin/steam-run $out/bin/${mainProgram} \
|
||||
--add-flags "$out'/lib/proton-mail/Proton Mail Beta'"
|
||||
'';
|
||||
}
|
|
@ -1,21 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
let
|
||||
platforms = {
|
||||
x86_64-linux = {
|
||||
archSuffix = "x86_64";
|
||||
hash = "sha256-b+YXBVnxu54HfC/tWapcs/ZYzwBOJswYbEbEU3SVNss=";
|
||||
};
|
||||
aarch64-linux = {
|
||||
archSuffix = "arm64";
|
||||
hash = "sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=";
|
||||
};
|
||||
};
|
||||
platform = platforms.${pkgs.stdenv.system} or (throw "unsupported system ${pkgs.stdenv.hostPlatform.system}");
|
||||
in
|
||||
pkgs.renoise.overrideAttrs (final: prev: {
|
||||
version = "3.4.4";
|
||||
src = pkgs.fetchurl {
|
||||
url = "https://files.renoise.com/demo/Renoise_3_4_4_Demo_Linux_${platform.archSuffix}.tar.gz";
|
||||
hash = platform.hash;
|
||||
};
|
||||
})
|
|
@ -1,20 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.writeScript "tmux-menu" ''
|
||||
s="$(${pkgs.tmux}/bin/tmux ls 2>/dev/null)"
|
||||
[ "$s" ] && s="$s
|
||||
"
|
||||
c=$(${pkgs.fzf}/bin/fzf -1 <<-EOF
|
||||
''${s}New Session
|
||||
Raw Shell
|
||||
EOF
|
||||
) || exit
|
||||
case "$c" in
|
||||
"New Session")
|
||||
read -p "Name? " -r n
|
||||
${pkgs.tmux}/bin/tmux new -s "$n" ;;
|
||||
"Raw Shell")
|
||||
${pkgs.bashInteractive}/bin/bash --login ;;
|
||||
*)
|
||||
${pkgs.tmux}/bin/tmux attach-session -t "''${c%%:*}" ;;
|
||||
esac
|
||||
''
|
|
@ -1,9 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.stdenv.mkDerivation {
|
||||
name = "wallpaper.jpg";
|
||||
src = ./..;
|
||||
phases = [ "installPhase" ];
|
||||
installPhase = ''
|
||||
cp $src/resources/wallpaper.jpg $out
|
||||
'';
|
||||
}
|
|
@ -3,8 +3,6 @@
|
|||
My flake-based nixos configuration.
|
||||
|
||||
* `flake.nix`: flake defining configurations
|
||||
* `hame-manager`: contains home-manager modules
|
||||
* `nixos`: contains nixos configuration modules
|
||||
* `pkgs`: contains derivations used by my config
|
||||
* `resources`: contains files needed for other parts
|
||||
* `secrets`: contains secret passwords using git-crypt
|
||||
* `home`: contains home-manager user configs
|
||||
* `lambda`: contains config for laptop
|
||||
* `shared`: contains assets shared accross installs
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 68 KiB |
|
@ -1,102 +0,0 @@
|
|||
/*******************************************************************************
|
||||
* MACOS SPOTLIGHT LIKE DARK THEME FOR ROFI
|
||||
* User : LR-Tech
|
||||
* Theme Repo : https://github.com/lr-tech/rofi-themes-collection
|
||||
*******************************************************************************/
|
||||
|
||||
* {
|
||||
font: "Montserrat 12";
|
||||
|
||||
bg0: #242424E6;
|
||||
bg1: #7E7E7E80;
|
||||
bg2: #0860f2E6;
|
||||
|
||||
fg0: #DEDEDE;
|
||||
fg1: #FFFFFF;
|
||||
fg2: #DEDEDE80;
|
||||
|
||||
background-color: transparent;
|
||||
text-color: @fg0;
|
||||
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
spacing: 0;
|
||||
}
|
||||
|
||||
window {
|
||||
background-color: @bg0;
|
||||
|
||||
location: center;
|
||||
width: 640;
|
||||
border-radius: 8;
|
||||
}
|
||||
|
||||
inputbar {
|
||||
font: "Montserrat 20";
|
||||
padding: 12px;
|
||||
spacing: 12px;
|
||||
children: [ icon-search, entry ];
|
||||
}
|
||||
|
||||
icon-search {
|
||||
expand: false;
|
||||
filename: "search";
|
||||
size: 28px;
|
||||
}
|
||||
|
||||
icon-search, entry, element-icon, element-text {
|
||||
vertical-align: 0.5;
|
||||
}
|
||||
|
||||
entry {
|
||||
font: inherit;
|
||||
|
||||
placeholder : "Search";
|
||||
placeholder-color : @fg2;
|
||||
}
|
||||
|
||||
message {
|
||||
border: 2px 0 0;
|
||||
border-color: @bg1;
|
||||
background-color: @bg1;
|
||||
}
|
||||
|
||||
textbox {
|
||||
padding: 8px 24px;
|
||||
}
|
||||
|
||||
listview {
|
||||
lines: 10;
|
||||
columns: 1;
|
||||
|
||||
fixed-height: false;
|
||||
border: 1px 0 0;
|
||||
border-color: @bg1;
|
||||
}
|
||||
|
||||
element {
|
||||
padding: 8px 16px;
|
||||
spacing: 16px;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
element normal active {
|
||||
text-color: @bg2;
|
||||
}
|
||||
|
||||
element alternate active {
|
||||
text-color: @bg2;
|
||||
}
|
||||
|
||||
element selected normal, element selected active {
|
||||
background-color: @bg2;
|
||||
text-color: @fg1;
|
||||
}
|
||||
|
||||
element-icon {
|
||||
size: 1em;
|
||||
}
|
||||
|
||||
element-text {
|
||||
text-color: inherit;
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 1.4 MiB |
BIN
secrets/eta.nix
BIN
secrets/eta.nix
Binary file not shown.
|
@ -1,5 +1,20 @@
|
|||
system: config: { pkgs, ... }:
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
settings = {
|
||||
PasswordAuthentication = false;
|
||||
PermitRootLogin = "no";
|
||||
};
|
||||
};
|
||||
|
||||
# [NFS]
|
||||
fileSystems."/home/rachel/music" = {
|
||||
device = "rachel.cafe:/srv/music";
|
||||
fsType = "nfs";
|
||||
options = [ "x-systemd.automount" "noauto" "x-systemd.idle-timeout=60" ];
|
||||
};
|
||||
|
||||
# [LOCALE]
|
||||
time.timeZone = "Europe/Stockholm";
|
||||
i18n.defaultLocale = "en_GB.UTF-8";
|
||||
|
@ -8,14 +23,14 @@ system: config: { pkgs, ... }:
|
|||
# [NIX]
|
||||
nix = {
|
||||
settings = {
|
||||
bash-prompt = "\\033[1m\\u\\033[0m@\\033[1m\\h\\033[0m: \\w\\n❄\\040";
|
||||
bash-prompt = "\\033[1m\\u\\033[0m@\\033[1m\\h\\033[0m: \\w\\n\\040";
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
auto-optimise-store = true;
|
||||
};
|
||||
gc = {
|
||||
automatic = true;
|
||||
dates = "weekly";
|
||||
options = "--delete-older-than 7d";
|
||||
dates = "monthly";
|
||||
options = "--delete-older-than 30d";
|
||||
};
|
||||
registry = {
|
||||
templates = {
|
||||
|
@ -31,51 +46,87 @@ system: config: { pkgs, ... }:
|
|||
};
|
||||
};
|
||||
|
||||
# [NFS]
|
||||
fileSystems."/home/${config.user}/music" = {
|
||||
device = "rachel.cafe:/srv/music";
|
||||
fsType = "nfs";
|
||||
options = [ "x-systemd.automount" "noauto" "x-systemd.idle-timeout=60" ];
|
||||
};
|
||||
|
||||
fileSystems."/mnt/eta" =
|
||||
let secrets = import ../../secrets/eta.nix;
|
||||
in {
|
||||
device = "//192.168.30.33/users";
|
||||
fsType = "cifs";
|
||||
options = [ "username=${secrets.etaUser}" "password=${secrets.etaPass}" "uid=1000" "gid=1000" "x-systemd.automount" "noauto" "x-systemd.idle-timeout=60" ];
|
||||
};
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nixpkgs.config.permittedInsecurePackages = [
|
||||
"electron-21.4.4" # needed for whalebird
|
||||
];
|
||||
|
||||
# [DESKTOP / XORG / WAYLAND]
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
xkb = {
|
||||
layout = "fox,sus";
|
||||
options = "ctrl:nocaps";
|
||||
extraLayouts.sus = {
|
||||
description = "Swedish US";
|
||||
languages = [ "se" ];
|
||||
symbolsFile = ../../resources/sus.xkb;
|
||||
symbolsFile = ../shared/sus.xkb;
|
||||
};
|
||||
extraLayouts.fox = {
|
||||
description = "Layout suitable to be used by a fox";
|
||||
languages = [ "se" ];
|
||||
symbolsFile = ../../resources/fox.xkb;
|
||||
symbolsFile = ../shared/fox.xkb;
|
||||
};
|
||||
};
|
||||
libinput = {
|
||||
enable = true;
|
||||
touchpad = {
|
||||
naturalScrolling = true;
|
||||
accelProfile = "flat" ;
|
||||
tapping = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# [PACKAGES / PROGRAMS]
|
||||
environment.systemPackages = with pkgs; [
|
||||
git
|
||||
git-crypt
|
||||
neovim
|
||||
];
|
||||
|
||||
# [TTY]
|
||||
console = {
|
||||
useXkbConfig = true;
|
||||
font = "LatGrkCyr-12x22";
|
||||
};
|
||||
|
||||
# [SOUND]
|
||||
sound.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
|
||||
alsa = {
|
||||
enable = true;
|
||||
support32Bit = true;
|
||||
};
|
||||
|
||||
pulse.enable = true;
|
||||
|
||||
jack.enable = true;
|
||||
|
||||
wireplumber.enable = true;
|
||||
};
|
||||
|
||||
|
||||
# [PACKAGES / PROGRAMS]
|
||||
environment.systemPackages = with pkgs; [
|
||||
git
|
||||
neovim
|
||||
];
|
||||
programs.gamemode = {
|
||||
enable = true;
|
||||
settings.general.renice = 20;
|
||||
};
|
||||
programs.steam.enable = true;
|
||||
ssbm.gcc = {
|
||||
rules.enable = true;
|
||||
oc-kmod.enable = true;
|
||||
};
|
||||
|
||||
# [SERVICES]
|
||||
services.printing.enable = true;
|
||||
virtualisation.docker.enable = true;
|
||||
|
||||
# [SECURITY / FIREWALL]
|
||||
networking.firewall.enable = true;
|
||||
networking.firewall.allowedTCPPorts = [ 22 ];
|
||||
networking.firewall.allowedUDPPorts = [ ];
|
||||
|
||||
security.doas = {
|
||||
enable = true;
|
||||
extraRules = [{
|
||||
|
@ -86,10 +137,8 @@ system: config: { pkgs, ... }:
|
|||
}];
|
||||
};
|
||||
# [USER]
|
||||
users.users.${config.user} = {
|
||||
users.users.rachel = {
|
||||
isNormalUser = true;
|
||||
shell = pkgs.zsh;
|
||||
ignoreShellProgramCheck = true;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
|
@ -97,23 +146,11 @@ system: config: { pkgs, ... }:
|
|||
"input"
|
||||
"audio"
|
||||
"docker"
|
||||
"libvirtd"
|
||||
];
|
||||
};
|
||||
# Done for gamemoderun
|
||||
security.pam.loginLimits = [
|
||||
{ domain = "${config.user}"; item = "nice"; "type" = "soft"; value = "-20"; }
|
||||
{ domain = "${config.user}"; item = "nice"; "type" = "hard"; value = "-20"; }
|
||||
{ domain = "rachel"; item = "nice"; "type" = "soft"; value = "-20"; }
|
||||
{ domain = "rachel"; item = "nice"; "type" = "hard"; value = "-20"; }
|
||||
];
|
||||
|
||||
# [SERVICES]
|
||||
services.printing.enable = true;
|
||||
virtualisation.docker.enable = true;
|
||||
services.mullvad-vpn.enable = true;
|
||||
|
||||
|
||||
# [SECURITY / FIREWALL]
|
||||
networking.firewall.enable = true;
|
||||
networking.firewall.allowedTCPPorts = [ 22 ];
|
||||
networking.firewall.allowedUDPPorts = [ ];
|
||||
}
|
|
@ -55,7 +55,5 @@ xkb_symbols "fox" {
|
|||
key <AB09> {[ v, V, VoidSymbol, VoidSymbol ]};
|
||||
key <AB10> {[ z, Z, VoidSymbol, VoidSymbol ]};
|
||||
|
||||
key <SPCE> {[ space, space, space, space ]};
|
||||
|
||||
};
|
||||
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
|
@ -5,5 +5,4 @@ xkb_symbols "sus" {
|
|||
key <AD11> {[ bracketleft, braceleft, aring, Aring ]};
|
||||
key <AC10> {[ semicolon, colon, odiaeresis, Odiaeresis ]};
|
||||
key <AC11> {[ apostrophe, quatedbl, adiaeresis, Adiaeresis ]};
|
||||
key <SPCE> {[ space, space, space, space ]};
|
||||
};
|
Loading…
Reference in New Issue
Block a user