File tree Expand file tree Collapse file tree 2 files changed +65
-53
lines changed
Expand file tree Collapse file tree 2 files changed +65
-53
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ def generate(self):
3737
3838 print ('Step 3/3: Building list' )
3939 versions_dict = self .parse_prestashop_versions (prestashop_data , available_php_versions )
40- branches_dict = self .previous_state_versions
40+ branches_dict = self .get_branches_and_nightly_from_existing_file ()
4141 self .write_versions_py (versions_dict | branches_dict )
4242
4343 def get_available_php_versions (self ):
@@ -49,6 +49,15 @@ def get_available_php_versions(self):
4949 available_versions .add (match .group (1 ))
5050 return available_versions
5151
52+ # Branches and nightly entries are manually added in versions.py file.
53+ # Let's reuse the existing contents on each generation.
54+ def get_branches_and_nightly_from_existing_file (self ):
55+ branches = {}
56+ for branch , php_versions in self .previous_state_versions .items ():
57+ if branch == self .NIGHTLY or branch .endswith ('x' ):
58+ branches [branch ] = (tuple (php_versions ))
59+ return branches
60+
5261 def parse_prestashop_versions (self , prestashop_json , available_php_versions ):
5362 versions = {}
5463 for entry in prestashop_json :
Original file line number Diff line number Diff line change 11VERSIONS = {
2+ # OSS Edition
23 '1.7.7.0' : (
34 '7.1' ,
45 '7.2' ,
128129 '7.3' ,
129130 '7.4' ,
130131 ),
131- '1.7.8.x' : (
132- '7.1' ,
133- '7.2' ,
134- '7.3' ,
135- '7.4' ,
136- ),
137132 '8.0.0' : (
138133 '7.2' ,
139134 '7.3' ,
162157 '8.0' ,
163158 '8.1' ,
164159 ),
165- '8.0.1-classic ' : (
160+ '8.0.2 ' : (
166161 '7.2' ,
167162 '7.3' ,
168163 '7.4' ,
169164 '8.0' ,
170165 '8.1' ,
171166 ),
172- '8.0.2 ' : (
167+ '8.0.3 ' : (
173168 '7.2' ,
174169 '7.3' ,
175170 '7.4' ,
176171 '8.0' ,
177172 '8.1' ,
178173 ),
179- '8.0.2-classic ' : (
174+ '8.0.4 ' : (
180175 '7.2' ,
181176 '7.3' ,
182177 '7.4' ,
183178 '8.0' ,
184179 '8.1' ,
185180 ),
186- '8.0.3 ' : (
181+ '8.0.5 ' : (
187182 '7.2' ,
188183 '7.3' ,
189184 '7.4' ,
190185 '8.0' ,
191186 '8.1' ,
192187 ),
193- '8.0.4 ' : (
188+ '8.1.0 ' : (
194189 '7.2' ,
195190 '7.3' ,
196191 '7.4' ,
197192 '8.0' ,
198193 '8.1' ,
199194 ),
200- '8.0.4-classic ' : (
195+ '8.1.0-beta.1 ' : (
201196 '7.2' ,
202197 '7.3' ,
203198 '7.4' ,
204199 '8.0' ,
205200 '8.1' ,
206201 ),
207- '8.0.5 ' : (
202+ '8.1.0-rc.1 ' : (
208203 '7.2' ,
209204 '7.3' ,
210205 '7.4' ,
211206 '8.0' ,
212207 '8.1' ,
213208 ),
214- '8.0.x ' : (
209+ '8.1.1 ' : (
215210 '7.2' ,
216211 '7.3' ,
217212 '7.4' ,
218213 '8.0' ,
219214 '8.1' ,
220215 ),
221- '8.1.0 ' : (
216+ '8.1.2 ' : (
222217 '7.2' ,
223218 '7.3' ,
224219 '7.4' ,
225220 '8.0' ,
226221 '8.1' ,
227222 ),
228- '8.1.0-beta.1 ' : (
223+ '8.1.3 ' : (
229224 '7.2' ,
230225 '7.3' ,
231226 '7.4' ,
232227 '8.0' ,
233228 '8.1' ,
234229 ),
235- '8.1.0-classic ' : (
230+ '8.1.4 ' : (
236231 '7.2' ,
237232 '7.3' ,
238233 '7.4' ,
239234 '8.0' ,
240235 '8.1' ,
241236 ),
242- '8.1.0-rc.1 ' : (
237+ '8.1.5 ' : (
243238 '7.2' ,
244239 '7.3' ,
245240 '7.4' ,
246241 '8.0' ,
247242 '8.1' ,
248243 ),
249- '8.1.1 ' : (
244+ '8.1.6 ' : (
250245 '7.2' ,
251246 '7.3' ,
252247 '7.4' ,
253248 '8.0' ,
254249 '8.1' ,
255250 ),
256- '8.1.1-classic ' : (
251+ '8.1.7 ' : (
257252 '7.2' ,
258253 '7.3' ,
259254 '7.4' ,
260255 '8.0' ,
261256 '8.1' ,
262257 ),
263- '8.1.2 ' : (
258+ '8.2.0 ' : (
264259 '7.2' ,
265260 '7.3' ,
266261 '7.4' ,
267262 '8.0' ,
268263 '8.1' ,
269264 ),
270- '8.1.2-classic ' : (
265+ '8.2.1 ' : (
271266 '7.2' ,
272267 '7.3' ,
273268 '7.4' ,
274269 '8.0' ,
275270 '8.1' ,
276271 ),
277- '8.1.3' : (
272+ # Nightly Build (OSS)
273+ '1.7.8.x' : (
274+ '7.1' ,
275+ '7.2' ,
276+ '7.3' ,
277+ '7.4' ,
278+ ),
279+ '8.0.x' : (
278280 '7.2' ,
279281 '7.3' ,
280282 '7.4' ,
281283 '8.0' ,
282284 '8.1' ,
283285 ),
284- '8.1.3-classic ' : (
286+ '8.1.x ' : (
285287 '7.2' ,
286288 '7.3' ,
287289 '7.4' ,
288290 '8.0' ,
289291 '8.1' ,
290292 ),
291- '8.1.4 ' : (
293+ '8.2.2 ' : (
292294 '7.2' ,
293295 '7.3' ,
294296 '7.4' ,
295297 '8.0' ,
296298 '8.1' ,
297299 ),
298- '8.1.4-classic ' : (
300+ '8.2.3 ' : (
299301 '7.2' ,
300302 '7.3' ,
301303 '7.4' ,
302304 '8.0' ,
303305 '8.1' ,
304306 ),
305- '8.1.5 ' : (
307+ '8.2.x ' : (
306308 '7.2' ,
307309 '7.3' ,
308310 '7.4' ,
309311 '8.0' ,
310312 '8.1' ,
311313 ),
312- '8.1.5-classic' : (
314+ '9.0.x' : (
315+ '8.1' ,
316+ '8.2' ,
317+ '8.3' ,
318+ '8.4' ,
319+ ),
320+ 'nightly' : (
321+ '8.1' ,
322+ '8.2' ,
323+ '8.3' ,
324+ '8.4' ,
325+ ),
326+ # Classic Edition
327+ '8.0.1-classic' : (
313328 '7.2' ,
314329 '7.3' ,
315330 '7.4' ,
316331 '8.0' ,
317332 '8.1' ,
318333 ),
319- '8.1.6 ' : (
334+ '8.0.2-classic ' : (
320335 '7.2' ,
321336 '7.3' ,
322337 '7.4' ,
323338 '8.0' ,
324339 '8.1' ,
325340 ),
326- '8.1.6 -classic' : (
341+ '8.0.4 -classic' : (
327342 '7.2' ,
328343 '7.3' ,
329344 '7.4' ,
330345 '8.0' ,
331346 '8.1' ,
332347 ),
333- '8.1.7 ' : (
348+ '8.1.0-classic ' : (
334349 '7.2' ,
335350 '7.3' ,
336351 '7.4' ,
337352 '8.0' ,
338353 '8.1' ,
339354 ),
340- '8.1.7 -classic' : (
355+ '8.1.1 -classic' : (
341356 '7.2' ,
342357 '7.3' ,
343358 '7.4' ,
344359 '8.0' ,
345360 '8.1' ,
346361 ),
347- '8.1.x ' : (
362+ '8.1.2-classic ' : (
348363 '7.2' ,
349364 '7.3' ,
350365 '7.4' ,
351366 '8.0' ,
352367 '8.1' ,
353368 ),
354- '8.2.0 ' : (
369+ '8.1.3-classic ' : (
355370 '7.2' ,
356371 '7.3' ,
357372 '7.4' ,
358373 '8.0' ,
359374 '8.1' ,
360375 ),
361- '8.2.0 -classic' : (
376+ '8.1.4 -classic' : (
362377 '7.2' ,
363378 '7.3' ,
364379 '7.4' ,
365380 '8.0' ,
366381 '8.1' ,
367382 ),
368- '8.2.1 ' : (
383+ '8.1.5-classic ' : (
369384 '7.2' ,
370385 '7.3' ,
371386 '7.4' ,
372387 '8.0' ,
373388 '8.1' ,
374389 ),
375- '8.2.1 -classic' : (
390+ '8.1.6 -classic' : (
376391 '7.2' ,
377392 '7.3' ,
378393 '7.4' ,
379394 '8.0' ,
380395 '8.1' ,
381396 ),
382- '8.2.2 ' : (
397+ '8.1.7-classic ' : (
383398 '7.2' ,
384399 '7.3' ,
385400 '7.4' ,
386401 '8.0' ,
387402 '8.1' ,
388403 ),
389- '8.2.3 ' : (
404+ '8.2.0-classic ' : (
390405 '7.2' ,
391406 '7.3' ,
392407 '7.4' ,
393408 '8.0' ,
394409 '8.1' ,
395410 ),
396- '8.2.x ' : (
411+ '8.2.1-classic ' : (
397412 '7.2' ,
398413 '7.3' ,
399414 '7.4' ,
418433 '8.3' ,
419434 '8.4' ,
420435 ),
421- '9.0.x' : (
422- '8.1' ,
423- '8.2' ,
424- '8.3' ,
425- '8.4' ,
426- ),
427- 'nightly' : (
428- '8.1' ,
429- '8.2' ,
430- '8.3' ,
431- '8.4' ,
432- ),
433436}
You can’t perform that action at this time.
0 commit comments