From 31d3efa0d4836ef863f6db540b0b51712f9b43d4 Mon Sep 17 00:00:00 2001 From: Marc Scholten Date: Thu, 23 Jun 2016 17:14:02 +0200 Subject: [PATCH] iTerm2: 2.1.4 -> 3.0.2 --- pkgs/applications/misc/iterm2/default.nix | 17 ++++++++++------- .../misc/iterm2/disable_updates.patch | 11 +++++++++++ 2 files changed, 21 insertions(+), 7 deletions(-) create mode 100644 pkgs/applications/misc/iterm2/disable_updates.patch diff --git a/pkgs/applications/misc/iterm2/default.nix b/pkgs/applications/misc/iterm2/default.nix index 4aac8ab72d2c..add16365324e 100644 --- a/pkgs/applications/misc/iterm2/default.nix +++ b/pkgs/applications/misc/iterm2/default.nix @@ -1,18 +1,21 @@ -{ stdenv, fetchurl, unzip }: +{ stdenv, fetchFromGitHub }: stdenv.mkDerivation rec { name = "iterm2-${version}"; - version = "2.1.4"; + version = "3.0.2"; - src = fetchurl { - url = "https://iterm2.com/downloads/stable/iTerm2-2_1_4.zip"; - sha256 = "1kb4j1p1kxj9dcsd34709bm2870ffzpq6jig6q9ixp08g0zbhqhh"; + src = fetchFromGitHub { + owner = "gnachman"; + repo = "iTerm2"; + rev = "v${version}"; + sha256 = "121g759i814y1g1g1jwhsmxgg4wrzv08vq7a7qwc7b85a17zbd3h"; }; - buildInputs = [ unzip ]; + patches = [ ./disable_updates.patch ]; + makeFlagsArray = ["Deployment"]; installPhase = '' mkdir -p "$out/Applications" - mv "$(pwd)" "$out/Applications/iTerm.app" + mv "build/Deployment/iTerm2.app" "$out/Applications/iTerm.app" ''; meta = { diff --git a/pkgs/applications/misc/iterm2/disable_updates.patch b/pkgs/applications/misc/iterm2/disable_updates.patch new file mode 100644 index 000000000000..e717c58f30f1 --- /dev/null +++ b/pkgs/applications/misc/iterm2/disable_updates.patch @@ -0,0 +1,11 @@ +--- iTerm2/sources/iTermPreferences.m 2016-06-23 16:55:28.000000000 +0200 ++++ iTerm2/sources/iTermPreferences.m 2016-06-23 16:55:42.000000000 +0200 +@@ -189,7 +189,7 @@ + kPreferenceKeyInstantReplayMemoryMegabytes: @4, + kPreferenceKeySavePasteAndCommandHistory: @NO, + kPreferenceKeyAddBonjourHostsToProfiles: @NO, +- kPreferenceKeyCheckForUpdatesAutomatically: @YES, ++ kPreferenceKeyCheckForUpdatesAutomatically: @NO, + kPreferenceKeyCheckForTestReleases: @NO, + kPreferenceKeyLoadPrefsFromCustomFolder: @NO, + kPreferenceKeyNeverRemindPrefsChangesLostForFileHaveSelection: @NO,