You are not logged in.

#1 2018-03-29 21:59:24

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

PKGBUILD review please - New Linode CLI

If all of you kind folks could cast an eye over these before I upload them - thanks smile

linode-cli-dev-git

# Maintainer: Slithery <aur at slithery dot uk>
pkgname=linode-cli-dev-git
_pkgbase=linode-cli
pkgver=1.0.3b3.r31.g4fd5d01
pkgrel=1
pkgdesc="CLI for the new Linode API v4"
arch=('any')
url="https://github.com/linode/linode-cli"
license=('unknown')
depends=('python' 'python-colorclass' 'python-future' 'python-linode-api' 'python-requests' 'python-setuptools'  'python-terminaltables')
makedepends=('git')
source=('git+https://github.com/linode/linode-cli.git')
sha256sums=('SKIP')

pkgver() {
  cd "$_pkgbase"
  git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

#build() {
#  python setup.py build
#}

package() {
  cd "$srcdir/$_pkgbase"
  python setup.py install --root="$pkgdir/" --optimize=1  #--skip-build
}

python-linode-api-git

# Maintainer: Slithery <aur at slithery dot uk>
pkgname=python-linode-api-git
_pkgbase=python-linode-api
pkgver=4.0.5a.r225.g9f449b9
pkgrel=1
pkgdesc="Bindings for the Linode API v4"
arch=('any')
url="https://github.com/linode/python-linode-api"
license=('BSD')
depends=('python')
makedepends=('git')
provides=('python-linode-api')
source=('git+https://github.com/linode/python-linode-api.git')
sha256sums=('SKIP')

pkgver() {
  cd "$_pkgbase"
  git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

#build() {
#  python setup.py build
#}

package() {
  cd "$srcdir/$_pkgbase"
  python setup.py install --root="$pkgdir/" --optimize=1 #--skip-build
  install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$_pkgbase/LICENSE"
}

I've not managed to find a license for the new linode-cli-dev-git yet, I obviously won't upload the PKGBUILD until I get an answer from upstream...
https://www.linode.com/community/questi … ased-under

Last edited by Slithery (2018-03-30 00:08:39)


No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

#2 2018-03-29 23:05:08

eschwartz
Fellow
Registered: 2014-08-08
Posts: 4,097

Re: PKGBUILD review please - New Linode CLI

use "unknown" as a placeholder then. tongue

1) pkgver should not start with a v, see the third entry in https://wiki.archlinux.org/index.php/VC … elines#Git
2) you should build the modules in build() before installing them in package():

python setup.py build

...

python setup.py install --root="$pkgdir/" --optimize=1 --skip-build

3) Does the git version of the cli depend on the git version of the api? Currently it says even the non-git version would be acceptable.

4) Why do you explicitly rename the source clones to the same thing they would be named by default?

5) It looks a bit weird that all your arrays are single-quoted except for arch which is not quoted at all. Same with options but you could probably delete that entirely, unless this package installs an empty directory you really want to remove?


Managing AUR repos The Right Way -- aurpublish (now a standalone tool)

Offline

#3 2018-03-30 00:06:10

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

Re: PKGBUILD review please - New Linode CLI

Eschwartz wrote:

use "unknown" as a placeholder then. tongue

Will do.

1) pkgver should not start with a v, see the third entry in https://wiki.archlinux.org/index.php/VC … elines#Git

Done.

2) you should build the modules in build() before installing them in package():

python setup.py build

...

python setup.py install --root="$pkgdir/" --optimize=1 --skip-build

Couldn't get this to work, am looking into it.

3) Does the git version of the cli depend on the git version of the api? Currently it says even the non-git version would be acceptable.

No it doesn't. There are 2 main branches of linode-cli at the moment, the stable branch [1] which hasn't seen any releases for years and the new development branch [2] hosted in a different git repo and with a new versioning scheme (I'll need to use epoch when the new version is deemed stable and I retire the old version from my AUR packages). Only the new version has a dependency on python-linode-api.

I plan to replace both of these *-git packages with stable releases as soon as upstream releases them.

4) Why do you explicitly rename the source clones to the same thing they would be named by default?

No idea. Fixed.

5) It looks a bit weird that all your arrays are single-quoted except for arch which is not quoted at all. Same with options but you could probably delete that entirely, unless this package installs an empty directory you really want to remove?

Done. Just copy-pasting from the wiki without putting in enough effort. Sorry smile

[1] https://github.com/linode/cli
[2] https://github.com/linode/linode-cli

First post edited with current versions.


No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

#4 2018-04-02 19:16:07

nsfyn55
Member
Registered: 2018-04-02
Posts: 1

Re: PKGBUILD review please - New Linode CLI

In response to your community post. We have pushed a 3-clause BSD license file to the repo. Let us know if you need anything else.

Last edited by nsfyn55 (2018-04-02 19:17:11)

Offline

#5 2018-04-04 19:09:22

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

Re: PKGBUILD review please - New Linode CLI

Uploaded.

I can't use the git masters for both packages at the moment as the hard dependency requirements don't match. I'll have to update the $pkgvers manually to keep them working and in sync until these go stable smile

https://aur.archlinux.org/packages/linode-cli-dev/
https://aur.archlinux.org/packages/python-linode-api/


No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

Board footer

Powered by FluxBB