You are not logged in.

#1 2010-10-31 10:39:17

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,636
Website

my proposed pacakge for a working flexget - please comment!

There are two flexget packages in the AUR but neither works.

http://aur.archlinux.org/packages.php?ID=30041
http://aur.archlinux.org/packages.php?ID=34827

Here is my stab at at PKGBUILD for flexget.  Please have a look and provide comments.  I'm sure it's not optimal as-is and I don't want to upload it to the AUR until people who know can have a look.  One problem I have with it is that I don't have an elegant way to install the setup.yml into the user's home dir/.flexget as you can see by my crude usage of $HOME.  How should I handle this?  Is it best to just place the file in a /usr/share/flexget and have a readme.install tell the user to manually copy it to his/her ~/.flexget?  Another problem I have is how to link the version number with the one that pip will being down.

FYI - config.yml isn't important, it's just an example config file.

Thanks!

# Contributor : graysky <graysky AT archlinux DOT us>
pkgname=flexget
pkgver=1.0.15.17
pkgrel=1
pkgdesc="An automation tool for content like torrents, podcasts, etc. that uses RSS-feeds, html, and even csv files.)"
arch=(any)
url="http://flexget.com"
depends=('python-yaml' 'python-feedparser')
makedepends=('python' 'python-pip' 'python-virtualenv')
license=('MIT')
source=('config.yml')
md5sums=('c6e6a53000a07c2cd8be9032badd5b67')
install=(readme.install)

build() {
 if [ -d $srcdir/flexget ]; then
  rm -rf $srcdir/flexget
 fi

 mkdir $srcdir/flexget && cd $srcdir/flexget
 virtualenv --no-site-packages --distribute livewire
 pip install -E livewire flexget
 install -D $srcdir/flexget/livewire/bin/flexget $pkgdir/usr/bin/flexget
 install -D $startdir/config.yml $pkgdir/etc/skel/config.yml
}

Last edited by graysky (2010-10-31 11:08:07)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#2 2010-10-31 10:47:17

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: my proposed pacakge for a working flexget - please comment!

Arch packages are not permitted to touch $HOME - use a post-install message.

Offline

#3 2010-10-31 11:07:24

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,636
Website

Re: my proposed pacakge for a working flexget - please comment!

Thanks for the feedback, tomk.  I edited my original post removing the references to $HOME.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#4 2010-10-31 12:49:08

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: my proposed pacakge for a working flexget - please comment!

I don't really do any packaging these days, but this one engaged me, mainly because I'm not 100% happy with my current rss download thing. Here's an alternative build, based on the PKGBUILD-python.proto template:

pkgname=flexget
pkgver=1.0r1571
pkgrel=1
pkgdesc="A multipurpose automation tool for content like torrents, nzbs, podcasts, comics, etc"
arch=('any')
url="http://flexget.com/"
license=('MIT')
depends=('python-yaml' 'python-feedparser' 'python-progressbar' 'pynzb' 'pyrss2gen' 'python-html5lib' 'beautiful-soup' 'python-sqlalchemy')
makedepends=()
options=(!emptydirs)
install=
source=(http://download.flexget.com/unstable/FlexGet-1.0r1571.tar.gz)

package() {
  cd "$srcdir/FlexGet-$pkgver"
  python2 setup.py install --root=$pkgdir/ --optimize=1
}
md5sums=('210fd75305cf1243239de67c00740031')

This installs and works fine once you put the config file in ~/.flexget, as you mentioned above. The deps are all in the repos or the AUR - some of the AUR ones still haven't been updated to use python2 but that's not a big deal.

I like this one mainly because it's totally Arch-like IMO. I don't know python at all really, so I guess using pip is more python-like?

One more thing - I just noticed that you're putting the config file in /etc/skel. That's not correct - use /usr/share/flexget.

Offline

#5 2010-10-31 13:39:01

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,636
Website

Re: my proposed pacakge for a working flexget - please comment!

@tomk - OK... three deps from the AUR isn't too bad.

http://aur.archlinux.org/packages.php?ID=42444

Modded changing /etc/skel to /usr/share/flexget as you suggested.

Last edited by graysky (2010-10-31 14:28:57)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#6 2010-10-31 16:41:58

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: my proposed pacakge for a working flexget - please comment!

One more thing - instead of submitting it under a different name, you should contact the current maintainer to see if he will either use this PKGBUILD or orphan the package so you can maintain it. If you really have to use a different name, flexget-beta would be better.

Offline

Board footer

Powered by FluxBB