Merge pull request #615 from d0ugal/master

Don't use Travis for deploying
This commit is contained in:
Dougal Matthews
2015-06-08 15:07:09 +01:00
2 changed files with 16 additions and 8 deletions

View File

@@ -17,11 +17,3 @@ matrix:
fast_finish: true
before_install: pip install codecov
after_success: codecov
deploy:
provider: pypi
user: mkdocsdeploy
on:
tags: true
distributions: sdist bdist_wheel
password:
secure: NajIoVN5cPFKq5EB1viIujcnwywFbOlU/KM5/Qp+WxdX5/ZTnFmaD1iwXc/6kgM07y3XVi6R/nDJr0eAC7kaCRnHE+uT7pRwJtXqtt2mkpIlHD8Y6ppPhxm9AnUhE638t22DuX89cD1JkkvQ97EGD6OJymWAVCRwwkzVzP1Cn/M=

View File

@@ -46,6 +46,22 @@ def get_package_data(package):
for filename in filenames])
return {package: filepaths}
if sys.argv[-1] == 'publish':
if os.system("pip freeze | grep wheel"):
print("wheel not installed.\nUse `pip install wheel`.\nExiting.")
sys.exit()
if os.system("pip freeze | grep twine"):
print("twine not installed.\nUse `pip install twine`.\nExiting.")
sys.exit()
os.system("python setup.py sdist bdist_wheel")
os.system("twine upload dist/*")
print("You probably want to also tag the version now:")
print(" git tag -a {0} -m 'version {0}'".format(get_version("mkdocs")))
print(" git push --tags")
sys.exit()
setup(
name="mkdocs",
version=get_version("mkdocs"),