From 3f9a4859a98123dd840e928d0e6af60ca921607a Mon Sep 17 00:00:00 2001 From: David Crompton Date: Tue, 18 Mar 2025 09:52:53 -0400 Subject: [PATCH] No longer need community overlay (for now) --- flake.lock | 38 -------------------------------------- flake.nix | 30 +++++++----------------------- 2 files changed, 7 insertions(+), 61 deletions(-) diff --git a/flake.lock b/flake.lock index b5a8a8f..6080a5f 100644 --- a/flake.lock +++ b/flake.lock @@ -1,26 +1,5 @@ { "nodes": { - "emacs-overlay": { - "inputs": { - "nixpkgs": [ - "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable" - }, - "locked": { - "lastModified": 1737825153, - "narHash": "sha256-R1p2ZXOydII+MT/SpeOXBjo/dgfD/gIArge2YAgSw38=", - "owner": "nix-community", - "repo": "emacs-overlay", - "rev": "4ebe4c890e7c8662ae31192359a56b0505cf10ba", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "emacs-overlay", - "type": "github" - } - }, "flake-utils": { "inputs": { "systems": "systems" @@ -55,25 +34,8 @@ "type": "github" } }, - "nixpkgs-stable": { - "locked": { - "lastModified": 1737672001, - "narHash": "sha256-YnHJJ19wqmibLQdUeq9xzE6CjrMA568KN/lFPuSVs4I=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "035f8c0853c2977b24ffc4d0a42c74f00b182cd8", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-24.11", - "repo": "nixpkgs", - "type": "github" - } - }, "root": { "inputs": { - "emacs-overlay": "emacs-overlay", "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } diff --git a/flake.nix b/flake.nix index 7b7de09..c49e52e 100644 --- a/flake.nix +++ b/flake.nix @@ -1,37 +1,21 @@ { inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; - inputs.emacs-overlay.url = "github:nix-community/emacs-overlay"; - inputs.emacs-overlay.inputs.nixpkgs.follows = "nixpkgs"; inputs.flake-utils.url = "github:numtide/flake-utils"; - outputs = { self, nixpkgs, flake-utils, emacs-overlay }: let - mkEmacs = pkgs: v: wayland: pkgs.emacsWithPackagesFromUsePackage { - config = ./main.org; - package = (pkgs."${v}${if pkgs.stdenv.isDarwin then "" else (if wayland then "-pgtk" else "")}").overrideAttrs (old: { - passthru = old.passthru // { - treeSitter = true; - }; - }); - extraEmacsPackages = epkgs: with epkgs; [ - treesit-grammars.with-all-grammars - ]; - }; + outputs = { self, nixpkgs, flake-utils }: let in (flake-utils.lib.eachDefaultSystem (system: let pkgs = import nixpkgs { inherit system; - overlays = [ - emacs-overlay.overlays.default - ]; }; in { packages = { - me-emacs = mkEmacs pkgs "emacs" false; - me-emacs-wayland = mkEmacs pkgs "emacs" true; + me-emacs = pkgs.emacs; + me-emacs-wayland = pkgs.emacs-pgtk; }; })) // { - overlays.default = final: prev: (emacs-overlay.overlays.default final prev) // { - me-emacs = mkEmacs final "emacs" false; - me-emacs-wayland = mkEmacs final "emacs" true; - }; + overlays.default = final: prev: ({ + me-emacs = final.emacs; + me-emacs-wayland = final.emacs-pgtk; + }); }; }