Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
isabelroses committed Feb 10, 2024
2 parents 17bdd80 + d34cb8a commit 27b886c
Show file tree
Hide file tree
Showing 136 changed files with 1,423 additions and 759 deletions.
87 changes: 65 additions & 22 deletions .github/README.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,39 @@
<div align="center">
<h1>
<img width=96 src="./assets/flake.svg"></img> <br>
isabel's dotfiles
</h1>
<img src="https://img.shields.io/github/stars/isabelroses/dotfiles?color=f5c2e7&labelColor=303446&style=for-the-badge&logo=starship&logoColor=f5c2e7">
<h1>isabel's dotfiles</h1>

<img alt="stars" src="https://img.shields.io/github/stars/isabelroses/dotfiles?color=f5c2e7&labelColor=303446&style=for-the-badge&logo=starship&logoColor=f5c2e7">
<img alt="ci" src="https://img.shields.io/github/actions/workflow/status/isabelroses/dotfiles/check.yml?label=build&color=a6e3a1&labelColor=303446&style=for-the-badge&logo=github&logoColor=a6e3a1" />
<img src="https://img.shields.io/github/repo-size/isabelroses/dotfiles?color=fab387&labelColor=303446&style=for-the-badge&logo=github&logoColor=fab387">
<img alt="repo size" src="https://img.shields.io/github/repo-size/isabelroses/dotfiles?color=fab387&labelColor=303446&style=for-the-badge&logo=github&logoColor=fab387">
</div>

### Config layout
<br />

