about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorThomas Tuegel <ttuegel@mailbox.org>2017-09-19 12:16:04 -0500
committerJörg Thalheim <joerg@thalheim.io>2017-09-19 22:08:53 +0100
commit6e01011211f856ca94c643daeab3f82694750916 (patch)
treeb5c2d1d28d6e888ebe734e17475865e91c8094ac /pkgs
parenta50d0b719f671f8955d5bd415586ef9358cb31b5 (diff)
downloadnixlib-6e01011211f856ca94c643daeab3f82694750916.tar
nixlib-6e01011211f856ca94c643daeab3f82694750916.tar.gz
nixlib-6e01011211f856ca94c643daeab3f82694750916.tar.bz2
nixlib-6e01011211f856ca94c643daeab3f82694750916.tar.lz
nixlib-6e01011211f856ca94c643daeab3f82694750916.tar.xz
nixlib-6e01011211f856ca94c643daeab3f82694750916.tar.zst
nixlib-6e01011211f856ca94c643daeab3f82694750916.zip
alacritty: respect pre- and post-hooks of overridden phases
Failing to `runHook` when overriding phases can have unpredictable results.

fixes #29572
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/misc/alacritty/default.nix6
1 files changed, 5 insertions, 1 deletions
diff --git a/pkgs/applications/misc/alacritty/default.nix b/pkgs/applications/misc/alacritty/default.nix
index 5e7dc934a093..79333e7d9fa1 100644
--- a/pkgs/applications/misc/alacritty/default.nix
+++ b/pkgs/applications/misc/alacritty/default.nix
@@ -46,12 +46,14 @@ buildRustPackage rec {
     pkgconfig
   ] ++ rpathLibs;
 
-  patchPhase = ''
+  postPatch = ''
     substituteInPlace copypasta/src/x11.rs \
       --replace Command::new\(\"xclip\"\) Command::new\(\"${xclip}/bin/xclip\"\)
   '';
 
   installPhase = ''
+    runHook preInstall
+
     mkdir -p $out/bin
     for f in $(find target/release -maxdepth 1 -type f); do
       cp $f $out/bin
@@ -60,6 +62,8 @@ buildRustPackage rec {
 
     mkdir -p $out/share/applications
     cp Alacritty.desktop $out/share/applications/alacritty.desktop
+
+    runHook postInstall
   '';
 
   dontPatchELF = true;