Move the nix flake to a separate repo

This commit is contained in:
larstvei 2024-07-20 13:12:11 +02:00
parent f82b34ffb2
commit 8a297c51c3
3 changed files with 35 additions and 197 deletions

View File

@ -1,147 +0,0 @@
{
"nodes": {
"emacs-overlay": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs",
"nixpkgs-stable": "nixpkgs-stable"
},
"locked": {
"lastModified": 1720256942,
"narHash": "sha256-ohfS5d4yR+zdLTICE78rNJmqL/en0BNPGm5zCK6N0QA=",
"owner": "nix-community",
"repo": "emacs-overlay",
"rev": "6d9837126e1be779c8f34ed9fdd609e676a1b891",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "emacs-overlay",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"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_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"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1720031269,
"narHash": "sha256-rwz8NJZV+387rnWpTYcXaRNvzUSnnF9aHONoJIYmiUQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "9f4128e00b0ae8ec65918efeba59db998750ead6",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1719957072,
"narHash": "sha256-gvFhEf5nszouwLAkT9nWsDzocUTqLWHuL++dvNjMp9I=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "7144d6241f02d171d25fba3edeaf15e0f2592105",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-23.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1720181791,
"narHash": "sha256-i4vJL12/AdyuQuviMMd1Hk2tsGt02hDNhA0Zj1m16N8=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "4284c2b73c8bce4b46a6adf23e16d9e2ec8da4bb",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"emacs-overlay": "emacs-overlay",
"flake-utils": "flake-utils_2",
"nixpkgs": "nixpkgs_2"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

View File

@ -1,29 +0,0 @@
{
description = "My emacs";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
flake-utils.url = "github:numtide/flake-utils";
emacs-overlay.url = "github:nix-community/emacs-overlay";
};
outputs = { self, nixpkgs, flake-utils, emacs-overlay }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
overlays =
[ emacs-overlay.overlays.emacs emacs-overlay.overlays.package ];
};
in {
defaultPackage = pkgs.emacsWithPackagesFromUsePackage {
config = ./init.org;
defaultInitFile = true;
alwaysEnsure = true;
alwaysTangle = true;
extraEmacsPackages = epkgs:
[ epkgs.treesit-grammars.with-all-grammars ];
};
});
}

View File

@ -15,6 +15,8 @@
If you really do want to try this config out, this is how I'd go about it: If you really do want to try this config out, this is how I'd go about it:
** Manual installation
Clone the repo. Clone the repo.
#+begin_src sh :tangle no #+begin_src sh :tangle no
@ -51,6 +53,17 @@
and you might have to restart your Emacs the first time. If you experience and you might have to restart your Emacs the first time. If you experience
bugs, please let me know! bugs, please let me know!
** With Nix
I keep an updated [[https://github.com/larstvei/emacs-flake][nix flake for my Emacs config]]. If that tells you anything,
you can try it out running:
#+begin_src sh :tangle no
nix run github:larstvei/emacs-flake
#+end_src
* Meta * Meta
All changes to the configuration should be done in =init.org=, *not* in All changes to the configuration should be done in =init.org=, *not* in
@ -331,7 +344,8 @@
** Modal meow ** Modal meow
I have been wanting to try out modal editing. [[https://github.com/meow-edit/meow][meow]] seems like a nice package, # TODO: This is so much more than what i need. Find something 1% as complicated.
I have been wanting to try out modal editing. [[https://github.com/meow-edit/meow][meow] seems like a nice package,
where I can still use a lot of the ten years of Emacs that are already in my where I can still use a lot of the ten years of Emacs that are already in my
fingers. These are the default settings for qwerty. fingers. These are the default settings for qwerty.
@ -1281,7 +1295,7 @@
(setq gptel-backend (gptel-make-ollama "Ollama" (setq gptel-backend (gptel-make-ollama "Ollama"
:host "localhost:11434" :host "localhost:11434"
:stream t :stream t
:models '("llama3")) :models '("llama3:8b-instruct-q8_0"))
gptel-model "llama3" gptel-model "llama3"
gptel-api-key (auth-source-pick-first-password gptel-api-key (auth-source-pick-first-password
:host "api.openai.com"))) :host "api.openai.com")))