Message ID | 20180403161836.9675-1-vkabatov@redhat.com |
---|---|
State | Accepted |
Headers | show |
Series | [docs] Fix incorrect autodelegation documentation | expand |
vkabatov@redhat.com writes: > From: Veronika Kabatova <vkabatov@redhat.com> > > The docs suggested to account for git prefixes (a/, b/) using eg. > ?/patchwork/views/*. My rules didn't work so I tried bare path > (patchwork/views/*) instead. Looking at the code, the prefix really is > striped away (filename = '/'.join(filename.split('/')[1:])). Fix the > documentation to reflect on what is really happening. Huh, right you are. It looks like this is a result of: 7bb0ebd78ff7 ("parser: Add patch_get_filenames()"), although I can't figure out if the documentation pre- or post-dates that. I am a bit concerned that the behaviour might be wrong for SVN or CVS, but I haven't used either in so long that I can't remember. And I guess no-one has reported a bug since that went in in late 2015. Anyway, looks good to me. Applied. Regards, Daniel > > Signed-off-by: Veronika Kabatova <vkabatov@redhat.com> > --- > docs/usage/delegation.rst | 15 +++++---------- > 1 file changed, 5 insertions(+), 10 deletions(-) > > diff --git a/docs/usage/delegation.rst b/docs/usage/delegation.rst > index eaabc20..8b99871 100644 > --- a/docs/usage/delegation.rst > +++ b/docs/usage/delegation.rst > @@ -30,21 +30,16 @@ Path > > A path in `fnmatch`__ format. The fnmatch library allows for limited, Unix > shell-style wildcarding. Filenames are extracted from patch lines beginning > - with ``---`` or ``+++``. Note that for projects using Git or Mercurial, the > - tools these VCS provide for producing patches are prefixed with `a` or `b`. > - You should account for this in your path. For example, to match the path > - `patchwork/views` (relative to the top of a Git repo) your pattern should > - be:: > + with ``---`` or ``+++``. > > - ?/patchwork/views/* > + You can simply use a bare path:: > > - It is also possible to use relative paths, such as:: > + patchwork/views/about.py > > - */manage.py > + Or it is also possible to use relative paths, such as:: > > - For projects using other VCSs like Subversion can simply use a bare path:: > + */manage.py > > - patchwork/views/* > > Rules are configured by setting the above fields and saving the rules. These > rules will be applied at patch parse time. > -- > 2.13.6 > > _______________________________________________ > Patchwork mailing list > Patchwork@lists.ozlabs.org > https://lists.ozlabs.org/listinfo/patchwork
diff --git a/docs/usage/delegation.rst b/docs/usage/delegation.rst index eaabc20..8b99871 100644 --- a/docs/usage/delegation.rst +++ b/docs/usage/delegation.rst @@ -30,21 +30,16 @@ Path A path in `fnmatch`__ format. The fnmatch library allows for limited, Unix shell-style wildcarding. Filenames are extracted from patch lines beginning - with ``---`` or ``+++``. Note that for projects using Git or Mercurial, the - tools these VCS provide for producing patches are prefixed with `a` or `b`. - You should account for this in your path. For example, to match the path - `patchwork/views` (relative to the top of a Git repo) your pattern should - be:: + with ``---`` or ``+++``. - ?/patchwork/views/* + You can simply use a bare path:: - It is also possible to use relative paths, such as:: + patchwork/views/about.py - */manage.py + Or it is also possible to use relative paths, such as:: - For projects using other VCSs like Subversion can simply use a bare path:: + */manage.py - patchwork/views/* Rules are configured by setting the above fields and saving the rules. These rules will be applied at patch parse time.