Skip to content

Commit aea0d96

Browse files
2witstudiosclaude
andcommitted
fix: Resolve clippy collapsible_if and surface archive errors in CI
- Collapse nested if in normalize_worktree_name (clippy::collapsible_if) - Add set -o pipefail to archive/export steps so xcodebuild failures propagate through xcbeautify pipe - Add ls check after archive to verify xcarchive was created Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent ced2634 commit aea0d96

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ jobs:
6969

7070
- name: Archive
7171
run: |
72+
set -o pipefail
7273
xcodebuild archive \
7374
-project apps/purepoint-macos/purepoint-macos.xcodeproj \
7475
-scheme purepoint-macos \
@@ -79,10 +80,12 @@ jobs:
7980
DEVELOPMENT_TEAM="${{ secrets.APPLE_TEAM_ID }}" \
8081
MARKETING_VERSION="${{ steps.version.outputs.marketing }}" \
8182
CURRENT_PROJECT_VERSION="${{ steps.version.outputs.build }}" \
82-
2>&1 | xcbeautify
83+
2>&1 | xcbeautify --report junit --report-path build/archive-report.xml
84+
ls -la build/PurePoint.xcarchive
8385
8486
- name: Export archive
8587
run: |
88+
set -o pipefail
8689
xcodebuild -exportArchive \
8790
-archivePath build/PurePoint.xcarchive \
8891
-exportPath build/export \

crates/pu-core/src/id.rs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,9 @@ pub fn normalize_worktree_name(input: &str) -> String {
7878
if ch.is_ascii_alphanumeric() {
7979
result.push(ch);
8080
prev_hyphen = false;
81-
} else if ch.is_whitespace() || ch == '_' || ch == '-' {
82-
if !prev_hyphen {
83-
result.push('-');
84-
prev_hyphen = true;
85-
}
81+
} else if (ch.is_whitespace() || ch == '_' || ch == '-') && !prev_hyphen {
82+
result.push('-');
83+
prev_hyphen = true;
8684
}
8785
// else: strip
8886
}

0 commit comments

Comments
 (0)