Skip to content

Commit

Permalink
Merge pull request #141 from ansys/maint/release_0.1.1
Browse files Browse the repository at this point in the history
Release 0.1.1
  • Loading branch information
greschd authored Dec 4, 2024
2 parents a192448 + 223a09b commit c9f7016
Show file tree
Hide file tree
Showing 59 changed files with 1,381 additions and 858 deletions.
9 changes: 9 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
documentation:
- changed-files:
- any-glob-to-any-file: ['doc/source/**/*']
maintenance:
- changed-files:
- any-glob-to-any-file: ['.github/**/*', '.flake8', 'pyproject.toml']
dependencies:
- changed-files:
- any-glob-to-any-file: ['poetry\.lock']
27 changes: 27 additions & 0 deletions .github/labels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
- name: bug
description: Something isn't working
color: d42a34

- name: dependencies
description: Related with project dependencies
color: ffc0cb

- name: documentation
description: Improvements or additions to documentation
color: 0677ba

- name: enhancement
description: New features or code improvements
color: FFD827

- name: good first issue
description: Easy to solve for newcomers
color: 62ca50

- name: maintenance
description: Package and maintenance related
color: f78c37

- name: release
description: Anything related to an incoming release
color: ffffff
61 changes: 39 additions & 22 deletions .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
- main

env:
MAIN_PYTHON_VERSION: "3.12"
MAIN_PYTHON_VERSION: "3.13"
PACKAGE_NAME: "ansys-tools-filetransfer"
DOCUMENTATION_CNAME: "filetransfer.tools.docs.pyansys.com"

Expand Down Expand Up @@ -39,7 +39,7 @@ jobs:
name: "Documentation style"
runs-on: ubuntu-latest
steps:
- uses: ansys/actions/doc-style@v5
- uses: ansys/actions/doc-style@v8
with:
token: ${{ secrets.GITHUB_TOKEN }}

Expand All @@ -49,15 +49,15 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ['3.9', '3.10', '3.11', '3.12']
python-version: ['3.10', '3.11', '3.12', '3.13']
should-release:
- ${{ github.event_name == 'push' && contains(github.ref, 'refs/tags') }}
exclude:
- should-release: false
os: macos-latest
steps:
- name: "Build wheelhouse and perform smoke test"
uses: ansys/actions/build-wheelhouse@v5
uses: ansys/actions/build-wheelhouse@v8
with:
library-name: ${{ env.PACKAGE_NAME }}
operating-system: ${{ matrix.os }}
Expand All @@ -70,7 +70,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: ['3.9', '3.10', '3.11', '3.12']
python-version: ['3.10', '3.11', '3.12', '3.13']
fail-fast: false

steps:
Expand Down Expand Up @@ -101,15 +101,13 @@ jobs:
name: coverage-report-html
path: htmlcov
retention-days: 7
# TODO: Uncomment once publicly released
#
# - name: "Upload coverage to Codecov"
# uses: codecov/codecov-action@v4
# if: matrix.os == 'ubuntu-latest' && matrix.python-version == env.MAIN_PYTHON_VERSION
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
# with:
# files: coverage.xml
- name: "Upload coverage to Codecov"
uses: codecov/codecov-action@v5
if: matrix.os == 'ubuntu-latest' && matrix.python-version == env.MAIN_PYTHON_VERSION
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
files: coverage.xml

docs:
name: Documentation
Expand All @@ -136,6 +134,7 @@ jobs:
retention-days: 7
- name: "Install OS packages for PDF"
run: |
sudo apt-get update
sudo apt-get install latexmk texlive-latex-extra
- name: Generate the PDF documentation with tox
run: tox -e doc-linux-pdf
Expand All @@ -152,26 +151,40 @@ jobs:
needs: [style, tests, docs, doc-style, build-wheelhouse]
steps:
- name: "Build library source and wheel artifacts"
uses: ansys/actions/build-library@v5
uses: ansys/actions/build-library@v8
with:
library-name: ${{ env.PACKAGE_NAME }}
python-version: ${{ env.MAIN_PYTHON_VERSION }}

