Skip to content

Commit

Permalink
add push script
Browse files Browse the repository at this point in the history
  • Loading branch information
aljabadi committed Jan 8, 2022
1 parent b44d3cc commit b53622a
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
.vscode
__pycahce__
.venv
.history
Expand Down
30 changes: 30 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"[python]": {
"editor.defaultFormatter": null,
"editor.rulers": [
88,
98
]
},
"python.linting.flake8Args": [
"--max-line-length=88",
],
"editor.formatOnSave": true,
"python.formatting.provider": "black",
"python.testing.unittestArgs": [
"-v",
"-s",
"./tests",
"-p",
"test_*.py"
],
"python.testing.pytestEnabled": false,
"python.testing.unittestEnabled": true,
"python.linting.flake8Enabled": true,
"files.exclude": {
"**/.history": true,
"**/.tox": true,
"**/__pycache__": true,
"**/.venv": true,
},
}
19 changes: 19 additions & 0 deletions scripts/bump-and-push.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# With a clean git stage, this script bumps up package version, tags it
# and pushes to PyPI, assuming PyPI API key is available in $HOME/.pypirc.
# It eventually opens the github release
# page where you need to create a new release used by pip
printf "Initiating Tag and Push ..."
printf "activate virtual env containing bump2version ..."
# bump version and tag
printf "bump the version ..."
bumpversion minor
# printf "push to github ..."
git push origin
# push tag
LAST_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)
git push origin $LAST_TAG
# printf "push to PyPI ..."
python setup.py sdist
twine upload dist/*
printf "open github release page to create the latest release for pip use..."
open https://github.com/aljabadi/logster/releases/new

0 comments on commit b53622a

Please sign in to comment.