17 June 2007

A .dsc/.changes aware scp

Every time I make a new emacs-snapshot release I have to copy the source package from my amd64 desktop to my i386 laptop to build it, then copy the built packages back in order to upload them. This scp'ing gets tiring after a while, so I wrote a trivial script called dscp which acts as a Debian-aware wrapper around scp, using python-deb822. It's similar in spirit to Myon's dget script, which does pretty much the same thing with wget.

Note that unlike scp it can only copy files to other machines, and currently does no command-line parsing at all, so you cannot pass options to scp (other than the user@host:/bla part, of course).

Also note that if the destination is local it will serve as a .dsc/.changes aware cp, which is also handy in some situations.

If there's interest I could probably add some sanity checks and propose it for inclusion into devscripts.

6 comments:

CLAIRE D'ETE said...

Well OF COURSE I'd thought of it, but I've already got something better, A Cfter which can actually terpit your FCG Spritz into jervexes, but you can only use it under Chicstool.It does include a boogybooster though, which allows weenturf users to handle the choco codes even if they don't understand a single word you say ;-)

Romain Francoise said...

Claire: you may want to skip entries tagged 'tech' in my blog, then. :)

Hamish said...

Nice.. but why not let the buildds build your i386 package? Or use an i386 chroot or pbuilder on your amd64 machine?

Fortunately the days when amd64 binaries can't be uploaded are long past.. :(

Romain Francoise said...

Hamish: I can't use the buildds because this package is not in Debian; and I *could* use an i386 chroot to build the packages but I like to test them on a real i386 machine before uploading them, so it's simpler to build them there too...

glandium said...

Why not just use dput with a specially crafted rule like:

[scp]
method = scp
fqdn = host.name
incoming = /directory
run_dinstall = 0

(you can also add
allow_unsigned_uploads = 1
if necessary)

Anonymous said...

why not sshfs/nfs?