Skip to content

Commit 6357572

Browse files
committed
try manually...
1 parent feb0372 commit 6357572

File tree

3 files changed

+26
-7
lines changed

3 files changed

+26
-7
lines changed

.github/scripts/install_swiftly.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ else
4242
curl -O https://download.swift.org/swiftly/darwin/swiftly.pkg && pkgutil --check-signature swiftly.pkg && pkgutil --verbose --expand swiftly.pkg "${SWIFTLY_HOME_DIR}" && tar -C "${SWIFTLY_HOME_DIR}" -xvf "${SWIFTLY_HOME_DIR}"/swiftly-*/Payload && "$SWIFTLY_HOME_DIR/bin/swiftly" init -y --skip-install
4343

4444
# shellcheck disable=SC1091
45+
chmod +x "$SWIFTLY_HOME_DIR/env.sh"
4546
. "$SWIFTLY_HOME_DIR/env.sh"
4647
fi
4748

@@ -84,5 +85,8 @@ echo "Displaying swift version"
8485
swiftly run "${runSelector[@]}" swift --version
8586

8687
if [[ "$(uname -s)" == "Linux" ]]; then
87-
CC=clang swiftly run "${runSelector[@]}" "$(dirname "$0")/install-libarchive.sh"
88+
if [[ -f "$(dirname "$0")/install-libarchive.sh" ]]; then
89+
CC=clang swiftly run "${runSelector[@]}" "$(dirname "$0")/install-libarchive.sh"
90+
fi
8891
fi
92+

.github/scripts/validate_docs.sh

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/bin/bash
2+
3+
set -e
4+
set -x
5+
6+
cat <<EOF >> Package.swift
7+
8+
package.dependencies.append(
9+
.package(url: "https://github.com/swiftlang/swift-docc-plugin", from: "1.0.0")
10+
)
11+
EOF
12+
13+
echo "Active Swift:"
14+
which swift
15+
swift -version
16+
17+
swift package plugin generate-documentation --target "SwiftJavaDocumentation" --warnings-as-errors --analyze

.github/workflows/pull_request.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,21 +26,19 @@ jobs:
2626
fail-fast: true
2727
matrix:
2828
swift_version: ['6.1.2']
29+
os_version: ['jammy']
2930
jdk_vendor: ['corretto']
3031
env:
3132
ADDITIONAL_DOCC_ARGUMENTS: ''
3233
steps:
3334
- uses: actions/checkout@v4
3435
- name: Prepare CI Environment
3536
uses: ./.github/actions/prepare_env
36-
- name: Install Swiftly
37+
- name: Install Swiftly / Swift ${{ matrix.swift_version }}
38+
shell: bash
3739
run: ./.github/scripts/install_swiftly.sh
38-
env:
39-
SWIFT_VERSION: "${{ matrix.swift_version }}"
4040
- name: Run documentation check
41-
run: |
42-
which curl || (apt -q update && apt -yq install curl)
43-
curl -s --retry 3 https://raw.githubusercontent.com/swiftlang/github-workflows/refs/heads/main/.github/workflows/scripts/check-docs.sh | bash
41+
run: ./github/scripts/validate_docs.sh
4442

4543
test-java:
4644
name: Test (Java) (${{ matrix.os_version }} swift:${{ matrix.swift_version }} jdk:${{matrix.jdk_vendor}})

0 commit comments

Comments
 (0)