save cmder_diag.* output to a file

This commit is contained in:
Dax T. Games 2021-09-17 12:22:25 -04:00
parent c34eb73555
commit f809af1eec
3 changed files with 130 additions and 81 deletions

View File

@ -1,5 +1,29 @@
@echo off @echo off
(echo.
echo ------------------------------------
echo set
echo ------------------------------------
set
echo.
echo ------------------------------------
echo where git
echo ------------------------------------
where git
echo.
echo ------------------------------------
echo where clink
echo ------------------------------------
where clink
echo.
echo ------------------------------------
echo systeminfo
echo ------------------------------------
systeminfo
echo ------------------------------------ echo ------------------------------------
echo dir "%cmder_root%" echo dir "%cmder_root%"
echo ------------------------------------ echo ------------------------------------
@ -23,25 +47,15 @@ echo dir /s "%cmder_root%\config"
echo ------------------------------------ echo ------------------------------------
dir /s "%cmder_root%\config" dir /s "%cmder_root%\config"
echo.
echo ------------------------------------
echo set
echo ------------------------------------
set
echo.
echo ------------------------------------
echo where git
echo ------------------------------------
where git
echo.
echo ------------------------------------
echo systeminfo
echo ------------------------------------
systeminfo
echo. echo.
echo ------------------------------------ echo ------------------------------------
echo Make sure you sanitize this output of private data prior to posting it online for review by the CMDER Team! echo Make sure you sanitize this output of private data prior to posting it online for review by the CMDER Team!
echo ------------------------------------ echo ------------------------------------
) > "%temp%\cmder_diag_cmd.log"
type "%temp%\cmder_diag_cmd.log"
echo.
echo Above output was saved in "%temp%\cmder_diag_cmd.log"

View File

@ -1,45 +1,64 @@
write-host ------------------------------------ if (test-path $env:temp/cmder_diag_ps.log) {
write-host get-childitem "$env:CMDER_ROOT" remove-item $env:temp/cmder_diag_ps.log
write-host ------------------------------------ }
get-childitem "$env:CMDER_ROOT"
write-host '' $cmder_diag = {
write-host ------------------------------------ ""
write-host get-childitem "$env:CMDER_ROOT/vendor" "------------------------------------"
write-host ------------------------------------ "get-childitem env:"
get-childitem "$env:CMDER_ROOT/vendor" "------------------------------------"
get-childitem env: | ft -autosize -wrap 2>&1
write-host '' ""
write-host ------------------------------------ "------------------------------------"
write-host get-childitem -s "$env:CMDER_ROOT/bin" "get-command git -all -ErrorAction SilentlyContinue"
write-host ------------------------------------ "------------------------------------"
get-childitem -s "$env:CMDER_ROOT/bin" get-command git -all -ErrorAction SilentlyContinue
write-host '' ""
write-host ------------------------------------ "------------------------------------"
write-host get-childitem -s "$env:CMDER_ROOT/config" "get-command clink -all -ErrorAction SilentlyContinue"
write-host ------------------------------------ "------------------------------------"
get-childitem -s "$env:CMDER_ROOT/config" get-command clink -all -ErrorAction SilentlyContinue
write-host '' ""
write-host ------------------------------------ "------------------------------------"
write-host get-childitem env: "systeminfo"
write-host ------------------------------------ "------------------------------------"
get-childitem env: |ft -autosize -wrap systeminfo 2>&1
write-host '' "------------------------------------"
write-host ------------------------------------ "get-childitem '$env:CMDER_ROOT'"
write-host get-command git "------------------------------------"
write-host ------------------------------------ get-childitem "$env:CMDER_ROOT" |ft LastWriteTime,mode,length,FullName
get-command git
write-host '' ""
write-host ------------------------------------ "------------------------------------"
write-host systeminfo "get-childitem '$env:CMDER_ROOT/vendor'"
write-host ------------------------------------ "------------------------------------"
systeminfo get-childitem "$env:CMDER_ROOT/vendor" |ft LastWriteTime,mode,length,FullName
write-host '' ""
write-host ------------------------------------ "------------------------------------"
write-host Make sure you sanitize this output of private data prior to posting it online for review by the CMDER Team! "get-childitem -s '$env:CMDER_ROOT/bin'"
write-host ------------------------------------ "------------------------------------"
get-childitem -s "$env:CMDER_ROOT/bin" |ft LastWriteTime,mode,length,FullName
""
"------------------------------------"
"get-childitem -s '$env:CMDER_ROOT/config'"
"------------------------------------"
get-childitem -s "$env:CMDER_ROOT/config" |ft LastWriteTime,mode,length,FullName
""
"------------------------------------"
"Make sure you sanitize this output of private data prior to posting it online for review by the CMDER Team!"
"------------------------------------"
}
& $cmder_diag | out-file -filePath $env:temp/cmder_diag_ps.log
get-content "$env:temp/cmder_diag_ps.log"
write-host ""
write-host Above output was saved in "$env:temp/cmder_diag_ps.log"

