refactor(emacs): use lib.makeBinPath
This commit is contained in:
@@ -62,27 +62,24 @@ in {
|
||||
name = "sydmacs";
|
||||
paths = [ ewp ];
|
||||
nativeBuildInputs = [ pkgs.makeWrapper ];
|
||||
buildInputs = [
|
||||
pkgs.git # Dependency of Straight.el.
|
||||
postBuild =
|
||||
let runtime-binaries = [
|
||||
my-aspell
|
||||
pkgs.direnv
|
||||
pkgs.git # Dependency of Straight.el.
|
||||
pkgs.ghostscript # For TeX.
|
||||
my-tex
|
||||
pkgs.unzip # For jump-to-source.
|
||||
];
|
||||
postBuild = ''
|
||||
in ''
|
||||
find "$out/bin" -name emacs -or -name "emacs-*" \
|
||||
| while IFS= read -r emacs; do
|
||||
echo "emacs: $emacs"
|
||||
wrapProgram "$emacs" \
|
||||
--add-flags "--init-directory \"${emacsConfigDir}\"" \
|
||||
--set EMACS_STRAIGHT_BASE_DIR "${straightBaseDir}" \
|
||||
--set EMACS_CACHE_DIR "${emacsCacheDir}" \
|
||||
--set EMACS_DATA_DIR "${emacsDataDir}" \
|
||||
--prefix PATH : "${pkgs.git}/bin" \
|
||||
--prefix PATH : "${my-aspell}/bin" \
|
||||
--prefix PATH : "${pkgs.direnv}/bin" \
|
||||
--prefix PATH : "${my-tex}/bin" \
|
||||
--prefix PATH : "${pkgs.unzip}/bin" \
|
||||
--set ASPELL_CONF "dict-dir ${my-aspell}/lib/aspell"
|
||||
--set ASPELL_CONF "dict-dir ${my-aspell}/lib/aspell" \
|
||||
--prefix PATH : "${lib.makeBinPath runtime-binaries}"
|
||||
done
|
||||
'';
|
||||
meta = emacsBasePackage.meta;
|
||||
|
||||
Reference in New Issue
Block a user