Package Details: lf 27-1

Git Clone URL: https://aur.archlinux.org/lf.git (read-only, click to copy)
Package Base: lf
Description: A terminal file manager inspred by ranger written in Go
Upstream URL: https://github.com/gokcehan/lf
Licenses: MIT
Submitter: None
Maintainer: nvllsvm
Last Packager: nvllsvm
Votes: 64
Popularity: 3.82
First Submitted: 2016-10-06 21:37 (UTC)
Last Updated: 2022-04-03 14:33 (UTC)

Latest Comments

MaxVerevkin commented on 2020-07-26 08:59 (UTC)

Also:

install -Dm644 -t "${pkgdir}/etc/profile.d" \
    ./etc/lf.csh \
    ./etc/lfcd.csh

Instead of

install -Dm644 -t "${pkgdir}/etc/profile.d" \
    ./etc/lf.csh
install -Dm644 -t "${pkgdir}/etc/profile.d" \
    ./etc/lfcd.csh

MaxVerevkin commented on 2020-07-26 08:49 (UTC) (edited on 2020-07-26 09:01 (UTC) by MaxVerevkin)

Please change

install -Dm644 -t "${pkgdir}/usr/share/zsh/site-functions/_lf" \
    ./etc/lf.zsh

to

install -Dm644 -T ./etc/lf.zsh "${pkgdir}/usr/share/zsh/site-functions/_lf"

Also delete _srcname since it is unused.

rumpelsepp commented on 2020-05-19 05:39 (UTC)

On arch-dev-public the new go packaging guidelines were announced: https://wiki.archlinux.org/index.php/Go_package_guidelines

Please adopt.

tinywrkb commented on 2020-04-17 12:30 (UTC)

I had to export GOPATH in build() to have go mod vendor not try to download to ~/go and fail as ~/ is ro & immutable on my system.
This only happens when using Yay, not an issue when fetching the PKGBUILD manually and running makepkg.
I don't know if it makes a difference but I also have BUILDDIR set.

jomority commented on 2020-04-14 13:08 (UTC)

The newest version (14) includes a .desktop file and zsh and (t)csh completion. For the first two, you can apply this patch:

