felipec / git

Fork of Junio Hamano's git for users
Other
204 stars 34 forks source link

Release #45

Closed lu-zero closed 11 years ago

lu-zero commented 11 years ago

Would be possible to have a release of the git-remote-hg/bzr tools?

felipec commented 11 years ago

What exactly do you mean by a release? I do have something planned, but I'm not sure it's what you are looking for.

lu-zero commented 11 years ago

Something I can distribute within Gentoo. Even better if you manage to get into the main git.

lu

felipec commented 11 years ago

I already sent the patches to make it more easy to distribute, they are not getting in.

Anyway, how about this?

make SCRIPT_PYTHON='git-remote-hg.py git-remote-bzr.py' install-python-script

I can fix the Makefile to make that work, and you use that in a git-remote-helpers, or git-hg, or whatever you want to call the package.

Also, I make a tag: v1.8.4.1-fc1, so you can use that to build the package.

How does that sound?

lu-zero commented 11 years ago

Having a tarball with the two scripts seems all I need (possibly with a readme with deps and a makefile).

Why they aren't getting in btw?

felipec commented 11 years ago

You cannot use those scripts like that. Some distributions use /usr/bin/python, others /usr/bin/python2, so regardless of which one I choose, it won't work for some people, that's why for distributions, the scripts must be generated, and Git uses the PYTHON_PATH variable.

If you do:

make SCRIPT_PYTHON='git-remote-hg.py git-remote-bzr.py' install-python-script

All of this would be handled for you, and the scripts would be installed to $prefix/libexec/git-core, which is where Git would expect them to be.

You can take the packaging rules for Git, and replace 'make install' with the command above, and everything would just work.

lu-zero commented 11 years ago

Sounds good as well.

On Sun, Sep 29, 2013 at 7:06 PM, Felipe Contreras notifications@github.comwrote:

You cannot those scripts like that. Some distributions use /usr/bin/python, others /usr/bin/python2, so regardless of which one I choose, it won't work for some people, that's why for distributions, the scripts must be generated, and Git uses the PYTHON_PATH variable.

If you do:

make SCRIPT_PYTHON='git-remote-hg.py git-remote-bzr.py' install-python-script

All of this would be handled for you, and the scripts would be installed to $prefix/libexec/git-core, which is where Git would expect them to be.

You can take the packaging rules for Git, and replace 'make install' with the command above, and everything would just work.

— Reply to this email directly or view it on GitHubhttps://github.com/felipec/git/issues/45#issuecomment-25324292 .

felipec commented 11 years ago

All right, I've made the changes and the tag 'v1.8.4.1+fc1'. Here's how the package would look like in Arch Linux:

pkgname=git-remote-helpers
pkgver=1.8.4.1+fc1
pkgrel=1
pkgdesc='Support for foreign repositories in Git'
arch=(any)
url='https://github.com/felipec/git'
license=('GPL2')
depends=('python2')
optdepends=('mercurial: support for Mercurial repositories'
            'bzr: support for Bazaar repositories')
source=("https://github.com/felipec/git/archive/v${pkgver}.tar.gz")
sha1sums=('0154003b7369a379105a00584952b3ecd8659b93')

package() {
  export PYTHON_PATH='/usr/bin/python2'
  cd "$srcdir/git-${pkgver/+/-}"
  make prefix=/usr gitexecdir=/usr/lib/git-core \
    SCRIPT_PYTHON='git-remote-hg.py git-remote-bzr.py' \
    DESTDIR="$pkgdir" install-python-script
}
felipec commented 11 years ago

Is this working as expected?