Commit Graph

509 Commits

Author SHA1 Message Date
Florian Schwalm
fc90722faa Prepend %GIT_INSTALL_ROOT%\cmd to path instead of appending it
The default setting for path enhancing is appending,
so the provided unix tools don't overwrite windows tools we may want to keep.
For Git this is undesired behavior, though, as we just compared git versions
to decide which one we want to use. The git directory thus needs to be prepended
to the path to make sure a call to git uses the version we selected.
2020-07-29 22:48:01 +02:00
Florian Schwalm
167c49ee6d Rewrite old calls to :verbose_output to working %lib_console% verbose_output 2020-07-29 22:46:35 +02:00
Florian Schwalm
0ed10e5e89 Reorder if-else-clauses in :compare_git_versions so last else block can be reached
It is hard to spot without the brackets, but the last else block - that resets %test_dir% and
logs in verbose mode that an older user git version will be ignored - can't actually be reached.
The else block is considered to belong to the if clause "if exist "%test_dir:~0,-4%\cmd\git.exe""
that will only ever be executed if ERRORLEVEL is greather than or equal to 0, thus if the test fails,
the following else if clause "else if ERRORLEVEL 0" will always succeed and the last else block will be ignored.
Using the vendored git version may still have worked because %GIT_INSTALL_ROOT% isn't set either way,
but to enable the log message I reordered if-else-clauses and brackets in the way I think the
original author intended them to work.
2020-07-29 22:39:46 +02:00
Florian Schwalm
cd50db3a7f Use ERRORLEVEL instead of %errorlevel% to compare git versions
%errorlevel% was always 0, even if the vendored git version was more current than the installed one
Usually exiting a batch script with "exit /b exitCode" as used in :compare_versions
sets %errorlevel% to the specified exit code
However, this may not work if %errorlevel% was set before with "Set errorlevel="
I didn't find the location where this might have happened,
but I saw the consequence of %errorlevel% always being 0
Thus I decided to use ERRORLEVEL instead as this will always work regardless of environment variable

For more information check https://ss64.com/nt/errorlevel.html
2020-07-29 22:25:49 +02:00
famoses
40c58417b2
quote time measures for timer.cmd
The startup time duration is calculated wrongly ( at least for me, on Windows 1909, with CmderMini 1.3.15.1010 ). I got something like "Elapsed Time: 80:36:1.00 (290161.00s total)" printed into the cmder consle window. I can be solved by quoting the time measures taken in `init.bat`. 

