mirror of
https://github.com/graycoreio/github-actions-magento2.git
synced 2026-06-13 13:14:53 +00:00
feat(supported-version): dynamically compute (#120)
Previously, I maintained supported versions by revising a file of versions. This was monotonous, like time. Now, these are just based upon the documented EoL dates of the versions published by Magento.
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
import { MagentoMatrixVersion } from '../matrix/matrix-type';
|
||||
import allVersions from '../versions/individual.json';
|
||||
|
||||
export const getCurrentlySupportedVersions = (date: Date): string[] =>
|
||||
Object.entries(<Record<string,MagentoMatrixVersion>>allVersions)
|
||||
.filter(([key, value]) => new Date(value.eol) >= date)
|
||||
.map(([key, value]) => key);
|
||||
Reference in New Issue
Block a user