update-changelog:
name: "Update CHANGELOG for new tag"
if: github.event_name == 'push' && contains(github.ref, 'refs/tags')
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: ansys/actions/doc-deploy-changelog@v8
with:
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
bot-user: ${{ secrets.PYANSYS_CI_BOT_USERNAME }}
bot-email: ${{ secrets.PYANSYS_CI_BOT_EMAIL }}

release:
name: Release project
if: github.event_name == 'push' && contains(github.ref, 'refs/tags')
needs: [build]
needs: [build, update-changelog]
runs-on: ubuntu-latest
steps:
- name: Release to the public PyPI repository
uses: ansys/actions/release-pypi-public@v5
uses: ansys/actions/release-pypi-public@v8
with:
library-name: ${{ env.PACKAGE_NAME }}
twine-username: "__token__"
twine-token: ${{ secrets.PYPI_TOKEN }}

- name: Release to GitHub
uses: ansys/actions/release-github@v5
uses: ansys/actions/release-github@v8
with:
library-name: ${{ env.PACKAGE_NAME }}

Expand All @@ -182,10 +195,12 @@ jobs:
needs: [build]
steps:
- name: Deploy the latest documentation
uses: ansys/actions/doc-deploy-dev@v5
uses: ansys/actions/doc-deploy-dev@v8
with:
cname: ${{ env.DOCUMENTATION_CNAME }}
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
bot-user: ${{ secrets.PYANSYS_CI_BOT_USERNAME }}
bot-email: ${{ secrets.PYANSYS_CI_BOT_EMAIL }}

upload_docs_release:
name: Upload release documentation
Expand All @@ -194,7 +209,9 @@ jobs:
needs: [release]
steps:
- name: Deploy the stable documentation
uses: ansys/actions/doc-deploy-stable@v5
uses: ansys/actions/doc-deploy-stable@v8
with:
cname: ${{ env.DOCUMENTATION_CNAME }}
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
bot-user: ${{ secrets.PYANSYS_CI_BOT_USERNAME }}
bot-email: ${{ secrets.PYANSYS_CI_BOT_EMAIL }}
102 changes: 102 additions & 0 deletions .github/workflows/label.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
name: Labeler
on:
pull_request:
# opened, reopened, and synchronize are default for pull_request
# edited - when PR title or body is changed
# labeled - when labels are added to PR
types: [opened, reopened, synchronize, edited, labeled]
push:
branches: [ main ]
paths:
- '../labels.yml'

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:

label-syncer:
name: Syncer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: micnncim/action-label-syncer@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

labeler:
name: Set labels
needs: [label-syncer]
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:

# Label based on modified files
- name: Label based on changed files
uses: actions/labeler@v5
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}

# Label based on branch name
- uses: actions-ecosystem/action-add-labels@v1
if: |
startsWith(github.event.pull_request.head.ref, 'doc') ||
startsWith(github.event.pull_request.head.ref, 'docs')
with:
labels: documentation

- uses: actions-ecosystem/action-add-labels@v1
if: |
startsWith(github.event.pull_request.head.ref, 'maint') ||
startsWith(github.event.pull_request.head.ref, 'no-ci') ||
startsWith(github.event.pull_request.head.ref, 'ci')
with:
labels: maintenance

- uses: actions-ecosystem/action-add-labels@v1
if: startsWith(github.event.pull_request.head.ref, 'feat')
with:
labels: |
enhancement
- uses: actions-ecosystem/action-add-labels@v1
if: |
startsWith(github.event.pull_request.head.ref, 'fix') ||
startsWith(github.event.pull_request.head.ref, 'patch')
with:
labels: bug

