@@ -20,25 +20,19 @@ import FirebaseManifest
20
20
import Utils
21
21
22
22
private enum Destination {
23
- case cpdc , trunk
23
+ case staging , trunk
24
24
}
25
25
26
26
enum Push {
27
- static func pushPodsToCPDC ( gitRoot: URL ) {
28
- push ( to: . cpdc , gitRoot: gitRoot)
27
+ static func pushPodsToStaging ( gitRoot: URL ) {
28
+ push ( to: . staging , gitRoot: gitRoot)
29
29
}
30
30
31
31
static func publishPodsToTrunk( gitRoot: URL ) {
32
32
push ( to: . trunk, gitRoot: gitRoot)
33
33
}
34
34
35
35
private static func push( to destination: Destination , gitRoot: URL ) {
36
- let cpdcRepo = " sso://cpdc-internal/firebase "
37
- let cpdcLocation = findOrRegisterPrivateCocoaPodsRepo (
38
- repo: cpdcRepo,
39
- gitRoot: gitRoot,
40
- defaultRepoName: " cpdc-internal-firebase "
41
- )
42
36
let stagingRepo = " [email protected] :firebase/SpecsStaging"
43
37
let stagingLocation = findOrRegisterPrivateCocoaPodsRepo (
44
38
repo: stagingRepo,
@@ -52,23 +46,14 @@ enum Push {
52
46
53
47
let command : String = {
54
48
switch destination {
55
- case . cpdc:
56
- var pushCommands = " "
57
- if pod. isClosedSource {
58
- // Push closed source pods to SpecsStaging to keep CI working.
59
- pushCommands =
60
- " pod repo push --skip-tests --use-json \( warningsOK) \( stagingLocation) " +
61
- pod. skipImportValidation ( ) + " \( pod. podspecName ( ) ) " +
62
- " --sources= \( stagingRepo) .git,https://cdn.cocoapods.org && "
63
- }
64
- pushCommands += " pod repo push --skip-tests --use-json \( warningsOK) \( cpdcLocation) " +
49
+ case . staging:
50
+ return " pod repo push --skip-tests --use-json \( warningsOK) \( stagingLocation) " +
65
51
pod. skipImportValidation ( ) + " \( pod. podspecName ( ) ) " +
66
- " --sources= \( cpdcRepo) .git,https://cdn.cocoapods.org "
67
- return pushCommands
68
-
52
+ " --sources= \( stagingRepo) .git,https://cdn.cocoapods.org "
69
53
case . trunk:
70
54
return " pod trunk push --skip-tests --synchronous \( warningsOK) " +
71
- pod. skipImportValidation ( ) + " ~/.cocoapods/repos/ \( cpdcLocation) /Specs/ \( pod. name) / " +
55
+ pod
56
+ . skipImportValidation ( ) + " ~/.cocoapods/repos/ \( stagingLocation) /Specs/ \( pod. name) / " +
72
57
" \( manifest. versionString ( pod) ) / \( pod. name) .podspec.json "
73
58
}
74
59
} ( )
0 commit comments