git related improvements and implementations
+ Get-GitRepo - Clone or update a repo, with tag support + Get-GitHubReleaseTag - Grab tag from latest release page + Refresh-GitRepo - Stage all possible changes, discarding any previously stageds changes = GitHub repo is now git repo - as some code isn't GitHub specific + cat Alias for Get-Content = Get-PossiblArguments improvement = Invoke-WebDownload fix = dcedit fixing bad argument processing
這個提交存在於:
父節點
aa44d120e4
當前提交
8a93a0f123
共有 11 個檔案被更改,包括 85 行新增 和 11 行删除
|
@ -6,7 +6,7 @@
|
|||
|
||||
)
|
||||
|
||||
$local:EditCandidates = @('docker-compose.###','.base.docker-compose.###')
|
||||
$local:EditCandidates = @('docker-compose.###','.base.docker-compose.###','secrets.env')
|
||||
$local:EditBonus = @('Dockerfile', '.env', '*.env')
|
||||
$local:editFiles = @()
|
||||
foreach( $local:ext in @('.yml', '.yaml') ) {
|
||||
|
@ -15,7 +15,7 @@ foreach( $local:ext in @('.yml', '.yaml') ) {
|
|||
foreach( $local:path in $ProjectPath ) {
|
||||
$local:testPath = Join-Path $path $fileName
|
||||
if( $Force -or $(Test-Path $testPath) ) {
|
||||
$editFiles += $testPath
|
||||
$editFiles += $testPath | Get-Path
|
||||
$editFiles += Get-ChildItem $(Join-Path $path '*') -Include $EditBonus -Depth 1 |
|
||||
Select-Object -ExpandProperty FullName
|
||||
}
|
||||
|
@ -37,9 +37,17 @@ $AdditionalFiles = $AdditionalFiles | Where-Object { $_ } | ForEach-Object {
|
|||
|
||||
$local:FinalEditList = $editFiles | Where-Object {$_} | Sort-Object {
|
||||
$local:n = [System.IO.Path]::GetFileName($_)
|
||||
Join-Path [PSystem.IO.ath]::GetDirectoryName($_) "$(if( $n[0] -eq '.' ) { "9" } else { "1" })$n"
|
||||
$local:sorder = "$(
|
||||
if( $n[0] -eq '.' ) { "2" }
|
||||
elseif( $n -match 'docker-compose\.y' ) { "1" }
|
||||
else { "9" }
|
||||
)$n"
|
||||
Write-Verbose "sorder($n)=$sorder"
|
||||
$local:sorder = Join-Path $([System.IO.Path]::GetDirectoryName($_)) $sorder
|
||||
$sorder
|
||||
}
|
||||
$FinalEditList = (@() + $FinalEditList + @() + $AdditionalFiles) | Select-Object -Unique
|
||||
Write-Verbose "`$FinalEditList = `n$($FinalEditList | Out-String)"
|
||||
|
||||
Edit-TextFile $FinalEditList
|
||||
|
||||
|
|
載入中…
新增表格
新增連結
新增問題並參考