Skip to content

second try to do nix-doom-emacs version locking #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions dotfiles/doom.d/config.el
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@
(setq org-adapt-indentation t)
(setq org-startup-indented t))

(toggle-debug-on-error)
(toggle-debug-on-quit)
;; This determines the style of line numbers in effect. If set to `nil', line
;; numbers are disabled. For relative line numbers, set this to `relative'.
(setq display-line-numbers-type t)
Expand Down
5 changes: 2 additions & 3 deletions dotfiles/doom.d/init.el
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,8 @@
;; NOTE: I switched from vertico to ivy completion becuase of a
;; bug that seems to be in the search code for vertico.
;; no idea when it may get resolved
ivy ; a search engine for love and life

;; vertico ; the search engine of the future
;; ivy ; a search engine for love and life
vertico ; the search engine of the future

:ui
;;deft ; notational velocity for Emacs
Expand Down
238 changes: 234 additions & 4 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,237 @@
};
};

outputs = inputs@{ self, darwin, nixpkgs, darwin-nixpkgs, home-manager, darwin-home-manager, nix-doom-emacs, # darwin-nix-doom-emacs,
outputs = inputs@{ self, darwin, nixpkgs, darwin-nixpkgs, home-manager, darwin-home-manager, nix-doom-emacs,
... }:

let
emacsPackagesOverlay = self: super: {

transient = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs, dash, git-commit, transient, with-editor}:
melpaBuild rec {
pname = "transient";
version = "0.3.6";
src = fetchFromGitHub {
owner = "magit";
repo = "transient";
rev = "51e833e5152e9fdcdc1dbbf34ad2d4905bde1f69";
sha256 = "sha256-fsNYL6N1ZaTzbsWOlEqClXpVhy21UzaZyyAaj/RvaYI=";
};
commit = "51e833e5152e9fdcdc1dbbf34ad2d4905bde1f69";
# elisp dependencies
packageRequires = [
emacs
];
recipe = pkgs.writeText "recipe" ''
(transient
:repo "magit/transient"
:fetcher github
:files
("lisp/*.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/transient.html";
license = lib.licenses.free;
};
}
) {};

magit = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs, dash, git-commit, transient, with-editor}:
melpaBuild rec {
pname = "magit";
version = "3.3.0";
src = fetchFromGitHub {
owner = "magit";
repo = "magit";
rev = "c1fb53d3de6390961ccd8dfb1cc135383508d0fc";
sha256 = "sha256-I1k8Lsczs1RuGou0qqrAIQuAXiUyIuQVWHwCIjf4EjI=";
};
commit = "c1fb53d3de6390961ccd8dfb1cc135383508d0fc";
# elisp dependencies
packageRequires = [
emacs compat dash git-commit transient with-editor
];
recipe = pkgs.writeText "recipe" ''
(magit
:repo "magit/magit"
:fetcher github
:files
("lisp/*.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/magit.html";
license = lib.licenses.free;
};
}
) {};

compat = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, seq, pkgs}:
melpaBuild rec {
pname = "compat";
version = "28.1.2.0";
src = fetchFromGitHub {
owner = "emacs-straight";
repo = "compat";
rev = "cc1924fd8b3f9b75b26bf93f084ea938c06f9615";
sha256 = "sha256-ZEQI/qvnUc4GEdPlbRMLDn7Oh4j53Gxy3wEXZFX8Aq4=";
};
commit = "cc1924fd8b3f9b75b26bf93f084ea938c06f9615";
# elisp dependencies
packageRequires = [
emacs seq
];
recipe = pkgs.writeText "recipe" ''
(compat
:repo "emacs-compat/compat"
:fetcher github
:files
("*.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/compat.html";
license = lib.licenses.free;
};
}
) {};

consult = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs}:
melpaBuild rec {
pname = "consult";
version = "0.18";
src = fetchFromGitHub {
owner = "minad";
repo = "consult";
rev = "6319aec3513cd587a8817269bc32c8283d419710";
sha256 = "sha256-0ppRvCvk93wzKMU6814LSGV5PlR84zeIvSUcvg5+TLY=";
};
commit = "6319aec3513cd587a8817269bc32c8283d419710";
# elisp dependencies
packageRequires = [
emacs compat
];
recipe = pkgs.writeText "recipe" ''
(consult
:repo "minad/consult"
:fetcher github
:files
("*.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/consult.html";
license = lib.licenses.free;
};
}
) {};

