On Fri, 2018-06-15 at 15:52 +0200, Petr Vorel wrote: > Signed-off-by: Petr Vorel <petr.vo...@gmail.com>
Makes sense. This is what we do for git-pw, fwiw. Reviewed-by: Stephen Finucane <step...@that.guru> ...and applied. Thanks for the contribution :) Stephen > --- > I like automatic syntax highlight, which requires suffix. > --- > patchwork/bin/pwclient | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/patchwork/bin/pwclient b/patchwork/bin/pwclient > index 29cad89..79137b0 100755 > --- a/patchwork/bin/pwclient > +++ b/patchwork/bin/pwclient > @@ -305,9 +305,10 @@ def action_get(rpc, patch_id): > sys.exit(1) > > base_fname = fname = os.path.basename(patch['filename']) > + fname += '.patch' > i = 0 > while os.path.exists(fname): > - fname = "%s.%d" % (base_fname, i) > + fname = "%s.%d.patch" % (base_fname, i) > i += 1 > > with io.open(fname, 'w', encoding='utf-8') as f: _______________________________________________ Patchwork mailing list Patchwork@lists.ozlabs.org https://lists.ozlabs.org/listinfo/patchwork