Remove flake (move to system configuration)

This commit is contained in:
outfoxxed 2023-01-17 17:10:10 -08:00
parent 4f4d7049fb
commit 370c7bd425
Signed by: outfoxxed
GPG key ID: 4C88A185FB89301E
2 changed files with 0 additions and 187 deletions

View file

@ -1,80 +0,0 @@
{
"nodes": {
"emacs-overlay": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1673838100,
"narHash": "sha256-iLNzJqL01hHuZcnxNoB7bqj65lfQtEAc7+krVW4R6ck=",
"owner": "nix-community",
"repo": "emacs-overlay",
"rev": "b63cf575927c768ad4dbc4a70f64201e59cf3da6",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "emacs-overlay",
"type": "github"
}
},
"flake-utils": {
"locked": {
"lastModified": 1667395993,
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1673704454,
"narHash": "sha256-5Wdj1MgdOgn3+dMFIBtg+IAYZApjF8JzwLWDPieg0C4=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "a83ed85c14fcf242653df6f4b0974b7e1c73c6c6",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-22.11",
"type": "indirect"
}
},
"root": {
"inputs": {
"emacs-overlay": "emacs-overlay",
"nixpkgs": "nixpkgs",
"ts-fold": "ts-fold"
}
},
"ts-fold": {
"flake": false,
"locked": {
"lastModified": 1673328482,
"narHash": "sha256-6yQ35uJDAK531QNQZgloQaOQayRa8azOlOMbO8lXsHE=",
"owner": "emacs-tree-sitter",
"repo": "ts-fold",
"rev": "75d6f9ed317b042b5bc7cb21503596d1c7a1b8c0",
"type": "github"
},
"original": {
"owner": "emacs-tree-sitter",
"repo": "ts-fold",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

107
flake.nix
View file

@ -1,107 +0,0 @@
{
inputs = {
nixpkgs.url = "nixpkgs/nixos-22.11";
emacs-overlay = {
url = "github:nix-community/emacs-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
ts-fold = {
url = "github:emacs-tree-sitter/ts-fold";
flake = false;
};
};
outputs = { ts-fold, nixpkgs, emacs-overlay, ... }: let
system = "x86_64-linux";
nix = import nixpkgs (let
inherit (emacs-overlay.overlays) emacs package;
grammers = (self: super: {
tree-sitter-grammars = super.tree-sitter-grammars // {
tree-sitter-rust = super.tree-sitter-grammars.tree-sitter-rust.overrideAttrs(_: {
nativeBuildInputs = [ self.nodejs self.tree-sitter ];
configurePhase = ''
tree-sitter generate --abi 13 src/grammar.json
'';
});
};
});
in {
inherit system;
overlays = [
emacs
package
grammers
];
});
custom-emacs =
with nix; with pkgs;
((emacsPackagesFor emacsPgtk).emacsWithPackages (epkgs: with epkgs; [
avy
company
editorconfig
evil
evil-collection
evil-goggles
evil-textobj-tree-sitter
flycheck
lsp-mode
lsp-treemacs
lsp-ui
magit
markdown-mode
nix-mode reformatter # required by nix mode
projectile
rainbow-mode
rustic
tree-sitter
tree-sitter-langs
(trivialBuild {
pname = "ts-fold";
version = "0.1.0";
src = ts-fold;
buildInputs = [
tree-sitter
s
fringe-helper
];
})
treemacs
treemacs-evil
treemacs-projectile
treemacs-magit
use-package
vertico
which-key
ws-butler
]));
in {
packages.${system} = {
default = custom-emacs;
module =
with nix; {
home.packages = [ custom-emacs ];
services.emacs = {
enable = true;
package = custom-emacs;
};
xdg.configFile."emacs".source = with pkgs;
runCommandNoCC ".emacs.d" {
nativeBuildInputs = [ emacsPgtk ];
} ''
cp ${./early-init.el} early-init.el
cp ${./init.el} init.el
cp ${./my-theme-theme.el} my-theme-theme.el
install -d $out
install *.el *.elc $out
'';
};
};
};
}