From a72b99b32c6978efd4127223ec5881bae8f8a4aa Mon Sep 17 00:00:00 2001 From: Alexander Bantyev Date: Wed, 13 Jan 2021 14:45:01 +0300 Subject: [PATCH] Fix mistakes with secrets --- modules/applications/yt-utilities.nix | 4 ++-- modules/workspace/i3blocks/default.nix | 4 ++-- modules/workspace/i3blocks/scripts/email.nix | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/applications/yt-utilities.nix b/modules/applications/yt-utilities.nix index 9589a94..116808b 100644 --- a/modules/applications/yt-utilities.nix +++ b/modules/applications/yt-utilities.nix @@ -6,8 +6,8 @@ secrets = [ "user" "token" ]; owner = "balsoft:users"; template = builtins.toJSON { - yt-token = "$user"; - user = "$token"; + yt-token = "$token"; + user = "$user"; from = { org = "/home/balsoft/Documents/serokell.org"; full-file = true; diff --git a/modules/workspace/i3blocks/default.nix b/modules/workspace/i3blocks/default.nix index 39ae5b7..64f2cb9 100644 --- a/modules/workspace/i3blocks/default.nix +++ b/modules/workspace/i3blocks/default.nix @@ -44,8 +44,8 @@ in { in '' interval=60 markup=pango - '' + genIniOrdered ([] - # (scr "email") + '' + genIniOrdered ( + [ (scr "email") ] ++ [ (scrint "weather" 600) (scr "emacs") (scr "nixos") ] ++ [ (scrint "youtrack-wage" 3600) (scrint "music" 3) (scrint "sound" 1) ] ++ [ (scrint "cpu" 5) diff --git a/modules/workspace/i3blocks/scripts/email.nix b/modules/workspace/i3blocks/scripts/email.nix index 556deca..e7e048b 100644 --- a/modules/workspace/i3blocks/scripts/email.nix +++ b/modules/workspace/i3blocks/scripts/email.nix @@ -1,8 +1,8 @@ { python3, iconfont, config, ... }: '' #!${python3}/bin/python3 import imaplib - obj = imaplib.IMAP4_SSL('imap.${config.secrets.mail.host}', 993) - obj.login("${config.secrets.mail.user}@${config.secrets.mail.host}", "${config.secrets.mail.password}") + obj = imaplib.IMAP4_SSL('balsoft.ru', 993) + obj.login("balsoft@balsoft.ru", "${config.secrets.gnome-keyring-envsubst-email.decrypted}") obj.select() l = len(obj.search(None, 'unseen')[1][0].split()) if l == 0: