Print tool version
stack version[Placeholder: Add detailed description of version command output and version numbering scheme]
The version command outputs:
- Version number (e.g.,
2.0.1) - Build hash (if available)
- Build timestamp (if available)
Example output:
stack version 2.0.1-d531f73-202505011750
- Major version: Breaking changes
- Minor version: New features
- Patch version: Bug fixes
- Build hash: Git commit hash
- Timestamp: Build date and time
# Display version
stack version
# Check version in scripts
if stack version | grep -q "2.0"; then
echo "Version 2.0 or higher"
fi- stack update - Update shiv binary from a distribution URL