git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christian Couder <christian.couder@gmail.com>
To: "Konrád Lőrinczi" <klorinczi@gmail.com>
Cc: git <git@vger.kernel.org>
Subject: Re: Suggestion: group files in GIT
Date: Mon, 8 Jun 2015 21:48:59 +0200	[thread overview]
Message-ID: <CAP8UFD24qiRzfPSkCppV-yPkoTVuwkJ+FDUGsv0Zrf66yOedOg@mail.gmail.com> (raw)
In-Reply-To: <CABEDGg8-B1QzkDas1dCcC7QivfOJuaGydki3OpON2T2WFVttFg@mail.gmail.com>

On Mon, Jun 8, 2015 at 10:50 AM, Konrád Lőrinczi <klorinczi@gmail.com> wrote:
> I would like to group some files, so I can list group files together,
> list group changes together, filter by group for staging, also order
> by group.
> It seems, there is no such feature in GIT I would need, so I send it
> as suggestion.
>
> We can call this feature as "Group files" or "Label files" (labeling
> is used in Gmail, so this may be also a naming alternative).
>
>
> Example file list I would like to group together into [group1]:
> theme/header.php
> theme/footer.php
> theme/body.php
> lib/theme.php

Can't you use a shell variable like:

group1="theme/header.php theme/footer.php theme/body.php lib/theme.php"

?

> They are in different directories, but mostly belongs together, so if
> I group them, then I can work easier with them.
>
>
> - I could select a file group for staging, so only the changes in the
> group would be added to stage.

git add $group1

> Changed files in the group:
> [group1]/theme/header.php
> [group1]/lib/theme.php
>
>
> - I could list files filtered by a group. Files filtered by [group1]:
> [group1]/theme/header.php
> [group1]/theme/footer.php
> [group1]/theme/body.php
> [group1]/lib/theme.php

ls -l $group1

> - I could order file list to list group files first, then directory files.
> [group1]/theme/header.php
> [group1]/theme/footer.php
> [group1]/theme/body.php
> [group1]/lib/theme.php
> other/files.php

I am not sure I see what you want to do with that.

      reply	other threads:[~2015-06-08 19:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-08  8:50 Suggestion: group files in GIT Konrád Lőrinczi
2015-06-08 19:48 ` Christian Couder [this message]

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=CAP8UFD24qiRzfPSkCppV-yPkoTVuwkJ+FDUGsv0Zrf66yOedOg@mail.gmail.com \
    --to=christian.couder@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=klorinczi@gmail.com \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).