Skip to content
Open
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
2 changes: 1 addition & 1 deletion tests/run-tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8c6903cd8c0fde910a37f88322edcfb5dd907a8 # v4
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
10 changes: 6 additions & 4 deletions tests/tests-ci.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@ jobs:
python-version: ["3.9", "3.10", "3.11"]

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v7
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
Expand All @@ -74,10 +74,12 @@ jobs:
run: pip list
- name: Run tests with pytest & nox
run: |
nox -s tests-${{ matrix.python-version }}
nox -s test-${{ matrix.python-version }}
# You only need to upload code coverage once to codecov unless you have a
# more complex build that you need coverage for.
- name: Upload coverage to Codecov
if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10'}}
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v7
with:
token: ${{ secrets.CODECOV_TOKEN }}
```
18 changes: 9 additions & 9 deletions tutorials/trusted-publishing.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,19 +109,19 @@ jobs:
name: Build the package
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v7
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: "3.12" # Select the version that you want to build your package on
uses: actions/setup-python@v7
with:
python-version: "3.12" # Select the version that you want to build your package on
- name: Upgrade pip, install Hatch, and check Hatch version
run: |
pip install --upgrade pip
pip install --upgrade hatch
hatch --version # Verify that Hatch is installed
run: |
pip install --upgrade pip
pip install --upgrade hatch
hatch --version # Verify that Hatch is installed
```

Notice that above, you provide a version for each action step. `action/checkout@v5` tells GitHub to use version 5 of the checkout action. The checkout action checks out the code from your repository. In this case, the code will be used to build your package.
Notice that above, you provide a version for each action step. `actions/checkout@v7` tells GitHub to use version 7 of the checkout action. The checkout action checks out the code from your repository. In this case, the code will be used to build your package.

Next, you will learn about a better way to secure (or "harden") your workflow

Expand Down
Loading