- 🏠 [home](../home/)
- 🖥️ [hosts](../hosts/)
- ☀️ [Amaterasu](../hosts/amatarasu/) My high-end gaming machine
- 🪄 [Luz](../hosts/luz/) A server configuration for some of my infrastructure
- 🐉 [Hydra](../hosts/hydra/) A super mid spec laptop
-[Lilith](../hosts/lilith/) A NixOS ISO image that can be quickly deployed and accessed via ssh
- 📖 [lib](../lib/) Useful repeated functions
- 🧩 [flake](../flake/) NixOS parts breaking down the complex configuration into smaller more manageable chunks
- 🔌 [modules](../modules/)
- [common](../modules/base/) The base configuration settings, which are common between all systems
- [base](../modules/base/common/) Core parts of the configuration
- [options](../modules/base/options/) Selectable settings that can be used to toggle certain settings
- [extra](../modules/extra) Extra configuration modules, for home-manager and NixOS
- [profiles](../modules/profiles/) System type configurations (e.g. laptop, servers, desktop)
<!--toc:start-->
- [What does this repo provided](#what-does-this-repo-provided)
- [Hyprland Shortcuts](#hyprland-shortcuts)
- [Config layout](#config-layout)
- [Install Notes](#install-notes)
- [Linux](#linux)
- [macOS (WIP)](#macos-wip)
- [Some Awesome people](#some-awesome-people)
<!--toc:end-->

### What does this repo provided

- Several applications and tools for the same purpose, so you can choose the one that best suits your needs
- `neovim`, `micro` and `vscode` for text editing
- `firefox` and `chromium` for web browsing
- `alacritty`, `kitty` and `wezterm` for terminal emulators
- `bash`, `zsh`, `fish` and `nushell` for shells
- Modular configuration, so you can add or remove parts of the configuration
- Sensible defaults, so you can get started quickly
- [Catppuccin](https://github.com/catppuccin/catppucin) everywhere

<details>
<summary> Hyprland Shortcuts </summary>
<summary>

#### Hyprland Shortcuts
</summary>

| Shortcut | What it does |
| ------------------------------- | -------------------------- |
Expand All @@ -43,6 +50,42 @@

</details>

### Config layout

- 🏠 [home](../home/)
- 🖥️ [hosts](../hosts/)
- ☀️ [Amaterasu](../hosts/amatarasu/) My high-end gaming machine
- 🐉 [Hydra](../hosts/hydra/) A super mid spec laptop
-[Lilith](../hosts/lilith/) A NixOS ISO image that can be quickly deployed and accessed via ssh
- 🪄 [Luz](../hosts/luz/) A server configuration for some of my infrastructure
- 𖤍 [Valkyrie](../hosts/valkyrie/) A WSL2 machine
- 💮 [Tatsumaki](../hosts/tatsumaki/) A WIP macOS host
- 📚 [lib](../lib/) Useful repeated functions
- 🧩 [flake](../flake/) NixOS parts breaking down the complex configuration into smaller more manageable chunks
- 📝 [docs](../docs/) Documentation for the configuration which can be found [here](https://isabelroses.github.io/dotfiles/)
- 🔌 [modules](../modules/)
- [base](../modules/base/) The base configuration settings, which are common between all systems
- [options](../modules/base/options/) Selectable settings that can be used to toggle certain settings
- [extra](../modules/extra) Extra configuration modules, for home-manager and Nix Darwin and NixOS
- [profiles](../modules/profiles/) System type configurations (e.g. laptop, servers, desktop)

### Install Notes

#### Linux

- Install [NixOS](https://nixos.org/download.html)
- Clone this repository to `~/.config/flake`
- Run `sudo nixos-rebuild switch --flake ~/.config/flake#<host>`

#### macOS (WIP)

- Install [homebrew](https://brew.sh/)
> `curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh | bash`
- Exclude nix from time machine backups
> `sudo tmutil addexclusion -v /nix`
- `nix run nix-darwin -- switch --flake ~/.config/flake#<host> --experimental-features "nix-command flakes"`
- Then good news you can use the `rebuild` alias that exists for the future

### Some Awesome people

[NotAShelf](https://github.com/notashelf/nyx) - [numtide/srvos](https://github.com/numtide/srvos) - [nullishamy](https://github.com/nullishamy/derivation-station) - [nekowinston](https://github.com/nekowinston/dotfiles) - [getchoo](https://github.com/getchoo) - [nyxkrage](https://github.com/nyxkrage)
48 changes: 0 additions & 48 deletions .github/assets/flake.svg

This file was deleted.

31 changes: 31 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Build and deploy docs

on:
workflow_dispatch:
push:
paths:
- "modules/extra/**/*"
- "docs/*"

jobs:
build:
name: Build and deploy docs
runs-on: ubuntu-latest
permissions:
contents: write

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install nix
uses: cachix/install-nix-action@v25

- name: Build Linux packages
run: "nix build -L .#docs-html"

- name: Deploy to gh-pages branch
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./result
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# funny macos thing
.DS_Store

# Ingore nixos build outputs
result
.direnv/
Expand Down
77 changes: 77 additions & 0 deletions docs/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
# All credits to @nekowinston for this script
# modfied from https://github.com/nekowinston/nur/blob/49cfefd3c252f4c56725df01f817d1a8b93447d8/docs/default.nix
{
lib,
pkgs,
...
}: let
inherit (lib) mkForce filterAttrs scrubDerivations removePrefix;

mkEval = module:
lib.evalModules {
modules = [
module
{
_module = {
pkgs = mkForce (scrubDerivations "pkgs" pkgs);
check = false;
};
}
];
specialArgs = {inherit pkgs;};
};

mkDoc = name: options: let
doc = pkgs.nixosOptionsDoc {
options = filterAttrs (n: _: n != "_module") options;
documentType = "none";
transformOptions = opt:
opt
// {
declarations =
map
(decl:
if lib.hasPrefix (toString ../.) (toString decl)
then let
subpath = removePrefix "/" (removePrefix (toString ../.) (toString decl));
in {
url = "https://github.com/isabelroses/dotfiles/tree/main/${subpath}";
name = subpath;
}
else decl)
opt.declarations;
};
};
in
pkgs.runCommand "${name}-module-doc.md" {} ''
cat >$out <<EOF
# ${name} module options
EOF
cat ${doc.optionsCommonMark} >> $out
'';

convert = md:
pkgs.runCommand "isabelroses-dotfiles.html" {nativeBuildInputs = with pkgs; [pandoc texinfo];} ''
mkdir $out
cp ${./pandoc.css} style.css
pandoc -o file.texi ${builtins.concatStringsSep " " md}
texi2any ./file.texi --html --split=chapter --css-include=./style.css --document-language=en -o $out
'';

modulesPath = ../modules;
extraModulesPath = modulesPath + /extra;

# internalEval = mkEval (import (modulesPath + /base));
nixosEval = mkEval (import (extraModulesPath + /nixos));
darwinEval = mkEval (import (extraModulesPath + /darwin));
hmEval = mkEval (import (extraModulesPath + /home-manager));

# internal = mkDoc "internal" internalEval.options.modules;
nixos = mkDoc "nixos" nixosEval.options;
darwin = mkDoc "darwin" darwinEval.options;
hm = mkDoc "home-manager" hmEval.options;
in {
html = convert [nixos darwin hm];
md = pkgs.linkFarm "md" (lib.mapAttrsToList (name: path: {inherit name path;}) ["nixos" "darwin" "hm"]);
}
1 change: 1 addition & 0 deletions docs/pandoc.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 27b886c

Please sign in to comment.