Compare commits
1 Commits
main
...
4f65912b4b
| Author | SHA1 | Date | |
|---|---|---|---|
| 4f65912b4b |
@@ -1,8 +0,0 @@
|
||||
{
|
||||
"tabWidth": 2,
|
||||
"printWidth": 90,
|
||||
"useTabs": false,
|
||||
"proseWrap": "always",
|
||||
"endOfLine": "lf",
|
||||
"embeddedLanguageFormatting": "auto"
|
||||
}
|
||||
251
CONTRIBUTING.md
@@ -1,251 +0,0 @@
|
||||
# CONTRIBUTING
|
||||
|
||||
## Tldr
|
||||
|
||||
**Do's**
|
||||
|
||||
- Be concise
|
||||
- Follow the [Formatting Rules](#formatting-rules) to the best of your ability
|
||||
- Segment larger changes into managable, reviewable commits
|
||||
- Leave a trail of your development so I can tell you put some effort in (doesnt really
|
||||
apply to smaller commits)
|
||||
- Write your own code
|
||||
- Leave some way of crediting your work
|
||||
- Disclose the capacity in which you used AI. Most of the time, anything more than making
|
||||
examples or helping you understand the codebase will be disallowed. As little AI code
|
||||
should make it to production as possible
|
||||
|
||||
**Dont's**
|
||||
|
||||
- Report upstream issues to me (ie an issue with the app itself, not my config)
|
||||
- Make major structural changes
|
||||
- Submit chore commits such as updating the flake, I can do that myself
|
||||
- Add new hosts for no reason, make your own flake and import the modules you want for
|
||||
your host
|
||||
- Majorly change existing hosts for your own preference
|
||||
- Ask AI to fix your issues and expect me to merge changes
|
||||
- Delete existing modules. Executive decisions like that will be made at my disgression,
|
||||
and will be done as non-destructively as possible, such as moving those modules to a
|
||||
"deprecated" branch in the future.
|
||||
|
||||
## General format
|
||||
|
||||
All emails regarding this repo (or another) should have a subject prepended with the
|
||||
following:
|
||||
|
||||
```text
|
||||
[GIT] [voidarc/nixos] (request type)
|
||||
```
|
||||
|
||||
The content of the second set of brackets should be replaced with the specific submodule
|
||||
or repo that is being referred to. For example, in the case of a quickshell bug, it should
|
||||
contain `voidarc/quickshell`.
|
||||
|
||||
In general, for most requests, I also implore you to include a github username (or
|
||||
equivalent, codeberg, gitlab, etc.) so that I have a frame of reference for you as a
|
||||
person, and also so that you can be credited in any resulting commits. Depending on
|
||||
scenario, this requirement can be waived, or substituted for a reddit account or
|
||||
something.
|
||||
|
||||
The third set of brackets pertains to the subject proper, and should only reasonably
|
||||
contain `issue`, `patch` or `feature`. If you believe that your request does not fit into
|
||||
any of those categories, then feel free to do whatever you want within reason.
|
||||
|
||||
## Issues
|
||||
|
||||
Issues are restricted to bugs or otherwise not fixed problems in the code. If it is an
|
||||
upstream bug, ie one not caused by my specific config, please don't send me a complaint
|
||||
about it, refer to the source app. The subject for an issue should be formatted as such:
|
||||
|
||||
```Text
|
||||
(prefix) (module type) (specific module) - (description of issue)
|
||||
```
|
||||
|
||||
The prefix shoud be formatted as above. In the case of an issue pertaining to another
|
||||
repo, the module type and module name may be omitted, unless it is an issue with the
|
||||
dendritic module implementation, in which case the repo in the subject should be this one.
|
||||
|
||||
The module type should match the repo's folder structure, being one of `feature`,
|
||||
`system`, `attr/attribute` or `host`. Self explanitory. Doesn't have to be an exact match.
|
||||
|
||||
The specific module should be the name of the module itself, not just the directory that
|
||||
contains it, due to the fact that some directories and files contain multiple modules. In
|
||||
the case of a file containing both a package and a module, favour the module that
|
||||
implements the package, and not the package itself (`self.nixosModules` rather than
|
||||
`self'.packages`).
|
||||
|
||||
The description should follow standard conventions, as you would report on other
|
||||
platforms. Don't make it stupidly long, common sense required.
|
||||
|
||||
The body of the email should be reminiscent of a github issue, and contain the following
|
||||
items in roughly the presented order:
|
||||
|
||||
- Clear description of the issue (and why it's an issue in the first place, and not
|
||||
personal preference)
|
||||
- Step by step instructions on how to replicate the given issue
|
||||
- Step by step instructions detailing what you believe the behaviour should be
|
||||
- Any attempts to fix the issue, or references to suspected code that may be causing the
|
||||
issue
|
||||
|
||||
If you have attempted to fix the issue, or altered the code, please refer to the next
|
||||
section
|
||||
|
||||
## Patches / Contributions (Pull requests)
|
||||
|
||||
Patches are for altered code that you would like me to review and possibly add to the
|
||||
codebase. Most of the time, these should be for issues that you have encountered using the
|
||||
repo, not new features entirely. If a patch doesn't fit an issue, is mostly or fully AI
|
||||
generated, or otherwise doesnt fit the repo, it will be rejected.
|
||||
|
||||
The format here is similar, but with a few key differences. The type of request should
|
||||
obviously be patch, and the rest should be identical to the previous type, containing
|
||||
module type, name, and a short description of the issue.
|
||||
|
||||
The body should also follow similar beats, having a breakdown of the issue and detailing
|
||||
the intended behaviour. Beyond the detailing portion, there are some other specific things
|
||||
that are required for issues in particular.
|
||||
|
||||
- A description of whatever alterations have been made to the code
|
||||
- Some form of username so that, in the event of a merge, you can be credited properly
|
||||
- A disclosure of how much or little AI was used in the creation of the patch. For
|
||||
completeness, even if no AI is used, please include "No AI was used" anyway, it is not
|
||||
implied.
|
||||
|
||||
A git patch file should be attatched to the email, not a link to a github repo or
|
||||
something else. Any "patch" email with no attatchments will probably not be looked at any
|
||||
further than the issue section. For patches, please refer to the
|
||||
[Formatting Rules](#formatting-rules)
|
||||
|
||||
Both issues and patches are on a first come first serve basis. Because there is no public
|
||||
forum (I'm sure as hell not maintaining one), if someone submits an issue or patch, even
|
||||
if someone else independantly discovered the bug, the first person will most likely be
|
||||
credited for that issue.
|
||||
|
||||
If you have previously opened an issue, and wish to make a patch for the same issue, reply
|
||||
to the initial issue email, and prefix the subject with `PATCH:` instead of the usual
|
||||
`RE:` or whatever your email client chooses to prepend. The rest of the subject should
|
||||
remain the same. The email should then contain the patch-specific sections, found above.
|
||||
Don't bother re-iterating the issue.
|
||||
|
||||
## Feature Requests
|
||||
|
||||
Feature requests are for anything that doesn't already exist or doesnt otherwise fall into
|
||||
the previous categories. These are more freeform, and could come in the form of a useful
|
||||
app, a better way of managing something, or a better replacement for something that is
|
||||
already in the repo. Most importantly, this is NOT somewhere to shill an app you
|
||||
vibe-coded. Any AI generated apps will be rejected out of principle.
|
||||
|
||||
Headers should follow this structure, but, again, this is lenient:
|
||||
|
||||
```text
|
||||
(prefix) - (Feature type) - (App name): (description)
|
||||
```
|
||||
|
||||
The feature type, as before, should be one of the given folders in the repo. Generally,
|
||||
this will be a `feature` for a new app, but could be `system` for a new driver or
|
||||
`attribute` for a new collection of packages. If it is more general than any of those
|
||||
categories, or smaller in scope than an entire feature, use the feature type `other`, and
|
||||
detail what you are requesting (other should be used if you are just requesting a singular
|
||||
package be added to the system, for example).
|
||||
|
||||
Instead of following a fixed structure for the body, it is up to you to make a case for
|
||||
whatever you are suggesting. Whatever that entails is up to you. It could be use cases, it
|
||||
could be reasons it is better than whatever I am using. Be as verbose or as minimal as you
|
||||
wish, but keep in mind that the better your argument is, the more likely I am to accept
|
||||
your contribution. Again, if you wish, you can leave a username so that you can be
|
||||
correctly credited if I decide to include whatever you suggested.
|
||||
|
||||
If you are suggesting a new feature, app or otherwise, you may also choose to make a basic
|
||||
or full module implementing that feature, and then attach that to the email in the form of
|
||||
a patch. Refer to the [Formatting Rules](#formatting-rules) for further instruction on how
|
||||
to write your code.
|
||||
|
||||
Please also leave references for whatever it is you're suggesting, not just the name of
|
||||
the app. This could come in the form of documentation, a homepage, or the link for its
|
||||
github. In general, if an app has none of these things, or is closed source in any
|
||||
capacity, it will not be accepted.
|
||||
|
||||
## Formatting rules
|
||||
|
||||
Formatting in this repo should attempt to be standard to whatever I am using. For ease of
|
||||
use, either refer to or use my nvim config (`#nvim` output for this repo, refer to the
|
||||
README for how to run it). This prevents ugly git histories with commits specifically for
|
||||
formatting etc.
|
||||
|
||||
### General rules
|
||||
|
||||
When submitting a patch, there should be no merge conflicts with the current HEAD at the
|
||||
time of creation. It is a good rule of thumb to pull from remote before making a patch,
|
||||
incase behaviour changes.
|
||||
|
||||
If there are commits pushed between the time you send a patch and the time it is reviewed,
|
||||
any resulting merge conflicts are not your fault, and therefore will not be treated as
|
||||
such. Don't resubmit the same patch because there are new commits on remote, when patches
|
||||
are reviewed they are inserted at the point at which they were created, not on top of
|
||||
newer commits.
|
||||
|
||||
#### Branches
|
||||
|
||||
All patches should be mergable to the main branch, ie not have a patch for the `feature-x`
|
||||
branch or some nonsense. I do not have your git history, and therefore don't have whatever
|
||||
branch you created on my machine. In general, most changes should be restricted to one
|
||||
commit, so that crediting is easy.
|
||||
|
||||
If a change is more than one or two commits, make a new branch, make the changes that you
|
||||
want, then merge to the latest head before submitting a patch. When merging back to main,
|
||||
please use a merge commit instead of fast forwarding or clobbering the branch. This makes
|
||||
it easy to see who made what changes in the git history, and keeps blame easy to read.
|
||||
This merge commit will be where your credit goes. If you submit a patch that contains a
|
||||
load of commits on the main branch, the chances I accept the patch are very low.
|
||||
|
||||
### Code
|
||||
|
||||
There are many types of code in this repo, so if there is any confusion, either refer to
|
||||
the config that I am using in nvim, or send me an email asking me how to handle it.
|
||||
|
||||
#### Nix
|
||||
|
||||
For starters, all nix code should be formatted with
|
||||
[Alejandra](https://github.com/kamadorueda/alejandra). If you choose to format your code
|
||||
with nix-fmt or something else, chances are I won't refuse it, but I will overwrite your
|
||||
commits with a formatted version. To format the entire repo properly, run the following
|
||||
command:
|
||||
|
||||
```bash
|
||||
nix-shell -p alejandra --run "alejandra ."
|
||||
```
|
||||
|
||||
This will recursively check and format all `.nix` files in the repo, which is what I want.
|
||||
|
||||
As a secondary requirement, try to follow the already set out conventions that are on
|
||||
display in this repo, as well as the conventions of dendritic nix. A few examples:
|
||||
|
||||
- All top level objects should be merged into one unless there is a good reason for it
|
||||
- The first item in a module should be the module definition (`flake.nixosModules.xyz`)
|
||||
- All modules should be portable unless there is a good reason for it
|
||||
- Modules should reference eachother through `self.nixosModules` instead of relative
|
||||
paths, which should be avoided in most scenarios
|
||||
- In general, if a package is available in nixpkgs, an input need not be added. This rule
|
||||
differs case-by-case due to versioning differences.
|
||||
|
||||
#### Markdown
|
||||
|
||||
All markdown files should be formatted using prettier, with the settings provided in this
|
||||
repo. For reference, the rules are:
|
||||
|
||||
- 90 characters maximum, excluding code blocks
|
||||
- word wrapping
|
||||
- tab width of 2, as well as replacing spaces with tabs
|
||||
|
||||
#### Other languages
|
||||
|
||||
For one-off config languages (think `kitty.conf`), no formatting is needed. Whitespace can
|
||||
be added at the programmer's disgression.
|
||||
|
||||
For standard structured languages, such as json, yaml or toml, if there is an available
|
||||
prettier formatter, then it should be used. In general, tabwidth should be 2 and spaces
|
||||
should be used across the board. Don't use some esoteric formatter just to be special.
|
||||
|
||||
For actual programming languages, like qml or lua, either use the provided formatter, such
|
||||
as `qmlformat`, with the settings configured, or refer to my nvim config (in this case I
|
||||
use `stylua` with the default settings)
|
||||
151
README.md
@@ -1,97 +1,38 @@
|
||||
# The Void
|
||||
|
||||
_An opinionated dendritic nix configuration_
|
||||
|
||||
## Screenshots
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
## Get Started
|
||||
|
||||
No cloning required
|
||||
|
||||
```bash
|
||||
# Run any app (replace appname with the one you want)
|
||||
nix run "git+https://git.voidarc.co.uk/voidarc/nixos.git#appname"
|
||||
|
||||
# Build configuration (HACKSTATION or mobile02)
|
||||
sudo nixos-rebuild switch --impure --flake "git+https://git.voidarc.co.uk/voidarc/nixos.git#mobile02"
|
||||
```
|
||||
|
||||
[More Information on Configs](#nixos-configurations)
|
||||
|
||||
[More Information on Binaries](#binaries)
|
||||
*An opinionated dendritic nix configuration*
|
||||
|
||||
## The Concept
|
||||
|
||||
I have been trying to get consistent, across device experiences from the second that I
|
||||
started using linux. I tried my best with arch, but I foolishly believed that just
|
||||
remembering what packages I installed would be enough. Then I started managing my dotfiles
|
||||
with GNU stow, but that only allowed for a single host per repo. I moved over to doot, and
|
||||
simultaneously nixos.
|
||||
started using linux. I tried my best with arch, but I foolishly believed that just remembering
|
||||
what packages I installed would be enough. Then I started managing my dotfiles with GNU stow,
|
||||
but that only allowed for a single host per repo. I moved over to doot, and simultaneously nixos.
|
||||
|
||||
I believed a dotfiles manager was my endgame. The final evolution, but it was far from
|
||||
ideal. I had to manage a mess of dotfiles, submodules and nix packages that were
|
||||
completely uncoupled from the apps that used them. Hyprland just assumed that I had all of
|
||||
my apps installed, assumed that otter-launcher's config existed. Just by forgetting an app
|
||||
or a toml file, I had the potential to brick my entire setup.
|
||||
I believed a dotfiles manager was my endgame. The final evolution, but it was far from ideal. I had to
|
||||
manage a mess of dotfiles, submodules and nix packages that were completely uncoupled from the apps that
|
||||
used them. Hyprland just assumed that I had all of my apps installed, assumed that otter-launcher's
|
||||
config existed. Just by forgetting an app or a toml file, I had the potential to brick my entire setup.
|
||||
|
||||
This is no longer the case.
|
||||
|
||||
The solution is similar to that of safely typed languages, like rust. Rust, instead of
|
||||
having optional parameters like typescript, requires that a variable be passed to a
|
||||
function, regardless of whether it contains anything. This leads to what is essentially a
|
||||
fixed dependancy tree, where there are no points of failiure, only allowing for logic
|
||||
errors and such. The same methodology can be applied to nix, using flake parts and wrapper
|
||||
scripts.
|
||||
The solution is similar to that of safely typed languages, like rust. Rust, instead of having optional parameters
|
||||
like typescript, requires that a variable be passed to a function, regardless of whether it contains anything.
|
||||
This leads to what is essentially a fixed dependancy tree, where there are no points of failiure, only allowing
|
||||
for logic errors and such. The same methodology can be applied to nix, using flake parts and wrapper scripts.
|
||||
|
||||
Instead of defining the packages beside the app, and its config, you can use the config to
|
||||
define the required binaries. By wrapping a config that contains a nix variable, ie a
|
||||
binary, that binary is intrinsically linked to that config, and will therefore always be
|
||||
installed. No more dependancy issues, and because the configs are defined within nix too,
|
||||
no more potential for missing config files. Dotfile managers are no more, long live
|
||||
dotfile managers. Any app with a `--config` flag can now be fully versioned and self
|
||||
contained within one repo, config and all, accessible on any machine with nix.
|
||||
Instead of defining the packages beside the app, and its config, you can use the config to define the required binaries.
|
||||
By wrapping a config that contains a nix variable, ie a binary, that binary is intrinsically linked to that config,
|
||||
and will therefore always be installed. No more dependancy issues, and because the configs are defined within nix too, no
|
||||
more potential for missing config files. Dotfile managers are no more, long live dotfile managers. Any app with a `--config`
|
||||
flag can now be fully versioned and self contained within one repo, config and all, accessible on any machine with nix.
|
||||
|
||||
One command for a truly reproducible, fully contained, configured system. This is the
|
||||
endgame.
|
||||
|
||||
### Mandatory thing on AI
|
||||
|
||||
I am not completely against AI. However, asking an agent to write a load of code and then
|
||||
posting it to reddit as if you made it yourself is disingenuous and (in my opinion) at
|
||||
least slightly morally incorrect. Many a time I have seen a cool project on a subreddit
|
||||
just for it to turn out to be ai generated garbage that I refuse to use out of principle.
|
||||
|
||||
I would go out on a limb and say that 99% of this codebase was written with no AI
|
||||
assistance. Every config, every module, every obscure fix for a bug that only exists
|
||||
because I'm using a dendritic pattern instead of being normal was programmed by hand by a
|
||||
real human (yours truly). I'm not saying I had no assistance at all, there are sections
|
||||
that are verbatim copied from the wiki of whatever app or language that I was using, but
|
||||
by and large, no AI code has made it into this repo.
|
||||
|
||||
There may be commits somewhere saying that opencode refactored something, or that it
|
||||
solved some obscure bug I was having, but after having those changes implemented for me, I
|
||||
took it upon myself to understand what actually happened, in order to make maintaining
|
||||
this config as easy as possible in the future.
|
||||
|
||||
This repo is not temporary. I daily drive this, and I intend to for many years to come.
|
||||
Going forward, I will keep to the same standard of only using AI as a last resort, and
|
||||
when needs must, only implementing and commiting changes that I fully understand and
|
||||
could've eventually come to myself. Sometimes, at the end of a long coding session, a man
|
||||
gets lazy. I could spend another 45 minutes fixing some quickshell update order bug, or I
|
||||
could get deepseek to do it. In the end, it was a 5 line fix that, in hindsight, was
|
||||
pretty obvious (lol).
|
||||
One command for a truly reproducible, fully contained, configured system. This is the endgame.
|
||||
|
||||
## Usage
|
||||
|
||||
Usage is similar to any other flake, with everything in the module directory being an
|
||||
output.
|
||||
Usage is similar to any other flake, with everything in the module directory being an output.
|
||||
|
||||
The folder structure is simply defined:
|
||||
|
||||
```
|
||||
modules/
|
||||
|- features/ - all available apps, every subfolder contains a seperate wrapped binary
|
||||
@@ -102,62 +43,32 @@ modules/
|
||||
|
||||
### Nixos Configurations
|
||||
|
||||
Due to the host module referencing `/etc/nixos/hardware-configuration.nix`, so that it is
|
||||
seperated from the repo, all rebuild commands will need `--impure`, unless you copy your
|
||||
configuration into the repo.
|
||||
Due to the host module referencing `/etc/nixos/hardware-configuration.nix`, so that it is seperated from the repo,
|
||||
all rebuild commands will need `--impure`, unless you copy your configuration into the repo.
|
||||
|
||||
HACKSTATION contains all features available (near enough), with mobile02 being a lighter
|
||||
version of the system, looking the same visually, but with less bloat, only really having
|
||||
firefox and a terminal.
|
||||
|
||||
It is recommended to clone the repo beforehand, but the system can be built directly from
|
||||
remote. When cloning the repo, in order to properly evaluate the `vinix` and `nrs` shell
|
||||
aliases, the config should be built from the directory you cloned it to, not from another
|
||||
directory. When building from remote, or in any other scenario in which the `$PWD`
|
||||
environment variable is not available, the zsh module will throw and evaluation warning,
|
||||
but the build will not be hindered.
|
||||
HACKSTATION is the heavier system, mobile02 is minimal and has no specialist hyprland config.
|
||||
|
||||
It is recommended to clone the repo beforehand, but the system can be built directly from remote
|
||||
```bash
|
||||
# The following commands will only work if your hostname is already
|
||||
# HACKSTATION or mobile02, if it is not, see next code block
|
||||
|
||||
# Local Clone, . is the directory containing flake.nix
|
||||
sudo nixos-rebuild switch --impure --flake .
|
||||
|
||||
# Build from remote
|
||||
sudo nixos-rebuild switch --impure --flake "git+https://git.voidarc.co.uk/voidarc/nixos.git"
|
||||
sudo nixos-rebuild switch --impure --flake "git+https://git.voidarc.co.uk/voidarc/nixos.git?ref=dendritic"
|
||||
```
|
||||
|
||||
Both of these commands can be appended with a desired hostname in order to build that
|
||||
configuration.
|
||||
|
||||
Both of these commands can be appended with a desired hostname in order to build that configuration.
|
||||
```bash
|
||||
# Example of building mobile02 from a local repo
|
||||
sudo nixos-rebuild switch --impure --flake .#mobile02
|
||||
```
|
||||
|
||||
There is no default output, so if the current hostname doesn't match a host, you will get
|
||||
an error. Building this config should be non destructive to any existing dotfiles, but
|
||||
will remove all users (not home directories) from the system other than `user01`, who's
|
||||
default password is `qwer`. No, that isn't my usual password.
|
||||
There is no default output, so if the current hostname doesn't match a host, you will get an error.
|
||||
Building this config should be non destructive to any existing dotfiles, but will remove all users (not home directories)
|
||||
from the system other than `user01`, who's default password is `qwer`.
|
||||
|
||||
### Binaries
|
||||
|
||||
Any binary can be run with the same base command:
|
||||
|
||||
Any binary can be run with the same base command (will change when merged to main)
|
||||
```bash
|
||||
nix run "git+https://git.voidarc.co.uk/voidarc/nixos.git#appname"
|
||||
nix run "git+https://git.voidarc.co.uk/voidarc/nixos.git?ref=dendritic#appname"
|
||||
```
|
||||
|
||||
`appname` can be substituted for the name of any folder in the `modules/features` dir, ie
|
||||
`kitty` or `otter-launcher`. Most if not all modules in a subdirectory will have a module
|
||||
name corresponding to that directory. This only applies for `default.nix` files, so files
|
||||
that have different names are not expected to follow this convention, even if there is not
|
||||
a `default.nix` in that directory.
|
||||
|
||||
## Issues and contributing
|
||||
|
||||
Because this is a private git server, there is no inline way to submit issues,
|
||||
contributions, or feature ideas. If you should wish, you may send such requests to
|
||||
<admin@voidarc.co.uk>, with the format found in [CONTRIBUTING.md]( CONTRIBUTING.md ). Failure to follow the
|
||||
format found there will most likely result in your email being ignored.
|
||||
`Appname` can be substituted for the name of any folder in the `modules/features` dir, ie `kitty` or `otter-launcher`
|
||||
|
||||
|
Before Width: | Height: | Size: 1.3 MiB |
|
Before Width: | Height: | Size: 1.7 MiB |
514
flake.lock
generated
16
flake.nix
@@ -4,17 +4,11 @@
|
||||
inputs = {
|
||||
# System
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-26.05";
|
||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
|
||||
# Apps
|
||||
nvim.url = "git+https://git.voidarc.co.uk/voidarc/nvim";
|
||||
hyprland = {
|
||||
url = "git+https://git.voidarc.co.uk/voidarc/hypr";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
hyprgrass = {
|
||||
url = "github:horriblename/hyprgrass";
|
||||
inputs.hyprland.follows = "hyprland/hyprland";
|
||||
};
|
||||
otter-launcher = {
|
||||
url = "github:kuokuo123/otter-launcher";
|
||||
@@ -35,14 +29,12 @@
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
woomer = {
|
||||
url = "github:voidarclabs/woomer";
|
||||
url = "github:coffeeispower/woomer";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
wshowkeys.url = "github:DreamMaoMao/wshowkeys";
|
||||
|
||||
# Secrets and stuff
|
||||
sops-nix = {
|
||||
url = "github:Mic92/sops-nix";
|
||||
wshowkeys.url = "github:voidarclabs/wshowkeys";
|
||||
weylus = {
|
||||
url = "github:voidarclabs/WeylusCommunityEdition";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
|
||||
@@ -3,16 +3,11 @@
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.gaming = moduleWithSystem ({pkgs, unstablePkgs, ...}: let
|
||||
flake.nixosModules.gaming = moduleWithSystem ({...}: let
|
||||
modules = with self.nixosModules; [
|
||||
steam
|
||||
];
|
||||
in {
|
||||
imports = modules;
|
||||
environment.systemPackages = with pkgs; [
|
||||
prismlauncher
|
||||
] ++ (with unstablePkgs; [
|
||||
bs-manager
|
||||
]);
|
||||
});
|
||||
}
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
{moduleWithSystem, ...}: {
|
||||
flake.nixosModules.music = moduleWithSystem ({pkgs, unfreePkgs, ...}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
ardour
|
||||
unfreePkgs.vital
|
||||
distrho-ports
|
||||
cardinal
|
||||
calf
|
||||
];
|
||||
});
|
||||
}
|
||||
@@ -1,12 +1,12 @@
|
||||
{
|
||||
self,
|
||||
self,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.name = moduleWithSystem ({
|
||||
pkgs,
|
||||
self',
|
||||
inputs',
|
||||
inputs',
|
||||
...
|
||||
}: let
|
||||
modules = with self.nixosModules; [];
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
{moduleWithSystem, ...}: {
|
||||
flake.nixosModules.distcc = moduleWithSystem ({unstablePkgs, ...}: {
|
||||
services.distccd = {
|
||||
enable = true;
|
||||
allowedClients = ["192.168.1.0/24"];
|
||||
};
|
||||
systemd.services.distccd = {
|
||||
serviceConfig = {
|
||||
Environment = [
|
||||
"\"PATH=/run/wrappers/bin:/run/current-system/sw/bin:/usr/bin:/bin\""
|
||||
"DISTCCD_PATH=/run/current-system/sw/bin:/run/wrappers/bin:/usr/bin:/bin"
|
||||
];
|
||||
};
|
||||
};
|
||||
environment.systemPackages = let
|
||||
pkgs = unstablePkgs;
|
||||
lib = pkgs.lib;
|
||||
in [
|
||||
(pkgs.writeShellScriptBin "x86_64-pc-linux-gnu-gcc" ''
|
||||
exec ${lib.getExe pkgs.gcc15} "$@"
|
||||
'')
|
||||
(pkgs.writeShellScriptBin "x86_64-pc-linux-gnu-g++" ''
|
||||
exec ${lib.getExe' pkgs.gcc15 "g++"} "$@"
|
||||
'')
|
||||
];
|
||||
});
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
inputs,
|
||||
inputs,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
@@ -15,10 +15,11 @@
|
||||
}: {
|
||||
packages = {
|
||||
gotify-desktop = let
|
||||
# Requires gpg keyring cert in order to get api key
|
||||
config-file = pkgs.writeText "config.toml" ''
|
||||
[gotify]
|
||||
url = "wss://ntfy.voidarc.co.uk:443"
|
||||
token = { command = "cat /run/secrets/gotify-desktop-key"}
|
||||
token = { command = "${pkgs.gnupg}/bin/gpg --quiet --batch --decrypt ${./gotify-key.secret}" }
|
||||
[notification]
|
||||
min_priority = 1
|
||||
'';
|
||||
|
||||
@@ -8,13 +8,11 @@
|
||||
self',
|
||||
pkgs,
|
||||
inputs',
|
||||
flakeLocation,
|
||||
...
|
||||
}: {config, ...}: let
|
||||
modules = with self.nixosModules; [
|
||||
audio
|
||||
systemTheme
|
||||
quickshell
|
||||
];
|
||||
|
||||
runtimePkgs = self'.packages.hyprland.passthru.runtimePackages;
|
||||
@@ -26,66 +24,32 @@
|
||||
else lib.getExe pkg;
|
||||
in {
|
||||
imports = modules;
|
||||
|
||||
options = {
|
||||
tabletSupport = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "Enable tablet support across all modules";
|
||||
};
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
package = self'.packages.hyprland;
|
||||
};
|
||||
|
||||
config = {
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
package = self'.packages.hyprland;
|
||||
};
|
||||
services.displayManager.defaultSession = "hyprland";
|
||||
services.xserver.enable = true;
|
||||
security.polkit.enable = true;
|
||||
|
||||
services.displayManager.defaultSession = "hyprland";
|
||||
services.xserver.enable = true;
|
||||
services.seatd.enable = true;
|
||||
security.polkit.enable = true;
|
||||
environment.systemPackages = with pkgs; [
|
||||
hyprlock
|
||||
gsettings-desktop-schemas
|
||||
];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gsettings-desktop-schemas
|
||||
glib
|
||||
];
|
||||
system.activationScripts.hyprRuntimeEnv = lib.stringAfter ["specialfs"] ''
|
||||
mkdir -p /run/hypr-runtime-env/bin
|
||||
${lib.concatStringsSep "\n" (lib.mapAttrsToList (name: pkg: ''
|
||||
ln -sfn ${runtimeTarget name pkg} /run/hypr-runtime-env/bin/${name}
|
||||
'')
|
||||
runtimePkgs)}
|
||||
'';
|
||||
|
||||
system.activationScripts.hyprRuntimeEnv = lib.stringAfter ["specialfs"] ''
|
||||
mkdir -p /run/hypr-runtime-env/bin
|
||||
${lib.concatStringsSep "\n" (lib.mapAttrsToList (name: pkg: ''
|
||||
ln -sfn ${runtimeTarget name pkg} /run/hypr-runtime-env/bin/${name}
|
||||
'')
|
||||
runtimePkgs)}
|
||||
'';
|
||||
|
||||
system.activationScripts.hyprConfig = let
|
||||
hyprgrassPath = "${inputs'.hyprgrass.packages.default}/lib/libhyprgrass.so";
|
||||
pluginFile = pkgs.writeText "plugins.lua" ''
|
||||
hl.on("hyprland.start", function ()
|
||||
${lib.optionalString config.tabletSupport ''
|
||||
hl.exec_cmd("hyprctl plugin load ${hyprgrassPath}")
|
||||
''}
|
||||
end)
|
||||
'';
|
||||
# Easy way to get nix runtime info (ie the directory the config is at)
|
||||
# into hyprland to run commands and stuff
|
||||
runtimeFile = pkgs.writeText "runtime.lua" ''
|
||||
hl.on("hyprland.start", function ()
|
||||
${lib.optionalString (flakeLocation != "") ''
|
||||
hl.exec_cmd( 'curl -X POST -H "Content-Type: application/json" -d "{\"ref\":\"$(git -C ${flakeLocation} rev-parse HEAD)\", \"status\":\"$(git -C ${flakeLocation} diff --quiet && echo "clean" || echo "dirty")\"}" https://n8n.voidarc.co.uk/webhook/config-checker' )
|
||||
''}
|
||||
end)
|
||||
'';
|
||||
in
|
||||
lib.stringAfter ["specialfs"] ''
|
||||
mkdir -p /run/hypr/config
|
||||
rm -rf /run/hypr/config/*
|
||||
ln -sfn ${inputs'.hyprland.packages.repo-files}/* /run/hypr/config
|
||||
ln -sfn ${pluginFile} /run/hypr/config/plugins.lua
|
||||
ln -sfn ${runtimeFile} /run/hypr/config/runtime.lua
|
||||
'';
|
||||
};
|
||||
system.activationScripts.hyprConfig = lib.stringAfter ["specialfs"] ''
|
||||
mkdir -p /run/hypr/config
|
||||
ln -sfn ${inputs'.hyprland.packages.repo-files}/* /run/hypr/config
|
||||
'';
|
||||
});
|
||||
perSystem = {
|
||||
self',
|
||||
@@ -97,7 +61,6 @@
|
||||
hyprland = inputs'.hyprland.packages.default.override {
|
||||
flags."--config" = "/run/hypr/config/hyprland.lua";
|
||||
env."MODULES_ROOT" = "/run/hypr/config/modules";
|
||||
env."HYPRLAND_ROOT" = "/run/hypr/config";
|
||||
runtimePackages =
|
||||
inputs.hyprland.lib.defaultRuntimePkgs.${system}
|
||||
// {
|
||||
@@ -105,9 +68,10 @@
|
||||
kitty = self'.packages.kitty;
|
||||
gotify-desktop = self'.packages.gotify-desktop;
|
||||
otter-launcher = self'.packages.otter-launcher;
|
||||
hyprlock = self'.packages.hyprlock;
|
||||
quickshell = self'.packages.quickshell;
|
||||
wshowkeys = self'.packages.wshowkeys;
|
||||
waybar = self'.packages.waybar;
|
||||
wlogout = self'.packages.wlogout;
|
||||
way-edges = self'.packages.way-edges;
|
||||
};
|
||||
};
|
||||
|
||||
|
Before Width: | Height: | Size: 3.5 KiB |
@@ -1,129 +0,0 @@
|
||||
{
|
||||
inputs,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.hyprlock = moduleWithSystem ({self', ...}: {
|
||||
environment.systemPackages = with self'.packages; [
|
||||
hyprock
|
||||
];
|
||||
});
|
||||
perSystem = {pkgs, ...}: {
|
||||
packages.hyprlock = inputs.wrappers.wrappers.hyprlock.wrap {
|
||||
inherit pkgs;
|
||||
"hyprlock.conf".content = ''
|
||||
source = ${./mocha.conf}
|
||||
|
||||
$accent = $mauve
|
||||
$accentAlpha = $mauveAlpha
|
||||
$font = FiraMono Nerd Font
|
||||
|
||||
# GENERAL
|
||||
general {
|
||||
hide_cursor = true
|
||||
}
|
||||
|
||||
# BACKGROUND
|
||||
background {
|
||||
monitor =
|
||||
path = screenshot
|
||||
blur_passes = 3
|
||||
color = rgba(0, 0, 0, 0)
|
||||
}
|
||||
|
||||
|
||||
# LAYOUT
|
||||
label {
|
||||
monitor =
|
||||
text = Layout: $LAYOUT
|
||||
color = $text
|
||||
font_size = 25
|
||||
font_family = $font
|
||||
position = 30, -30
|
||||
halign = left
|
||||
valign = top
|
||||
}
|
||||
|
||||
# TIME
|
||||
label {
|
||||
monitor =
|
||||
text = $TIME
|
||||
color = $text
|
||||
font_size = 90
|
||||
font_family = $font
|
||||
position = -30, 0
|
||||
halign = right
|
||||
valign = top
|
||||
}
|
||||
|
||||
# DATE
|
||||
label {
|
||||
monitor =
|
||||
text = cmd[update:43200000] date +"%A, %d %B %Y"
|
||||
color = $text
|
||||
font_size = 25
|
||||
font_family = $font
|
||||
position = -30, -150
|
||||
halign = right
|
||||
valign = top
|
||||
}
|
||||
|
||||
# FINGERPRINT
|
||||
{
|
||||
monitor = "";
|
||||
text = "$FPRINTPROMPT";
|
||||
color = "$text";
|
||||
font_size = 14;
|
||||
font_family = $font;
|
||||
position = "0, -107";
|
||||
halign = "center";
|
||||
valign = "center";
|
||||
}
|
||||
|
||||
image {
|
||||
path = ${./cat.png}
|
||||
size = 240
|
||||
border_color = transparent
|
||||
rounding = 0
|
||||
position = 0, 7px
|
||||
}
|
||||
|
||||
# USER AVATAR
|
||||
image {
|
||||
monitor =
|
||||
path = $HOME/.face
|
||||
size = 100
|
||||
border_color = $accent
|
||||
position = 0, 75
|
||||
halign = center
|
||||
valign = center
|
||||
}
|
||||
|
||||
# INPUT FIELD
|
||||
input-field {
|
||||
monitor =
|
||||
size = 300, 60
|
||||
outline_thickness = 4
|
||||
dots_size = 0.2
|
||||
dots_spacing = 0.2
|
||||
dots_center = true
|
||||
outer_color = $accent
|
||||
inner_color = $surface0
|
||||
font_color = $text
|
||||
fade_on_empty = false
|
||||
placeholder_text = <span foreground="##$textAlpha"><i> Logged in as </i><span foreground="##$accentAlpha">$USER</span></span>
|
||||
hide_input = false
|
||||
check_color = $accent
|
||||
fail_color = $red
|
||||
fail_text = <i>$FAIL <b>($ATTEMPTS)</b></i>
|
||||
capslock_color = $yellow
|
||||
position = 0, -47
|
||||
halign = center
|
||||
valign = center
|
||||
}
|
||||
|
||||
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,79 +0,0 @@
|
||||
|
||||
$rosewater = rgb(f5e0dc)
|
||||
$rosewaterAlpha = f5e0dc
|
||||
|
||||
$flamingo = rgb(f2cdcd)
|
||||
$flamingoAlpha = f2cdcd
|
||||
|
||||
$pink = rgb(f5c2e7)
|
||||
$pinkAlpha = f5c2e7
|
||||
|
||||
$mauve = rgb(cba6f7)
|
||||
$mauveAlpha = cba6f7
|
||||
|
||||
$red = rgb(f38ba8)
|
||||
$redAlpha = f38ba8
|
||||
|
||||
$maroon = rgb(eba0ac)
|
||||
$maroonAlpha = eba0ac
|
||||
|
||||
$peach = rgb(fab387)
|
||||
$peachAlpha = fab387
|
||||
|
||||
$yellow = rgb(f9e2af)
|
||||
$yellowAlpha = f9e2af
|
||||
|
||||
$green = rgb(a6e3a1)
|
||||
$greenAlpha = a6e3a1
|
||||
|
||||
$teal = rgb(94e2d5)
|
||||
$tealAlpha = 94e2d5
|
||||
|
||||
$sky = rgb(89dceb)
|
||||
$skyAlpha = 89dceb
|
||||
|
||||
$sapphire = rgb(74c7ec)
|
||||
$sapphireAlpha = 74c7ec
|
||||
|
||||
$blue = rgb(89b4fa)
|
||||
$blueAlpha = 89b4fa
|
||||
|
||||
$lavender = rgb(b4befe)
|
||||
$lavenderAlpha = b4befe
|
||||
|
||||
$text = rgb(cdd6f4)
|
||||
$textAlpha = cdd6f4
|
||||
|
||||
$subtext1 = rgb(bac2de)
|
||||
$subtext1Alpha = bac2de
|
||||
|
||||
$subtext0 = rgb(a6adc8)
|
||||
$subtext0Alpha = a6adc8
|
||||
|
||||
$overlay2 = rgb(9399b2)
|
||||
$overlay2Alpha = 9399b2
|
||||
|
||||
$overlay1 = rgb(7f849c)
|
||||
$overlay1Alpha = 7f849c
|
||||
|
||||
$overlay0 = rgb(6c7086)
|
||||
$overlay0Alpha = 6c7086
|
||||
|
||||
$surface2 = rgb(585b70)
|
||||
$surface2Alpha = 585b70
|
||||
|
||||
$surface1 = rgb(45475a)
|
||||
$surface1Alpha = 45475a
|
||||
|
||||
$surface0 = rgb(313244)
|
||||
$surface0Alpha = 313244
|
||||
|
||||
$base = rgb(1e1e2e)
|
||||
$baseAlpha = 1e1e2eee
|
||||
|
||||
$mantle = rgb(181825)
|
||||
$mantleAlpha = 181825
|
||||
|
||||
$crust = rgb(11111b)
|
||||
$crustAlpha = 11111b
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
set $mod Mod1
|
||||
set $mod Mod4
|
||||
set $term kitty
|
||||
set $menu dmenu_run
|
||||
|
||||
|
||||
@@ -18,21 +18,17 @@
|
||||
windowManager.i3 = {
|
||||
enable = true;
|
||||
package = self'.packages.i3;
|
||||
extraPackages = with pkgs; [
|
||||
dmenu
|
||||
i3status
|
||||
xinit
|
||||
];
|
||||
extraPackages = with pkgs;
|
||||
[
|
||||
dmenu
|
||||
i3status
|
||||
xinit
|
||||
];
|
||||
};
|
||||
};
|
||||
});
|
||||
perSystem = {
|
||||
pkgs,
|
||||
lib,
|
||||
self',
|
||||
...
|
||||
}: {
|
||||
packages.i3 = lib.warn "i3 is no longer maintained and therefore marked as deprecated" inputs.wrappers.lib.wrapPackage ({...}: {
|
||||
perSystem = {pkgs, self', ...}: {
|
||||
packages.i3 = inputs.wrappers.lib.wrapPackage ({...}: {
|
||||
inherit pkgs;
|
||||
package = pkgs.i3;
|
||||
runtimePkgs = with pkgs;
|
||||
|
||||
@@ -30,8 +30,6 @@
|
||||
font_size = 11;
|
||||
scrollbar = "never";
|
||||
pixel_scroll = false;
|
||||
remember_window_position = false;
|
||||
remember_window_size = false;
|
||||
window_padding_width = 9;
|
||||
background_opacity = 0.50;
|
||||
confirm_os_window_close = 0;
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
{moduleWithSystem, ...}: {
|
||||
flake.nixosModules.libvirt = moduleWithSystem ({...}: {
|
||||
virtualisation.libvirtd = {
|
||||
enable = true;
|
||||
qemu = {
|
||||
runAsRoot = true;
|
||||
};
|
||||
};
|
||||
programs.virt-manager.enable = true;
|
||||
});
|
||||
}
|
||||
@@ -10,20 +10,27 @@ clear_screen_after_execution = false
|
||||
loop_mode = false # don't quit after executing a module, useful with scratchpads; stderr is hidden in loop mode
|
||||
external_editor = "nvim" # if set, press ctrl+x ctrl+ee (or v in vi normal mode) to edit prompt in the specified program
|
||||
delay_startup = 0 # sometimes the otter runs too fast even before the terminal window is ready; this slows it down by milliseconds; useful when chafa image is skewed
|
||||
height = 11
|
||||
|
||||
[interface]
|
||||
# use three quotes to write longer codes
|
||||
header = """
|
||||
\x1b[1;38;2;203;166;247m$USER@nixos\x1b[0m
|
||||
"""
|
||||
\x1b[1;38;2;203;166;247m$USER@nixos\x1b[0m
|
||||
"""
|
||||
header_cmd = '' # run a command and print stdout above the header
|
||||
header_cmd_trimmed_lines = 0 # remove trailing lines from header_cmd output, in case of some programs appending excessive empty lines
|
||||
placeholder = "execute" # at the input field
|
||||
place_holder = "execute" # at the input field
|
||||
suggestion_mode = "list" # available options: list, hint
|
||||
suggestion_position = "bottom"
|
||||
seperator = true
|
||||
separator = """
|
||||
$( \
|
||||
text=" "; \
|
||||
printf "\u001B[0;90m$text \
|
||||
$(printf -v line '%*s' \"$(( COLUMNS - $(printf "$text" | wc -m) - 3 ))\" ''; printf '%s' \"${line// /─}\")" \
|
||||
)"""
|
||||
footer = "" # add a line after suggestion list
|
||||
suggestion_lines = 7 # 0 to disable suggestions and tab completion
|
||||
list_prefix = " "
|
||||
selection_prefix = "\u001B[31;1m "
|
||||
prefix_padding = 3 # format prefixes to have a uniformed width
|
||||
default_module_message = " \u001B[33mlaunch\u001B[0m app" # shown when the default module is in use
|
||||
empty_module_message = "" # shown when the empty module is in use
|
||||
customized_list_order = false # false to list modules alphabetically; true to list as per the configured order in the below [[modules]] section
|
||||
@@ -34,8 +41,9 @@ prefix_color = "\u001B[33m"
|
||||
description_color = "\u001B[39m"
|
||||
place_holder_color = "\u001B[30m"
|
||||
hint_color = "\u001B[30m" # suggestion color in hint mode
|
||||
# Pad interface
|
||||
padding = [0, 0, 0, 2]
|
||||
# move the interface rightward or downward
|
||||
move_interface_right = 21
|
||||
move_interface_down = 0
|
||||
|
||||
[[modules]]
|
||||
description = "programs"
|
||||
|
||||
@@ -18,12 +18,9 @@
|
||||
packages = {
|
||||
otter-launcher = let
|
||||
extra-config = ''
|
||||
[image]
|
||||
format = "kitty"
|
||||
path = "${./cat.png}"
|
||||
width = 20
|
||||
position = "left"
|
||||
|
||||
[overlay]
|
||||
overlay_cmd = "${lib.getExe pkgs.kitty} +kitten icat --fit height --align left --no-trailing-newline ${./cat.png}"
|
||||
overlay_trimmed_lines = 0
|
||||
'';
|
||||
final-config = pkgs.writeText "config.toml" ''
|
||||
${extra-config}
|
||||
|
||||
@@ -3,24 +3,11 @@
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.quickshell = moduleWithSystem ({
|
||||
self',
|
||||
pkgs,
|
||||
...
|
||||
}: {config, ...}: {
|
||||
environment.systemPackages = with self'.packages;
|
||||
[
|
||||
quickshell
|
||||
]
|
||||
++ (
|
||||
if config.tabletSupport == true
|
||||
then
|
||||
# If on tablet enable on screen keyboard
|
||||
(with pkgs; [
|
||||
wvkbd
|
||||
])
|
||||
else []
|
||||
);
|
||||
flake.nixosModules.quickshell = moduleWithSystem ({self', ...}: {
|
||||
services.upower.enable = true;
|
||||
environment.systemPackages = with self'.packages; [
|
||||
quickshell
|
||||
];
|
||||
});
|
||||
perSystem = {pkgs, ...}: {
|
||||
packages.quickshell = inputs.wrappers.wrappers.quickshell.wrap {
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
{pkgs, ...}:
|
||||
# Sable is a Matrix client (a Cinny fork). It is not in nixpkgs and upstream
|
||||
# ships only prebuilt artifacts, so wrap the published AppImage rather than
|
||||
# building from source. Bump `version` and `hash` together on updates; the
|
||||
# hash can be regenerated with:
|
||||
# nix store prefetch-file --name sable.AppImage <url>
|
||||
let
|
||||
pname = "sable";
|
||||
version = "1.22.6";
|
||||
|
||||
src = pkgs.fetchurl {
|
||||
url = "https://github.com/SableClient/Sable/releases/download/v${version}/Sable-${version}-linux-x86_64.AppImage";
|
||||
hash = "sha256-DFZZrdwSF/jrlrRQ9gWguDe7AOQVMablEUcD1l3Giic=";
|
||||
};
|
||||
|
||||
contents = pkgs.appimageTools.extract {inherit pname version src;};
|
||||
in
|
||||
pkgs.appimageTools.wrapType2 {
|
||||
inherit pname version src;
|
||||
|
||||
extraInstallCommands = ''
|
||||
install -Dm444 ${contents}/${pname}.desktop \
|
||||
$out/share/applications/${pname}.desktop
|
||||
cp -r ${contents}/usr/share/icons $out/share/ 2>/dev/null || true
|
||||
substituteInPlace $out/share/applications/${pname}.desktop \
|
||||
--replace-quiet 'Exec=AppRun' 'Exec=${pname}' \
|
||||
--replace-quiet 'Exec=sable' 'Exec=${pname}'
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Matrix client focused on quality-of-life features (Cinny fork)";
|
||||
homepage = "https://sable.moe";
|
||||
platforms = ["x86_64-linux"];
|
||||
mainProgram = pname;
|
||||
};
|
||||
}
|
||||
@@ -1,12 +0,0 @@
|
||||
{
|
||||
self,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.sable = moduleWithSystem ({self', ...}: {
|
||||
environment.systemPackages = with self'.packages; [sable];
|
||||
});
|
||||
perSystem = {pkgs, ...}: {
|
||||
packages.sable = pkgs.callPackage ./_sable.nix {};
|
||||
};
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
{inputs, ...}: {
|
||||
flake.nixosModules.sops = {config, ...}: {
|
||||
imports = [inputs.sops-nix.nixosModules.sops];
|
||||
|
||||
sops = {
|
||||
age.keyFile = "/etc/sops/age/keys.txt";
|
||||
defaultSopsFile = ./secrets.yaml;
|
||||
|
||||
secrets = {
|
||||
gotify-desktop-key = {
|
||||
# Make readable
|
||||
mode = "0444";
|
||||
};
|
||||
};
|
||||
templates = {
|
||||
"gotify-desktop-key".content = config.sops.placeholder.gotify-desktop-key;
|
||||
};
|
||||
};
|
||||
# Make the secrets dir readable to normal users
|
||||
systemd.tmpfiles.rules = [
|
||||
"d /run/secrets 0755 root root -"
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
gotify-desktop-key: ENC[AES256_GCM,data:kMCJfkrf5jKAgjX9hT9S,iv:T/zDp94522MeW6V3874JgyaQCx5H1qY+DsZOoPBaC1w=,tag:Csu+9imWiMBYXaE0uXzMsg==,type:str]
|
||||
matrix-recovery-key: ENC[AES256_GCM,data:JssA1EJwxV3ZFXazKOhy0hF08x8qvQ1rzcy0vd3ko3mLvpTDMK5iHGfFf9xO4oK7cZFHGoSsXqaGzTs=,iv:TpBJzYulg8L8Yl7NpZl3u81U7hmxll4CYQ8XdbBOrSY=,tag:eP0Ubmx26e3wjzVbYO4Vmw==,type:str]
|
||||
matrix-cinny-key: ENC[AES256_GCM,data:1vfnRIFTIpLcySHi8Q5PGx3whxNATQxoWMqkDAfbMvIUWDVQcQBW6sHnllyB4364V1LMmq2JANqqyJM=,iv:DpEo993W8UgnJ/aeEyOpcgoNBiSdmBEoWPECB7BJr/Y=,tag:tZfAsGsppkC31vFbjWlvog==,type:str]
|
||||
sops:
|
||||
age:
|
||||
- enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBKR3ZQTzVxWWFFam91Y1V0
|
||||
VGdnSkZFcmJ6RG1JOHp3R1puY2ZRazkxbmlZCjYyek5QOWEzaWg2bnpXc0ZrNks0
|
||||
QUl2Nk45R1h6WjFTSWlveUF5RHlRcEUKLS0tIE5mYmQ1aWpvNGNjYzJrUW9DSXpm
|
||||
MS8ralY4WDI1YjhNSmRWYWxYL3VkbDAKQuLvaHiUXkwiaOif10vrl3LFh/4mKQUV
|
||||
Y3HJ9Jr3DAyokEzN7S/S1v50coM1bE4d74SS/V1uIw0nYdZRUGrZww==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
recipient: age1rg4rsns375z2zj4tv8cyqtjl504fw8tprlmj2w057dz6ztttjstsgjvkvy
|
||||
lastmodified: "2026-10-04T19:47:26Z"
|
||||
mac: ENC[AES256_GCM,data:0OMarmjmNE5CziZqJbsB96K4u9QgnrB5FkuM3ILgxsxjb6UQLpqjql/th0KIDDAgyVFy9K5KwtocBYeLfuhYkLuj6i8EtlBAyi4KG+WCgy4LF+st8iaTxPy/Xn5yLxbp15DURXPuXrvDs1kpCqFWvfAXAABx/GyHUnYNwpmUytk=,iv:2O3NnZrvwN6CxFcdV/FDBurgRbthshDQ7tpbeHQAlCc=,tag:CzZV/PS26ngz5f4lGs9hzA==,type:str]
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.13.3
|
||||
@@ -1,11 +0,0 @@
|
||||
{
|
||||
self,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.tailscale = moduleWithSystem ({...}: {
|
||||
services.tailscale = {
|
||||
enable = true;
|
||||
};
|
||||
});
|
||||
}
|
||||
@@ -8,8 +8,8 @@
|
||||
waybar
|
||||
];
|
||||
});
|
||||
perSystem = {pkgs, lib, ...}: {
|
||||
packages.waybar = lib.warn "Waybar is deprecated and no longer maintained. Please use pacakges.quickshell instead" inputs.wrappers.wrappers.waybar.wrap {
|
||||
perSystem = {pkgs, ...}: {
|
||||
packages.waybar = inputs.wrappers.wrappers.waybar.wrap {
|
||||
inherit pkgs;
|
||||
"style.css".path = ./style.css;
|
||||
configFile.content = ''
|
||||
|
||||
9
modules/features/weylus/default.nix
Normal file
@@ -0,0 +1,9 @@
|
||||
{moduleWithSystem, ...}: {
|
||||
flake.nixosModules.weylus = moduleWithSystem ({inputs', ...}: {
|
||||
programs.weylus = {
|
||||
enable = true;
|
||||
package = inputs'.weylus.packages.default;
|
||||
users = ["user01"];
|
||||
};
|
||||
});
|
||||
}
|
||||
|
Before Width: | Height: | Size: 102 KiB |
|
Before Width: | Height: | Size: 199 KiB |
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
0
modules/features/wpaperd/wallpapers/wallpaper-sun.jpg
Normal file → Executable file
|
Before Width: | Height: | Size: 592 KiB After Width: | Height: | Size: 592 KiB |
@@ -17,11 +17,6 @@ final_space = true
|
||||
alignment = 'left'
|
||||
newline = true
|
||||
|
||||
[[blocks.segments]] # Hostname
|
||||
type = 'text'
|
||||
style = 'plain'
|
||||
template = '{{ if .Env.SSH_CLIENT }}<green> {{.HostName}}</> <#7f849c>|</> {{ end }}'
|
||||
|
||||
[[blocks.segments]]
|
||||
type = 'text'
|
||||
style = 'plain'
|
||||
@@ -39,6 +34,11 @@ template = '''
|
||||
{{- end -}}
|
||||
'''
|
||||
|
||||
[[blocks.segments]] # Hostname
|
||||
type = 'text'
|
||||
style = 'plain'
|
||||
template = '{{ if eq .HostName "server02" }}<green> {{.HostName}}</> <#7f849c>|</> {{ end }}'
|
||||
|
||||
[[blocks.segments]] # Python venv
|
||||
type = 'text'
|
||||
style = 'plain'
|
||||
|
||||
@@ -25,85 +25,85 @@
|
||||
});
|
||||
perSystem = {
|
||||
pkgs,
|
||||
self',
|
||||
lib,
|
||||
flakeLocation,
|
||||
self',
|
||||
...
|
||||
}: {
|
||||
packages = {
|
||||
zsh = lib.warnIf (flakeLocation == "") "Flake Location is undefined. Are you building in the right directory?"
|
||||
inputs.wrappers.wrappers.zsh.wrap {
|
||||
inherit pkgs;
|
||||
runtimePkgs = [pkgs.carapace pkgs.devenv pkgs.fzf];
|
||||
zshAliases = {
|
||||
ls = "${lib.getExe pkgs.lsd} -l";
|
||||
v = lib.getExe self'.packages.nvim;
|
||||
cat = lib.getExe pkgs.bat;
|
||||
lg = lib.getExe pkgs.lazygit;
|
||||
man = "man -P \"${lib.getExe pkgs.bat} -p\"";
|
||||
nsh = "nix-shell -p";
|
||||
nrs =
|
||||
if flakeLocation != ""
|
||||
then "( cd ${flakeLocation} && sudo nixos-rebuild switch --impure --flake . )"
|
||||
else "echo 'Flake location not specified. Did you build with --impure?'";
|
||||
vinix =
|
||||
if flakeLocation != ""
|
||||
then "nvim --cmd 'cd ${flakeLocation}'"
|
||||
else "echo 'Flake location not specified. Did you build with --impure?'";
|
||||
zsh = let
|
||||
flakeLocation = builtins.getEnv "PWD";
|
||||
in
|
||||
lib.warnIf (flakeLocation == "") "Flake Location is undefined. Are you building in the right directory?"
|
||||
inputs.wrappers.wrappers.zsh.wrap {
|
||||
inherit pkgs;
|
||||
runtimePkgs = [pkgs.carapace pkgs.devenv pkgs.fzf];
|
||||
zshAliases = {
|
||||
ls = "${lib.getExe pkgs.lsd} -l";
|
||||
v = lib.getExe self'.packages.nvim;
|
||||
cat = lib.getExe pkgs.bat;
|
||||
lg = lib.getExe pkgs.lazygit;
|
||||
man = "man -P \"${lib.getExe pkgs.bat} -p\"";
|
||||
nsh = "nix-shell -p";
|
||||
nrs =
|
||||
if flakeLocation != ""
|
||||
then "( cd ${flakeLocation} && sudo nixos-rebuild switch --impure --flake . )"
|
||||
else "echo 'Flake location not specified. Did you build with --impure?'";
|
||||
vinix =
|
||||
if flakeLocation != ""
|
||||
then "nvim --cmd 'cd ${flakeLocation}'"
|
||||
else "echo 'Flake location not specified. Did you build with --impure?'";
|
||||
};
|
||||
zshrc.content = ''
|
||||
source ${./devenv.zsh}
|
||||
|
||||
if (( ''${+terminfo[smkx]} )) && (( ''${+terminfo[rmkx]} )); then
|
||||
function zle-line-init() { echoti smkx }
|
||||
function zle-line-finish() { echoti rmkx }
|
||||
zle -N zle-line-init
|
||||
zle -N zle-line-finish
|
||||
fi
|
||||
|
||||
autoload -U compinit && compinit
|
||||
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
|
||||
zstyle ':completion:*' format $'\e[2;37mCompleting %d\e[m'
|
||||
source <(${lib.getExe pkgs.carapace} _carapace)
|
||||
zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
|
||||
|
||||
autoload -U select-word-style
|
||||
select-word-style bash
|
||||
|
||||
autoload -U up-line-or-beginning-search down-line-or-beginning-search
|
||||
zle -N up-line-or-beginning-search
|
||||
zle -N down-line-or-beginning-search
|
||||
bindkey "^[OA" up-line-or-beginning-search
|
||||
bindkey "^[OB" down-line-or-beginning-search
|
||||
|
||||
bindkey "^[[1;5C" forward-word
|
||||
bindkey "^[[1;5D" backward-word
|
||||
bindkey "^[[3;5~" kill-word
|
||||
bindkey "^H" backward-kill-word
|
||||
|
||||
source <(${lib.getExe pkgs.fzf} --zsh)
|
||||
|
||||
setopt NO_CASE_GLOB
|
||||
|
||||
${lib.getExe pkgs.any-nix-shell} zsh --info-right | source /dev/stdin
|
||||
|
||||
export EDITOR=nvim
|
||||
|
||||
eval "$(${lib.getExe self'.packages.ohMyPosh} init zsh)"
|
||||
|
||||
eval "$(${lib.getExe pkgs.devenv} hook zsh)"
|
||||
|
||||
typeset -ag precmd_functions
|
||||
if (( ! ''${precmd_functions[(I)__devenv_reload_apply]} )); then
|
||||
precmd_functions+=(__devenv_reload_apply)
|
||||
fi
|
||||
if (( ! ''${precmd_functions[(I)__devenv_restore_path]} )); then
|
||||
precmd_functions+=(__devenv_restore_path)
|
||||
fi
|
||||
'';
|
||||
};
|
||||
zshrc.content = ''
|
||||
source ${./devenv.zsh}
|
||||
|
||||
if (( ''${+terminfo[smkx]} )) && (( ''${+terminfo[rmkx]} )); then
|
||||
function zle-line-init() { echoti smkx }
|
||||
function zle-line-finish() { echoti rmkx }
|
||||
zle -N zle-line-init
|
||||
zle -N zle-line-finish
|
||||
fi
|
||||
|
||||
autoload -U compinit && compinit
|
||||
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
|
||||
zstyle ':completion:*' format $'\e[2;37mCompleting %d\e[m'
|
||||
source <(${lib.getExe pkgs.carapace} _carapace)
|
||||
zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
|
||||
|
||||
autoload -U select-word-style
|
||||
select-word-style bash
|
||||
|
||||
autoload -U up-line-or-beginning-search down-line-or-beginning-search
|
||||
zle -N up-line-or-beginning-search
|
||||
zle -N down-line-or-beginning-search
|
||||
bindkey "^[OA" up-line-or-beginning-search
|
||||
bindkey "^[OB" down-line-or-beginning-search
|
||||
|
||||
bindkey "^[[1;5C" forward-word
|
||||
bindkey "^[[1;5D" backward-word
|
||||
bindkey "^[[3;5~" kill-word
|
||||
bindkey "^H" backward-kill-word
|
||||
|
||||
source <(${lib.getExe pkgs.fzf} --zsh)
|
||||
|
||||
setopt NO_CASE_GLOB
|
||||
|
||||
if command -v ${lib.getExe pkgs.nix-your-shell} > /dev/null; then
|
||||
${lib.getExe pkgs.nix-your-shell} -- zsh | source /dev/stdin
|
||||
fi
|
||||
|
||||
export EDITOR=nvim
|
||||
|
||||
eval "$(${lib.getExe self'.packages.ohMyPosh} init zsh)"
|
||||
|
||||
eval "$(${lib.getExe pkgs.devenv} hook zsh)"
|
||||
|
||||
typeset -ag precmd_functions
|
||||
if (( ! ''${precmd_functions[(I)__devenv_reload_apply]} )); then
|
||||
precmd_functions+=(__devenv_reload_apply)
|
||||
fi
|
||||
if (( ! ''${precmd_functions[(I)__devenv_restore_path]} )); then
|
||||
precmd_functions+=(__devenv_restore_path)
|
||||
fi
|
||||
'';
|
||||
};
|
||||
ohMyPosh = inputs.wrappers.wrappers.oh-my-posh.wrap {
|
||||
inherit pkgs;
|
||||
configFile = ./config.toml;
|
||||
|
||||
@@ -9,15 +9,14 @@
|
||||
hackstationConfiguration
|
||||
amdDrivers
|
||||
youtube
|
||||
distcc
|
||||
development
|
||||
bottles
|
||||
gaming
|
||||
davinci
|
||||
sddm-autologin
|
||||
nix-ld
|
||||
sable
|
||||
libvirt
|
||||
|
||||
i3
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
environment.systemPackages = with pkgs; [
|
||||
tor-browser
|
||||
tor
|
||||
cinny-desktop
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -9,8 +9,6 @@
|
||||
mobile02Configuration
|
||||
intelDrivers
|
||||
development
|
||||
upower
|
||||
music
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
{
|
||||
self,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
flake.nixosConfigurations.mobile03 = inputs.nixpkgs.lib.nixosSystem {
|
||||
modules = with self.nixosModules; [
|
||||
desktop
|
||||
mobile03Configuration
|
||||
intelDrivers
|
||||
development
|
||||
thinkpadFanControl
|
||||
upower
|
||||
distcc
|
||||
obs-studio
|
||||
({...}: {
|
||||
tabletSupport = true;
|
||||
})
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
{
|
||||
self,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.mobile03Configuration = {...}: {
|
||||
networking = {
|
||||
hostName = "mobile03";
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -12,8 +12,6 @@
|
||||
playerctl
|
||||
pavucontrol
|
||||
pulseaudioFull
|
||||
pipewire
|
||||
pipewire.jack
|
||||
];
|
||||
services.pulseaudio.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
@@ -26,7 +24,6 @@
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
wireplumber.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,13 @@
|
||||
{self, ...}: {
|
||||
flake.nixosModules.core = {pkgs, ...}: let
|
||||
{
|
||||
self,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.core = {
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
modules = with self.nixosModules; [
|
||||
user
|
||||
bootloader
|
||||
@@ -13,14 +21,8 @@
|
||||
/etc/nixos/hardware-configuration.nix
|
||||
]
|
||||
++ modules;
|
||||
|
||||
services = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
settings = {
|
||||
PermitRootLogin = "yes";
|
||||
};
|
||||
};
|
||||
openssh.enable = true;
|
||||
avahi.enable = true;
|
||||
};
|
||||
environment.systemPackages = with pkgs; [
|
||||
|
||||
@@ -1,15 +1,8 @@
|
||||
{inputs, ...}: {
|
||||
perSystem = {system, ...}: {
|
||||
_module.args = {
|
||||
unfreePkgs = import inputs.nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
unstablePkgs = import inputs.nixpkgs-unstable {
|
||||
inherit system;
|
||||
};
|
||||
# Make flakeLocation universally addressable
|
||||
flakeLocation = builtins.getEnv "PWD";
|
||||
_module.args.unfreePkgs = import inputs.nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
};
|
||||
flake.nixosModules.nix = {...}: {
|
||||
|
||||
@@ -20,13 +20,7 @@
|
||||
description = "user01";
|
||||
extraGroups = [
|
||||
"root"
|
||||
"seat"
|
||||
"audio"
|
||||
"video"
|
||||
"libvirtd"
|
||||
"wheel"
|
||||
"plugdev"
|
||||
"networkmanager"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
@@ -10,8 +10,6 @@
|
||||
sddm
|
||||
network
|
||||
omnisearch
|
||||
tailscale
|
||||
sops
|
||||
];
|
||||
in {
|
||||
imports = modules;
|
||||
|
||||
@@ -1,5 +1,13 @@
|
||||
{...}: {
|
||||
flake.nixosModules.amdDrivers = {pkgs, ...}: {
|
||||
{
|
||||
self,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.amdDrivers = {
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
mesa
|
||||
rocmPackages.rocm-smi
|
||||
|
||||
@@ -12,20 +12,11 @@
|
||||
mesa
|
||||
vulkan-tools
|
||||
];
|
||||
|
||||
environment.sessionVariables = {
|
||||
LIBVA_DRIVER_NAME = "iHD";
|
||||
};
|
||||
|
||||
boot.initrd.kernelModules = ["i915"];
|
||||
services.xserver.videoDrivers = ["modesetting"];
|
||||
|
||||
hardware.graphics = {
|
||||
enable = true;
|
||||
extraPackages = with pkgs; [
|
||||
intel-media-driver
|
||||
vpl-gpu-rt
|
||||
intel-compute-runtime
|
||||
intel-vaapi-driver
|
||||
libva-vdpau-driver
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
{
|
||||
self,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.thinkpadFanControl = moduleWithSystem ({inputs', ...}: {
|
||||
# Enable fan control for the thinkpad module (why is this not the default??)
|
||||
boot.extraModprobeConfig = ''
|
||||
options thinkpad_acpi fan_control=1
|
||||
'';
|
||||
|
||||
services.thinkfan = {
|
||||
enable = true;
|
||||
|
||||
extraArgs = ["-s" "5"];
|
||||
|
||||
levels = [
|
||||
[0 0 55]
|
||||
[1 50 60]
|
||||
[3 58 68]
|
||||
[5 65 75]
|
||||
[7 73 85]
|
||||
["level disengaged" 82 32767]
|
||||
];
|
||||
};
|
||||
});
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
{...}: {
|
||||
flake.nixosModules.upower = {pkgs, ...}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
upower
|
||||
];
|
||||
services = {
|
||||
upower.enable = true;
|
||||
power-profiles-daemon.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,5 +1,13 @@
|
||||
{moduleWithSystem, ...}: {
|
||||
flake.nixosModules.network = moduleWithSystem ({...}: {config, ...}: {
|
||||
{
|
||||
self,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.network = {
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
networking = {
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
@@ -14,11 +22,7 @@
|
||||
services.unbound = {
|
||||
enable = true;
|
||||
};
|
||||
programs.nm-applet.enable =
|
||||
if config.tabletSupport == true
|
||||
then true
|
||||
else false;
|
||||
|
||||
systemd.services.NetworkManager-wait-online.enable = false;
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||