[Buildbot-devel] Mac's "cat" behaves strangely if encapsulated in buildbot's ShellCommand

Ben Hearsum bhearsum at mozilla.com
Wed Jul 14 13:51:58 UTC 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

>   The solution is to specify your command as a string, so it will be run by
>   `/bin/sh`:
> 
>     factory.addStep(ShellCommand(
>         command="rm *.old",
>         ...))
> 
>    However, this can introduce all the classic shell quoting nightmares.
> """

You can also use:
command=["bash", "-c", "rm *.old"]

which is a little bit cleaner.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Darwin)

iEYEARECAAYFAkw9wP4ACgkQJE25Np0n+NsjtQCgj3mNhnBvEqe3nReWpRE+cn+N
hgkAn0iFODYTMWQnpCiTNjjCZDUWByR6
=NTKj
-----END PGP SIGNATURE-----




More information about the devel mailing list