=dcsw additional output
This commit is contained in:
parent
c8b9f5d2dc
commit
c2675e2346
6 changed files with 202 additions and 8 deletions
|
@ -1,7 +1,7 @@
|
|||
[CmdletBinding()]param(
|
||||
[switch]$NoClearScreen,
|
||||
[string]$DataSet = 'szmedia/nextcloud',
|
||||
[string]$DestBackupRoot = '_gw:z/szbackup'
|
||||
[string]$DestBackupRoot = 'root@gw.lksz.me:z/szbackup'
|
||||
)
|
||||
if( -not $NoClearScreen ) { Clear-Host }
|
||||
Write-Verbose "& syncoid --recursive `$DataSet{'$DataSet'} `"`$DestBackupRoot/`$DataSet`"{`"$DestBackupRoot/$DataSet`"}"
|
||||
|
|
|
@ -48,7 +48,7 @@ process {
|
|||
$local:item = $Path | Get-Item
|
||||
|
||||
$Path | Get-Item | ForEach-Object {
|
||||
$local:p = $_.FullName
|
||||
$local:p = $_.FullName -replace "'","''"
|
||||
$local:nextCmd = ""
|
||||
|
||||
$nextCmd = "(@(Get-Item '$p') + (Get-ChildItem '$p' $cmdArgs)) | " +
|
||||
|
|
|
@ -1 +1,20 @@
|
|||
Invoke-ExpressionEx -sudo "`$env:TERM='tmux-256color'; `$env:EDITOR='$env:EDITOR'; ranger $args"
|
||||
[CmdletBinding()]param(
|
||||
[Parameter(Position = 0, ValueFromRemainingArguments)]
|
||||
[string[]]$Path,
|
||||
[string]$User,
|
||||
[switch]$NoTmuxManipulations
|
||||
)
|
||||
|
||||
$local:sudoParams = @{sudoArgs=@("-i")}
|
||||
if( $User ) {
|
||||
$sudoParams.sudoArgs += @("-u",$User)
|
||||
}
|
||||
|
||||
if( -not $NoTmuxManipulations ) {
|
||||
# this should probably be controlled by byobu-keybindings script, but it looks like it's broken
|
||||
tmux source-file $env:BYOBU_PREFIX/share/byobu/keybindings/f-keys.tmux.disable ';' source-file ~/.byobu/keybindings.tmux ';' display-message "Byobu F-keys: DISABLED"
|
||||
}
|
||||
Invoke-ExpressionEx -sudo @sudoParams "`$env:TERM='tmux-256color'; `$env:EDITOR='$env:EDITOR'; ranger $($Path -join '')"
|
||||
if( -not $NoTmuxManipulations ) {
|
||||
tmux source-file $env:BYOBU_PREFIX/share/byobu/keybindings/f-keys.tmux ';' source-file ~/.byobu/keybindings.tmux ';' display-message "Byobu F-keys: ENABLED"
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue