How im-open/git-version-lite works
Main Components
a. Input Processing Layer
• Inputs like tag-prefix, branch-name, calculate-prerelease-version, etc.
b. Core Processing Components
• Git Interface Component (representing git-commands.js)
• Version Calculator Component (representing version.js)
• Main Orchestrator (representing main.js)
c. Output Generation Layer
• Version outputs (NEXT_VERSION, PRIOR_VERSION, etc.)
Component Relationships
[GitHub Workflow] → [Input Processing] → [Main Orchestrator]
• ↓
[Git Repository] ← [Git Interface] ← → [Version Calculator]
• ↓
• [Output Generation] → [GitHub Environment/Outputs]
Important Elements to Highlight
a. Version Calculation Logic:
• Version increment decision flow
• Commit message pattern matching
• Demonstrate the branching logic for release vs. pre-release
b. Git Integration:
• Interaction with git history
• Tag handling and prefix management
Technical Details
• Node.js runtime environment
• GitHub Actions integration points
• Git command execution flow
• Version pattern matching rules
Environment variable handling
This system design should help developers understand how the action processes inputs, interacts with git, calculates versions, and provides outputs to the GitHub Actions environment.