From 2a4321bfa68d843936d3e5424c236a85b66eb4e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20B=C3=B6hme?= Date: Sat, 17 May 2025 22:07:17 +0200 Subject: [PATCH 1/6] feat: add links --- machines/moritz-server/website/root/config.toml | 5 ++++- .../moritz-server/website/root/content/_index.md | 6 +++++- machines/moritz-server/website/root/default.nix | 13 ++++++++++++- .../moritz-server/website/root/templates/robots.txt | 5 +++++ .../root/templates/shortcodes/mastodon_footer.html | 1 + .../root/templates/shortcodes/mastodon_root.html | 1 + 6 files changed, 28 insertions(+), 3 deletions(-) create mode 100644 machines/moritz-server/website/root/templates/robots.txt create mode 100644 machines/moritz-server/website/root/templates/shortcodes/mastodon_footer.html create mode 100644 machines/moritz-server/website/root/templates/shortcodes/mastodon_root.html diff --git a/machines/moritz-server/website/root/config.toml b/machines/moritz-server/website/root/config.toml index d7d05a2..cd3df49 100644 --- a/machines/moritz-server/website/root/config.toml +++ b/machines/moritz-server/website/root/config.toml @@ -9,11 +9,14 @@ description = "Stay a while :)" compile_sass = true # Whether to build a search index to be used later on by a JavaScript library -build_search_index = true +build_search_index = false # NOTE: enable this when adding a search script # The site theme to use. theme = "anemone" +# When set to "true", a feed is automatically generated. +generate_feeds = false + [markdown] # Whether to do syntax highlighting # Theme can be customised by setting the `highlight_theme` variable to a theme supported by Zola diff --git a/machines/moritz-server/website/root/content/_index.md b/machines/moritz-server/website/root/content/_index.md index c95e864..86ffefa 100644 --- a/machines/moritz-server/website/root/content/_index.md +++ b/machines/moritz-server/website/root/content/_index.md @@ -1,3 +1,7 @@ +++ +++ -Hello World! + +# Links +- {{ mastodon_root(text="mastodon") }} +- [git](https://git.moritzboeh.me/) +- [mail](mailto:contact@moritz.place) diff --git a/machines/moritz-server/website/root/default.nix b/machines/moritz-server/website/root/default.nix index ee987fb..e87e930 100644 --- a/machines/moritz-server/website/root/default.nix +++ b/machines/moritz-server/website/root/default.nix @@ -22,5 +22,16 @@ installPhase = "cp -r public $out"; }; in { - services.nginx.virtualHosts."moritz.place".locations."/".root = "${package}"; + services.nginx.virtualHosts."moritz.place".root = "${package}"; + services.nginx.virtualHosts."moritz.place".locations."/" = { + index = "index.html"; + tryFiles = ''"''${uri}.html" $uri $uri/ =404''; + }; + services.nginx.virtualHosts."moritz.place".extraConfig = '' + error_page 404 /404.html; + + location = /404.html { + internal; + } + ''; } diff --git a/machines/moritz-server/website/root/templates/robots.txt b/machines/moritz-server/website/root/templates/robots.txt new file mode 100644 index 0000000..34d4b42 --- /dev/null +++ b/machines/moritz-server/website/root/templates/robots.txt @@ -0,0 +1,5 @@ +User-agent: * +Allow: /$ +Allow: /{{ get_url(path="sitemap.xml") }} +Disallow: / +Sitemap: {{ get_url(path="sitemap.xml") }} diff --git a/machines/moritz-server/website/root/templates/shortcodes/mastodon_footer.html b/machines/moritz-server/website/root/templates/shortcodes/mastodon_footer.html new file mode 100644 index 0000000..81498cb --- /dev/null +++ b/machines/moritz-server/website/root/templates/shortcodes/mastodon_footer.html @@ -0,0 +1 @@ + diff --git a/machines/moritz-server/website/root/templates/shortcodes/mastodon_root.html b/machines/moritz-server/website/root/templates/shortcodes/mastodon_root.html new file mode 100644 index 0000000..e3d777b --- /dev/null +++ b/machines/moritz-server/website/root/templates/shortcodes/mastodon_root.html @@ -0,0 +1 @@ +{{ text | safe }} From cfcf6f707a257564334efde449a42bb4af38e470 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20B=C3=B6hme?= Date: Sat, 17 May 2025 22:08:21 +0200 Subject: [PATCH 2/6] chore: remove unneeded extension --- modules/moritz/programs/firefox.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/moritz/programs/firefox.nix b/modules/moritz/programs/firefox.nix index 48cddce..4944675 100644 --- a/modules/moritz/programs/firefox.nix +++ b/modules/moritz/programs/firefox.nix @@ -65,7 +65,6 @@ in { ''; extensions.packages = with pkgs.nur.repos.rycee.firefox-addons; [ darkreader - firefox-color istilldontcareaboutcookies kagi-search keepassxc-browser From 6e68c63a5452f5db64adbb90657f82a10ddd0699 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20B=C3=B6hme?= Date: Sat, 17 May 2025 22:08:38 +0200 Subject: [PATCH 3/6] feat: make lazygit more usable with gpg --- modules/moritz/programs/lazygit.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/moritz/programs/lazygit.nix b/modules/moritz/programs/lazygit.nix index f06c97e..81fdaed 100644 --- a/modules/moritz/programs/lazygit.nix +++ b/modules/moritz/programs/lazygit.nix @@ -137,6 +137,9 @@ in { loadingText = "Creating conventional commit..."; } ]; + git = { + overrideGpg = true; + }; }; }; }; From 6bed137ccf02761b1c75056c7c2bb67a66a6d2e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20B=C3=B6hme?= Date: Sat, 17 May 2025 22:08:54 +0200 Subject: [PATCH 4/6] fix: switch to cpp nix to get clan to work --- modules/moritz/programs/nix.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/moritz/programs/nix.nix b/modules/moritz/programs/nix.nix index 73a83bf..d00dfd1 100644 --- a/modules/moritz/programs/nix.nix +++ b/modules/moritz/programs/nix.nix @@ -30,7 +30,7 @@ in { nix = { nixPath = ["nixpkgs=${inputs.nixpkgs}"]; - package = pkgs.lix; + package = pkgs.nix; # TODO: change this back extraOptions = '' experimental-features = nix-command flakes From 74ef51361612151d781d3c2c59e3482cf432ebea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20B=C3=B6hme?= Date: Sat, 17 May 2025 22:09:51 +0200 Subject: [PATCH 5/6] fix: do not use builders for shell --- .envrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.envrc b/.envrc index 0f94eed..2cefe8a 100644 --- a/.envrc +++ b/.envrc @@ -1,2 +1,2 @@ # shellcheck shell=bash -use flake +use flake . --builders "" From 4fbdadbe6f3b790da5468296b6de99383170534d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20B=C3=B6hme?= Date: Sat, 17 May 2025 22:10:51 +0200 Subject: [PATCH 6/6] feat: add initial jujutsu config --- machines/moritz-desktop/configuration.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/machines/moritz-desktop/configuration.nix b/machines/moritz-desktop/configuration.nix index d7cb2b0..51c2cbe 100644 --- a/machines/moritz-desktop/configuration.nix +++ b/machines/moritz-desktop/configuration.nix @@ -45,6 +45,24 @@ networking.firewall.allowedTCPPorts = [9090]; + # TODO: make this its own module! + home-manager.users.moritz.programs.jujutsu = { + enable = true; + settings = { + user = { + email = "mail@moritzboeh.me"; + name = "Moritz Böhme"; + }; + ui.paginate = "never"; + signing = { + behavior = "drop"; + backend = "gpg"; + key = "0x970C6E89EB0547A9"; + }; + git.sign-on-push = true; + }; + }; + home-manager.users.moritz.services.kanshi.settings = [ { profile.name = "default";