Package Details: advanced-ssh-config 2.16.0-1

Git Clone URL: https://aur.archlinux.org/advanced-ssh-config.git (read-only, click to copy)
Package Base: advanced-ssh-config
Description: ssh wrapper using ProxyCommand that adds regex, aliases, gateways, includes, dynamic hostnames to SSH and ssh-config
Upstream URL: https://github.com/moul/assh
Keywords: assh
Licenses: MIT
Conflicts: assh-git
Submitter: pschmitt
Maintainer: SibrenVasse
Last Packager: SibrenVasse
Votes: 3
Popularity: 0.000000
First Submitted: 2016-06-01 09:49 (UTC)
Last Updated: 2023-12-10 19:53 (UTC)

Dependencies (4)

Required by (0)

Sources (1)

Latest Comments

grawlinson commented on 2021-08-03 22:02 (UTC)

Some suggested changes:

diff --git a/PKGBUILD b/PKGBUILD
index c29cc21..d825da5 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -14,17 +14,25 @@ url='https://github.com/moul/assh'
 license=('MIT')
 depends=('glibc')
 makedepends=('go')
+optdepends=(
+  'bash-completion: for shell auto-completion'
+  'zsh-completions: for shell auto-completion'
+)
 conflicts=('assh-git')
 source=("${pkgname}-${pkgver}.tar.gz::https://github.com/moul/assh/archive/v${pkgver}.tar.gz")
 sha256sums=('da95db33f72ad2531124b0de42074ba61ac1eebdad90bac90c68d1b02aa51354')

 build() {
+  export CGO_CPPFLAGS="${CPPFLAGS}"
+  export CGO_CFLAGS="${CFLAGS}"
+  export CGO_CXXFLAGS="${CXXFLAGS}"
+  export CGO_LDFLAGS="${LDFLAGS}"
   cd "$_name-$pkgver"
   go build \
      -trimpath \
      -buildmode=pie \
      -modcacherw \
-     -ldflags "-X 'moul.io/assh/v2/pkg/version.Version=${pkgver}' -X 'moul.io/assh/v2/pkg/version.VcsRef=${_vcsref}'" \
+     -ldflags "-linkmode external -extldflags \"${LDFLAGS}\" -X 'moul.io/assh/v2/pkg/version.Version=${pkgver}' -X 'moul.io/assh/v2/pkg/version.VcsRef=${_vcsref}'" \
      -o assh \
      .
 }

SibrenVasse commented on 2021-08-01 13:01 (UTC)

Coelacanthus: thank you for your suggestions. I've partially implemented them in the PGKBUILD. I've removed the building and running of gen-completion, as the autocomplete files are already generated in the release tarball. As it's not a vcs package, building and running gen-completion does nothing.

Coelacanthus commented on 2021-08-01 08:35 (UTC)

Make it can also install completion files and examples, add lost dependency glibc as well

# Maintainer: Sibren Vasse <arch@sibrenvasse.nl>
# Contributor: Hyacinthe Cartiaux <hyacinthe.cartiaux@free.fr>
# Contributor: Philipp Schmitt <philipp@schmitt.co>
# Contributor: Coelacanthus <coelacanthus@outlook.com>

pkgname=advanced-ssh-config
_name=assh
pkgver=2.11.3
_vcsref=281772c
pkgrel=1
pkgdesc='ssh wrapper using ProxyCommand that adds regex, aliases, gateways, includes, dynamic hostnames to SSH and ssh-config'
arch=('x86_64')
url='https://github.com/moul/assh'
license=('MIT')
depends=('glibc')
makedepends=('go')
conflicts=('assh-git')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/moul/assh/archive/v${pkgver}.tar.gz")
sha256sums=('da95db33f72ad2531124b0de42074ba61ac1eebdad90bac90c68d1b02aa51354')

build() {
  cd "$_name-$pkgver"
  go build \
     -trimpath \
     -buildmode=pie \
     -modcacherw \
     -ldflags "-linkmode external -extldflags \"${LDFLAGS}\"" \
     -ldflags "-X 'moul.io/assh/v2/pkg/version.Version=${pkgver}' -X 'moul.io/assh/v2/pkg/version.VcsRef=${_vcsref}'" \
     -o assh \
     .
  cd contrib/completion/gen
  go build \
     -trimpath \
     -buildmode=pie \
     -modcacherw \
     -ldflags "-linkmode external -extldflags \"${LDFLAGS}\"" \
     -o gen-completion \
     main.go
  ./gen-completion

}

check() {
  cd "$_name-$pkgver"
  go test ./...
}

package() {
  cd "$_name-$pkgver"
  install -Dm755 assh "${pkgdir}/usr/bin/assh"
  install -Dm755 contrib/completion/zsh_autocomplete "${pkgdir}/usr/share/zsh/site-functions/_assh"
  install -Dm755 contrib/completion/bash_autocomplete "${pkgdir}/usr/share/bash-completion/completions/assh"
  for _dir_name in examples/*
  do
    install -Dm755 -t "${pkgdir}/usr/share/doc/advanced-ssh-config/$_dir_name" $_dir_name/*
  done
  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/$pkgname/LICENSE"
}

# vim:set ts=2 sw=2 et:

azmo commented on 2019-03-06 10:37 (UTC)

Just came around checking and it's building great again - thanks for the fixes!

SibrenVasse commented on 2019-02-22 14:39 (UTC) (edited on 2019-02-22 14:39 (UTC) by SibrenVasse)

@azmo: I've fixed the build and added a few improvements.

As for the _gourl and the go modules, those changes happened after the v2.8.0 release. This is not a VCS package, so we'll have to wait for an upstream release.

azmo commented on 2019-02-12 19:11 (UTC)

Project has moved _gourl to moul.io/assh; also uses go modules now. Would appreciate an update, this doesn't build for me anymore.