Skip to content

Commit

Permalink
Adding Azure-Keyvault To List of Omitted Releases (#4065)
Browse files Browse the repository at this point in the history
* list of packages that are to be ignored

* moving omittedreleases to global.

* updating capitalization
  • Loading branch information
scbedd authored and lmazuel committed Dec 14, 2018
1 parent 376e691 commit 456158f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions build_package.py
Expand Up @@ -19,6 +19,7 @@
from pip._vendor.packaging.version import parse as Version, InvalidVersion

DEFAULT_DEST_FOLDER = "./dist"
OMITTED_RELEASE_PACKAGES = ['azure-keyvault']

def create_package(name, dest_folder=DEFAULT_DEST_FOLDER):
absdirpath = os.path.abspath(name)
Expand All @@ -31,6 +32,7 @@ def travis_build_package():
This method prints on stdout for Travis.
Return is obj to pass to sys.exit() directly
"""

travis_tag = os.environ.get('TRAVIS_TAG')
if not travis_tag:
print("TRAVIS_TAG environment variable is not present")
Expand All @@ -48,6 +50,10 @@ def travis_build_package():
print("Version must be a valid PEP440 version (version is: {})".format(version))
return "Version must be a valid PEP440 version (version is: {})".format(version)

if name.lower() in OMITTED_RELEASE_PACKAGES:
print("The input package {} has been disabled for release from Travis.CI.".format(name))
return

abs_dist_path = Path(os.environ['TRAVIS_BUILD_DIR'], 'dist')
create_package(name, str(abs_dist_path))

Expand Down

0 comments on commit 456158f

Please sign in to comment.