| ... | ... |
@@ -48,7 +48,7 @@ Using MacPorts |
| 48 | 48 |
|
| 49 | 49 |
**[FreeBSD](https://www.freebsd.org/cgi/ports.cgi?query=fzy&stype=all)**: `pkg install fzy` |
| 50 | 50 |
|
| 51 |
-**[Gentoo Linux](https://packages.gentoo.org/packages/app-shells/fzy)**: `emerge -av app-shells/fzy` |
|
| 51 |
+**[Gentoo Linux](https://packages.gentoo.org/packages/app-text/fzy)**: `emerge -av app-text/fzy` |
|
| 52 | 52 |
|
| 53 | 53 |
**[Ubuntu](https://packages.ubuntu.com/search?keywords=fzy&searchon=names&suite=bionic§ion=all)/[Debian](https://packages.debian.org/search?keywords=fzy&searchon=names&suite=all§ion=all)**: `apt-get install fzy` |
| 54 | 54 |
|
| ... | ... |
@@ -16,6 +16,8 @@ fzy works great btw |
| 16 | 16 |
-<a href="https://twitter.com/alexblackie/status/719297828892188672">@alexblackie</a> |
| 17 | 17 |
</blockquote> |
| 18 | 18 |
|
| 19 |
+ [](https://github.com/jhawthorn/fzy/actions) |
|
| 20 |
+ |
|
| 19 | 21 |
## Why use this over fzf, pick, selecta, ctrlp, ...? |
| 20 | 22 |
|
| 21 | 23 |
fzy is faster and shows better results than other fuzzy finders. |
| ... | ... |
@@ -16,8 +16,6 @@ fzy works great btw |
| 16 | 16 |
-<a href="https://twitter.com/alexblackie/status/719297828892188672">@alexblackie</a> |
| 17 | 17 |
</blockquote> |
| 18 | 18 |
|
| 19 |
-[](https://travis-ci.org/jhawthorn/fzy) |
|
| 20 |
- |
|
| 21 | 19 |
## Why use this over fzf, pick, selecta, ctrlp, ...? |
| 22 | 20 |
|
| 23 | 21 |
fzy is faster and shows better results than other fuzzy finders. |
OS X's `find` command requires a path. By changing `find -type f` to
`find . -type f` we can make sure this is compatible with OS X without
losing its Linux support.
| ... | ... |
@@ -85,9 +85,9 @@ function! FzyCommand(choice_command, vim_command) |
| 85 | 85 |
endif |
| 86 | 86 |
endfunction |
| 87 | 87 |
|
| 88 |
-nnoremap <leader>e :call FzyCommand("find -type f", ":e")<cr>
|
|
| 89 |
-nnoremap <leader>v :call FzyCommand("find -type f", ":vs")<cr>
|
|
| 90 |
-nnoremap <leader>s :call FzyCommand("find -type f", ":sp")<cr>
|
|
| 88 |
+nnoremap <leader>e :call FzyCommand("find . -type f", ":e")<cr>
|
|
| 89 |
+nnoremap <leader>v :call FzyCommand("find . -type f", ":vs")<cr>
|
|
| 90 |
+nnoremap <leader>s :call FzyCommand("find . -type f", ":sp")<cr>
|
|
| 91 | 91 |
``` |
| 92 | 92 |
|
| 93 | 93 |
Any program can be used to filter files presented through fzy. [ag (the silver searcher)](https://github.com/ggreer/the_silver_searcher) can be used to ignore files specified by `.gitignore`. |
| ... | ... |
@@ -114,3 +114,4 @@ It prefers shorter candidates: `test` matches <tt><b>test</b>s</tt> over <tt><b> |
| 114 | 114 |
|
| 115 | 115 |
* [fzy.js](https://github.com/jhawthorn/fzy.js) Javascript port |
| 116 | 116 |
|
| 117 |
+ |
| ... | ... |
@@ -110,3 +110,7 @@ It prefers shorter matches: `abce` matches <tt><b>abc</b>d<b>e</b>f</tt> over <t |
| 110 | 110 |
|
| 111 | 111 |
It prefers shorter candidates: `test` matches <tt><b>test</b>s</tt> over <tt><b>test</b>ing</b></tt>. |
| 112 | 112 |
|
| 113 |
+## See Also |
|
| 114 |
+ |
|
| 115 |
+* [fzy.js](https://github.com/jhawthorn/fzy.js) Javascript port |
|
| 116 |
+ |
| ... | ... |
@@ -1,7 +1,8 @@ |
| 1 | 1 |
 |
| 2 | 2 |
|
| 3 |
-**fzy** is a fast, simple fuzzy text selector for the terminal with an advanced [scoring |
|
| 4 |
-algorithm](#sorting). |
|
| 3 |
+**fzy** is a fast, simple fuzzy text selector for the terminal with an advanced scoring algorithm. |
|
| 4 |
+ |
|
| 5 |
+[Try it out online!](http://jhawthorn.github.io/fzy-demo) |
|
| 5 | 6 |
|
| 6 | 7 |
 |
| 7 | 8 |
|
| ... | ... |
@@ -43,17 +43,17 @@ Using MacPorts |
| 43 | 43 |
|
| 44 | 44 |
sudo port install fzy |
| 45 | 45 |
|
| 46 |
-**Arch Linux/MSYS2**: `pacman -S fzy` |
|
| 46 |
+**[Arch Linux](https://www.archlinux.org/packages/?sort=&q=fzy&maintainer=&flagged=)/MSYS2**: `pacman -S fzy` |
|
| 47 | 47 |
|
| 48 |
-**FreeBSD**: `pkg install fzy` |
|
| 48 |
+**[FreeBSD](https://www.freebsd.org/cgi/ports.cgi?query=fzy&stype=all)**: `pkg install fzy` |
|
| 49 | 49 |
|
| 50 |
-**Gentoo Linux**: `emerge -av app-shells/fzy` |
|
| 50 |
+**[Gentoo Linux](https://packages.gentoo.org/packages/app-shells/fzy)**: `emerge -av app-shells/fzy` |
|
| 51 | 51 |
|
| 52 |
-**Ubuntu/Debian 64-bit**: `apt-get install fzy` |
|
| 52 |
+**[Ubuntu](https://packages.ubuntu.com/search?keywords=fzy&searchon=names&suite=bionic§ion=all)/[Debian](https://packages.debian.org/search?keywords=fzy&searchon=names&suite=all§ion=all)**: `apt-get install fzy` |
|
| 53 | 53 |
|
| 54 |
-**pkgsrc (NetBSD and others)**: `pkgin install fzy` |
|
| 54 |
+**[pkgsrc](http://pkgsrc.se/misc/fzy) (NetBSD and others)**: `pkgin install fzy` |
|
| 55 | 55 |
|
| 56 |
-**openSUSE**: `zypper in fzy` |
|
| 56 |
+**[openSUSE](https://software.opensuse.org/package/fzy)**: `zypper in fzy` |
|
| 57 | 57 |
|
| 58 | 58 |
### From source |
| 59 | 59 |
|
| ... | ... |
@@ -33,52 +33,35 @@ Rather than clearing the screen, fzy displays its interface directly below the c |
| 33 | 33 |
|
| 34 | 34 |
## Installation |
| 35 | 35 |
|
| 36 |
-### From source |
|
| 37 |
- |
|
| 38 |
- make |
|
| 39 |
- sudo make install |
|
| 40 |
- |
|
| 41 |
-The `PREFIX` environment variable can be used to specify the install location, |
|
| 42 |
-the default is `/usr/local`. |
|
| 43 |
- |
|
| 44 |
-### Arch Linux/MSYS2 |
|
| 45 |
- |
|
| 46 |
-fzy is available in the `community` repo. |
|
| 47 |
- |
|
| 48 |
- sudo pacman -S fzy |
|
| 49 |
- |
|
| 50 |
-### Fedora/Redhat/CentOS |
|
| 51 |
- |
|
| 52 |
- sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.9/fzy-0.9-1.x86_64.rpm |
|
| 53 |
- |
|
| 54 |
-### FreeBSD |
|
| 36 |
+**macOS** |
|
| 55 | 37 |
|
| 56 |
- pkg install fzy |
|
| 38 |
+Using Homebrew |
|
| 57 | 39 |
|
| 58 |
-### Gentoo Linux |
|
| 40 |
+ brew install fzy |
|
| 59 | 41 |
|
| 60 |
-fzy is available in the main repo. |
|
| 42 |
+Using MacPorts |
|
| 61 | 43 |
|
| 62 |
- emerge -av app-shells/fzy |
|
| 44 |
+ sudo port install fzy |
|
| 63 | 45 |
|
| 64 |
-### macOS |
|
| 46 |
+**Arch Linux/MSYS2**: `pacman -S fzy` |
|
| 65 | 47 |
|
| 66 |
-Using Homebrew |
|
| 48 |
+**FreeBSD**: `pkg install fzy` |
|
| 67 | 49 |
|
| 68 |
- brew install fzy |
|
| 50 |
+**Gentoo Linux**: `emerge -av app-shells/fzy` |
|
| 69 | 51 |
|
| 70 |
-Using MacPorts |
|
| 52 |
+**Ubuntu/Debian 64-bit**: `apt-get install fzy` |
|
| 71 | 53 |
|
| 72 |
- sudo port install fzy |
|
| 54 |
+**pkgsrc (NetBSD and others)**: `pkgin install fzy` |
|
| 73 | 55 |
|
| 74 |
-### Ubuntu/Debian 64-bit |
|
| 56 |
+**openSUSE**: `zypper in fzy` |
|
| 75 | 57 |
|
| 76 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.9/fzy_0.9-1_amd64.deb |
|
| 77 |
- sudo dpkg -i fzy_0.9-1_amd64.deb |
|
| 58 |
+### From source |
|
| 78 | 59 |
|
| 79 |
-### pkgsrc (NetBSD and others) |
|
| 60 |
+ make |
|
| 61 |
+ sudo make install |
|
| 80 | 62 |
|
| 81 |
- sudo pkgin install fzy |
|
| 63 |
+The `PREFIX` environment variable can be used to specify the install location, |
|
| 64 |
+the default is `/usr/local`. |
|
| 82 | 65 |
|
| 83 | 66 |
## Usage |
| 84 | 67 |
|
While here, sort the list of distros and operating systems.
| ... | ... |
@@ -41,30 +41,19 @@ Rather than clearing the screen, fzy displays its interface directly below the c |
| 41 | 41 |
The `PREFIX` environment variable can be used to specify the install location, |
| 42 | 42 |
the default is `/usr/local`. |
| 43 | 43 |
|
| 44 |
-### MacOS |
|
| 45 |
- |
|
| 46 |
-Using Homebrew |
|
| 47 |
- |
|
| 48 |
- brew install fzy |
|
| 49 |
- |
|
| 50 |
-Using MacPorts |
|
| 51 |
- |
|
| 52 |
- sudo port install fzy |
|
| 44 |
+### Arch Linux/MSYS2 |
|
| 53 | 45 |
|
| 54 |
-### Ubuntu/Debian 64-bit |
|
| 46 |
+fzy is available in the `community` repo. |
|
| 55 | 47 |
|
| 56 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.9/fzy_0.9-1_amd64.deb |
|
| 57 |
- sudo dpkg -i fzy_0.9-1_amd64.deb |
|
| 48 |
+ sudo pacman -S fzy |
|
| 58 | 49 |
|
| 59 | 50 |
### Fedora/Redhat/CentOS |
| 60 | 51 |
|
| 61 | 52 |
sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.9/fzy-0.9-1.x86_64.rpm |
| 62 | 53 |
|
| 63 |
-### Arch Linux/MSYS2 |
|
| 64 |
- |
|
| 65 |
-fzy is available in the `community` repo. |
|
| 54 |
+### FreeBSD |
|
| 66 | 55 |
|
| 67 |
- sudo pacman -S fzy |
|
| 56 |
+ pkg install fzy |
|
| 68 | 57 |
|
| 69 | 58 |
### Gentoo Linux |
| 70 | 59 |
|
| ... | ... |
@@ -72,6 +61,21 @@ fzy is available in the main repo. |
| 72 | 61 |
|
| 73 | 62 |
emerge -av app-shells/fzy |
| 74 | 63 |
|
| 64 |
+### macOS |
|
| 65 |
+ |
|
| 66 |
+Using Homebrew |
|
| 67 |
+ |
|
| 68 |
+ brew install fzy |
|
| 69 |
+ |
|
| 70 |
+Using MacPorts |
|
| 71 |
+ |
|
| 72 |
+ sudo port install fzy |
|
| 73 |
+ |
|
| 74 |
+### Ubuntu/Debian 64-bit |
|
| 75 |
+ |
|
| 76 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.9/fzy_0.9-1_amd64.deb |
|
| 77 |
+ sudo dpkg -i fzy_0.9-1_amd64.deb |
|
| 78 |
+ |
|
| 75 | 79 |
### pkgsrc (NetBSD and others) |
| 76 | 80 |
|
| 77 | 81 |
sudo pkgin install fzy |
| ... | ... |
@@ -66,6 +66,10 @@ fzy is available in the `community` repo. |
| 66 | 66 |
|
| 67 | 67 |
sudo pacman -S fzy |
| 68 | 68 |
|
| 69 |
+### pkgsrc (NetBSD and others) |
|
| 70 |
+ |
|
| 71 |
+ sudo pkgin install fzy |
|
| 72 |
+ |
|
| 69 | 73 |
## Usage |
| 70 | 74 |
|
| 71 | 75 |
fzy is a drop in replacement for [selecta](https://github.com/garybernhardt/selecta), and can be used with its [usage examples](https://github.com/garybernhardt/selecta#usage-examples). |
This is not supported:
$ sudo brew install fzy
Error: Running Homebrew as root is extremely dangerous and no longer supported.
As Homebrew does not drop privileges on installation you would be giving all
build scripts full access to your system.
| ... | ... |
@@ -62,10 +62,9 @@ Using MacPorts |
| 62 | 62 |
|
| 63 | 63 |
### Arch Linux |
| 64 | 64 |
|
| 65 |
-fzy is available |
|
| 66 |
-[in the AUR](https://aur.archlinux.org/packages/fzy/) |
|
| 67 |
-with a very simple |
|
| 68 |
-[PKGBUILD](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=fzy) |
|
| 65 |
+fzy is available in the `community` repo. |
|
| 66 |
+ |
|
| 67 |
+ sudo pacman -S fzy |
|
| 69 | 68 |
|
| 70 | 69 |
## Usage |
| 71 | 70 |
|
| ... | ... |
@@ -41,6 +41,16 @@ Rather than clearing the screen, fzy displays its interface directly below the c |
| 41 | 41 |
The `PREFIX` environment variable can be used to specify the install location, |
| 42 | 42 |
the default is `/usr/local`. |
| 43 | 43 |
|
| 44 |
+### MacOS |
|
| 45 |
+ |
|
| 46 |
+Using Homebrew |
|
| 47 |
+ |
|
| 48 |
+ sudo brew install fzy |
|
| 49 |
+ |
|
| 50 |
+Using MacPorts |
|
| 51 |
+ |
|
| 52 |
+ sudo port install fzy |
|
| 53 |
+ |
|
| 44 | 54 |
### Ubuntu/Debian 64-bit |
| 45 | 55 |
|
| 46 | 56 |
wget https://github.com/jhawthorn/fzy/releases/download/0.9/fzy_0.9-1_amd64.deb |
| ... | ... |
@@ -57,11 +67,6 @@ fzy is available |
| 57 | 67 |
with a very simple |
| 58 | 68 |
[PKGBUILD](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=fzy) |
| 59 | 69 |
|
| 60 |
-### MacOS |
|
| 61 |
- |
|
| 62 |
- brew install fzy # Homebrew |
|
| 63 |
- sudo port install fzy # MacPorts |
|
| 64 |
- |
|
| 65 | 70 |
## Usage |
| 66 | 71 |
|
| 67 | 72 |
fzy is a drop in replacement for [selecta](https://github.com/garybernhardt/selecta), and can be used with its [usage examples](https://github.com/garybernhardt/selecta#usage-examples). |
| ... | ... |
@@ -57,9 +57,10 @@ fzy is available |
| 57 | 57 |
with a very simple |
| 58 | 58 |
[PKGBUILD](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=fzy) |
| 59 | 59 |
|
| 60 |
-### OS X via Homebrew |
|
| 60 |
+### MacOS |
|
| 61 | 61 |
|
| 62 |
- brew install fzy |
|
| 62 |
+ brew install fzy # Homebrew |
|
| 63 |
+ sudo port install fzy # MacPorts |
|
| 63 | 64 |
|
| 64 | 65 |
## Usage |
| 65 | 66 |
|
| ... | ... |
@@ -90,9 +90,9 @@ nnoremap <leader>s :call FzyCommand("find -type f", ":sp")<cr>
|
| 90 | 90 |
Any program can be used to filter files presented through fzy. [ag (the silver searcher)](https://github.com/ggreer/the_silver_searcher) can be used to ignore files specified by `.gitignore`. |
| 91 | 91 |
|
| 92 | 92 |
``` vim |
| 93 |
-nnoremap <leader>e :call FzyCommand("ag . -l -g ''", ":e")<cr>
|
|
| 94 |
-nnoremap <leader>v :call FzyCommand("ag . -l -g ''", ":vs")<cr>
|
|
| 95 |
-nnoremap <leader>s :call FzyCommand("ag . -l -g ''", ":sp")<cr>
|
|
| 93 |
+nnoremap <leader>e :call FzyCommand("ag . --silent -l -g ''", ":e")<cr>
|
|
| 94 |
+nnoremap <leader>v :call FzyCommand("ag . --silent -l -g ''", ":vs")<cr>
|
|
| 95 |
+nnoremap <leader>s :call FzyCommand("ag . --silent -l -g ''", ":sp")<cr>
|
|
| 96 | 96 |
``` |
| 97 | 97 |
|
| 98 | 98 |
## Sorting |
| ... | ... |
@@ -43,12 +43,12 @@ the default is `/usr/local`. |
| 43 | 43 |
|
| 44 | 44 |
### Ubuntu/Debian 64-bit |
| 45 | 45 |
|
| 46 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.8/fzy_0.8-1_amd64.deb |
|
| 47 |
- sudo dpkg -i fzy_0.8-1_amd64.deb |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.9/fzy_0.9-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.9-1_amd64.deb |
|
| 48 | 48 |
|
| 49 | 49 |
### Fedora/Redhat/CentOS |
| 50 | 50 |
|
| 51 |
- sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.8/fzy-0.8-1.x86_64.rpm |
|
| 51 |
+ sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.9/fzy-0.9-1.x86_64.rpm |
|
| 52 | 52 |
|
| 53 | 53 |
### Arch Linux |
| 54 | 54 |
|
See https://github.com/Homebrew/homebrew-core/pull/11513
| ... | ... |
@@ -68,7 +68,7 @@ fzy is a drop in replacement for [selecta](https://github.com/garybernhardt/sele |
| 68 | 68 |
|
| 69 | 69 |
### Use with Vim |
| 70 | 70 |
|
| 71 |
-fzy can be integrated very simply in vim. There is also [fzy-vim](https://github.com/Dkendal/fzy-vim), a more fully featured vim plugin. |
|
| 71 |
+fzy can be easily integrated with vim. |
|
| 72 | 72 |
|
| 73 | 73 |
``` vim |
| 74 | 74 |
function! FzyCommand(choice_command, vim_command) |
| ... | ... |
@@ -43,12 +43,12 @@ the default is `/usr/local`. |
| 43 | 43 |
|
| 44 | 44 |
### Ubuntu/Debian 64-bit |
| 45 | 45 |
|
| 46 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.7/fzy_0.7-1_amd64.deb |
|
| 47 |
- sudo dpkg -i fzy_0.7-1_amd64.deb |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.8/fzy_0.8-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.8-1_amd64.deb |
|
| 48 | 48 |
|
| 49 | 49 |
### Fedora/Redhat/CentOS |
| 50 | 50 |
|
| 51 |
- sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.7/fzy-0.7-1.x86_64.rpm |
|
| 51 |
+ sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.8/fzy-0.8-1.x86_64.rpm |
|
| 52 | 52 |
|
| 53 | 53 |
### Arch Linux |
| 54 | 54 |
|
| ... | ... |
@@ -43,12 +43,12 @@ the default is `/usr/local`. |
| 43 | 43 |
|
| 44 | 44 |
### Ubuntu/Debian 64-bit |
| 45 | 45 |
|
| 46 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.6/fzy_0.6-1_amd64.deb |
|
| 47 |
- sudo dpkg -i fzy_0.6-1_amd64.deb |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.7/fzy_0.7-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.7-1_amd64.deb |
|
| 48 | 48 |
|
| 49 | 49 |
### Fedora/Redhat/CentOS |
| 50 | 50 |
|
| 51 |
- sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.6/fzy-0.6-1.x86_64.rpm |
|
| 51 |
+ sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.7/fzy-0.7-1.x86_64.rpm |
|
| 52 | 52 |
|
| 53 | 53 |
### Arch Linux |
| 54 | 54 |
|
| ... | ... |
@@ -43,12 +43,12 @@ the default is `/usr/local`. |
| 43 | 43 |
|
| 44 | 44 |
### Ubuntu/Debian 64-bit |
| 45 | 45 |
|
| 46 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.5/fzy_0.5-1_amd64.deb |
|
| 47 |
- sudo dpkg -i fzy_0.5-1_amd64.deb |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.6/fzy_0.6-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.6-1_amd64.deb |
|
| 48 | 48 |
|
| 49 | 49 |
### Fedora/Redhat/CentOS |
| 50 | 50 |
|
| 51 |
- sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.5/fzy-0.5-1.x86_64.rpm |
|
| 51 |
+ sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.6/fzy-0.6-1.x86_64.rpm |
|
| 52 | 52 |
|
| 53 | 53 |
### Arch Linux |
| 54 | 54 |
|
| ... | ... |
@@ -43,12 +43,12 @@ the default is `/usr/local`. |
| 43 | 43 |
|
| 44 | 44 |
### Ubuntu/Debian 64-bit |
| 45 | 45 |
|
| 46 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.4/fzy_0.4-1_amd64.deb |
|
| 47 |
- sudo dpkg -i fzy_0.4-1_amd64.deb |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.5/fzy_0.5-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.5-1_amd64.deb |
|
| 48 | 48 |
|
| 49 | 49 |
### Fedora/Redhat/CentOS |
| 50 | 50 |
|
| 51 |
- sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.4/fzy-0.4-1.x86_64.rpm |
|
| 51 |
+ sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.5/fzy-0.5-1.x86_64.rpm |
|
| 52 | 52 |
|
| 53 | 53 |
### Arch Linux |
| 54 | 54 |
|
Unfortunately can't host this from the github repo due to
https://github.com/isaacs/github/issues/316
Added logo to repo instead of hotlinking. Also cropped the image to
better line up with the rest of the text in the README.
Logo by Victoria, BC artist Nick Picard
https://www.instagram.com/nick.picard/
| ... | ... |
@@ -1,6 +1,6 @@ |
| 1 |
-# fzy |
|
| 1 |
+<img src="http://i.hawth.ca/u/fzy-200.png" width="200" height="116" alt="fzy" /> |
|
| 2 | 2 |
|
| 3 |
-A fast, simple fuzzy text selector for the terminal with an advanced [scoring |
|
| 3 |
+**fzy** is a fast, simple fuzzy text selector for the terminal with an advanced [scoring |
|
| 4 | 4 |
algorithm](#sorting). |
| 5 | 5 |
|
| 6 | 6 |
 |
| ... | ... |
@@ -48,8 +48,7 @@ the default is `/usr/local`. |
| 48 | 48 |
|
| 49 | 49 |
### Fedora/Redhat/CentOS |
| 50 | 50 |
|
| 51 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.4/fzy-0.4-1.x86_64.rpm |
|
| 52 |
- sudo rpm -i fzy-0.4-1.x86_64.rpm |
|
| 51 |
+ sudo yum install https://github.com/jhawthorn/fzy/releases/download/0.4/fzy-0.4-1.x86_64.rpm |
|
| 53 | 52 |
|
| 54 | 53 |
### Arch Linux |
| 55 | 54 |
|
| ... | ... |
@@ -43,8 +43,13 @@ the default is `/usr/local`. |
| 43 | 43 |
|
| 44 | 44 |
### Ubuntu/Debian 64-bit |
| 45 | 45 |
|
| 46 |
- wget https://github.com/jhawthorn/fzy/releases/download/0.3/fzy_0.3-1_amd64.deb |
|
| 47 |
- sudo dpkg -i fzy_0.3-1_amd64.deb |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.4/fzy_0.4-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.4-1_amd64.deb |
|
| 48 |
+ |
|
| 49 |
+### Fedora/Redhat/CentOS |
|
| 50 |
+ |
|
| 51 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.4/fzy-0.4-1.x86_64.rpm |
|
| 52 |
+ sudo rpm -i fzy-0.4-1.x86_64.rpm |
|
| 48 | 53 |
|
| 49 | 54 |
### Arch Linux |
| 50 | 55 |
|
| ... | ... |
@@ -87,9 +87,9 @@ nnoremap <leader>s :call FzyCommand("find -type f", ":sp")<cr>
|
| 87 | 87 |
Any program can be used to filter files presented through fzy. [ag (the silver searcher)](https://github.com/ggreer/the_silver_searcher) can be used to ignore files specified by `.gitignore`. |
| 88 | 88 |
|
| 89 | 89 |
``` vim |
| 90 |
-nnoremap <leader>e :call FzyCommand("ag . --no-color -l -g ''", ":e")<cr>
|
|
| 91 |
-nnoremap <leader>v :call FzyCommand("ag . --no-color -l -g ''", ":vs")<cr>
|
|
| 92 |
-nnoremap <leader>s :call FzyCommand("ag . --no-color -l -g ''", ":sp")<cr>
|
|
| 90 |
+nnoremap <leader>e :call FzyCommand("ag . -l -g ''", ":e")<cr>
|
|
| 91 |
+nnoremap <leader>v :call FzyCommand("ag . -l -g ''", ":vs")<cr>
|
|
| 92 |
+nnoremap <leader>s :call FzyCommand("ag . -l -g ''", ":sp")<cr>
|
|
| 93 | 93 |
``` |
| 94 | 94 |
|
| 95 | 95 |
## Sorting |
| ... | ... |
@@ -41,12 +41,17 @@ Rather than clearing the screen, fzy displays its interface directly below the c |
| 41 | 41 |
The `PREFIX` environment variable can be used to specify the install location, |
| 42 | 42 |
the default is `/usr/local`. |
| 43 | 43 |
|
| 44 |
+### Ubuntu/Debian 64-bit |
|
| 45 |
+ |
|
| 46 |
+ wget https://github.com/jhawthorn/fzy/releases/download/0.3/fzy_0.3-1_amd64.deb |
|
| 47 |
+ sudo dpkg -i fzy_0.3-1_amd64.deb |
|
| 48 |
+ |
|
| 44 | 49 |
### Arch Linux |
| 45 | 50 |
|
| 46 | 51 |
fzy is available |
| 47 | 52 |
[in the AUR](https://aur.archlinux.org/packages/fzy/) |
| 48 | 53 |
with a very simple |
| 49 |
-[PKGBUILD](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=fzy). |
|
| 54 |
+[PKGBUILD](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=fzy) |
|
| 50 | 55 |
|
| 51 | 56 |
### OS X via Homebrew |
| 52 | 57 |
|
| ... | ... |
@@ -41,6 +41,13 @@ Rather than clearing the screen, fzy displays its interface directly below the c |
| 41 | 41 |
The `PREFIX` environment variable can be used to specify the install location, |
| 42 | 42 |
the default is `/usr/local`. |
| 43 | 43 |
|
| 44 |
+### Arch Linux |
|
| 45 |
+ |
|
| 46 |
+fzy is available |
|
| 47 |
+[in the AUR](https://aur.archlinux.org/packages/fzy/) |
|
| 48 |
+with a very simple |
|
| 49 |
+[PKGBUILD](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=fzy). |
|
| 50 |
+ |
|
| 44 | 51 |
### OS X via Homebrew |
| 45 | 52 |
|
| 46 | 53 |
brew tap jhawthorn/fzy |
| ... | ... |
@@ -33,12 +33,19 @@ Rather than clearing the screen, fzy displays its interface directly below the c |
| 33 | 33 |
|
| 34 | 34 |
## Installation |
| 35 | 35 |
|
| 36 |
- $ make |
|
| 37 |
- $ sudo make install |
|
| 36 |
+### From source |
|
| 37 |
+ |
|
| 38 |
+ make |
|
| 39 |
+ sudo make install |
|
| 38 | 40 |
|
| 39 | 41 |
The `PREFIX` environment variable can be used to specify the install location, |
| 40 | 42 |
the default is `/usr/local`. |
| 41 | 43 |
|
| 44 |
+### OS X via Homebrew |
|
| 45 |
+ |
|
| 46 |
+ brew tap jhawthorn/fzy |
|
| 47 |
+ brew install fzy |
|
| 48 |
+ |
|
| 42 | 49 |
## Usage |
| 43 | 50 |
|
| 44 | 51 |
fzy is a drop in replacement for [selecta](https://github.com/garybernhardt/selecta), and can be used with its [usage examples](https://github.com/garybernhardt/selecta#usage-examples). |
| ... | ... |
@@ -1,16 +1,35 @@ |
| 1 | 1 |
# fzy |
| 2 | 2 |
|
| 3 |
-A fuzzy text selector for terminals in C inspired by |
|
| 4 |
-[selecta](https://github.com/garybernhardt/selecta), |
|
| 5 |
-but with an improved [scoring algorithm](#sorting). |
|
| 3 |
+A fast, simple fuzzy text selector for the terminal with an advanced [scoring |
|
| 4 |
+algorithm](#sorting). |
|
| 6 | 5 |
|
| 7 | 6 |
 |
| 8 | 7 |
|
| 9 |
-> It's been kind of life-changing. |
|
| 10 |
-> -[@graygilmore](https://github.com/graygilmore/) |
|
| 8 |
+<blockquote> |
|
| 9 |
+It's been kind of life-changing. |
|
| 10 |
+-<a href="https://github.com/graygilmore/">@graygilmore</a> |
|
| 11 |
+</blockquote> |
|
| 11 | 12 |
|
| 12 |
-> fzy works great btw |
|
| 13 |
-> -[@alexblackie](https://twitter.com/alexblackie/status/719297828892188672) |
|
| 13 |
+<blockquote> |
|
| 14 |
+fzy works great btw |
|
| 15 |
+-<a href="https://twitter.com/alexblackie/status/719297828892188672">@alexblackie</a> |
|
| 16 |
+</blockquote> |
|
| 17 |
+ |
|
| 18 |
+[](https://travis-ci.org/jhawthorn/fzy) |
|
| 19 |
+ |
|
| 20 |
+## Why use this over fzf, pick, selecta, ctrlp, ...? |
|
| 21 |
+ |
|
| 22 |
+fzy is faster and shows better results than other fuzzy finders. |
|
| 23 |
+ |
|
| 24 |
+Most other fuzzy matchers sort based on the length of a match. fzy tries to |
|
| 25 |
+find the result the user intended. It does this by favouring matches on |
|
| 26 |
+consecutive letters and starts of words. This allows matching using acronyms or |
|
| 27 |
+different parts of the path. |
|
| 28 |
+ |
|
| 29 |
+A gory comparison of the sorting used by fuzzy finders can be found in [ALGORITHM.md](ALGORITHM.md) |
|
| 30 |
+ |
|
| 31 |
+fzy is designed to be used both as an editor plugin and on the command line. |
|
| 32 |
+Rather than clearing the screen, fzy displays its interface directly below the current cursor position, scrolling the screen if necessary. |
|
| 14 | 33 |
|
| 15 | 34 |
## Installation |
| 16 | 35 |
|
| ... | ... |
@@ -9,6 +9,9 @@ but with an improved [scoring algorithm](#sorting). |
| 9 | 9 |
> It's been kind of life-changing. |
| 10 | 10 |
> -[@graygilmore](https://github.com/graygilmore/) |
| 11 | 11 |
|
| 12 |
+> fzy works great btw |
|
| 13 |
+> -[@alexblackie](https://twitter.com/alexblackie/status/719297828892188672) |
|
| 14 |
+ |
|
| 12 | 15 |
## Installation |
| 13 | 16 |
|
| 14 | 17 |
$ make |
| ... | ... |
@@ -25,7 +25,7 @@ fzy can be integrated very simply in vim. There is also [fzy-vim](https://github |
| 25 | 25 |
``` vim |
| 26 | 26 |
function! FzyCommand(choice_command, vim_command) |
| 27 | 27 |
try |
| 28 |
- silent let output = system(a:choice_command . " | fzy ") |
|
| 28 |
+ let output = system(a:choice_command . " | fzy ") |
|
| 29 | 29 |
catch /Vim:Interrupt/ |
| 30 | 30 |
" Swallow errors from ^C, allow redraw! below |
| 31 | 31 |
endtry |
Seems to be necessary on some systems.
| ... | ... |
@@ -24,7 +24,11 @@ fzy can be integrated very simply in vim. There is also [fzy-vim](https://github |
| 24 | 24 |
|
| 25 | 25 |
``` vim |
| 26 | 26 |
function! FzyCommand(choice_command, vim_command) |
| 27 |
- silent let output = system(a:choice_command . " | fzy ") |
|
| 27 |
+ try |
|
| 28 |
+ silent let output = system(a:choice_command . " | fzy ") |
|
| 29 |
+ catch /Vim:Interrupt/ |
|
| 30 |
+ " Swallow errors from ^C, allow redraw! below |
|
| 31 |
+ endtry |
|
| 28 | 32 |
redraw! |
| 29 | 33 |
if v:shell_error == 0 && !empty(output) |
| 30 | 34 |
exec a:vim_command . ' ' . output |
| ... | ... |
@@ -48,10 +48,10 @@ nnoremap <leader>s :call FzyCommand("ag . --no-color -l -g ''", ":sp")<cr>
|
| 48 | 48 |
|
| 49 | 49 |
fzy attempts to present the best matches first. The following considerations are weighted when sorting: |
| 50 | 50 |
|
| 51 |
-It prefers matching the beginning of words: `amo` is likely to match <tt><b>a</b>pp/<b>m</b>odels/<b>o</b>rder.rb</tt>. |
|
| 52 |
- |
|
| 53 | 51 |
It prefers consecutive characters: `file` will match <tt><b>file</b></tt> over <tt><b>fil</b>t<b>e</b>r</tt>. |
| 54 | 52 |
|
| 53 |
+It prefers matching the beginning of words: `amp` is likely to match <tt><b>a</b>pp/<b>m</b>odels/<b>p</b>osts.rb</tt>. |
|
| 54 |
+ |
|
| 55 | 55 |
It prefers shorter matches: `abce` matches <tt><b>abc</b>d<b>e</b>f</tt> over <tt><b>abc</b> d<b>e</b></tt>. |
| 56 | 56 |
|
| 57 | 57 |
It prefers shorter candidates: `test` matches <tt><b>test</b>s</tt> over <tt><b>test</b>ing</b></tt>. |
| ... | ... |
@@ -1,9 +1,8 @@ |
| 1 | 1 |
# fzy |
| 2 | 2 |
|
| 3 | 3 |
A fuzzy text selector for terminals in C inspired by |
| 4 |
-[selecta](https://github.com/garybernhardt/selecta) |
|
| 5 |
-and |
|
| 6 |
-[dmenu](http://tools.suckless.org/dmenu/) |
|
| 4 |
+[selecta](https://github.com/garybernhardt/selecta), |
|
| 5 |
+but with an improved [scoring algorithm](#sorting). |
|
| 7 | 6 |
|
| 8 | 7 |
 |
| 9 | 8 |
|
| ... | ... |
@@ -14,3 +13,46 @@ and |
| 14 | 13 |
|
| 15 | 14 |
The `PREFIX` environment variable can be used to specify the install location, |
| 16 | 15 |
the default is `/usr/local`. |
| 16 |
+ |
|
| 17 |
+## Usage |
|
| 18 |
+ |
|
| 19 |
+fzy is a drop in replacement for [selecta](https://github.com/garybernhardt/selecta), and can be used with its [usage examples](https://github.com/garybernhardt/selecta#usage-examples). |
|
| 20 |
+ |
|
| 21 |
+### Use with Vim |
|
| 22 |
+ |
|
| 23 |
+fzy can be integrated very simply in vim. There is also [fzy-vim](https://github.com/Dkendal/fzy-vim), a more fully featured vim plugin. |
|
| 24 |
+ |
|
| 25 |
+``` vim |
|
| 26 |
+function! FzyCommand(choice_command, vim_command) |
|
| 27 |
+ silent let output = system(a:choice_command . " | fzy ") |
|
| 28 |
+ redraw! |
|
| 29 |
+ if v:shell_error == 0 && !empty(output) |
|
| 30 |
+ exec a:vim_command . ' ' . output |
|
| 31 |
+ endif |
|
| 32 |
+endfunction |
|
| 33 |
+ |
|
| 34 |
+nnoremap <leader>e :call FzyCommand("find -type f", ":e")<cr>
|
|
| 35 |
+nnoremap <leader>v :call FzyCommand("find -type f", ":vs")<cr>
|
|
| 36 |
+nnoremap <leader>s :call FzyCommand("find -type f", ":sp")<cr>
|
|
| 37 |
+``` |
|
| 38 |
+ |
|
| 39 |
+Any program can be used to filter files presented through fzy. [ag (the silver searcher)](https://github.com/ggreer/the_silver_searcher) can be used to ignore files specified by `.gitignore`. |
|
| 40 |
+ |
|
| 41 |
+``` vim |
|
| 42 |
+nnoremap <leader>e :call FzyCommand("ag . --no-color -l -g ''", ":e")<cr>
|
|
| 43 |
+nnoremap <leader>v :call FzyCommand("ag . --no-color -l -g ''", ":vs")<cr>
|
|
| 44 |
+nnoremap <leader>s :call FzyCommand("ag . --no-color -l -g ''", ":sp")<cr>
|
|
| 45 |
+``` |
|
| 46 |
+ |
|
| 47 |
+## Sorting |
|
| 48 |
+ |
|
| 49 |
+fzy attempts to present the best matches first. The following considerations are weighted when sorting: |
|
| 50 |
+ |
|
| 51 |
+It prefers matching the beginning of words: `amo` is likely to match <tt><b>a</b>pp/<b>m</b>odels/<b>o</b>rder.rb</tt>. |
|
| 52 |
+ |
|
| 53 |
+It prefers consecutive characters: `file` will match <tt><b>file</b></tt> over <tt><b>fil</b>t<b>e</b>r</tt>. |
|
| 54 |
+ |
|
| 55 |
+It prefers shorter matches: `abce` matches <tt><b>abc</b>d<b>e</b>f</tt> over <tt><b>abc</b> d<b>e</b></tt>. |
|
| 56 |
+ |
|
| 57 |
+It prefers shorter candidates: `test` matches <tt><b>test</b>s</tt> over <tt><b>test</b>ing</b></tt>. |
|
| 58 |
+ |
| ... | ... |
@@ -5,3 +5,10 @@ A fuzzy text selector for terminals in C inspired by |
| 5 | 5 |
and |
| 6 | 6 |
[dmenu](http://tools.suckless.org/dmenu/) |
| 7 | 7 |
|
| 8 |
+## Installation |
|
| 9 |
+ |
|
| 10 |
+ $ make |
|
| 11 |
+ $ sudo make install |
|
| 12 |
+ |
|
| 13 |
+The `PREFIX` environment variable can be used to specify the install location, |
|
| 14 |
+the default is `/usr/local`. |