aboutsummaryrefslogtreecommitdiffstats
path: root/nikola/plugins/command/deploy.py
diff options
context:
space:
mode:
authorLibravatarUnit 193 <unit193@unit193.net>2021-04-22 20:23:51 -0400
committerLibravatarUnit 193 <unit193@unit193.net>2021-04-22 20:23:51 -0400
commit5fe4d85d8450575556385f20c46d67887009e245 (patch)
treee07d531240670225499657eff04a16105eb4bb5f /nikola/plugins/command/deploy.py
parent501ee1930f5424ac00be29a7537a74e30c5d901f (diff)
parent8eeed31eb2f86ac982fa4b26f93b15828289c56d (diff)
Update upstream source from tag 'upstream/8.1.3'
Update to upstream version '8.1.3' with Debian dir ff84f28157b98ab52cbb563f4853d749beb4be60
Diffstat (limited to 'nikola/plugins/command/deploy.py')
-rw-r--r--nikola/plugins/command/deploy.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/nikola/plugins/command/deploy.py b/nikola/plugins/command/deploy.py
index 5273b58..64c1c9f 100644
--- a/nikola/plugins/command/deploy.py
+++ b/nikola/plugins/command/deploy.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-# Copyright © 2012-2020 Roberto Alsina and others.
+# Copyright © 2012-2021 Roberto Alsina and others.
# Permission is hereby granted, free of charge, to any
# person obtaining a copy of this software and associated
@@ -54,6 +54,8 @@ class CommandDeploy(Command):
if last_deploy is not None:
last_deploy = dateutil.parser.parse(last_deploy)
clean = False
+ else:
+ clean = True
if self.site.config['COMMENT_SYSTEM'] and self.site.config['COMMENT_SYSTEM_ID'] == 'nikolademo':
self.logger.warning("\nWARNING WARNING WARNING WARNING\n"
@@ -96,6 +98,8 @@ class CommandDeploy(Command):
self.logger.info("Successful deployment")
new_deploy = datetime.utcnow()
+ if last_deploy is None:
+ last_deploy = new_deploy
self._emit_deploy_event(last_deploy, new_deploy, clean, undeployed_posts)
# Store timestamp of successful deployment