# Note: Hardcoded use of 'copyright' & 'spdx' is the result
# of a decision made at 2017 plugfest to limit searches to
# just these two strings.
- if re.search("copyright", content, re.IGNORECASE):
- logger.info('Contains needed Licence string: %s', patch_file)
- elif re.search("spdx", content, re.IGNORECASE):
+ patterns = ['copyright', 'spdx',
+ 'http://creativecommons.org/licenses/by/4.0']
+ if any(i in content.lower() for i in patterns):
logger.info('Contains needed Licence string: %s', patch_file)
else:
logger.error('Licence header missing in file: %s', patch_file)
# Note: Hardcoded use of 'copyright' & 'spdx' is the result
# of a decision made at 2017 plugfest to limit searches to
# just these two strings.
- if re.search("copyright", content, re.IGNORECASE):
- logger.info('Licence string present: %s', full_path)
- elif re.search("spdx", content, re.IGNORECASE):
+ patterns = ['copyright', 'spdx',
+ 'http://creativecommons.org/licenses/by/4.0']
+ if any(i in content.lower() for i in patterns):
logger.info('Licence string present: %s', full_path)
else:
logger.error('Licence header missing: %s', full_path)
- wget.+build\.opnfv\.org
- wget.+artifacts\.opnfv\.org
- wget.+git\.openstack.org
- - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
\ No newline at end of file
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
- wget.+artifacts\.opnfv\.org
- wget.+git\.openstack.org
- git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
-
- wget.+artifacts\.opnfv\.org
- wget.+git\.openstack.org
- git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
-
- wget.+artifacts\.opnfv\.org
- wget.+git\.openstack.org
- git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
-
- \'password\'\:.password
- \'password\'\:.\{
- metadata_secret
- - compass_user_password
\ No newline at end of file
+ - compass_user_password
- wget.+artifacts\.opnfv\.org
- wget.+git\.openstack.org
- git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
-
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
- git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
- openssl-dev.libjpeg-turbo-dev.git.wget.&
- RUN.+curl.*https\:\/\/get\.rvm\.io.*bash.*stable
- - grep.sed.wget.ca-certificates.git.\&&
\ No newline at end of file
+ - grep.sed.wget.ca-certificates.git.\&&
# of escaping YAML delimiters too (such as `:`) using double quotes "".
binaries:
- binary_ignore: [nullvalue]
+ dynamic-flow.png:
+ - d0d7dfc73e0fac09d920ebbdf8cd4e0ef623f15d6246ff20d7a6d12c9a48bf41
file_audits:
file_names: [nullvalue]
file_contents:
- wget.+artifacts\.opnfv\.org
- wget.+git\.openstack.org
- git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
-
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
--- /dev/null
+---
+# When adding projects all `arrays: []` sections must have
+# a value, Use 'nullvalue' if no waivers are available.
+#
+# This file uses standard regular expression syntax, however be mindful
+# of escaping YAML delimiters too (such as `:`) using double quotes "".
+
+binaries:
+ binary_ignore: [nullvalue]
+
+file_audits:
+ file_names: [nullvalue]
+ file_contents:
+ - ^#
+ - git clone.+\.openstack\.org
+ - git clone.+gerrit\.opnfv\.org
+ - wget.+build\.opnfv\.org
+ - wget.+artifacts\.opnfv\.org
+ - wget.+git\.openstack.org
+ - git clone.+https:\/\/git.opendaylight\.org\/gerrit\/
- compass4nfv: exceptions/compass4nfv.yaml
- conductor: exceptions/conductor.yaml
- copper: exceptions/copper.yaml
+ - cperf: exceptions/cperf.yaml
+ - daisy: exceptions/daisy.yaml
+ - doctor: exceptions/doctor.yaml
+ - dovetail: exceptions/dovetail.yaml
+ - dpacc: exceptions/dpacc.yaml
+ - enfv: exceptions/enfv.yaml
+ - escalator: exceptions/escalator.yaml
+ - fds: exceptions/fds.yaml
- functest: exceptions/functest.yaml
- octopus: exceptions/octopus.yaml
- pharos: exceptions/pharos.yaml
- releng: exceptions/releng.yaml
- sandbox: exceptions/sandbox.yaml
+ - yardstick: exceptions/yardstick.yaml
binaryornot==0.4.3
chardet==3.0.2
docopt==0.6.2
+invoke==0.18.0
packaging==16.8
pyaml==16.12.2
pyparsing==2.2.0
PyYAML==3.12
six==1.10.0
+twine==1.9.1
@task
-def test():
+def test(ctx):
run('python setup.py test', pty=True)
@task
-def clean():
- run("rm -rf build")
- run("rm -rf dist")
- run("rm -rf anteater.egg-info")
- clean_docs()
+def clean(ctx):
+ ctx.run("rm -rf build")
+ ctx.run("rm -rf dist")
+ ctx.run("rm -rf anteater.egg-info")
+ clean_docs(ctx)
print("Cleaned up.")
@task
-def clean_docs():
- run("rm -rf %s" % build_dir)
+def clean_docs(ctx):
+ ctx.run("rm -rf %s" % build_dir)
@task
-def browse_docs():
- run("open %s" % os.path.join(build_dir, 'index.html'))
+def browse_docs(ctx):
+ ctx.run("open %s" % os.path.join(build_dir, 'index.html'))
@task
-def build_docs(clean=False, browse=False):
+def build_docs(ctx, clean=False, browse=False):
if clean:
clean_docs()
- run("sphinx-build %s %s" % (docs_dir, build_dir), pty=True)
+ ctx.run("sphinx-build %s %s" % (docs_dir, build_dir), pty=True)
if browse:
browse_docs()
@task
-def readme(browse=False):
- run('rst2html.py README.rst > README.html')
+def readme(ctx, browse=False):
+ ctx.run('rst2html.py README.rst > README.html')
@task
-def publish(test=False):
- """Publish to the cheeseshop."""
+def build(ctx):
+ """Build source distribution and wheels."""
+ ctx.run('python setup.py sdist bdist_wheel')
+
+
+@task
+def publish(ctx, test=False):
+ """Publish to the cheeseshop.
+
+ This command follows the Python packaging guidelines:
+ https://packaging.python.org/tutorials/distributing-packages
+
+ Information on configuration required for '--test' can be found
+ here: https://wiki.python.org/moin/TestPyPI
+
+ Before uploading please ensure you've signed the release using:
+
+ gpg --detach-sign -a dist/package-1.0.1.tar.gz
+ """
if test:
- run('python setup.py register -r test sdist upload -r test')
+ ctx.run('twine upload -r test dist/*')
else:
- run("python setup.py register sdist upload")
+ ctx.run("twine upload dist/*")