File tree 1 file changed +14
-10
lines changed
1 file changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,18 @@ def execute(repository, payloads)
41
41
42
42
43
43
def execute
44
- call_mirror if needs_push?
44
+ y = ''
45
+
46
+ logger . info ( "Pushing changes to #{ url } ... " )
47
+ y << " - Pushing changes to #{ url } ... "
48
+
49
+ if needs_push?
50
+ y << call_mirror
51
+ else
52
+ y << "This mirror doesn't need to be updated\n "
53
+ end
54
+
55
+ y
45
56
end
46
57
47
58
@@ -72,23 +83,16 @@ def check_ref_spec
72
83
73
84
74
85
def call_mirror
75
- y = ''
76
-
77
- logger . info ( "Pushing changes to #{ url } ... " )
78
- y << " - Pushing changes to #{ url } ... "
79
-
80
86
push_failed , push_message = MirrorPush . new ( mirror ) . call
81
87
82
88
if push_failed
83
89
logger . error ( 'Failed!' )
84
90
logger . error ( "#{ push_message } " )
85
- y << " [failure]\n "
91
+ " [failure]\n "
86
92
else
87
93
logger . info ( 'Succeeded!' )
88
- y << " [success]\n "
94
+ " [success]\n "
89
95
end
90
-
91
- y
92
96
end
93
97
94
98
You can’t perform that action at this time.
0 commit comments