test: remove unused command #3
This file contains hidden or 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
name: "Test" | |
on: | |
pull_request: | |
push: | |
jobs: | |
tests: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
runs-on: ${{ matrix.os }} | |
permissions: | |
contents: read | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v31 | |
- uses: cachix/cachix-action@v16 | |
with: | |
name: planet-a-ventures | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- name: Install devenv.sh | |
run: nix profile install nixpkgs#devenv | |
- name: Build the devenv shell and run any pre-commit hooks | |
run: devenv test | |
env: | |
NOTION_TOKEN: ${{ secrets.NOTION_TOKEN }} | |
build: | |
name: Build distribution 📦 | |
runs-on: ubuntu-latest | |
needs: | |
- tests | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v31 | |
- uses: cachix/cachix-action@v16 | |
with: | |
name: planet-a-ventures | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- name: Install devenv.sh | |
run: nix profile install nixpkgs#devenv | |
- name: Create the package tarball | |
run: devenv shell build | |
- name: Store the distribution packages | |
uses: actions/upload-artifact@v4 | |
with: | |
name: python-package-distributions | |
path: dist/ | |
publish-to-pypi: | |
name: >- | |
Publish Python 🐍 distribution 📦 to PyPI | |
if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes | |
needs: | |
- build | |
runs-on: ubuntu-latest | |
environment: | |
name: release | |
url: https://pypi.org/p/dlt-source-notion | |
permissions: | |
id-token: write # IMPORTANT: mandatory for trusted publishing | |
steps: | |
- name: Download all the dists | |
uses: actions/download-artifact@v4 | |
with: | |
name: python-package-distributions | |
path: dist/ | |
- name: Publish distribution 📦 to PyPI | |
uses: pypa/gh-action-pypi-publish@release/v1 |