diff --git a/PKGBUILD b/PKGBUILD
index bed4031..b33863c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -49,6 +49,9 @@ package() {
   install -Dm644 -t "${pkgdir}/usr/share/man/man1" \
       ./lf.1

+  install -Dm644 -t "${pkgdir}/usr/share/applications" \
+      ./lf.desktop
+
   # vim
   install -Dm644 -t "${pkgdir}/usr/share/vim/vimfiles/syntax" \
       ./etc/lf.vim
@@ -60,4 +63,7 @@ package() {
       ./etc/lf.fish
   install -Dm644 -t "${pkgdir}/usr/share/fish/vendor_functions.d" \
       ./etc/lfcd.fish
+
+  # zsh
+  install -Dm644 ./etc/lf.zsh "${pkgdir}/usr/share/zsh/site-functions/_lf"
 }

For the tcsh comletion I'm not sure as I'm not familiar with it. Maybe drop the two .csh files in /usr/share/lf and let the user source them.

nvllsvm commented on 2019-11-02 04:03 (UTC)

For anyone upgrading from an older release of this package (<13-4) and using yay - you need to manually clear the cache for the package.

You'll have to use sudo or some chowning due to user hostile bullshit with Go's dependency management: https://github.com/golang/go/issues/27455

For yay, just:

sudo rm -rf ~/.cache/yay/lf

karcher commented on 2019-10-31 10:03 (UTC) (edited on 2019-10-31 10:06 (UTC) by karcher)

I'm getting an error during update (apparently due to permission issues):

==> Making package: lf 13-4 (Thu 31 Oct 2019 10:35:40 AM CET)
==> Retrieving sources...
  -> Found lf-r13.tar.gz
==> Validating source files with sha256sums...
    lf-r13.tar.gz ... Passed
==> Cleaning up...
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_appengine.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/benchmark_test.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/.travis.yml': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_test.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_posix_test.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_posix.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/README.mkd': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_js.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/LICENSE': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/api_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/termbox_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/keyboard.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/random_output.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/output.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/paint.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/editbox.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/raw_input.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/interrupt.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_netbsd.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/termbox.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_darwin.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_darwin_amd64.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_linux.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/terminfo_builtin.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/collect_terminfo.py': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_openbsd.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_dragonfly.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/escwait.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/api.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_freebsd.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/terminfo.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/termbox_common.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/README.md': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/LICENSE': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/api_common.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/AUTHORS': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/escwait_darwin.go': Permission denied
==> WARNING: PACKAGER should have the format 'Example Name <email@address.invalid>'
==> Making package: lf 13-4 (Thu 31 Oct 2019 10:35:43 AM CET)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Found lf-r13.tar.gz
==> Validating source files with sha256sums...
    lf-r13.tar.gz ... Passed
==> Removing existing $srcdir/ directory...
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_appengine.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/benchmark_test.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/.travis.yml': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_test.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_posix_test.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_posix.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/README.mkd': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_js.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/runewidth.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/mattn/go-runewidth@v0.0.4/LICENSE': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/api_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/termbox_windows.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/keyboard.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/random_output.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/output.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/paint.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/editbox.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/raw_input.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/_demos/interrupt.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_netbsd.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/termbox.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_darwin.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_darwin_amd64.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_linux.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/terminfo_builtin.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/collect_terminfo.py': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_openbsd.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_dragonfly.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/escwait.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/api.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/syscalls_freebsd.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/terminfo.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/termbox_common.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/README.md': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/LICENSE': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/api_common.go': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/AUTHORS': Permission denied
rm: cannot remove '/home/user/.cache/yay/lf/src/pkg/mod/github.com/nsf/termbox-go@v0.0.0-20190325093121-288510b9734e/escwait_darwin.go': Permission denied

==> ERROR: An unknown error has occurred. Exiting...
Error making: lf

nvllsvm commented on 2019-10-27 15:29 (UTC)

@sseneca aarch64 support has been added.

@ruy16109 man page has been added

sseneca commented on 2019-10-27 10:01 (UTC)

Could you add 'aarch64' as a supported architecture? Adding that to the PKGBUILD makes the package work fine on my rPi running Arch Linux ARM.

ruy16109 commented on 2019-10-18 16:42 (UTC) (edited on 2019-10-18 18:03 (UTC) by ruy16109)

Is it possible to include the manpage during installation in the new update? Currently there is no manpage even though it is available in the upstream repo.

To add the manpage, I added the following lines at the end of package() in PKGBUILD:

local _mansec=1
install -Dm644 ./${pkgname}.${_mansec} -t "${pkgdir}/usr/share/man/man${_mansec}"

rumpelsepp commented on 2019-10-05 06:49 (UTC) (edited on 2019-10-05 06:49 (UTC) by rumpelsepp)

Using a non-GOPATH build resulted in build sources being placed in my ~/go directory. I do not think that is appropriate.

Yes it is, since this is how it works, and it is the default. Also, I think, you skip upstream's dependency versioning by changing the built to the deprecated GOPATH build. If you do not want the build system to create files in your homedir, then set GOPATH outside of the PKGBUILD to /tmp or something.

Requiring go-pie to build this is too opinionated - especially when it requires someone to uninstall their existing go installation.

This needs to be discussed with the arch team.

nvllsvm commented on 2019-10-05 05:11 (UTC)

  • Using a non-GOPATH build resulted in build sources being placed in my ~/go directory. I do not think that is appropriate.
  • Requiring go-pie to build this is too opinionated - especially when it requires someone to uninstall their existing go installation. There is no harm in requiring the regular go package as the go-pie package can be used as a drop-in replacement (provides).

rumpelsepp commented on 2019-10-04 05:32 (UTC) (edited on 2019-10-04 05:34 (UTC) by rumpelsepp)

Thank you!

nvllsvm commented on 2019-10-03 22:41 (UTC)

Package fixed.

@rumpelsepp - I didn't use your patch, but I did add -trimpath to the build arguments. Also - why did you make go-pie an explicit requirement when go is more than sufficient?

kronikpillow commented on 2019-09-27 16:37 (UTC) (edited on 2019-09-28 02:09 (UTC) by kronikpillow)

still fails to build :-/ please fix the package

rumpelsepp commented on 2019-09-18 18:46 (UTC) (edited on 2019-09-19 06:08 (UTC) by rumpelsepp)

Here is an update. Mind me adding as a co maintainer? :-)

edit: I added completions and everything as well.

diff --git a/PKGBUILD b/PKGBUILD
index e3c68c2..d038e0e 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,33 +1,38 @@
+# Maintainer: Andrew Rabert <ar@nullsum.net>
 # Contributor: Ian Beringer <ian@ianberinger.com>
 # Contributor: Stefan Husmann <stefan-husmann@t-online.de>
-# Maitainer: Andrew Rabert <ar@nullsum.net>
+# Contributor: Stefan Tatschner <stefan@rumpelsepp.org>

 pkgname=lf
 pkgver=13
 pkgrel=1
 license=('MIT')
 pkgdesc="A terminal file manager inspred by ranger written in Go"
-depends=("glibc")
-makedepends=('git' 'go')
+makedepends=('go-pie')
 arch=('armv7h' 'i686' 'x86_64')
 url="https://github.com/gokcehan/lf"
 source=("$pkgname-r$pkgver.tar.gz::https://github.com/gokcehan/$pkgname/archive/r$pkgver.tar.gz")
 sha256sums=('fe99ed9785fbdc606835139c0c52c854b32b1f1449ba83567a115b21d2e882f4')