View File

@ -1,45 +1,61 @@
echo ------------------------------------ #!/usr/bin/env bash
echo ls -la "$CMDER_ROOT"
echo ------------------------------------
ls -la "$CMDER_ROOT"
echo '' [[ -f "$TEMP/cmder_diag_sh.log" ]] && rm -f "$TEMP/cmder_diag_sh.log"
echo ------------------------------------
echo ls -la "$CMDER_ROOT/vendor"
echo ------------------------------------
ls -la "$CMDER_ROOT/vendor"
echo '' (echo ''
echo ------------------------------------
echo ls -la /s "$CMDER_ROOT/bin"
echo ------------------------------------
ls -laR /s "$CMDER_ROOT/bin"
echo ''
echo ------------------------------------
echo ls -la /s "$CMDER_ROOT/config"
echo ------------------------------------
ls -laR /s "$CMDER_ROOT/config"
echo ''
echo ------------------------------------ echo ------------------------------------
echo env echo env
echo ------------------------------------ echo ------------------------------------
env env 2>&1
echo '' echo ''
echo ------------------------------------ echo ------------------------------------
echo which git echo which git
echo ------------------------------------ echo ------------------------------------
which git 2>&1
echo ''
echo ------------------------------------
echo which clink
echo ------------------------------------
which clink 2>&1
which git
echo '' echo ''
echo ------------------------------------ echo ------------------------------------
echo systeminfo echo systeminfo
echo ------------------------------------ echo ------------------------------------
systeminfo systeminfo 2>&1
echo ------------------------------------
echo ls -la "$CMDER_ROOT"
echo ------------------------------------
ls -la "$CMDER_ROOT" 2>&1
echo ''
echo ------------------------------------
echo ls -la "$CMDER_ROOT/vendor"
echo ------------------------------------
ls -la "$CMDER_ROOT/vendor" 2>&1
echo ''
echo ------------------------------------
echo ls -la /s "$CMDER_ROOT/bin"
echo ------------------------------------
ls -laR /s "$CMDER_ROOT/bin" 2>&1
echo ''
echo ------------------------------------
echo ls -la /s "$CMDER_ROOT/config"
echo ------------------------------------
ls -laR /s "$CMDER_ROOT/config" 2>&1
echo '' echo ''
echo ------------------------------------ echo ------------------------------------
echo Make sure you sanitize this output of private data prior to posting it online for review by the CMDER Team! echo Make sure you sanitize this output of private data prior to posting it online for review by the CMDER Team!
echo ------------------------------------ echo ------------------------------------
) > "$TEMP/cmder_diag_sh.log"
cat "$TEMP/cmder_diag_sh.log"
echo ''
echo Above output was saved in "$TEMP/cmder_diag_sh.log"