From ca356464b511f81479de3c7530316eab64aaba0e Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sat, 2 Nov 2019 11:15:13 +0000 Subject: [PATCH] Save a file to indicate that a new shared item is available --- shares.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/shares.py b/shares.py index 587965a6..4e516735 100644 --- a/shares.py +++ b/shares.py @@ -144,6 +144,14 @@ def addShare(baseDir: str, \ saveJson(sharesJson,sharesFilename) + # indicate that a new share is available + newShareFile=baseDir+'/accounts/.newShare' + try: + with open(newShareFile, 'w') as fp: + fp.write('\n') + except: + pass + def expireShares(baseDir: str) -> None: """Removes expired items from shares """