-_srcname=${pkgname}-r$pkgver

 build() {
-  export GOPATH=${srcdir}
-  mkdir -p ${GOPATH}/src
-  rm -rf ${GOPATH}/src/${_srcname} 
-  mv ${_srcname} ${GOPATH}/src
-  cd ${GOPATH}/src/${_srcname}
-  go get
-  version=r$pkgver ./gen/build.sh
+   cd $pkgname-r$pkgver
+   go build \
+    -trimpath \
+    -ldflags "-X main.gVersion=$version -extldflags $LDFLAGS" \
+    -o $pkgname .
 }

 package() {
-  cd ${GOPATH}/src/${_srcname}
-  install -Dm755 lf-r$pkgver "${pkgdir}"/usr/bin/lf
-  install -Dm644 ./LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
-  install -Dm644 ./README.md "${pkgdir}"/usr/share/doc/${pkgname}/README.md
+  cd $pkgname-r$pkgver
+
+  install -Dm755 lf "${pkgdir}"/usr/bin/lf
+  install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
+  install -Dm644 README.md "${pkgdir}"/usr/share/doc/${pkgname}/README.md
+
+  install -Dm644 etc/lfrc.example "${pkgdir}"/usr/share/doc/${pkgname}/lfrc.example
+  install -Dm644 etc/lf.vim "${pkgdir}"/usr/share/vim/vimfiles/plugin/lf.vim
+  install -Dm644 etc/lf.fish "${pkgdir}"/usr/share/fish/vendor_completions.d/lf.fish
+  install -Dm644 etc/lfcd.fish "${pkgdir}"/usr/share/fish/vendor_functions.d/lfcd.fish
+  install -Dm644 etc/lfcd.sh "${pkgdir}"/usr/share/${pkgname}/lfcd.sh
+  install -Dm644 lf.1 "${pkgdir}"/usr/share/man/man1/lf.1
 }

nvllsvm commented on 2018-11-14 00:30 (UTC) (edited on 2018-11-14 00:35 (UTC) by nvllsvm)

This package needs some love. It fails to build currently.

Recommended changes:

  • build dependencies are missing. Use dep to install these
  • requires go-pie when go is sufficient
  • add armv7h support

Here's a working version:

# Contributor: Ian Beringer <ian@ianberinger.com>
# Maintainer: Stefan Husmann <stefan-husmann@t-online.de>

pkgname=lf
pkgver=8
pkgrel=2
license=('MIT')
pkgdesc="A terminal file manager inspred by ranger written in Go"
depends=("glibc")
makedepends=('dep' 'git' 'go')
arch=('armv7h' 'i686' 'x86_64')
url="https://github.com/gokcehan/lf"
source=("$pkgname-r$pkgver.tar.gz::https://github.com/gokcehan/$pkgname/archive/r$pkgver.tar.gz")
sha256sums=('b92bfba41cc1b4054c44bf615907380482c66694fc9eaf4affe185b39cb9bb26')
_srcname=${pkgname}-r$pkgver

build() {
  export GOPATH=${srcdir}
  mkdir -p ${GOPATH}/src
  rm -rf ${GOPATH}/src/${_srcname} 
  mv ${_srcname} ${GOPATH}/src
  cd ${GOPATH}/src/${_srcname}
  dep ensure -v
  go build
}

package() {
  cd ${GOPATH}/src/${_srcname}
  install -Dm755 lf-r$pkgver "${pkgdir}"/usr/bin/lf
  install -Dm644 ./LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
  install -Dm644 ./README.md "${pkgdir}"/usr/share/doc/${pkgname}/README.md
}

obreitwi commented on 2018-09-28 09:31 (UTC) (edited on 2018-09-28 09:32 (UTC) by obreitwi)

There are two missing go dependencies, causing the package build to fail if not present.

Workaround is to go get the two dependencies manually beforehand:

go get github.com/mattn/go-runewidth
go get github.com/nsf/termbox-go

Could you add them? Thank you!

benneti commented on 2017-04-20 07:55 (UTC)

Could you add armv7h to the arch list and the sources? I just tested it, works flawless on armv7h with the linux-arm build

anika200 commented on 2017-04-11 13:04 (UTC)

Checksums need updated again, thanks.

commented on 2017-01-24 00:39 (UTC)

Done!

hav3lock commented on 2017-01-19 01:37 (UTC)

Could you please update the checksums?

commented on 2016-11-22 21:02 (UTC)

Sorry for the delay! I just updated the package to remove go as a make dependency, which in turns removes the need for git. The package is now using a precompiled binary from the official repository.

sekret commented on 2016-10-14 15:08 (UTC)

Please add git to the makedepends. Without it I get this output. ==> Retrieving sources... -> Found nightly.tar.gz ==> Validating source files with sha256sums... nightly.tar.gz ... Passed ==> Extracting sources... -> Extracting nightly.tar.gz with bsdtar ==> Starting prepare()... go: missing Git command. See https://golang.org/s/gogetcmd package github.com/nsf/termbox-go: exec: "git": executable file not found in $PATH ==> ERROR: A failure occurred in prepare(). Aborting... And the checksum is outdated. I know that it's caused by the nature of nightly builds without any versioning. If you don't intend to update the checksum regularly, you might aswell use 'SKIP'