mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-05 01:50:27 +08:00
feat: Implement dynamic version detection and passing system
**Installation System Updates**: - install-remote.ps1: Auto-detect version from GitHub API and pass to installer - Install-Claude.ps1: Accept dynamic version via -SourceVersion parameter - install-remote.sh: Synchronize version detection logic with PowerShell version - Add installer_version field to version.json for tracking **Codex Agent Optimization** (.codex/AGENTS.md): - Add system optimization requirements for direct binary execution - Prioritize apply_patch tool over Python scripts for file editing - Add Windows UTF-8 encoding configuration for Chinese character support **Version Flow**: 1. install-remote.* detects version from GitHub API (latest release tag) 2. Passes version to Install-Claude.* via -SourceVersion/-SourceBranch 3. Installer writes accurate version to version.json 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -563,7 +563,23 @@ function Main {
|
||||
}
|
||||
|
||||
# Determine version and branch information to pass
|
||||
$versionToPass = if ($Tag) { $Tag } else { "latest" }
|
||||
$versionToPass = ""
|
||||
if ($Tag) {
|
||||
# Specific tag version
|
||||
$versionToPass = $Tag -replace '^v', '' # Remove 'v' prefix
|
||||
} elseif ($Version -eq "stable") {
|
||||
# Auto-detected latest stable
|
||||
$latestTag = Get-LatestRelease
|
||||
if ($latestTag) {
|
||||
$versionToPass = $latestTag -replace '^v', ''
|
||||
} else {
|
||||
$versionToPass = "latest"
|
||||
}
|
||||
} else {
|
||||
# Latest development or branch
|
||||
$versionToPass = "latest"
|
||||
}
|
||||
|
||||
$branchToPass = if ($Version -eq "branch") { $Branch } elseif ($Version -eq "latest") { "main" } elseif ($Tag) { $Tag } else { "main" }
|
||||
|
||||
Write-ColorOutput "Version info: $versionToPass (branch: $branchToPass)" $ColorInfo
|
||||
|
||||
Reference in New Issue
Block a user