Skip to content
This repository has been archived by the owner on Aug 5, 2024. It is now read-only.

Commit

Permalink
code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
dynasticorpheus committed Apr 25, 2015
1 parent 12c8118 commit e80da4c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gigasetelements-cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
gc.disable()

_author_ = 'dynasticorpheus@gmail.com'
_version_ = '1.1.4'
_version_ = '1.1.5'

parser = argparse.ArgumentParser(description='Gigaset Elements - Command-line Interface by dynasticorpheus@gmail.com')
parser.add_argument('-c', '--config', help='fully qualified name of configuration-file', required=False)
Expand Down Expand Up @@ -211,7 +211,7 @@ def add_cron(schedule):
timer = now.replace(hour=time.strptime(args.cronjob, '%H:%M')[3], minute=time.strptime(args.cronjob, '%H:%M')[4], second=0, microsecond=0)
job = cron.new(command=os.path.realpath(__file__) + ' -m ' + args.modus, comment='added by gigasetelements-cli on ' + str(now)[:16])
job.month.on(datetime.datetime.now().strftime('%-m'))
if now < now.replace(hour=time.strptime(args.cronjob, '%H:%M')[3], minute=time.strptime(args.cronjob, '%H:%M')[4], second=0, microsecond=0):
if now < timer:
job.day.on(datetime.datetime.now().strftime('%-d'))
else:
job.day.on(str((int(datetime.datetime.now().strftime('%-d')) + 1)))
Expand Down

0 comments on commit e80da4c

Please sign in to comment.