Implement innovative two-character option scheme

- Replace single-character options with memorable two-character alternatives
- Based on syllable mapping: -to (target-org), -qy (query), -fm (format), etc.
- Updated all bash and PowerShell scripts with consistent options
- Added comprehensive documentation and examples to README.md
- Maintains backward compatibility with long options
- More intuitive and self-documenting than traditional CLI options
This commit is contained in:
reynold
2025-08-28 18:11:08 +08:00
parent d919e5cfb8
commit 628fe95b50
11 changed files with 206 additions and 132 deletions

View File

@@ -20,7 +20,7 @@
.PARAMETER OutputDir
Output directory for retrieved metadata (default: current directory)
.PARAMETER TargetOrg
.PARAMETER o
Target org username or alias (uses default if not specified)
.PARAMETER Wait
@@ -33,9 +33,9 @@
Show this help message
.EXAMPLE
.\sf-retrieve.ps1 -MetadataTypes "ApexClass,CustomObject"
.\sf-retrieve.ps1 -MetadataTypes "ApexClass,CustomObject" -o myorg -OutputDir retrieved
.\sf-retrieve.ps1 -Manifest "manifest/package.xml"
.\sf-retrieve.ps1 -Package "MyPackage" -TargetOrg "myorg"
.\sf-retrieve.ps1 -Package "MyPackage" -o "myorg"
.\sf-retrieve.ps1 -MetadataTypes "Flow" -OutputDir "./retrieved" -Verbose
.NOTES
@@ -54,7 +54,7 @@ param(
[string]$Package,
[string]$OutputDir,
[string]$TargetOrg,
[string]$o,
[int]$Wait = 10,
[switch]$Verbose,
[switch]$Help
@@ -154,10 +154,10 @@ if ($OutputDir) {
$sfArgs += $OutputDir
}
if ($TargetOrg) {
if ($o) {
$sfArgs += "--target-org"
$sfArgs += $TargetOrg
Write-Host "Target org: $TargetOrg" -ForegroundColor Cyan
$sfArgs += $o
Write-Host "Target org: $o" -ForegroundColor Cyan
}
if ($Wait -ne 10) {