-
-
Notifications
You must be signed in to change notification settings - Fork 98
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
231: The scripts I use to manage uploading to PyPI. r=astronouth7303 a=pathunstrom Co-authored-by: Piper Thunstrom <pathunstrom@gmail.com>
- Loading branch information
Showing
7 changed files
with
33 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# PyPI Upload Scripts | ||
|
||
I constantly have to lookup how to do the varying steps for this, so I | ||
wrote some bash scripts for handling the artifact generation and PyPI | ||
uploads, including to the test server. | ||
|
||
## Process | ||
|
||
1. Navigate to the directory root. | ||
2. `sh ./.upload-scripts/env-build.sh` | ||
3. `source ./.upload-venv/bin/activate` | ||
4. `sh ./.upload-scripts/generate.sh` | ||
5. Check the new build artifact for errors. | ||
6. `sh ./.upload-scripts/test-upload.sh` | ||
7. Check the uploaded version. Test install with | ||
`pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple ppb` | ||
When you're sure, move on. | ||
8. `sh ./.upload-scripts/up` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
python3 -m venv .upload-venv | ||
./.upload-venv/bin/pip install -r ./requirements-upload.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
python3 setup.py sdist bdist_wheel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
twine upload --repository-url https://test.pypi.org/legacy/ --skip-existing dist/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
twine upload dist/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
setuptools >= 38.6.0 | ||
wheel >= 0.31.0 | ||
twine >= 1.11.0 | ||
pip >= 19 |