diff --git a/.github/actions/xcode-cache/action.yml b/.github/actions/xcode-cache/action.yml index 4674a3ffc..ce9b997ab 100644 --- a/.github/actions/xcode-cache/action.yml +++ b/.github/actions/xcode-cache/action.yml @@ -5,6 +5,10 @@ runs: steps: - run: echo "IMAGE=${ImageOS}-${ImageVersion}" >> $GITHUB_ENV shell: bash - - uses: mikehardy/buildcache-action@v2 + - name: Cache SPM + uses: actions/cache@v4 + id: spm-cache with: - cache_key: ${{ env.IMAGE }}-buildcache- + path: spm_cache + key: ${{ env.IMAGE }}-spm-${{ hashFiles('**/Package.resolved') }} + restore-keys: ${{ env.IMAGE }}-spm- diff --git a/.github/workflows/cron-checks.yml b/.github/workflows/cron-checks.yml index 8c3cb97f6..aba1be009 100644 --- a/.github/workflows/cron-checks.yml +++ b/.github/workflows/cron-checks.yml @@ -21,28 +21,25 @@ jobs: strategy: matrix: include: - # - ios: "26.0" TODO: IOS-1181 + # - ios: "26.1" # TODO: IOS-1181 # device: "iPhone 17 Pro" - # xcode: "26.0.1" # setup_runtime: false - ios: "18.5" device: "iPhone 16 Pro" - xcode: "26.0.1" setup_runtime: false - ios: "17.5" device: "iPhone 15 Pro" - xcode: "26.0.1" setup_runtime: true - ios: "16.4" device: "iPhone 14 Pro" - xcode: "16.4" setup_runtime: true fail-fast: false runs-on: macos-15 env: GITHUB_EVENT: ${{ toJson(github.event) }} ALLURE_TOKEN: ${{ secrets.ALLURE_TOKEN }} - XCODE_VERSION: ${{ matrix.xcode }} + XCODE_VERSION: "26.1.1" + IOS_SIMULATOR_DEVICE: "${{ matrix.device }} (${{ matrix.ios }})" steps: - uses: actions/checkout@v4.1.1 - uses: ./.github/actions/bootstrap @@ -63,7 +60,7 @@ jobs: - name: Launch Allure TestOps run: bundle exec fastlane allure_launch cron:true - name: Run UI Tests (Debug) - run: bundle exec fastlane test_e2e_mock device:"${{ matrix.device }} (${{ matrix.ios }})" + run: bundle exec fastlane test_e2e_mock device:"${{ env.IOS_SIMULATOR_DEVICE }}" timeout-minutes: 90 - name: Allure TestOps Upload if: success() || failure() @@ -92,7 +89,7 @@ jobs: strategy: matrix: include: - - xcode: 26.0.1 # swift 6.2 + - xcode: 26.1.1 # swift 6.2 os: macos-15 - xcode: 16.4 # swift 6.1 os: macos-15 diff --git a/.github/workflows/smoke-checks.yml b/.github/workflows/smoke-checks.yml index 1181519d8..97e8a3f03 100644 --- a/.github/workflows/smoke-checks.yml +++ b/.github/workflows/smoke-checks.yml @@ -20,7 +20,7 @@ concurrency: env: HOMEBREW_NO_INSTALL_CLEANUP: 1 # Disable cleanup for homebrew, we don't need it on CI - IOS_SIMULATOR_DEVICE: "iPhone 16 Pro (18.5)" + IOS_SIMULATOR_DEVICE: "iPhone 17 Pro (26.1)" GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_PR_NUM: ${{ github.event.pull_request.number }} @@ -92,8 +92,6 @@ jobs: runs-on: macos-15 env: GITHUB_TOKEN: ${{ secrets.CI_BOT_GITHUB_TOKEN }} # to open a PR - IOS_SIMULATOR_DEVICE: "iPhone 16 Pro (18.5)" # TODO: IOS-1181 - XCODE_VERSION: "16.4" # TODO: IOS-1181 steps: - uses: actions/checkout@v4.1.1 - uses: ./.github/actions/bootstrap @@ -160,7 +158,6 @@ jobs: env: LAUNCH_ID: ${{ needs.allure_testops_launch.outputs.launch_id }} IOS_SIMULATOR_DEVICE: "iPhone 16 Pro (18.5)" # TODO: IOS-1181 - XCODE_VERSION: "16.4" # TODO: IOS-1181 strategy: matrix: batch: [0, 1] diff --git a/.swiftformat b/.swiftformat index d07296f9a..77d3b2f9a 100644 --- a/.swiftformat +++ b/.swiftformat @@ -1,6 +1,6 @@ # Stream rules --header "\nCopyright © {year} Stream.io Inc. All rights reserved.\n" ---swiftversion 5.9 +--swiftversion 5.10 # Use allow-list --rules blankLinesAroundMark diff --git a/Package.swift b/Package.swift index 4a99f7601..f2961c098 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.9 +// swift-tools-version:5.10 import Foundation import PackageDescription diff --git a/Scripts/bootstrap.sh b/Scripts/bootstrap.sh index 175b32467..c74679e36 100755 --- a/Scripts/bootstrap.sh +++ b/Scripts/bootstrap.sh @@ -30,7 +30,7 @@ if [ "${SKIP_SWIFT_BOOTSTRAP:-}" != true ]; then puts "Install SwiftLint v${SWIFT_LINT_VERSION}" DOWNLOAD_URL="https://github.com/realm/SwiftLint/releases/download/${SWIFT_LINT_VERSION}/SwiftLint.pkg" DOWNLOAD_PATH="/tmp/SwiftLint-${SWIFT_LINT_VERSION}.pkg" - curl -sL "$DOWNLOAD_URL" -o "$DOWNLOAD_PATH" + wget "$DOWNLOAD_URL" -O "$DOWNLOAD_PATH" sudo installer -pkg "$DOWNLOAD_PATH" -target / swiftlint version @@ -39,7 +39,7 @@ if [ "${SKIP_SWIFT_BOOTSTRAP:-}" != true ]; then DOWNLOAD_PATH="/tmp/swiftformat-${SWIFT_FORMAT_VERSION}.zip" BIN_PATH="/usr/local/bin/swiftformat" brew uninstall swiftformat || true - curl -sL "$DOWNLOAD_URL" -o "$DOWNLOAD_PATH" + wget "$DOWNLOAD_URL" -O "$DOWNLOAD_PATH" unzip -o "$DOWNLOAD_PATH" -d /tmp/swiftformat-${SWIFT_FORMAT_VERSION} sudo mv /tmp/swiftformat-${SWIFT_FORMAT_VERSION}/swiftformat "$BIN_PATH" sudo chmod +x "$BIN_PATH" @@ -50,7 +50,7 @@ if [ "${SKIP_SWIFT_BOOTSTRAP:-}" != true ]; then DOWNLOAD_PATH="/tmp/swiftgen-${SWIFT_GEN_VERSION}.zip" INSTALL_DIR="/usr/local/lib/swiftgen" BIN_PATH="/usr/local/bin/swiftgen" - curl -sL "$DOWNLOAD_URL" -o "$DOWNLOAD_PATH" + wget "$DOWNLOAD_URL" -O "$DOWNLOAD_PATH" sudo rm -rf "$INSTALL_DIR" sudo mkdir -p "$INSTALL_DIR" sudo unzip -o "$DOWNLOAD_PATH" -d "$INSTALL_DIR" @@ -62,7 +62,7 @@ fi if [[ ${INSTALL_SONAR-default} == true ]]; then puts "Install sonar scanner v${SONAR_VERSION}" DOWNLOAD_URL="https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${SONAR_VERSION}-macosx-x64.zip" - curl -sL "${DOWNLOAD_URL}" -o ./fastlane/sonar.zip + wget "${DOWNLOAD_URL}" -O ./fastlane/sonar.zip cd fastlane unzip sonar.zip rm sonar.zip @@ -74,12 +74,12 @@ fi if [[ ${INSTALL_ALLURE-default} == true ]]; then puts "Install allurectl v${ALLURECTL_VERSION}" DOWNLOAD_URL="https://github.com/allure-framework/allurectl/releases/download/${ALLURECTL_VERSION}/allurectl_darwin_amd64" - curl -sL "${DOWNLOAD_URL}" -o ./fastlane/allurectl + wget "${DOWNLOAD_URL}" -O ./fastlane/allurectl chmod +x ./fastlane/allurectl puts "Install xcresults v${XCRESULTS_VERSION}" DOWNLOAD_URL="https://github.com/eroshenkoam/xcresults/releases/download/${XCRESULTS_VERSION}/xcresults" - curl -sL "${DOWNLOAD_URL}" -o ./fastlane/xcresults + wget "${DOWNLOAD_URL}" -O ./fastlane/xcresults chmod +x ./fastlane/xcresults fi diff --git a/StreamChatSwiftUI-XCFramework.podspec b/StreamChatSwiftUI-XCFramework.podspec index 7fa4c1417..fd5b2bbbe 100644 --- a/StreamChatSwiftUI-XCFramework.podspec +++ b/StreamChatSwiftUI-XCFramework.podspec @@ -8,7 +8,7 @@ Pod::Spec.new do |spec| spec.license = { type: 'BSD-3', file: 'LICENSE' } spec.author = { 'getstream.io' => 'support@getstream.io' } spec.social_media_url = 'https://getstream.io' - spec.swift_version = '5.9' + spec.swift_version = '5.10' spec.platform = :ios, '14.0' spec.requires_arc = true diff --git a/StreamChatSwiftUI.podspec b/StreamChatSwiftUI.podspec index 8c410f611..5e0a034bd 100644 --- a/StreamChatSwiftUI.podspec +++ b/StreamChatSwiftUI.podspec @@ -8,7 +8,7 @@ Pod::Spec.new do |spec| spec.license = { type: 'BSD-3', file: 'LICENSE' } spec.author = { 'getstream.io' => 'support@getstream.io' } spec.social_media_url = 'https://getstream.io' - spec.swift_version = '5.9' + spec.swift_version = '5.10' spec.platform = :ios, '14.0' spec.source = { git: 'https://github.com/GetStream/stream-chat-swiftui.git', tag: spec.version } spec.requires_arc = true diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 5866b6bd5..4dbe78002 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -8,13 +8,12 @@ require 'xcodeproj' import 'Sonarfile' import 'Allurefile' -xcode_version = ENV['XCODE_VERSION'] || '16.4' +xcode_version = ENV['XCODE_VERSION'] || '26.1.1' xcode_project = 'StreamChatSwiftUI.xcodeproj' sdk_names = ['StreamChatSwiftUI'] github_repo = ENV['GITHUB_REPOSITORY'] || 'GetStream/stream-chat-swiftui' derived_data_path = 'derived_data' source_packages_path = 'spm_cache' -buildcache_xcargs = 'CC=clang CPLUSPLUS=clang++ LD=clang LDPLUSPLUS=clang++' is_localhost = !is_ci project_package_resolved = "#{xcode_project}/project.xcworkspace/xcshareddata/swiftpm/Package.resolved" swift_environment_path = File.absolute_path('../Sources/StreamChatSwiftUI/Generated/SystemEnvironment+Version.swift') @@ -262,7 +261,6 @@ lane :test_ui do |options| build_for_testing: options[:build_for_testing], skip_build: options[:skip_build], number_of_retries: options[:record].to_s.empty? ? 1 : nil, - xcargs: buildcache_xcargs, fail_build: !record_mode ) @@ -295,8 +293,7 @@ lane :build_test_app_and_frameworks do derived_data_path: derived_data_path, cloned_source_packages_path: source_packages_path, clean: is_localhost, - build_for_testing: true, - xcargs: buildcache_xcargs + build_for_testing: true ) end @@ -325,7 +322,6 @@ lane :test_e2e_mock do |options| cloned_source_packages_path: source_packages_path, clean: is_localhost, test_without_building: options[:test_without_building], - xcargs: buildcache_xcargs, devices: options[:device], prelaunch_simulator: is_ci, number_of_retries: 3 @@ -385,8 +381,7 @@ lane :build_demo do |options| derived_data_path: derived_data_path, cloned_source_packages_path: source_packages_path, build_for_testing: true, - devices: options[:device], - xcargs: buildcache_xcargs + devices: options[:device] ) end