-
Notifications
You must be signed in to change notification settings - Fork 664
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into mahesh/readme-edits
- Loading branch information
Showing
27 changed files
with
881 additions
and
967 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
name: Python | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
detect-packages: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
packages: ${{ steps.find-packages.outputs.packages }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Find Python packages | ||
id: find-packages | ||
working-directory: src | ||
run: | | ||
PACKAGES=$(find . -name pyproject.toml -exec dirname {} \; | sed 's/^\.\///' | jq -R -s -c 'split("\n")[:-1]') | ||
echo "packages=$PACKAGES" >> $GITHUB_OUTPUT | ||
build: | ||
needs: [detect-packages] | ||
strategy: | ||
matrix: | ||
package: ${{ fromJson(needs.detect-packages.outputs.packages) }} | ||
name: Build ${{ matrix.package }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Install uv | ||
uses: astral-sh/setup-uv@v3 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version-file: "src/${{ matrix.package }}/.python-version" | ||
|
||
- name: Install dependencies | ||
working-directory: src/${{ matrix.package }} | ||
run: uv sync --frozen --all-extras --dev | ||
|
||
- name: Run pyright | ||
working-directory: src/${{ matrix.package }} | ||
run: uv run --frozen pyright | ||
|
||
- name: Build package | ||
working-directory: src/${{ matrix.package }} | ||
run: uv build | ||
|
||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: dist-${{ matrix.package }} | ||
path: src/${{ matrix.package }}/dist/ | ||
|
||
publish: | ||
runs-on: ubuntu-latest | ||
needs: [build, detect-packages] | ||
if: github.event_name == 'release' | ||
|
||
strategy: | ||
matrix: | ||
package: ${{ fromJson(needs.detect-packages.outputs.packages) }} | ||
name: Publish ${{ matrix.package }} | ||
|
||
environment: release | ||
permissions: | ||
id-token: write # Required for trusted publishing | ||
|
||
steps: | ||
- name: Download artifacts | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: dist-${{ matrix.package }} | ||
path: dist/ | ||
|
||
- name: Publish package to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 |
2 changes: 2 additions & 0 deletions
2
.github/workflows/main.yml → .github/workflows/typescript.yml
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 |
---|---|---|
@@ -1,3 +1,5 @@ | ||
name: TypeScript | ||
|
||
on: | ||
push: | ||
branches: | ||
|
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
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
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
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
Oops, something went wrong.