Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: add workflow to upload package to pypi #149

Merged
merged 1 commit into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ jobs:
fetch-depth: 0

- name: Python Semantic Release
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: 3.12

- name: Install dependencies
run: |
Expand All @@ -28,3 +28,12 @@ jobs:
run: make release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Build package
run: |
python -m build --sdist --wheel --outdir dist/ .
- name: Publish package
uses: pypa/[email protected]
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
release: ## release a new version
@echo "Releasing a new version."
@echo "This is a remote release, it will push to the remote repository."
semantic-release -vv version --changelog --push --tag --commit
semantic-release --strict version --changelog --push --tag --commit

local-release:
@echo "Releasing a new version."
@echo "This is a local release, it will not push to the remote repository."
@echo "You can push the changes and release manually."
semantic-release -vv version --changelog --commit --no-push
semantic-release version --changelog --commit --no-push

selfcheck: ## check that the Makefile is well-formed
@echo "The Makefile is well-formed."
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ requires = ["setuptools>=42", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "drydock"
name = "tutor-contrib-drydock"
dynamic = ["version"]
description = "A Tutor plugin to manage our opinionated Open edX operations"
readme = "README.md"
Expand Down
Loading