about summary refs log tree commit diff
path: root/third_party/lieer/default.nix
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2020-12-10T10·22+0100
committertazjin <mail@tazj.in>2020-12-14T19·41+0000
commita9014203b602d62d7cd932cd75385ea42bb7fdfa (patch)
tree5bd088f45184d55cfb874c6b53bb04c0e3e59db1 /third_party/lieer/default.nix
parent316a4fa1e0ba6254d90df9181e5d72ff693af055 (diff)
chore(3p/lieer): Upgrade to lieer 1.3 r/2014
* rebases the send scope patch
* removes the API key override patch, lieer now has a configuration
  option for this

Change-Id: I198e8b61855f6cdb2b1439a1c8f2d9d69261c1b5
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2242
Tested-by: BuildkiteCI
Reviewed-by: glittershark <grfn@gws.fyi>
Diffstat (limited to 'third_party/lieer/default.nix')
-rw-r--r--third_party/lieer/default.nix29
1 files changed, 3 insertions, 26 deletions
diff --git a/third_party/lieer/default.nix b/third_party/lieer/default.nix
index 6dd4cecd1d3f..631be82a8a49 100644
--- a/third_party/lieer/default.nix
+++ b/third_party/lieer/default.nix
@@ -1,44 +1,21 @@
 # Lieer is a small tool to synchronise a Gmail account with a local
 # maildir.
-#
-# Lieer is packaged in nixpkgs, but as of 2019-12-23 it is an old
-# version using the previous branding (gmailieer).
 { pkgs, ... }:
 
-# For a variety of reasons (specific to my setup), custom OAuth2
-# scopes are used.
-#
-# The below client ID is the default for *@tazj.in and is overridden
-# in a private repository for my work account. Publishing it here is
-# not a security issue.
-{
-  clientId ? "515965513093-7b4bo4gm0q09ccsmikkuaas9a40j0jcj.apps.googleusercontent.com",
-  clientSecret ? "3jVbpfT4GmubFD64svctJSdQ",
-  project ? "tazjins-infrastructure"
-}:
-
-with pkgs;
-
 let
-  authPatch = runCommand "client_secret.patch" {} ''
-    export CLIENT_ID='${clientId}'
-    export CLIENT_SECRET='${clientSecret}'
-    export PROJECT_ID='${project}'
-    cat ${./api_client.patch} | ${gettext}/bin/envsubst > $out
-  '';
+  inherit (pkgs) fetchFromGitHub python3Packages;
 in python3Packages.buildPythonApplication rec {
   name = "lieer-${version}";
-  version = "1.0";
+  version = "1.3";
 
   src = fetchFromGitHub {
     owner = "gauteh";
     repo = "lieer";
     rev = "v${version}";
-    sha256 = "1zzylv8xbcrh34bz0s29dawzcyx39lai8y8wk0bl4x75v1jfynvf";
+    sha256 = "12sl7d381l1gjaam419xc8gxmsprxf0hgksz1f974qmmijvr02bh";
   };
 
   patches = [
-    authPatch
     ./send_scope.patch
   ];