Em 08/04/2013 19:12, Maxime GAUDUIN escreveu:
On Mon, Apr 8, 2013 at 10:44 PM, Rafael Ferreira
<[email protected]>wrote:
Em 08/04/2013 17:35, Daniel Wallace escreveu:
On Mon, Apr 08, 2013 at 05:23:24PM -0300, Rafael Ferreira wrote:
Hi there.
I notice that if you have SRCDEST set in makepkg.conf, working in
'src/' folder with Subversion doesn't seem to work just like 'git
log -1 ....' or 'git describe | ....', as it seems that 'src/' is
simply a 'svn export' copy of $SRCDEST (e.g.: /home/foobar/sources).
In pcsx2-svn [1], I'm using the following function to accomplish the
task of getting pkgver dynamically:
pkgver () {
svnversion "${SRCDEST:-$srcdir}"/$pkgname
}
Any opinions or better solution to get pkgver?
[1]
https://aur.archlinux.org/**packages/pcsx2-svn/<https://aur.archlinux.org/packages/pcsx2-svn/>
Rafael Ferreira
you could just cd $pkgnaem and not include $SRCDEST or $srcdir, because
before pkgver, makepkg places you in the correct directory to just cd
into the svn checkout.
Thanks for the reply, Daniel.
Actually no. Makepkg will place me specifically in $srcdir which is
"<working folder>/src". If a 'svn export' is made from makepkg's
$SRCDEST
to $srcdir, the copy inside $srcdir won't be a svn working copy.
See the ouptut:
~/repos/pkgbuilds/pcsx2-svn/**src/pcsx2 $ LC_ALL=C svn info | grep
^Revision
svn: E155007: '/home/rafael/repos/pkgbuilds/**pcsx2-svn/src/pcsx2' is
not
a working copy
... however:
~/sources/pcsx2 $ LC_ALL=C svn info | grep ^Revision
Revision: 5607
This is already known, look here:
https://wiki.archlinux.org/index.php/VCS_PKGBUILD_Guidelines#Subversion
Cheers.
That was not in there last time I saw it. :) Thanks for the heads up
Cheers,
Rafael Ferreira