mirror of
https://github.com/junegunn/fzf.git
synced 2025-08-03 05:32:08 -07:00
Compare commits
4 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
b3010a4624 | ||
|
7d53051ec8 | ||
|
ed893c5f47 | ||
|
a4eb3323da |
@@ -1,6 +1,11 @@
|
|||||||
CHANGELOG
|
CHANGELOG
|
||||||
=========
|
=========
|
||||||
|
|
||||||
|
0.10.8
|
||||||
|
------
|
||||||
|
|
||||||
|
- Fixed panic when trying to set colors after colors are disabled (#370)
|
||||||
|
|
||||||
0.10.7
|
0.10.7
|
||||||
------
|
------
|
||||||
|
|
||||||
|
4
install
4
install
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
[[ "$@" =~ --pre ]] && version=0.10.7 pre=1 ||
|
[[ "$@" =~ --pre ]] && version=0.10.8 pre=1 ||
|
||||||
version=0.10.7 pre=0
|
version=0.10.8 pre=0
|
||||||
|
|
||||||
cd $(dirname $BASH_SOURCE)
|
cd $(dirname $BASH_SOURCE)
|
||||||
fzf_base=$(pwd)
|
fzf_base=$(pwd)
|
||||||
|
@@ -21,7 +21,7 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
THE SOFTWARE.
|
THE SOFTWARE.
|
||||||
..
|
..
|
||||||
.TH fzf 1 "Oct 2015" "fzf 0.10.7" "fzf - a command-line fuzzy finder"
|
.TH fzf 1 "Oct 2015" "fzf 0.10.8" "fzf - a command-line fuzzy finder"
|
||||||
|
|
||||||
.SH NAME
|
.SH NAME
|
||||||
fzf - a command-line fuzzy finder
|
fzf - a command-line fuzzy finder
|
||||||
|
@@ -416,6 +416,9 @@ function! s:cmd_callback(lines) abort
|
|||||||
set noautochdir
|
set noautochdir
|
||||||
for item in a:lines
|
for item in a:lines
|
||||||
execute cmd s:escape(item)
|
execute cmd s:escape(item)
|
||||||
|
if exists('#BufEnter') && isdirectory(item)
|
||||||
|
doautocmd BufEnter
|
||||||
|
endif
|
||||||
endfor
|
endfor
|
||||||
finally
|
finally
|
||||||
let &autochdir = autochdir
|
let &autochdir = autochdir
|
||||||
|
@@ -8,7 +8,7 @@ import (
|
|||||||
|
|
||||||
const (
|
const (
|
||||||
// Current version
|
// Current version
|
||||||
version = "0.10.7"
|
version = "0.10.8"
|
||||||
|
|
||||||
// Core
|
// Core
|
||||||
coordinatorDelayMax time.Duration = 100 * time.Millisecond
|
coordinatorDelayMax time.Duration = 100 * time.Millisecond
|
||||||
|
@@ -380,8 +380,11 @@ func parseTiebreak(str string) tiebreak {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func dupeTheme(theme *curses.ColorTheme) *curses.ColorTheme {
|
func dupeTheme(theme *curses.ColorTheme) *curses.ColorTheme {
|
||||||
dupe := *theme
|
if theme != nil {
|
||||||
return &dupe
|
dupe := *theme
|
||||||
|
return &dupe
|
||||||
|
}
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func parseTheme(defaultTheme *curses.ColorTheme, str string) *curses.ColorTheme {
|
func parseTheme(defaultTheme *curses.ColorTheme, str string) *curses.ColorTheme {
|
||||||
@@ -402,7 +405,7 @@ func parseTheme(defaultTheme *curses.ColorTheme, str string) *curses.ColorTheme
|
|||||||
}
|
}
|
||||||
// Color is disabled
|
// Color is disabled
|
||||||
if theme == nil {
|
if theme == nil {
|
||||||
errorExit("colors disabled; cannot customize colors")
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
pair := strings.Split(str, ":")
|
pair := strings.Split(str, ":")
|
||||||
|
@@ -316,3 +316,15 @@ func TestColorSpec(t *testing.T) {
|
|||||||
t.Errorf("using default colors")
|
t.Errorf("using default colors")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func TestParseNilTheme(t *testing.T) {
|
||||||
|
var theme *curses.ColorTheme
|
||||||
|
newTheme := parseTheme(theme, "prompt:12")
|
||||||
|
if newTheme != nil {
|
||||||
|
t.Errorf("color is disabled. keep it that way.")
|
||||||
|
}
|
||||||
|
newTheme = parseTheme(theme, "prompt:12,dark,prompt:13")
|
||||||
|
if newTheme.Prompt != 13 {
|
||||||
|
t.Errorf("color should now be enabled and customized")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Reference in New Issue
Block a user