vertico = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs}:
melpaBuild rec {
pname = "vertico";
version = "0.25";
src = fetchFromGitHub {
owner = "minad";
repo = "vertico";
rev = "2ad46196653b8a873adf11aee949d621af8ff6bc";
sha256 = "sha256-R7MYPn9Co+MT5CQ8+D5F5JBe92GjxEY0v14aPgBLFlg=";
};
commit = "2ad46196653b8a873adf11aee949d621af8ff6bc";

# elisp dependencies
packageRequires = [
emacs compat
];
recipe = pkgs.writeText "recipe" ''
(vertico
:repo "minad/vertico"
:fetcher github
:files
("*.el"
"extensions/*.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/vertico.html";
license = lib.licenses.free;
};
}
) {};

embark = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs}:
melpaBuild rec {
pname = "embark";
version = "0.17";
src = pkgs.fetchFromGitHub {
owner = "oantolin";
repo = "embark";
rev = "5d0459d27aa7cf738b5af36cf862723a62bef955";
sha256 = "sha256-7U94GRmUA+UdqvwSBSEGSwHSpfqaaiKghqg4P4gn85c=";
};
commit = "5d0459d27aa7cf738b5af36cf862723a62bef955";
packageRequires = [
emacs compat
];
recipe = pkgs.writeText "recipe" ''
(embark
:repo "oantolin/embark"
:fetcher github
:files ("embark.el" "embark-org.el" "embark.texi"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/embark.html";
license = lib.licenses.free;
};
}) {};
embark-consult = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs}:
melpaBuild rec {
pname = "embark-consult";
version = "0.17";
src = pkgs.fetchFromGitHub {
owner = "oantolin";
repo = "embark";
rev = "5d0459d27aa7cf738b5af36cf862723a62bef955";
sha256 = "sha256-7U94GRmUA+UdqvwSBSEGSwHSpfqaaiKghqg4P4gn85c=";
};
commit = "5d0459d27aa7cf738b5af36cf862723a62bef955";
packageRequires = [
emacs compat
];
recipe = pkgs.writeText "recipe" ''
(embark-consult
:repo "oantolin/embark"
:fetcher github
:files
("embark-consult.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/embark-consult.html";
license = lib.licenses.free;
};
}) {};

orderless = self.callPackage({melpaBuild, fetchFromGitHub, lib, emacs, compat, pkgs}:
melpaBuild rec {
pname = "orderless";
version = "0.7";
src = pkgs.fetchFromGitHub {
owner = "oantolin";
repo = "orderless";
rev = "8b9af2796fa0eb87eea4140bc08d16880a493803";
sha256 = "sha256-yHJYdyEUM6rQPVjCXnVFIHwHoMgRjEHBOcwbTmZ6fW0=";
};
commit = "8b9af2796fa0eb87eea4140bc08d16880a493803";
packageRequires = [
emacs
];
recipe = pkgs.writeText "recipe" ''
(orderless
:repo "oantolin/orderless"
:fetcher github
:files
("*.el"))
'';
meta = {
homepage = "https://elpa.gnu.org/packages/orderless.html";
license = lib.licenses.free;
};
}) {};
};
home-manager-config = { user, home }:
{ config, pkgs, lib, ... }:
{
Expand Down Expand Up @@ -71,13 +298,12 @@
extraConfig = ''
(add-to-list 'exec-path "~/.nix-profile/bin/")
'';
# inherit emacsPackagesOverlay;
};

# workaround; see https://github.com/nix-community/home-manager/issues/3342#issuecomment-1283158398
manual.manpages.enable = false;
};


darwin-home-config = user-config:
let
system = "x86_64-darwin";
Expand Down Expand Up @@ -149,5 +375,9 @@
homeConfigurations."ci-ubuntu".runner = linux-home-config{
user = "runner"; home = "/home/runner";
};

# used for testing/development purposes, makes it easier to experiment
emacsPackagesOverlay = nixpkgs.legacyPackages."${builtins.currentSystem}".emacsPackages.overrideScope' emacsPackagesOverlay;
};
}