Skip to content

Instantly share code, notes, and snippets.

@infinisil
Created December 3, 2017 03:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save infinisil/b83233d19f5f34742035445c58882dc6 to your computer and use it in GitHub Desktop.
Save infinisil/b83233d19f5f34742035445c58882dc6 to your computer and use it in GitHub Desktop.
with import <nixpkgs> {};
stdenv.mkDerivation {
name = "test";
buildInputs = [
hello
];
shellHook = let
aliases = ''
alias sayhi="${hello}/bin/hello"
'';
in ''
rm -f $HOME/.aliases
cp ${writeText "aliases" aliases} $HOME/.aliases
${aliases}
'';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment