Skip to content

Commit 12c4ead

Browse files
feat: add latest app version to release index data (#961)
* feat: add latest app version to release index data * chore: normalize workflow name * feat: add latest URL to release index data * refactor: update release index to include latest release object * chore: remove releases.json file * fix: update version detection logic in build-releases.js - Changed the latest version pattern to YY.MM-patch format. - Introduced MIN_STABLE_VERSION for stable version validation. * refactor: restructure build-releases.js for improved maintainability * test: add unit tests for VersionManager, ReleaseProcessor, and ReleaseIndexBuilder * test: enhance ReleaseProcessor tests with console log suppression * readme.md * chore: clean up comments and formatting in build-releases.js and README.md * docs: add mermaid diagram to README for channel classification flow
1 parent 0a26b2b commit 12c4ead

File tree

7 files changed

+4466
-346
lines changed

7 files changed

+4466
-346
lines changed
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
## Channel Classification Flow
2+
3+
```mermaid
4+
flowchart TD
5+
Start([Version Input]) --> Check{Matches<br/>YY.MM-patch?}
6+
7+
Check -->|"Yes (25.04-1)"| Month{Month<br/>1-12?}
8+
Check -->|"No (1.2.3)"| Stable[Stable Channel]
9+
10+
Month -->|Yes| Latest["Latest Channel<br/>(normalize: 25.4.1)"]
11+
Month -->|"No (25.13-1)"| Stable
12+
13+
Latest --> ValidL{Valid<br/>semver?}
14+
Stable --> ValidS{"Valid semver<br/>>= 1.0.0?"}
15+
16+
ValidL -->|Yes| AcceptL["✅ Accept as Latest"]
17+
ValidL -->|No| Reject["❌ Skip"]
18+
19+
ValidS -->|Yes| AcceptS["✅ Accept as Stable"]
20+
ValidS -->|No| Reject
21+
22+
style AcceptL fill:#90EE90,stroke:#2d5016
23+
style AcceptS fill:#87CEEB,stroke:#003d5c
24+
style Reject fill:#ffcccb,stroke:#8b0000
25+
style Latest fill:#e1f5ff,stroke:#0066cc
26+
style Stable fill:#f0fff0,stroke:#006400
27+
```
28+
29+
### Examples
30+
31+
| Input Version | Matches Pattern? | Month Valid? | Channel | Normalized | Valid? | Result |
32+
|--------------|------------------|--------------|---------|------------|--------|--------|
33+
| `25.04-1` | ✅ Yes | ✅ Yes (4) | Latest | `25.4.1` | ✅ Yes |**Accept Latest** |
34+
| `25.13-1` | ✅ Yes | ❌ No (13) | Stable | `25.13-1` | ❌ No |**Skip** |
35+
| `1.2.3` | ❌ No | - | Stable | `1.2.3` | ✅ Yes |**Accept Stable** |
36+
| `0.9.0` | ❌ No | - | Stable | `0.9.0` | ❌ No (< 1.0.0) |**Skip** |
37+
| `24.12-10` | ✅ Yes | ✅ Yes (12) | Latest | `24.12.10` | ✅ Yes |**Accept Latest** |

0 commit comments

Comments
 (0)