Skip to content

Commit ad43b7f

Browse files
authored
Debug print token in CI (#213)
* [don't merge] verify token in CI * secrets: inherit * Update .github/workflows/unit-tests.yml * Only print when CI_DISABLE_NETWORK_MONITOR is 1
1 parent ed54f3c commit ad43b7f

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Sources/Hub/HubApi.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,11 @@ public struct HubApi: Sendable {
7676
useOfflineMode: Bool? = nil
7777
) {
7878
self.hfToken = hfToken ?? Self.hfTokenFromEnv()
79+
80+
let debugPrint = ProcessInfo.processInfo.environment["CI_DISABLE_NETWORK_MONITOR"] == "1"
81+
if debugPrint {
82+
print(self.hfToken == nil ? "🔴 NO TOKEN **" : "✅ got token")
83+
}
7984
if let downloadBase {
8085
self.downloadBase = downloadBase
8186
} else {

0 commit comments

Comments
 (0)