* +fzf

This only includes building the `fzf` binary. It does not include shell
keybindings or completions.

* fix provided binary name
This commit is contained in:
John Allen 2023-01-14 13:21:42 -05:00 committed by GitHub
parent d26f5a7d96
commit ed90d40fd1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 35 additions and 0 deletions

View file

@ -0,0 +1,2 @@
hello
world

View file

@ -0,0 +1,33 @@
distributable:
url: https://github.com/junegunn/fzf/archive/refs/tags/{{version}}.tar.gz
strip-components: 1
versions:
github: junegunn/fzf
provides:
- bin/fzf
build:
script: |
go build -v -ldflags="$LDFLAGS"
mkdir -p "{{ prefix }}"/bin
mv fzf "{{ prefix }}"/bin
dependencies:
go.dev: ^1.18
env:
LDFLAGS:
- -s
- -w
- -X main.version={{ version }}
- -X main.revision=tea
linux:
# or segmentation fault
# fix found here https://github.com/docker-library/golang/issues/402#issuecomment-982204575
LDFLAGS:
- -buildmode=pie
test:
script: |
out=$(cat data.txt | fzf -f wld)
test "$out" = "world"