first commit

This commit is contained in:
Thorn Avery 2020-12-18 17:33:58 +13:00
commit a01e33e54d
3 changed files with 87 additions and 0 deletions

43
flake.lock Normal file
View File

@ -0,0 +1,43 @@
{
"nodes": {
"flake-utils": {
"locked": {
"lastModified": 1605370193,
"narHash": "sha256-YyMTf3URDL/otKdKgtoMChu4vfVL3vCMkRqpGifhUn0=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "5021eac20303a61fafe17224c087f5519baed54d",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1608062904,
"narHash": "sha256-QVaxOnGwZoBtNTlnAV0aeC30ASeJpo583wjotmhpOtg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "647cc06986c1ae4a2bb05298e0cf598723e42970",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-20.09",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

23
flake.nix Normal file
View File

@ -0,0 +1,23 @@
{
description = "tA's emacs setup";
inputs = {
nixpkgs = {
url = "github:NixOS/nixpkgs/nixos-20.09";
};
flake-utils = {
url = "github:numtide/flake-utils";
};
};
outputs = { self, nixpkgs, flake-utils, ... }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
overlays = [ (import ./overlay.nix) ];
inherit system;
};
in {
defaultPackage = pkgs.ta.emacs;
}) // {
overlay = import ./overlay.nix;
};
}

21
overlay.nix Normal file
View File

@ -0,0 +1,21 @@
self: super:
let
myEmacs = (super.emacs.override {
withGTK3 = false;
withGTK2 = false;
withX = false;
});
emacsWithPackages = (super.emacsPackagesGen myEmacs).emacsWithPackages;
in {
ta = {
emacs =
emacsWithPackages (epkgs: (with epkgs.melpaStablePackages; [
magit
zerodark-theme
]) ++ (with epkgs.melpaPackages; [
racket-mode
idris-mode
nix-mode
]));
};
}