commenter:
runs-on: ubuntu-latest
steps:
- name: Suggest to add labels
uses: peter-evans/create-or-update-comment@v4
# Execute only when no labels have been applied to the pull request
if: toJSON(github.event.pull_request.labels.*.name) == '{}'
with:
issue-number: ${{ github.event.pull_request.number }}
body: |
Please add one of the following labels to add this contribution to the Release Notes :point_down:
- [bug](https://github.com/ansys/ansys-tools-local-product-launcher/pulls?q=label%3Abug+)
- [documentation](https://github.com/ansys/ansys-tools-local-product-launcher/pulls?q=label%3Adocumentation+)
- [enhancement](https://github.com/ansys/ansys-tools-local-product-launcher/pulls?q=label%3Aenhancement+)
- [good first issue](https://github.com/ansys/ansys-tools-local-product-launcher/pulls?q=label%3Agood+first+issue)
- [maintenance](https://github.com/ansys/ansys-tools-local-product-launcher/pulls?q=label%3Amaintenance+)
- [release](https://github.com/ansys/ansys-tools-local-product-launcher/pulls?q=label%3Arelease+)
changelog-fragment:
name: "Create changelog fragment"
needs: [labeler]
permissions:
contents: write
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: ansys/actions/doc-changelog@v8
with:
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
bot-user: ${{ secrets.PYANSYS_CI_BOT_USERNAME }}
bot-email: ${{ secrets.PYANSYS_CI_BOT_EMAIL }}
12 changes: 3 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
# Created by https://www.toptal.com/developers/gitignore/api/python
# Edit at https://www.toptal.com/developers/gitignore?templates=python

### Python ###
# Byte-compiled / optimized / DLL files
__pycache__/
Expand Down Expand Up @@ -149,10 +146,7 @@ dmypy.json
cython_debug/

# PyCharm
# JetBrains specific template is maintainted in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/
.idea

# End of https://www.toptal.com/developers/gitignore/api/python
# VSCode
.vscode
14 changes: 7 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
repos:

- repo: https://github.com/asottile/pyupgrade
rev: v3.15.0
rev: v3.19.0
hooks:
- id: pyupgrade
args: [--py39-plus]
args: [--py310-plus]

- repo: https://github.com/psf/black
rev: 24.2.0
rev: 24.10.0
hooks:
- id: black

Expand All @@ -17,15 +17,15 @@ repos:
- id: isort

- repo: https://github.com/pycqa/flake8
rev: 7.0.0
rev: 7.1.1
hooks:
- id: flake8

- repo: https://github.com/codespell-project/codespell
rev: v2.2.6
rev: v2.3.0
hooks:
- id: codespell
exclude: "^(poetry\\.lock)|(CONTRIBUTORS\\.md)$"
exclude: "^(pyproject\\.toml)|(poetry\\.lock)|(CONTRIBUTORS\\.md)|(CODE_OF_CONDUCT\\.md)$"

- repo: https://github.com/pycqa/pydocstyle
rev: 6.3.0
Expand All @@ -35,7 +35,7 @@ repos:
exclude: "tests/"

- repo: https://github.com/ansys/pre-commit-hooks
rev: v0.2.8
rev: v0.4.4
hooks:
- id: add-license-headers
args: ["--start_year", "2022"]
Expand Down
4 changes: 2 additions & 2 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
# For contributions made under a Corporate CLA, the organization is
# added to this file.
#
# If you have contributed to the repository and wish to be added to this file
# please submit a request.
# If you have contributed to the repository and want to be added to this file,
# submit a request.
#
#
ANSYS, Inc.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
# CHANGELOG
# CHANGELOG

This project uses [towncrier](https://towncrier.readthedocs.io/) and the changes for the upcoming release can be found in <https://github.com/ansys/ansys-tools-filetransfer/tree/main/doc/changelog.d/>.

<!-- towncrier release notes start -->
3 changes: 2 additions & 1 deletion CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
# Contributors

## Project Lead or Owner
## Project Lead

* [Dominik Gresch](https://github.com/greschd)

## Individual Contributors

* [Alex Kaszynski](https://github.com/akaszynski)
* [Dominik Gresch](https://github.com/greschd)
* [Kathy Pippert](https://github.com/PipKat)
* [Jorge Martínez](https://github.com/jorgepiloto)
* [Roberto Pastor Muela](https://github.com/RobPasMue)
* [Udo Tremel](https://github.com/ansutremel)
Loading

0 comments on commit c9f7016

Please sign in to comment.