Chris Antos
5305ebd4a6
Use Clink async prompt filtering for git.
...
`git status` and `git diff` can be slow in large repos. Clink v1.2.10
and higher support using Lua coroutines to do expensive parts of prompt
filtering in the background. When the expensive parts complete, the
prompt gets refreshed.
This means even large repos can have fast prompts PLUS git status all
the time!
This change should be backward/forward compatible with both older and
newer versions of Clink (of course only newer versions will gain the
benefit).
2021-05-31 21:29:19 -07:00
dgames
56b04fc9ce
fix unknown color and code dedup
2021-05-31 10:53:18 -04:00
dgames
aebe37bd28
fix default unknown color
2021-05-30 08:56:05 -04:00
dgames
a41fad80d5
Merge branch 'status-branchonly' into status-branchonly-dax
2021-05-30 07:56:01 -04:00
dgames
c9acb13d0b
Fix cmder no status prompt
2021-05-30 07:50:48 -04:00
dgames
03d0f913ea
fixing branch only
2021-05-30 07:27:16 -04:00
Ian Craig
9df8f1a92a
Revert to boolean, keep branch name when status=false
2021-05-25 17:53:41 -07:00
Ian Craig
c262934822
Add branchonly option to cmdstatus
2021-05-20 17:53:05 -07:00
Dax T. Games
6d79ed5eb2
Merge branch 'master' of https://github.com/cmderdev/cmder into fix_configurable_prompt
2021-05-02 21:04:23 -04:00
Dax T. Games
11fb1b3a50
do not rely on config\cmder_prompt_config.lua
2021-05-02 20:56:02 -04:00
Abhishek Aryan
e8df3ef247
Refactor the env substution logic
...
And some prompt cleanup
2021-05-02 21:53:22 +03:00
Dax T. Games
e0cb86d738
parametrized status colors
2021-04-11 18:42:43 -04:00
Dax T. Games
0ef76ee2d3
add configurable prompt
2021-04-11 18:28:43 -04:00
Dax T. Games
6027ac31c4
set global cmderGitStatusOptIn var for use in clink-completions
2021-04-07 22:30:53 -04:00
dgames
0fd2d9c8a8
CHANGELOG.md
2021-03-25 19:14:18 -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
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
44a8bf5802
add ability to disable git
2019-11-03 11:00:27 -05:00
Dax T. Games
3a44bc809d
add ~ match to vendor/clink.lua/
2019-09-27 18:17:24 -04:00
Joshua Webb
52eea5fe9f
Close file handles in clink.lua
2019-04-19 16:16:45 +10:00
b0bh00d
89499f2a60
Replaced the 'hg -id' command with the 'hg branch' and 'hg status' pair for improved response times.
2019-01-20 21:02:31 -07:00
b0bh00d
5a48e568a8
Updated the HG prompt code to use the '-ib' option to 'hg id' to always have the branch name available.
2019-01-01 11:17:53 -07:00
Martin Böhm
51e75d4bb5
add percent escaping for string.gsub ( #1991 )
...
In `string.gsub()`, the `%` character has special meaning and must be escaped to be treated verbatim, otherwise the "invalid use of '%' in replacement string" warning will show up.
This adds a verbatim() function for that purpose. It fixes this warning for situations where `'%` characters are in the current path (cwd), version control branch names, or in the previous `PROMPT` set by the user.
2018-12-19 21:17:45 +01:00
Dax T. Games
749ce17dbe
git prompt yellow
2018-09-16 15:53:49 -05:00
Dax T. Games
1d36ba4ed4
fix user lua and git detection
2018-09-16 10:18:10 -05:00
Benjamin Staneck
0d2e16c653
Merge pull request #1871 from daxgames/user_lua
...
Embed 'alias' functionality into 'vendor\bin' and Load User Lua files
2018-09-13 22:41:19 +02:00
Dax T. Games
059a31618b
cleanup
2018-09-01 15:32:43 -04:00
Dax T. Games
e69e7f9b82
run user lua afer cmder lua
2018-09-01 14:59:40 -04:00
Dax T. Games
e93231114f
Merge remote-tracking branch 'origin' into user_lua
2018-09-01 14:35:41 -04:00
Bob Hood
0f99f66b42
Refactored the Mercurial prompt code to be more efficient.
2018-07-06 14:34:48 -06:00
Benjamin Staneck
e3cdf43afc
better fix for #1265
2018-06-07 18:29:48 +02:00
Benjamin Staneck
6c016788d4
Revert "sanitize dir before assigning to prompt"
...
This reverts commit 0b2d7bd655
.
2018-06-07 17:04:06 +02:00
Benjamin Staneck
0b2d7bd655
sanitize dir before assigning to prompt
...
Fixes #1265
2018-06-07 16:08:53 +02:00
Dax T. Games
864f778099
load user clink
2018-03-24 08:03:28 -05:00
David Refoua
ff2e09849e
simplified λ prompt in lua ( #1693 )
...
* replace lambda with $
* simplified $ prompt
The $ character for the prompt is defined only once instead of twice
* fixed λ prompt
2018-03-08 12:01:48 +01:00
Benjamin Staneck
a71c6a50ad
always close open file handles
...
Fixes #1619
2018-01-16 21:59:11 +01:00
Benjamin Staneck
5e703796c9
git should no longer require extra file closing after the recent changes
2018-01-09 14:52:48 +01:00
Benjamin Staneck
b88a01822f
re-order git/hg/svn functions
2018-01-09 14:52:48 +01:00
Benjamin Staneck
145a1b144b
Fix for the last
2018-01-06 23:52:24 +01:00
Benjamin Staneck
29c5e83975
Replace --no-lock-index with the new --no-optional-locks
2018-01-06 23:43:50 +01:00
Benjamin Staneck
46d468aea0
touch up clink.lua
2017-11-03 13:13:51 +01:00
Benjamin Staneck
a8d32611a9
Fix lamda color after a ConEmu change
...
Seems like https://github.com/Maximus5/ConEmu/issues/1288 caused this
2017-10-29 10:46:38 +01:00
Benjamin Staneck
399999d7f7
Merge pull request #1299 from alexandr-san4ez/master
...
Changed the way directory is defined .git
2017-04-07 02:42:18 +02:00
dr024625
9977c0563d
Adding svn support
2017-04-03 21:07:41 -05:00
Alexandr
018cc9ceda
Changed the way directory is defined .git
...
clink.find_dirs - do not specify the directory if there is Cyrillic in the way.
clink.is_dir - more logical and faster.
2017-03-09 19:22:13 +03:00
Alexandr
c8adf424e2
Added closing process in get_git_status ( #1 )
...
After execution command: git add * git continues to operate without closing. The process does not stop.
2016-09-27 22:59:09 +02:00
Benjamin Staneck
bb312ad74b
try --no-lock-index for Git
2016-09-17 22:48:02 +02:00
Jan Schulz
6b10771312
Parse the original prompt for cwd and env names
...
clink.get_cwd() is returning a string which is differently encoded than what
clink.prompt.value expects. This results in garbled path names if the path
condains non-ASCII chars. The (arguable hacky) solution is to parse the old
prompt for the current directory (which breaks if the user sets a PROMPT env var
which is incompatible to the regex used here...).
Also parse out a environment name set by systems like virtualenv or conda: this
could be done more specifically by targeting each such system and using the
usually set environment variable but this would mean that we would have to do
that for each and every such system out there and that is probably not a sane
idea...
2016-08-09 13:45:36 +02:00
Benjamin Staneck
13fd41eb82
change how we ask hg for the status
...
closes #1035
Thanks @raleighr3
2016-07-30 00:36:32 +02:00