On Mon, Oct 20, 2008 at 10:26 PM, Jeff Forcier <[EMAIL PROTECTED]> wrote: > Then, your command can expect to get the arguments as keyword > arguments as is normal in Python: > > def upload(f1, f2, f3): > put(f1) > put(f2) > ...
Not in vanilla Fabric 0.0.9. See bellow. > > And, of course, you can do the usual ** trick to take any arbitrary > number of files to upload: > > def upload(**kwargs): > for filename in kwargs.values(): > put(filename) It's kwargs.keys() instead of values(), but otherwise this is the only way to do it. However!!! I just fixed it so it works with values() and your multiple-arguments trick above. Maybe it's something you had in your own branch? > > (Note that I am probably not using the right call signature for > 'put()' here, as it's one part of Fabric I haven't used much yet :)) put takes two arguments: localpath and remotepath, and an optional fail. -- Venlig hilsen / Kind regards, Christian Vest Hansen. _______________________________________________ Fab-user mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/fab-user
