Add Git push scripts and SSH configuration
This commit is contained in:
parent
a27e45a024
commit
ca6a401148
1
CUsers华为.sshknown_hosts
Normal file
1
CUsers华为.sshknown_hosts
Normal file
@ -0,0 +1 @@
|
|||||||
|
hblu.top ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKysWvs0o99Qgtl5RFw4wyINkIu8WRcxOBlwlV9r41l3
|
||||||
3
push.ps1
Normal file
3
push.ps1
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
= "12345678"
|
||||||
|
= Start-Process -FilePath "git" -ArgumentList "push" -NoNewWindow -PassThru -RedirectStandardInput "stdin.txt"
|
||||||
|
| Out-File -FilePath "stdin.txt" -Encoding ascii
|
||||||
15
push3.ps1
Normal file
15
push3.ps1
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
$psi = New-Object System.Diagnostics.ProcessStartInfo
|
||||||
|
$psi.FileName = "git"
|
||||||
|
$psi.Arguments = "push"
|
||||||
|
$psi.UseShellExecute = $false
|
||||||
|
$psi.RedirectStandardInput = $true
|
||||||
|
$psi.RedirectStandardOutput = $true
|
||||||
|
$psi.RedirectStandardError = $true
|
||||||
|
$p = [System.Diagnostics.Process]::Start($psi)
|
||||||
|
$p.StandardInput.WriteLine("12345678")
|
||||||
|
$p.StandardInput.Flush()
|
||||||
|
$p.WaitForExit()
|
||||||
|
$output = $p.StandardOutput.ReadToEnd()
|
||||||
|
$error = $p.StandardError.ReadToEnd()
|
||||||
|
Write-Host $output
|
||||||
|
Write-Host $error
|
||||||
15
push4.ps1
Normal file
15
push4.ps1
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
$psi = New-Object System.Diagnostics.ProcessStartInfo
|
||||||
|
$psi.FileName = "git"
|
||||||
|
$psi.Arguments = "push"
|
||||||
|
$psi.UseShellExecute = $false
|
||||||
|
$psi.RedirectStandardInput = $true
|
||||||
|
$psi.RedirectStandardOutput = $true
|
||||||
|
$psi.RedirectStandardError = $true
|
||||||
|
$p = [System.Diagnostics.Process]::Start($psi)
|
||||||
|
$p.StandardInput.WriteLine("12345678")
|
||||||
|
$p.StandardInput.Flush()
|
||||||
|
$p.WaitForExit()
|
||||||
|
$output = $p.StandardOutput.ReadToEnd()
|
||||||
|
$err = $p.StandardError.ReadToEnd()
|
||||||
|
Write-Host $output
|
||||||
|
Write-Host $err
|
||||||
Loading…
Reference in New Issue
Block a user