Commit a14748c
committed
Validate and Construct sync Parameters
Why these changes are being introduced:
First, we want to ensure that the only additional parameters supplied
by the caller workflow are `--include` and `--exclude` parameters.
Second, since we pass the parameters via an `env:` block, we have to
be extra careful with double-quotes (which are required by the
`aws s3 sync` command, but typically get stripped when expanded in a
bash script).
How these changes are implemented:
* Add a block to the validation step to throw an error if there is
any other parameter in the SYNC_PARAMS input outside of `--include` and
`--exclude`
* If the SYNC_PARAMS is valid, merge it together with the other stock
`--exclude` parameters and set one string in the GITHUB_ENV with the
full list of inclues and excludes
* Add the `eval` command to properly expand the `aws s3 sync` command
and preserve the double-quotes where they are required
Side effects:
None.1 parent 98f7d25 commit a14748c
1 file changed
Lines changed: 26 additions & 11 deletions
File tree
- .github/workflows
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
67 | 67 | | |
68 | 68 | | |
69 | 69 | | |
70 | | - | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
71 | 73 | | |
72 | 74 | | |
73 | 75 | | |
74 | 76 | | |
75 | 77 | | |
76 | 78 | | |
77 | 79 | | |
| 80 | + | |
78 | 81 | | |
79 | 82 | | |
80 | 83 | | |
| |||
100 | 103 | | |
101 | 104 | | |
102 | 105 | | |
| 106 | + | |
103 | 107 | | |
104 | 108 | | |
105 | 109 | | |
| |||
108 | 112 | | |
109 | 113 | | |
110 | 114 | | |
111 | | - | |
| 115 | + | |
112 | 116 | | |
113 | 117 | | |
114 | 118 | | |
| |||
118 | 122 | | |
119 | 123 | | |
120 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
121 | 139 | | |
122 | 140 | | |
123 | 141 | | |
| |||
153 | 171 | | |
154 | 172 | | |
155 | 173 | | |
156 | | - | |
| 174 | + | |
157 | 175 | | |
158 | | - | |
| 176 | + | |
159 | 177 | | |
160 | 178 | | |
161 | 179 | | |
| |||
184 | 202 | | |
185 | 203 | | |
186 | 204 | | |
187 | | - | |
| 205 | + | |
188 | 206 | | |
189 | 207 | | |
190 | 208 | | |
| |||
193 | 211 | | |
194 | 212 | | |
195 | 213 | | |
196 | | - | |
197 | | - | |
198 | | - | |
199 | | - | |
200 | | - | |
201 | | - | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
202 | 217 | | |
203 | 218 | | |
204 | 219 | | |
| |||
0 commit comments