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

feat(ci): add GitHub Actions job to publish the package #31

Merged
merged 4 commits into from
Nov 21, 2024
Merged

Conversation

himkt
Copy link
Collaborator

@himkt himkt commented Nov 21, 2024

Created the action job to automate the publish pipeline based on https://github.com/pypa/gh-action-pypi-publish.

@himkt himkt marked this pull request as ready for review November 21, 2024 08:52
- name: create a distribution
run: |
pip3 install build wheel
python3 -m build --wheel
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot 2024-11-21 at 17 53 37

We have published torch-dftd with sdist and wheel for the previous versions. Since a wheel distribution covers all the environment that we want to support (only requiring Python3), I think it's enough to publish with one of these formats.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have no strong opinion about this. (Either is fine for me)

@ShigeruIwase-PFN
Copy link
Collaborator

(MEMO) Workflow filename (.github/workflows/publish.yml) is consistent with the registered one.

@ShigeruIwase-PFN
Copy link
Collaborator

ShigeruIwase-PFN commented Nov 21, 2024

Don't we need to set the PyPI repository url as well?

   environment:
     name: pypi
     url: https://pypi.org/p/<your-pypi-project-name>

ref: https://github.com/pypa/gh-action-pypi-publish

@ShigeruIwase-PFN
Copy link
Collaborator

How about testing using TestPyPI, just in case?

@himkt
Copy link
Collaborator Author

himkt commented Nov 21, 2024

  • I created GitHub Environment release. Now the environment is referred from the workflow ffe1943.
  • I don't think we need TestPyPI (I think it's acceptable to run only on PyPI. In addition, there is no project torch-dftd on TestPyPI now).

Copy link
Collaborator

@ShigeruIwase-PFN ShigeruIwase-PFN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for me

@himkt himkt merged commit 29c4cba into master Nov 21, 2024
1 check passed
@himkt himkt deleted the pypi-gha branch November 21, 2024 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants