wip: added obsidian

but waybar failed to build
This commit is contained in:
2025-07-30 08:29:27 -04:00
parent 13fc210f8b
commit 739f2e125f
6 changed files with 71 additions and 18 deletions

23
flake.lock generated
View File

@@ -64,11 +64,11 @@
"zon2nix": "zon2nix" "zon2nix": "zon2nix"
}, },
"locked": { "locked": {
"lastModified": 1751123364, "lastModified": 1753816554,
"narHash": "sha256-Nb3pxs1onnbdhhnoNc+IfHzrW9dM+UbEdjK0AguR2J4=", "narHash": "sha256-eyFfBXb5IJaNTGTdkjpWKSMTs8wiJ0i+9n5jUKtVFa4=",
"owner": "ghostty-org", "owner": "ghostty-org",
"repo": "ghostty", "repo": "ghostty",
"rev": "f6d1c274b9c0e095dc0a1b411dec7410ad779bf5", "rev": "c78d32074ebab14d2060e5cd3c7667cbe37ab8ee",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -84,11 +84,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1750792728, "lastModified": 1753592768,
"narHash": "sha256-Lh3dopA8DdY+ZoaAJPrtkZOZaFEJGSYjOdAYYgOPgE4=", "narHash": "sha256-oV695RvbAE4+R9pcsT9shmp6zE/+IZe6evHWX63f2Qg=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "366f00797b1efb70f2882d3da485e3c10fd3d557", "rev": "fc3add429f21450359369af74c2375cb34a2d204",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -129,11 +129,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1750969886, "lastModified": 1753749649,
"narHash": "sha256-zW/OFnotiz/ndPFdebpo3X0CrbVNf22n4DjN2vxlb58=", "narHash": "sha256-+jkEZxs7bfOKfBIk430K+tK9IvXlwzqQQnppC2ZKFj4=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "a676066377a2fe7457369dd37c31fd2263b662f4", "rev": "1f08a4df998e21f4e8be8fb6fbf61d11a1a5076a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -170,7 +170,8 @@
"zig": { "zig": {
"inputs": { "inputs": {
"flake-compat": [ "flake-compat": [
"ghostty" "ghostty",
"flake-compat"
], ],
"flake-utils": [ "flake-utils": [
"ghostty", "ghostty",
@@ -216,8 +217,8 @@
}, },
"original": { "original": {
"owner": "jcollie", "owner": "jcollie",
"ref": "56c159be489cc6c0e73c3930bd908ddc6fe89613",
"repo": "zon2nix", "repo": "zon2nix",
"rev": "56c159be489cc6c0e73c3930bd908ddc6fe89613",
"type": "github" "type": "github"
} }
} }

View File

@@ -1,4 +1,5 @@
{ {
config,
lib, lib,
pkgs, pkgs,
userName, userName,
@@ -13,7 +14,7 @@
}; };
in { in {
# Import sub modules # Import sub modules
imports = map (module: import module {inherit lib pkgs dirs userName userEmail ghostty;}) [ imports = map (module: import module {inherit config lib pkgs dirs userName userEmail ghostty;}) [
./atuin.nix ./atuin.nix
./shell.nix ./shell.nix
./packages ./packages
@@ -27,6 +28,7 @@ in {
./browser.nix ./browser.nix
./zellij.nix ./zellij.nix
./bat.nix ./bat.nix
./obsidian.nix
]; ];
# Home Manager needs a bit of information about you and the # Home Manager needs a bit of information about you and the
@@ -56,7 +58,7 @@ in {
size = 22; size = 22;
}; };
stateVersion = "24.11"; stateVersion = "25.05";
}; };
# Let Home Manager install and manage itself. # Let Home Manager install and manage itself.

52
home/obsidian.nix Normal file
View File

@@ -0,0 +1,52 @@
{ config, pkgs, ...}: {
home.packages = with pkgs; [
obsidian
obsidian-export
];
# programs.obsidian = {
# enable = true;
# vaults = {
# "notes" = {
# enable = true;
# target = "${config.home.homeDirectory}/Documents/obsidian/notes";
# };
# "work-notes" = {
# enable = true;
# target = "${config.home.homeDirectory}/Documents/obsidian/work-notes";
# };
# };
# # defaultSettings = {
# # themes = [ "catppuccin" ];
# # };
# };
home.activation.obsidianRepos = config.lib.dag.entryAfter ["writeBoundary"] ''
REPOS_DIR="${config.home.homeDirectory}/Documents/obsidian"
# Create the repos directory if it doesn't exist
mkdir -p "$REPOS_DIR"
# Function to clone or update a repository
clone_or_update() {
local repo_url="$1"
local vault_name="$2"
local vault_path="$REPOS_DIR/$vault_name"
if [ -d "$vault_path/.git" ]; then
echo "Updating existing vault: $vault_name"
cd "$vault_path"
${pkgs.git}/bin/git pull origin main || ${pkgs.git}/bin/git pull origin master || true
else
echo "Cloning new vault: $vault_name"
rm -rf "$vault_path" # Remove if exists but not a git repo
${pkgs.git}/bin/git clone "$repo_url" "$vault_path" || true
fi
}
# Clone repositories
clone_or_update "https://scm.wyattjmiller.com/NoteFolio/notes.git" "notes"
clone_or_update "https://scm.wyattjmiller.com/NoteFolio/work-notes.git" "work-notes"
echo "Obsidian repository vaults setup complete in $REPOS_DIR"
'';
}

View File

@@ -23,7 +23,6 @@
fh fh
aria2 aria2
yt-dlp yt-dlp
obsidian
vscode vscode
weechat weechat
inetutils inetutils

View File

@@ -149,17 +149,17 @@ in {
systemd.enable = true; systemd.enable = true;
package = pkgs.waybar.overrideAttrs (old: { package = pkgs.waybar.overrideAttrs (old: {
version = "0.11.0"; version = "0.13.0";
src = pkgs.fetchFromGitHub { src = pkgs.fetchFromGitHub {
owner = "Alexays"; owner = "Alexays";
repo = "Waybar"; repo = "Waybar";
rev = "d56dd6ee7fdf8c5ba4e90790af62b7f7829d3a47"; rev = "0fcda9afa519eb84deda68c051f7938a6c6bdbce";
sha256 = "sha256-3lc0voMU5RS+mEtxKuRayq/uJO09X7byq6Rm5NZohq8="; sha256 = "sha256-3lc0voMU5RS+mEtxKuRayq/uJO09X7byq6Rm5NZohq8=";
fetchSubmodules = true; fetchSubmodules = true;
}; };
buildInputs = old.buildInputs ++ [ pkgs.fftw pkgs.libcava ]; # buildInputs = old.buildInputs ++ [ pkgs.fftw libcava ];
# mesonFlags = (old.mesonFlags or []) ++ [ "-Dcava=disabled" ]; # mesonFlags = (old.mesonFlags or []) ++ [ "-Dcava=disabled" ];
}); });
}; };

View File

@@ -11,7 +11,6 @@
"info.beyondallreason.bar" "info.beyondallreason.bar"
"io.dbeaver.DBeaverCommunity" "io.dbeaver.DBeaverCommunity"
"io.openrct2.OpenRCT2" "io.openrct2.OpenRCT2"
"md.obsidian.Obsidian"
"org.prismlauncher.PrismLauncher" "org.prismlauncher.PrismLauncher"
"sh.cider.Cider" "sh.cider.Cider"
]; ];