Skip to content

Commit

Permalink
Improved how the statefile last modified date is updated
Browse files Browse the repository at this point in the history
  • Loading branch information
Neraud committed Aug 3, 2018
1 parent 7bc4d13 commit e0b243b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion plugins/git/git_commit_behind
Expand Up @@ -101,6 +101,7 @@ GPLv2

import logging
import os
from pathlib import Path
from random import randint
import re
from subprocess import check_output, call, DEVNULL, CalledProcessError
Expand Down Expand Up @@ -231,7 +232,9 @@ def do_update_repos():
logging.error('Repo not found at path %s' %
repos_conf[repo_code]['path'])
logging.debug('Updating the state file')
open(conf['state_file'], 'w')

# 'touch' the state file to update its last modified date
Path(conf['state_file']).touch()


if len(sys.argv) > 1:
Expand Down

0 comments on commit e0b243b

Please sign in to comment.