Use Anthropic ratelimit headers as primary Claude scrape (Clawdmeter method) #104
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: iOS CI | |
| "on": | |
| push: | |
| branches: | |
| - main | |
| - tidy/deps-format | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| build-and-test: | |
| runs-on: macos-15 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install XcodeGen | |
| run: brew install xcodegen | |
| - name: Generate Xcode project | |
| working-directory: ios/CodexMeterApp | |
| run: xcodegen generate | |
| - name: Show Xcode version | |
| run: xcodebuild -version | |
| - name: Run app tests | |
| working-directory: ios/CodexMeterApp | |
| run: | | |
| SIMULATOR_ID="$(xcrun simctl list devices available -j | python3 -c 'import json, sys | |
| devices = json.load(sys.stdin).get("devices", {}) | |
| iphones = [ | |
| device | |
| for runtime_devices in devices.values() | |
| for device in runtime_devices | |
| if device.get("isAvailable") and device.get("name", "").startswith("iPhone") | |
| ] | |
| if iphones: | |
| print(iphones[0]["udid"]) | |
| ')" | |
| if [ -z "$SIMULATOR_ID" ]; then | |
| echo "No available iPhone simulator found" | |
| xcrun simctl list devices available | |
| exit 1 | |
| fi | |
| echo "Using simulator $SIMULATOR_ID" | |
| xcodebuild \ | |
| -project CodexMeterApp.xcodeproj \ | |
| -scheme CodexMeterApp \ | |
| -destination "platform=iOS Simulator,id=$SIMULATOR_ID" \ | |
| test | |
| - name: Build widget extension | |
| working-directory: ios/CodexMeterApp | |
| run: | | |
| xcodebuild \ | |
| -project CodexMeterApp.xcodeproj \ | |
| -target CodexMeterAppWidget \ | |
| -sdk iphonesimulator \ | |
| -configuration Debug \ | |
| CODE_SIGNING_ALLOWED=NO \ | |
| build |