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

Only run checkout if not running locally with act, and update to latest merge ref #61

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
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
18 changes: 18 additions & 0 deletions .github/workflows/soundness.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,12 @@ jobs:
timeout-minutes: 20
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Mark the workspace as safe
# https://github.com/actions/checkout/issues/766
run: git config --global --add safe.directory ${GITHUB_WORKSPACE}
Expand All @@ -100,10 +102,12 @@ jobs:
timeout-minutes: 20
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Run documentation check
run: |
apt-get -qq update && apt-get -qq -y install curl yq
Expand All @@ -116,10 +120,12 @@ jobs:
timeout-minutes: 1
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Run unacceptable language check
env:
UNACCEPTABLE_WORD_LIST: ${{ inputs.unacceptable_language_check_word_list}}
Expand All @@ -132,10 +138,12 @@ jobs:
timeout-minutes: 1
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Run license header check
env:
PROJECT_NAME: ${{ inputs.license_header_check_project_name }}
Expand All @@ -148,10 +156,12 @@ jobs:
timeout-minutes: 1
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Run broken symlinks check
run: curl -s https://raw.githubusercontent.com/swiftlang/github-workflows/refs/heads/main/.github/workflows/scripts/check-broken-symlinks.sh | bash

Expand All @@ -164,10 +174,12 @@ jobs:
timeout-minutes: 20
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Mark the workspace as safe
# https://github.com/actions/checkout/issues/766
run: git config --global --add safe.directory ${GITHUB_WORKSPACE}
Expand All @@ -185,10 +197,12 @@ jobs:
timeout-minutes: 5
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Mark the workspace as safe
# https://github.com/actions/checkout/issues/766
run: git config --global --add safe.directory ${GITHUB_WORKSPACE}
Expand All @@ -204,10 +218,12 @@ jobs:
timeout-minutes: 5
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Run yamllint
run: |
which yamllint >/dev/null || ( apt-get update && apt-get install -y yamllint )
Expand All @@ -224,10 +240,12 @@ jobs:
timeout-minutes: 5
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Run flake8
run: |
pip3 install flake8 flake8-import-order
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/swift_package_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,10 @@ jobs:
- name: Swift version
run: swift --version
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Set environment variables
if: ${{ inputs.linux_env_vars }}
run: |
Expand All @@ -92,7 +95,10 @@ jobs:
- ${{ fromJson(inputs.windows_exclude_swift_versions) }}
steps:
- name: Checkout repository
if: env.ACT != 'true'
uses: actions/checkout@v4
with:
ref: ${{ github.ref }} # Include changes to the target branch when action is re-run https://github.com/actions/checkout/issues/1036
- name: Pull Docker image
id: pull_docker_image
run: |
Expand Down