summaryrefslogtreecommitdiff
path: root/passlib/_setup
diff options
context:
space:
mode:
authorEli Collins <elic@assurancetechnologies.com>2012-08-01 12:52:39 -0400
committerEli Collins <elic@assurancetechnologies.com>2012-08-01 12:52:39 -0400
commit432fd93f6884036df59007f09dee86adfb7078ad (patch)
tree6b7b702984775a66f73d6831cd2a8749156147ba /passlib/_setup
parent189346c45a4907479f083c854469a896dcf3b581 (diff)
downloadpasslib-432fd93f6884036df59007f09dee86adfb7078ad.tar.gz
project-wide whitespace & comment cleanup (it's been a couple of years)
Diffstat (limited to 'passlib/_setup')
-rw-r--r--passlib/_setup/docdist.py38
-rw-r--r--passlib/_setup/stamp.py18
2 files changed, 28 insertions, 28 deletions
diff --git a/passlib/_setup/docdist.py b/passlib/_setup/docdist.py
index 4532e95..dadb4b5 100644
--- a/passlib/_setup/docdist.py
+++ b/passlib/_setup/docdist.py
@@ -1,35 +1,35 @@
"custom command to build doc.zip file"
-#=========================================================
-#imports
-#=========================================================
-#core
+#=============================================================================
+# imports
+#=============================================================================
+# core
import os
from distutils import dir_util
from distutils.cmd import Command
from distutils.errors import *
from distutils.spawn import spawn
-#local
+# local
__all__ = [
"docdist"
]
-#=========================================================
-#command
-#=========================================================
+#=============================================================================
+# command
+#=============================================================================
class docdist(Command):
description = "create zip file containing standalone html docs"
-
+
user_options = [
('build-dir=', None, 'Build directory'),
('dist-dir=', 'd',
"directory to put the source distribution archive(s) in "
- "[default: dist]"),
+ "[default: dist]"),
('format=', 'f',
"archive format to create (tar, ztar, gztar, zip)"),
('sign', 's', 'sign files using gpg'),
('identity=', 'i', 'GPG identity used to sign files'),
]
-
+
def initialize_options(self):
self.build_dir = None
self.dist_dir = None
@@ -37,7 +37,7 @@ class docdist(Command):
self.keep_temp = False
self.sign = False
self.identity = None
-
+
def finalize_options(self):
if self.identity and not self.sign:
raise DistutilsOptionError(
@@ -50,7 +50,7 @@ class docdist(Command):
self.dist_dir = "dist"
if not self.format:
self.format = "zip"
-
+
def run(self):
# call build sphinx to build docs
self.run_command("build_sphinx")
@@ -77,11 +77,11 @@ class docdist(Command):
gpg_args[2:2] = ["--local-user", self.identity]
spawn(gpg_args,
dry_run=self.dry_run)
-
- #cleanup
+
+ # cleanup
if not self.keep_temp:
dir_util.remove_tree(tmp_dir, dry_run=self.dry_run)
-
-#=========================================================
-#eof
-#=========================================================
+
+#=============================================================================
+# eof
+#=============================================================================
diff --git a/passlib/_setup/stamp.py b/passlib/_setup/stamp.py
index e3127e4..dfa62bc 100644
--- a/passlib/_setup/stamp.py
+++ b/passlib/_setup/stamp.py
@@ -1,22 +1,22 @@
"update version string during build"
-#=========================================================
+#=============================================================================
# imports
-#=========================================================
+#=============================================================================
from __future__ import with_statement
-#core
+# core
import os
import re
import time
from distutils.dist import Distribution
-#pkg
-#local
+# pkg
+# local
__all__ = [
"stamp_source",
"stamp_distutils_output",
]
-#=========================================================
+#=============================================================================
# helpers
-#=========================================================
+#=============================================================================
def get_command_class(opts, name):
return opts['cmdclass'].get(name) or Distribution().get_command_class(name)
@@ -52,6 +52,6 @@ def stamp_distutils_output(opts, version):
stamp_source(base_dir, version, self.dry_run)
opts['cmdclass']['sdist'] = sdist
-#=========================================================
+#=============================================================================
# eof
-#=========================================================
+#=============================================================================