[geneagrapher] 190/226: Update the makedist.py script and remove licensify.py.
Doug Torrance
dtorrance-guest at moszumanska.debian.org
Sat Jul 11 17:11:07 UTC 2015
This is an automated email from the git hooks/post-receive script.
dtorrance-guest pushed a commit to branch master
in repository geneagrapher.
commit 8d27d5758ba25416e423a45c42dbaf1268cc9268
Author: David Alber <alber.david at gmail.com>
Date: Sat Dec 3 22:45:16 2011 -0800
Update the makedist.py script and remove licensify.py.
The licensify functionality is being removed because other
examples of open source projects that prepend every Python source
file with the license are not known.
This references #11.
---
licensify.py | 31 -------------------------------
makedist.py | 28 +---------------------------
2 files changed, 1 insertion(+), 58 deletions(-)
diff --git a/licensify.py b/licensify.py
deleted file mode 100644
index 045b00a..0000000
--- a/licensify.py
+++ /dev/null
@@ -1,31 +0,0 @@
-"""This small tool copies the license text in the file defined in the
-'license' variable below to the top of each file defined in the
-'files' variable. The license is prepended by the comment character.
-
-This script is meant to be called before packaging."""
-
-def prependLicense(file, license):
- res = ''
-
- lin = open(license, 'r')
- for line in lin:
- res = '%s# %s' % (res, line)
- lin.close()
- res = '%s\n' % (res)
-
- fin = open(file, 'r')
- for line in fin:
- res = '%s%s' % (res, line)
-
- fin.close()
- return res
-
-if __name__ == '__main__':
- files = ['geneagrapher/GGraph.py', 'geneagrapher/geneagrapher.py',
- 'geneagrapher/grab.py', 'geneagrapher/ggrapher.py']
- license = 'COPYING'
- for file in files:
- res = prependLicense(file, license)
- fout = open(file, "w")
- fout.write(res)
- fout.close()
diff --git a/makedist.py b/makedist.py
index cbbf093..7b2a041 100644
--- a/makedist.py
+++ b/makedist.py
@@ -1,31 +1,9 @@
"""This tool sets up a distribution of the software by automating
-several tasks that need to be done.
-
-The directory should be in pristine condition when this is run (i.e.,
-devoid of files that need to be removed before packaging begins). It
-is best to run this on a fresh check out of the repository."""
+several tasks that need to be done."""
import os
-import licensify
if __name__ == '__main__':
- # "Licensify" the source files.
- files = ['geneagrapher/GGraph.py', 'geneagrapher/geneagrapher.py',
- 'geneagrapher/grab.py', 'geneagrapher/ggrapher.py']
- license = 'COPYING'
- for file in files:
- res = licensify.prependLicense(file, license)
- fout = open(file, "w")
- fout.write(res)
- fout.close()
-
- # Remove files (including this one) that are not to be in the
- # distribution.
- os.system('svn rm licensify.py')
- os.system('rm -f licensify.pyc')
- os.system('svn rm makedist.py')
- os.system('rm -f makedist.pyc')
-
# Make the distribution.
os.system('python setup.py sdist --format gztar,zip')
@@ -39,7 +17,3 @@ if __name__ == '__main__':
comm = 'gpg -abs %s' % (file)
os.system(comm)
os.chdir('..')
-
- # Add files to repository.
- os.system('svn add Geneagrapher.egg-info')
- os.system('svn add dist')
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/geneagrapher.git
More information about the debian-science-commits
mailing list