mirror of
https://github.com/cmderdev/cmder.git
synced 2025-01-27 00:29:08 +08:00
add cleanup of unused env vars
This commit is contained in:
parent
1e623ecab4
commit
3a2e747d22
24
vendor/bin/timer.cmd
vendored
24
vendor/bin/timer.cmd
vendored
@ -11,6 +11,7 @@ set /a hours=%end_h%-%start_h%
|
|||||||
set /a mins=%end_m%-%start_m%
|
set /a mins=%end_m%-%start_m%
|
||||||
set /a secs=%end_s%-%start_s%
|
set /a secs=%end_s%-%start_s%
|
||||||
set /a ms=%end_ms%-%start_ms%
|
set /a ms=%end_ms%-%start_ms%
|
||||||
|
|
||||||
if %ms% lss 0 set /a secs = %secs% - 1 & set /a ms = 100%ms%
|
if %ms% lss 0 set /a secs = %secs% - 1 & set /a ms = 100%ms%
|
||||||
if %secs% lss 0 set /a mins = %mins% - 1 & set /a secs = 60%secs%
|
if %secs% lss 0 set /a mins = %mins% - 1 & set /a secs = 60%secs%
|
||||||
if %mins% lss 0 set /a hours = %hours% - 1 & set /a mins = 60%mins%
|
if %mins% lss 0 set /a hours = %hours% - 1 & set /a mins = 60%mins%
|
||||||
@ -20,3 +21,26 @@ if 1%ms% lss 100 set ms=0%ms%
|
|||||||
:: Mission accomplished
|
:: Mission accomplished
|
||||||
set /a totalsecs = %hours%*3600 + %mins%*60 + %secs%
|
set /a totalsecs = %hours%*3600 + %mins%*60 + %secs%
|
||||||
echo Elapsed Time: %hours%:%mins%:%secs%.%ms% (%totalsecs%.%ms%s total)
|
echo Elapsed Time: %hours%:%mins%:%secs%.%ms% (%totalsecs%.%ms%s total)
|
||||||
|
|
||||||
|
:: cleanup
|
||||||
|
set start=
|
||||||
|
set end=
|
||||||
|
set options=
|
||||||
|
|
||||||
|
set start_h=
|
||||||
|
set start_m=
|
||||||
|
set start_s=
|
||||||
|
set start_ms=
|
||||||
|
|
||||||
|
set end_h=
|
||||||
|
set end_m=
|
||||||
|
set end_s=
|
||||||
|
set end_ms=
|
||||||
|
|
||||||
|
set hours=
|
||||||
|
set mins=
|
||||||
|
set secs=
|
||||||
|
set ms=
|
||||||
|
|
||||||
|
set totalsecs=
|
||||||
|
|
||||||
|
23
vendor/init.bat
vendored
23
vendor/init.bat
vendored
@ -560,9 +560,26 @@ if defined CMDER_USER_CONFIG (
|
|||||||
|
|
||||||
:CMDER_CONFIGURED
|
:CMDER_CONFIGURED
|
||||||
if not defined CMDER_CONFIGURED set CMDER_CONFIGURED=1
|
if not defined CMDER_CONFIGURED set CMDER_CONFIGURED=1
|
||||||
|
|
||||||
set CMDER_INIT_END=%time%
|
set CMDER_INIT_END=%time%
|
||||||
|
call "%cmder_root%\vendor\bin\timer.cmd" "%CMDER_INIT_START%" "%CMDER_INIT_END%"
|
||||||
|
|
||||||
|
:: Cleanup
|
||||||
|
set architecture_bits=
|
||||||
|
set CMDER_ALIASES=
|
||||||
|
set CMDER_INIT_END=
|
||||||
|
set CMDER_INIT_START=
|
||||||
|
set CMDER_USER_FLAGS=
|
||||||
|
set debug_output=
|
||||||
|
set fast_init=
|
||||||
|
set max_depth=
|
||||||
|
set nix_tools=
|
||||||
|
set path_position=
|
||||||
|
set print_debug=
|
||||||
|
set print_error=
|
||||||
|
set print_verbose=
|
||||||
|
set print_warning=
|
||||||
|
set time_init=
|
||||||
|
set verbose_output=
|
||||||
|
set user_aliases=
|
||||||
|
|
||||||
"%cmder_root%\vendor\bin\timer.cmd" "%CMDER_INIT_START%" "%CMDER_INIT_END%"
|
|
||||||
)
|
|
||||||
exit /b
|
exit /b
|
||||||
|
36
vendor/user_init.cmd.template
vendored
36
vendor/user_init.cmd.template
vendored
@ -145,24 +145,28 @@ if not defined CMDER_CONFIGURED set CMDER_CONFIGURED=1
|
|||||||
set CMDER_INIT_END=%time%
|
set CMDER_INIT_END=%time%
|
||||||
|
|
||||||
if "%CMDER_INIT_END%" neq "" if "%CMDER_INIT_START%" neq "" (
|
if "%CMDER_INIT_END%" neq "" if "%CMDER_INIT_START%" neq "" (
|
||||||
"%cmder_root%\vendor\bin\timer.cmd" "%CMDER_INIT_START%" "%CMDER_INIT_END%"
|
call "%cmder_root%\vendor\bin\timer.cmd" "%CMDER_INIT_START%" "%CMDER_INIT_END%"
|
||||||
)
|
)
|
||||||
|
|
||||||
:: Cleanup
|
:: Cleanup
|
||||||
set architecture_bits=""
|
set architecture_bits=
|
||||||
set CMDER_ALIASES=""
|
set CMDER_ALIASES=
|
||||||
set CMDER_INIT_END=""
|
set CMDER_INIT_END=
|
||||||
set CMDER_INIT_START=""
|
set CMDER_INIT_START=
|
||||||
set debug_output=""
|
set CMDER_USER_FLAGS=
|
||||||
set fast_init=""
|
set debug_output=
|
||||||
set max_depth=""
|
set fast_init=
|
||||||
set nix_tools=""
|
set max_depth=
|
||||||
set path_position=""
|
set nix_tools=
|
||||||
set print_debug=""
|
set path_position=
|
||||||
set print_error=""
|
set print_debug=
|
||||||
set print_verbose=""
|
set print_error=
|
||||||
set print_warning=""
|
set print_verbose=
|
||||||
set time_init=""
|
set print_warning=
|
||||||
set verbose_output=""
|
set time_init=
|
||||||
|
set verbose_output=
|
||||||
|
set user_aliases=
|
||||||
|
|
||||||
exit /b
|
exit /b
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user