From: Alexey Gladkov <legion@altlinux.ru>
To: ALT Linux Team development discussions <devel@lists.altlinux.org>
Subject: Re: [devel] [PATCH 1/3] Introduce nodiff directive for gear-rules
Date: Thu, 26 Nov 2020 16:17:01 +0100
Message-ID: <20201126151701.zm627zsqorxzd52z@example.org> (raw)
In-Reply-To: <20201126145439.GA2742643@portlab>
On Thu, Nov 26, 2020 at 05:54:39PM +0300, Vladimir D. Seleznev wrote:
> On Thu, Nov 26, 2020 at 03:49:27PM +0100, Alexey Gladkov wrote:
> > On Thu, Nov 26, 2020 at 05:16:34PM +0300, Vladimir D. Seleznev wrote:
> > > The directive specifies a glob pattern that define files that should be
> > > excluded from diff generation.
> >
> > Мои комментарии относятся только к технической части. Относительно
> > именования директив и нужности директивы вообще должен Дима высказаться.
> >
> > Лично мне не нравится, что опция для директивы diff сделана директивой.
> > Это выглядит хаком. У вас аргумент nodiff не может иметь пробелы. В этом
> > случае несложно сделать `diff: exclude=glob_pattern`.
>
> Я просто исходил из логики, что в подавляющей большинстве случаев там,
> где это уместно использовать, rules будет выглядеть так:
>
> tar: v@version@:.
> diff: v@version@:. .
> nodiff: .gear
У тебя, кстати, для такого варианта нет проверки, что указан nodiff, но
нет директивы diff так как это явная ошибка.
> В этом плане
>
> tar: v@version@:.
> diff: v@version@:. exclude=.gear
>
> по-моему выглядит менее красиво. Но я могу подготовить и такой вариант.
Для меня это выглядит более понятно так как первый вариант выглядит
понятно только если знать, что nodiff это опция директивы diff.
Если хотите увеличить читабильность, то давайте реализуем многострочные
директивы. Тогда можно будет написать:
tar: v@version@:.
diff: v@version@:. . \
name=@new_dir@-@version@-@release@.patch \
exclude=.gear
--
Rgrds, legion
next prev parent reply other threads:[~2020-11-26 15:17 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-26 14:16 Vladimir D. Seleznev
2020-11-26 14:16 ` [devel] [PATCH 2/3] tests: add test for nodiff directive Vladimir D. Seleznev
2020-11-26 14:16 ` [devel] [PATCH 3/3] tests: check nodiff does not fail if pattern matches no file Vladimir D. Seleznev
2020-11-26 14:49 ` [devel] [PATCH 1/3] Introduce nodiff directive for gear-rules Alexey Gladkov
2020-11-26 14:54 ` Vladimir D. Seleznev
2020-11-26 15:17 ` Alexey Gladkov [this message]
2020-11-26 15:20 ` Anton Farygin
2020-11-26 15:51 ` Alexey Gladkov
2020-12-09 2:10 ` Dmitry V. Levin
2020-12-09 10:40 ` Alexey Gladkov
2020-12-09 14:39 ` [devel] gear-rules: allow backslashes to escape any characters Dmitry V. Levin
2020-12-09 14:48 ` Vladimir D. Seleznev
2020-12-09 15:51 ` Alexey Gladkov
2020-12-10 10:31 ` Dmitry V. Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201126151701.zm627zsqorxzd52z@example.org \
--to=legion@altlinux.ru \
--cc=devel@lists.altlinux.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
ALT Linux Team development discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
public-inbox-index devel
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.devel
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git