It seems that `time.cmd` fails in recognizing two arguments. In fact it did split the first time measure into two arguments and ignored the second time measure.
Example: 
from the two time measures
λ echo %CMDER_INIT_START% %CMDER_INIT_END%
12:53:44,34 12:53:54,04
The call to `time.cmd` created following output (i added echo commands to print variables start and end right after they got assigned the arguments)
start: 12:53:44
end:   34
2020-07-18 13:32:22 +02:00
Dax T Games
c6edbc0068
Merge pull request #2311 from daxgames/fix_path_enh_recurs
Fix and enhance enhance_path_recursive
2020-06-26 16:27:42 -04:00
Dax T Games
8781779636
Update init.bat
If CMDER_CONFIGURED==1 skip to :CMDER_CONFIGURED
2020-06-09 19:41:08 -04:00
Dax T Games
31c019b7e4
Update init.bat
Move skip to user config below clink enablement in cmder_configured == 1
2020-06-08 21:18:23 -04:00
Dax T Games
4d86559841
Update init.bat
Remove cmder_configured goto
2020-06-08 21:03:41 -04:00
Dax T. Games
a999d17f71 Allow setting cmder init.bat arg vars globally on windows. 2020-06-07 15:32:15 -04:00
Dax T. Games
04c784cb16 Allow setting cmder init.bat arg vars globally on windows. 2020-06-07 14:49:02 -04:00
Dax T. Games
b91bb84f3d fix cexec.cmd 2020-05-10 10:56:12 -04:00
Dax T. Games
1f5ea5e596 Fix and enhance enhance_path_recursive 2020-04-29 12:03:24 -04:00
wtof
2936abe2a5 Update git for windows to 2.26.2 2020-04-28 11:18:24 +08:00
Dax T. Games
be5ec648c4 Fix Cmder issue #2290 2020-04-06 10:15:00 -04:00
Dax T Games
2517f55f15
Merge branch 'master' into 1.3.15 2020-04-06 08:48:19 -04:00
Dax T. Games
1af12666e4 move git functions to git lib 2020-04-06 08:46:46 -04:00
Dax T. Games
93f8718489 move git functions to git lib 2020-04-06 08:20:26 -04:00
Michael Roy
1071221468
Fix an issue with clink.find_files() return order not always consistent, leading to .init.lua not being run first lua path being broken (#2278) 2020-03-14 13:01:06 +00:00
andyburgess
251968b4c6 Fixes #2247, fixes #2254 2020-02-21 11:52:52 -05:00
Dax T Games
0e37a4c2f9
Merge pull request #2222 from daxgames/1.3.14
1.3.14
2020-01-08 21:34:19 -05:00
Dax T. Games
492fc284f2 Fix issue #2214 2020-01-06 22:57:29 -05:00
Johannes Rappen
fe3d2034ef
Bump git-for-windows to v2.24.1.windows.2 2020-01-06 22:45:17 +01:00
Dax T. Games
180e72a6aa revert --no-log to fix windows 7 clink prompt 2020-01-05 13:52:23 -08:00
Dax T. Games
93cf865071 post-install fixes 2020-01-05 16:41:02 -05:00
Vladimir Kotikov
8df688bada
Update clink-completions
https://github.com/vladimir-kotikov/clink-completions/releases/tag/0.3.5
2019-12-05 10:53:32 +03:00
Dax T. Games
a857d8419c fixes for cmd:cmder init script 2019-12-04 16:04:16 -05:00
Dax T. Games
0cf1c5e2eb fix 2019-11-23 18:13:03 -05:00
Dax T. Games
2428e8529f dd per shell git opt out 2019-11-23 11:54:53 -05:00
Dax T. Games
589b48d06e update conemu 2019-11-09 17:50:57 -05:00
Dax T. Games
3ee244e4c1 allow git prompt status opt out for powershell and bash 2019-11-09 16:36:16 -05:00
Dax T. Games
44bc089ee4 move lambda to cmder prompt method for easier user change 2019-11-03 14:14:47 -05:00
Dax T. Games
6ab4599a4d separate powershell functions from profile.ps1 2019-11-03 13:07:20 -05:00
Dax T. Games
dac4b27e28 separate powershell functions from profile.ps1 2019-11-03 12:59:36 -05:00
Dax T. Games
661f59d0fb Fix #2191 profile.ps1: CheckGit does not export $gitLoaded 2019-11-03 12:36:28 -05:00
Dax T. Games
44a8bf5802 add ability to disable git 2019-11-03 11:00:27 -05:00
Dax T Games
f1a9721256
Update init.bat 2019-10-22 22:44:17 -04:00
Dax Games
34468ef2fd cleanup 2019-08-22 06:20:19 -04:00
Dax Games
5cb8021864 Merge branch 'fix_path_with!' of https://github.com/daxgames/cmder into fix_path_with! 2019-08-22 06:11:18 -04:00
Greg Lucas
7f69f15637 Fix #2192: Set default prompt hooks before loading user profile 2019-10-22 11:17:13 -04:00
Dax T. Games
468dba474e fixes 2019-10-13 15:47:25 -04:00
Dax T. Games
db42252ef2 cleanup 2019-10-13 10:18:04 -04:00
Dax T. Games
57b328b209 cleanup 2019-10-13 10:15:26 -04:00
Dax T. Games
e8b33aa45b Merge branch 'master' of https://github.com/cmderdev/cmder into fix_path_with! 2019-10-13 10:11:25 -04:00
Dax T. Games
377d97e56a fix path with ! in dir 2019-10-13 10:07:23 -04:00
Benjamin Staneck
4575ac3209 ⬆️ Update ConEmu to 190714
Release Notes: https://conemu.github.io/en/Whats_New.html
2019-10-12 19:45:23 +02:00
Benjamin Staneck
035f209bc4 ⬆️ Update Git to 2.23.0
Release Notes: https://github.com/git-for-windows/git/releases/tag/v2.23.0.windows.1
2019-10-12 19:43:46 +02:00
Dax T Games
19a2fd11e3 Clink Completions 0.3.4 (#2177)
* update Changelog, clink-completions 0.3.4, fix ps fg color

* Update CHANGELOG.md

* Update CHANGELOG.md
2019-09-28 02:21:47 +02:00
Dax T. Games
3a44bc809d add ~ match to vendor/clink.lua/ 2019-09-27 18:17:24 -04:00
Dax T. Games
45e5600249 update Changelog, clink 0.3.4, fix ps fg color 2019-09-26 18:07:25 -04:00