2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
/*
|
|
|
|
This derivation is impure: it relies on an Xcode toolchain being installed
|
|
|
|
and available in the expected place. The values of sandboxProfile
|
|
|
|
are copied pretty directly from the MacVim derivation, which
|
|
|
|
is also impure. In order to build you at least need the `sandbox`
|
|
|
|
option set to `relaxed` or `false`.
|
|
|
|
*/
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "iterm2";
|
2021-08-05 21:33:18 +00:00
|
|
|
version = "3.4.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "gnachman";
|
|
|
|
repo = "iTerm2";
|
|
|
|
rev = "v${version}";
|
2021-08-05 21:33:18 +00:00
|
|
|
sha256 = "09nhrmi25zxw3vp0wlib9kjr3p1j6am2zpwimdzqn0c80fq1lwvi";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [ ./disable_updates.patch ];
|
|
|
|
postPatch = ''
|
|
|
|
sed -i -e 's/CODE_SIGN_IDENTITY = "Developer ID Application"/CODE_SIGN_IDENTITY = ""/g' ./iTerm2.xcodeproj/project.pbxproj
|
|
|
|
'';
|
|
|
|
|
|
|
|
preConfigure = "LD=$CC";
|
|
|
|
makeFlagsArray = ["Nix"];
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/Applications
|
|
|
|
mv Build/Products/Deployment/iTerm2.app $out/Applications/iTerm.app
|
|
|
|
'';
|
|
|
|
|
|
|
|
sandboxProfile = ''
|
|
|
|
(allow file-read* file-write* process-exec mach-lookup)
|
|
|
|
; block homebrew dependencies
|
|
|
|
(deny file-read* file-write* process-exec mach-lookup (subpath "/usr/local") (with no-log))
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A replacement for Terminal and the successor to iTerm";
|
|
|
|
homepage = "https://www.iterm2.com/";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ tricktron ];
|
|
|
|
platforms = platforms.darwin;
|
|
|
|
hydraPlatforms = [];
|
|
|
|
};
|
|
|
|
}
|