From 52141e3221a7c972d0db32470e1a5e511db29b8c Mon Sep 17 00:00:00 2001 From: Kyle Date: Mon, 27 Jul 2026 03:42:57 +0800 Subject: [PATCH] Revert "Enable Tuist caching and build insights in CI (#230)" This reverts commit eb494fb9ce31e78e7e0220e7b30793d809e13450. --- .github/workflows/compatibility_tests.yml | 27 ++-------------- .github/workflows/compute.yml | 27 ++-------------- .github/workflows/ios.yml | 39 +++-------------------- .github/workflows/release.yml | 21 ++---------- .github/workflows/xcframework.yml | 15 --------- Example/Project.swift | 5 +-- Example/Tuist.swift | 10 +----- Example/Tuist/Package.resolved | 15 +++++++++ Example/Tuist/Package.swift | 5 ++- Example/mise.toml | 2 +- Scripts/build_xcframework.sh | 17 ++-------- Tuist.swift | 5 --- mise.toml | 2 +- 13 files changed, 37 insertions(+), 153 deletions(-) create mode 100644 Example/Tuist/Package.resolved diff --git a/.github/workflows/compatibility_tests.yml b/.github/workflows/compatibility_tests.yml index 9f5422f4..ce12df1c 100644 --- a/.github/workflows/compatibility_tests.yml +++ b/.github/workflows/compatibility_tests.yml @@ -9,9 +9,6 @@ on: jobs: compatibility_tests_macos: name: Execute compatibility tests - permissions: - contents: read - id-token: write strategy: fail-fast: false matrix: @@ -34,18 +31,6 @@ jobs: uses: OpenSwiftUIProject/setup-xcode@v2 with: xcode-version: ${{ matrix.xcode-version }} - - name: Set up mise - uses: jdx/mise-action@v2 - with: - install: false - cache: false - - name: Set up Tuist cache - run: | - mise trust mise.toml - mise install - mise exec -- tuist auth login - mise exec -- tuist setup cache - shell: bash - name: Set up build environment run: Scripts/CI/darwin_setup_build.sh shell: bash @@ -57,18 +42,10 @@ jobs: --build-path .build-compatibility-test-debug - name: Run tests against Apple's AttributeGraph on macOS via Xcode run: | - result_bundle="${RUNNER_TEMP:-/tmp}/openattributegraph-compatibility-macos-${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT:-0}.xcresult" - rm -rf "$result_bundle" - trap 'rm -rf "$result_bundle"' EXIT - mise exec -- tuist xcodebuild test \ + xcodebuild test \ -workspace .swiftpm/xcode/package.xcworkspace \ -scheme OpenAttributeGraph-Package \ -sdk macosx \ -destination "platform=macOS" \ - -resultBundlePath "$result_bundle" \ -skipPackagePluginValidation \ - -skipMacroValidation \ - COMPILATION_CACHE_ENABLE_CACHING=YES \ - COMPILATION_CACHE_REMOTE_SERVICE_PATH="$HOME/.local/state/tuist/OpenSwiftUIProject_openattributegraph.sock" \ - COMPILATION_CACHE_ENABLE_PLUGIN=YES \ - COMPILATION_CACHE_ENABLE_DIAGNOSTIC_REMARKS=YES + -skipMacroValidation diff --git a/.github/workflows/compute.yml b/.github/workflows/compute.yml index 91dcefc7..239f5eff 100644 --- a/.github/workflows/compute.yml +++ b/.github/workflows/compute.yml @@ -57,9 +57,6 @@ jobs: compute_ios_build: name: Build with Compute (binary) on iOS - permissions: - contents: read - id-token: write strategy: fail-fast: false matrix: @@ -82,34 +79,14 @@ jobs: uses: OpenSwiftUIProject/setup-xcode@v2 with: xcode-version: ${{ matrix.xcode-version }} - - name: Set up mise - uses: jdx/mise-action@v2 - with: - install: false - cache: false - - name: Set up Tuist cache - run: | - mise trust mise.toml - mise install - mise exec -- tuist auth login - mise exec -- tuist setup cache - shell: bash - name: Build in debug mode on iOS Simulator run: | - result_bundle="${RUNNER_TEMP:-/tmp}/openattributegraph-compute-ios-${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT:-0}.xcresult" - rm -rf "$result_bundle" - trap 'rm -rf "$result_bundle"' EXIT - mise exec -- tuist xcodebuild build \ + xcodebuild build \ -workspace .swiftpm/xcode/package.xcworkspace \ -scheme OpenAttributeGraph \ -configuration Debug \ -destination "platform=iOS Simulator,OS=${{ matrix.ios-version }},name=${{ matrix.ios-simulator-name }}" \ -derivedDataPath .build-debug \ - -resultBundlePath "$result_bundle" \ -skipMacroValidation \ -skipPackagePluginValidation \ - OTHER_SWIFT_FLAGS="-warnings-as-errors" \ - COMPILATION_CACHE_ENABLE_CACHING=YES \ - COMPILATION_CACHE_REMOTE_SERVICE_PATH="$HOME/.local/state/tuist/OpenSwiftUIProject_openattributegraph.sock" \ - COMPILATION_CACHE_ENABLE_PLUGIN=YES \ - COMPILATION_CACHE_ENABLE_DIAGNOSTIC_REMARKS=YES + OTHER_SWIFT_FLAGS="-warnings-as-errors" diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index ecec55eb..90b4f500 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -9,9 +9,6 @@ on: jobs: ios_test: name: Execute tests on iOS - permissions: - contents: read - id-token: write strategy: fail-fast: false matrix: @@ -36,63 +33,35 @@ jobs: uses: OpenSwiftUIProject/setup-xcode@v2 with: xcode-version: ${{ matrix.xcode-version }} - - name: Set up mise - uses: jdx/mise-action@v2 - with: - install: false - cache: false - - name: Set up Tuist cache - run: | - mise trust mise.toml - mise install - mise exec -- tuist auth login - mise exec -- tuist setup cache - shell: bash - name: Set up build environment run: Scripts/CI/darwin_setup_build.sh shell: bash - name: Build in debug mode on iOS run: | - result_bundle="${RUNNER_TEMP:-/tmp}/openattributegraph-ios-build-${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT:-0}.xcresult" - rm -rf "$result_bundle" - trap 'rm -rf "$result_bundle"' EXIT # Swift 6.2.4 crashes while indexing C++ interop test targets. - mise exec -- tuist xcodebuild build \ + xcodebuild build \ -workspace .swiftpm/xcode/package.xcworkspace \ -scheme OpenAttributeGraph-Package \ -configuration Debug \ -destination "platform=iOS Simulator,OS=${{ matrix.ios-version }},name=${{ matrix.ios-simulator-name }}" \ -derivedDataPath .build-debug \ - -resultBundlePath "$result_bundle" \ -skipMacroValidation \ -skipPackagePluginValidation \ COMPILER_INDEX_STORE_ENABLE=NO \ - OTHER_SWIFT_FLAGS="-warnings-as-errors" \ - COMPILATION_CACHE_ENABLE_CACHING=YES \ - COMPILATION_CACHE_REMOTE_SERVICE_PATH="$HOME/.local/state/tuist/OpenSwiftUIProject_openattributegraph.sock" \ - COMPILATION_CACHE_ENABLE_PLUGIN=YES \ - COMPILATION_CACHE_ENABLE_DIAGNOSTIC_REMARKS=YES + OTHER_SWIFT_FLAGS="-warnings-as-errors" - name: Build and run tests in debug mode with coverage on iOS Simulator run: | - result_bundle="${RUNNER_TEMP:-/tmp}/openattributegraph-ios-test-${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT:-0}.xcresult" - rm -rf "$result_bundle" - trap 'rm -rf "$result_bundle"' EXIT # Swift 6.2.4 crashes while indexing C++ interop test targets. - mise exec -- tuist xcodebuild test \ + xcodebuild test \ -workspace .swiftpm/xcode/package.xcworkspace \ -scheme OpenAttributeGraph-Package \ -configuration Debug \ -destination "platform=iOS Simulator,OS=${{ matrix.ios-version }},name=${{ matrix.ios-simulator-name }}" \ -enableCodeCoverage=YES \ -derivedDataPath .build-test-debug \ - -resultBundlePath "$result_bundle" \ -skipPackagePluginValidation \ -skipMacroValidation \ - COMPILER_INDEX_STORE_ENABLE=NO \ - COMPILATION_CACHE_ENABLE_CACHING=YES \ - COMPILATION_CACHE_REMOTE_SERVICE_PATH="$HOME/.local/state/tuist/OpenSwiftUIProject_openattributegraph.sock" \ - COMPILATION_CACHE_ENABLE_PLUGIN=YES \ - COMPILATION_CACHE_ENABLE_DIAGNOSTIC_REMARKS=YES + COMPILER_INDEX_STORE_ENABLE=NO # OTHER_SWIFT_FLAGS="-warnings-as-errors" Conflicting options '-warnings-as-errors' and '-suppress-warnings' - name: Generate iOS coverage report run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index dcf2a105..44a2a8c4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -11,7 +11,6 @@ jobs: runs-on: macos-15 permissions: contents: write - id-token: write env: GH_TOKEN: ${{ github.token }} steps: @@ -23,31 +22,17 @@ jobs: uses: OpenSwiftUIProject/setup-xcode@v2 with: xcode-version: "26.3" - - name: Set up mise - uses: jdx/mise-action@v2 - with: - install: false - cache: false - - name: Set up Tuist cache - run: | - mise trust mise.toml - mise install - mise exec -- tuist auth login - mise exec -- tuist setup cache - shell: bash - name: Build XCFramework run: ./Scripts/build_xcframework.sh - name: Compute Checksum id: checksum run: | - echo "checksum=$(swift package compute-checksum .build/Xcode/Frameworks/OpenAttributeGraph.xcframework.zip)" >> "$GITHUB_OUTPUT" + echo "checksum=$(swift package compute-checksum .build/Xcode/Frameworks/OpenAttributeGraph.xcframework.zip)" >> $GITHUB_OUTPUT - name: Collect Build Info id: build_info run: | - { - echo "xcode_version=$(xcodebuild -version | head -1)" - echo "swift_version=$(swift --version 2>&1 | head -1)" - } >> "$GITHUB_OUTPUT" + echo "xcode_version=$(xcodebuild -version | head -1)" >> $GITHUB_OUTPUT + echo "swift_version=$(swift --version 2>&1 | head -1)" >> $GITHUB_OUTPUT - name: Generate Release Notes run: | TAG_NAME="${GITHUB_REF#refs/tags/}" diff --git a/.github/workflows/xcframework.yml b/.github/workflows/xcframework.yml index 08f4e4fa..f80aee33 100644 --- a/.github/workflows/xcframework.yml +++ b/.github/workflows/xcframework.yml @@ -9,9 +9,6 @@ on: jobs: build_xcframework: name: Build XCFramework - permissions: - contents: read - id-token: write strategy: fail-fast: false matrix: @@ -28,18 +25,6 @@ jobs: uses: OpenSwiftUIProject/setup-xcode@v2 with: xcode-version: ${{ matrix.xcode-version }} - - name: Set up mise - uses: jdx/mise-action@v2 - with: - install: false - cache: false - - name: Set up Tuist cache - run: | - mise trust mise.toml - mise install - mise exec -- tuist auth login - mise exec -- tuist setup cache - shell: bash - name: Build XCFramework run: ./Scripts/build_xcframework.sh - name: Upload XCFramework diff --git a/Example/Project.swift b/Example/Project.swift index c5c70612..5c3aec6e 100644 --- a/Example/Project.swift +++ b/Example/Project.swift @@ -7,9 +7,6 @@ let indexStoreDisabledSettings: SettingsDictionary = [ let project = Project( name: "Example", - packages: [ - .package(path: ".."), - ], settings: .settings(base: indexStoreDisabledSettings), targets: [ .target( @@ -21,7 +18,7 @@ let project = Project( sources: ["Sources/**"], dependencies: [ .sdk(name: "c++", type: .library), - .package(product: "OpenAttributeGraph"), + .external(name: "OpenAttributeGraph"), ], settings: .settings(base: indexStoreDisabledSettings) ), diff --git a/Example/Tuist.swift b/Example/Tuist.swift index 7e779ccc..abf9ffd0 100644 --- a/Example/Tuist.swift +++ b/Example/Tuist.swift @@ -1,13 +1,5 @@ import ProjectDescription let tuist = Tuist( - fullHandle: "OpenSwiftUIProject/openattributegraph", - xcodeCache: .xcodeCache( - upload: Environment.isCI - ), - project: .tuist( - generationOptions: .options( - enableCaching: true - ) - ) + project: .tuist() ) diff --git a/Example/Tuist/Package.resolved b/Example/Tuist/Package.resolved new file mode 100644 index 00000000..e8cf1f64 --- /dev/null +++ b/Example/Tuist/Package.resolved @@ -0,0 +1,15 @@ +{ + "originHash" : "b4d69cd3c6294a612f2691e0c9ace37d5e8c8904296914f23e337abb762050c2", + "pins" : [ + { + "identity" : "swift-numerics", + "kind" : "remoteSourceControl", + "location" : "https://github.com/apple/swift-numerics", + "state" : { + "revision" : "0c0290ff6b24942dadb83a929ffaaa1481df04a2", + "version" : "1.1.1" + } + } + ], + "version" : 3 +} diff --git a/Example/Tuist/Package.swift b/Example/Tuist/Package.swift index e18a677e..9384c666 100644 --- a/Example/Tuist/Package.swift +++ b/Example/Tuist/Package.swift @@ -17,5 +17,8 @@ let packageSettings = PackageSettings( let package = Package( name: "ExampleDependencies", - dependencies: [] + dependencies: [ + .package(path: "../../"), + .package(url: "https://github.com/apple/swift-numerics", from: "1.1.1"), + ] ) diff --git a/Example/mise.toml b/Example/mise.toml index cc14d054..9d16c181 100644 --- a/Example/mise.toml +++ b/Example/mise.toml @@ -1,2 +1,2 @@ [tools] -tuist = "4.203.0-rc.1" +tuist = "4.193.0" diff --git a/Scripts/build_xcframework.sh b/Scripts/build_xcframework.sh index 385f7b8d..603ded86 100755 --- a/Scripts/build_xcframework.sh +++ b/Scripts/build_xcframework.sh @@ -42,36 +42,25 @@ done echo "Building xcframework for $SCHEME (debug info: $DEBUG_INFO)" # Archive for each platform using the Tuist-generated xcodeproj -rm -rf \ - "$BUILD_DIR/Archives/$SCHEME-macOS.xcarchive" \ - "$BUILD_DIR/Archives/$SCHEME-macOS.xcresult" \ - "$BUILD_DIR/Archives/$SCHEME-iOS.xcarchive" \ - "$BUILD_DIR/Archives/$SCHEME-iOS.xcresult" \ - "$BUILD_DIR/Archives/$SCHEME-iOS-Simulator.xcarchive" \ - "$BUILD_DIR/Archives/$SCHEME-iOS-Simulator.xcresult" - -tuist xcodebuild archive \ +xcodebuild archive \ -project "$XCODEPROJ" \ -scheme "$SCHEME" \ -destination "generic/platform=macOS" \ -archivePath "$BUILD_DIR/Archives/$SCHEME-macOS.xcarchive" \ - -resultBundlePath "$BUILD_DIR/Archives/$SCHEME-macOS.xcresult" \ ENABLE_USER_SCRIPT_SANDBOXING=NO -tuist xcodebuild archive \ +xcodebuild archive \ -project "$XCODEPROJ" \ -scheme "$SCHEME" \ -destination "generic/platform=iOS" \ -archivePath "$BUILD_DIR/Archives/$SCHEME-iOS.xcarchive" \ - -resultBundlePath "$BUILD_DIR/Archives/$SCHEME-iOS.xcresult" \ ENABLE_USER_SCRIPT_SANDBOXING=NO -tuist xcodebuild archive \ +xcodebuild archive \ -project "$XCODEPROJ" \ -scheme "$SCHEME" \ -destination "generic/platform=iOS Simulator" \ -archivePath "$BUILD_DIR/Archives/$SCHEME-iOS-Simulator.xcarchive" \ - -resultBundlePath "$BUILD_DIR/Archives/$SCHEME-iOS-Simulator.xcresult" \ ENABLE_USER_SCRIPT_SANDBOXING=NO echo "Archives completed successfully." diff --git a/Tuist.swift b/Tuist.swift index 191f66bd..a1d52306 100644 --- a/Tuist.swift +++ b/Tuist.swift @@ -1,13 +1,8 @@ import ProjectDescription let tuist = Tuist( - fullHandle: "OpenSwiftUIProject/openattributegraph", - xcodeCache: .xcodeCache( - upload: Environment.isCI - ), project: .tuist( generationOptions: .options( - enableCaching: true, manifestEnvironment: [ "OPENSWIFTUI_*", "OPENATTRIBUTEGRAPH_*", diff --git a/mise.toml b/mise.toml index cc14d054..82eb7c50 100644 --- a/mise.toml +++ b/mise.toml @@ -1,2 +1,2 @@ [tools] -tuist = "4.203.0-rc.1" +tuist = "4.156.0"