2) Make a tag to the commit you want to reference.
Cheers,
Rafael Ascensão
You can achieve something close (on small repos, more on that later) with:
$ git log --graph --color \
--format='%C(auto)changeset: %h:%H%nuser: %an%ndate: %ad%nsummary:
%s%n' \
| git name-rev --refs=$(git rev-parse --abbrev-ref HEAD) --name-only --stdin
* changeset: 5fa0f52
I missed this RFC series which fixes this and others issues:
https://public-inbox.org/git/20180405173446.32372-1-new...@gmail.com
Cheers,
Rafael Ascensão
---
Yesterday on #git, an user reported the following behaviour of
git clean:
$ git init
$ mkdir foo
$ touch a.txt b.txt bar.txt foo/qux.txt
$ git clean -f bar.txt foo/qux.txt
Removing bar.txt
Where the behaviour they expected would be:
$ git clean -f bar.txt foo/qux.tx
mine which format should be used with --graph.
This would still require user configuration which may be what you were
trying to avoid by proposing the change in default behaviour.
Settling for a compromise feels like giving up on the strengths from both.
Cheers,
Rafael Ascensão
h -.
In other words, git log --boundary .. should give you
exactly what you asked with the small caveat it marks excluded commits
differently.
Cheers,
Rafael Ascensão
3e5d2a5d873 for an example.
But my nitpick wasn't necessarily because I didn't agree about the way
you line wrapped the patch. It was about figuring out if you had a
misconfigured editor (that could also be the cause of tabs and spaces
mix), which you later mentioned was probably the case.
Cheers,
Rafael Ascensão
This issue was mentioned previously here in the mailing list.
Here it is for reference:
https://public-inbox.org/git/3305f7dc-0044-41fe-8aab-ee800535d...@kde.org/
Cheers,
Rafael Ascensão
omething else. For example adding `--list-head` instead,
as discussed in early versions of this patch.
https://public-inbox.org/git/20181011223457.GB7131@rigel/
Cheers,
Rafael Ascensão
On Fri, Dec 14, 2018 at 12:30:28PM +, Oliver Joseph Ash wrote:
> I believe I have found a bug in `git commit --fixup`.
That's not a bug, it's actually the documented behaviour of rebase
--autosquash.
As you figured out, the squash/fixup is based on whether the message
has the squash!/fixup! p
an ok combination.
But I can see where personal preference starts to play a role here, as
the logical solution isn't good enough. Which makes the case for being
able to configure a bit stronger.
Cheers,
Rafael Ascensão
27; which context the exclude
pattern is tied to, so refs.c:filter_refs() can decide if it should
ignore the prefix when trying to match.
Signed-off-by: Rafael Ascensão
---
refs.c | 4
t/t6018-rev-list-glob.sh | 24
2 files changed, 16 insertions(
--branches`, `--tags`, `--remotes` use the optional
inclusive glob.
Demonstrate this failure.
Signed-off-by: Rafael Ascensão
---
t/t6018-rev-list-glob.sh | 60 ++--
1 file changed, 57 insertions(+), 3 deletions(-)
diff --git a/t/t6018-rev-list-glob.sh b/t/t601
While trying to set up some aliases for my own use, I found out that
--exclude with --branches behave differently depending if the latter
uses globs.
I tried to fix it making my 2nd contribution. :)
Cheers,
Rafael Ascensão (2):
refs: show --exclude failure with --branches/tags/remotes=glob
necessary" helper and do everything
> inside cmd_branch(), so perhaps this can be made function local, no?
>
I was not sure if these 3 lines were global intentionally or if it was
just an artifact from the past. Since it looks like the latter, I'll
make them local.
--
Rafael Ascensão
logic to the more reliable check for the detached head.
Signed-off-by: Rafael Ascensão
---
This patch is meant to be either applied or squashed on top of the
current series.
I am basing the claims of it being more reliable of what Junio suggested
on a previous iteration of this series:
https://p
ced, is that you're using %p with --graph. And --graph
enables parent rewriting. Which may surprise you if you don't know what
it does.
But apart from that, and assuming you only did `git merge f087081868`
everything looks normal between those two pastes.
Cheers,
Rafael Ascensão
the ones that were forcibly added.
If needed, git ls-files can be used to list either category.
Cheers,
Rafael Ascensão
die(_("HEAD not found below refs/heads!"));
What's being proposed can be achieved with
+ } else if (show_current) {
+ if (!filter.detached)
+ puts(head);
+ return 0;
without failing tests.
--
Cheers,
Rafael Ascensão
and it would coalesce nicely as long as --list-head conforms with the
default formatting for --list.
--
Cheers
Rafael Ascensão
en HEAD is
detached (Showing the detached at message.)
Is there a strong reason to *not* "resolve" HEAD when it is attached?
Would it be that bad to have some DWIM behaviour here? After all, as
HEAD is an invalid name for a branch, nothing would ever match it
anyways.
Thanks for the input. :)
--
Cheers
Rafael Ascensão
Otherwise people will
eventually start parsing it instead of using the recommended plumbing.
--
Cheers
Rafael Ascensão
-- >8 --
diff --git a/builtin/branch.c b/builtin/branch.c
index b67593288c..78a3de526c 100644
--- a/builtin/branch.c
+++ b/builtin/branch.c
@@ -684,6 +684,17 @@ int cmd_bra
g that many new users misunderstand. So, if the original
motivation behind this patch is to be able to determine the current
branch without using the concept of 'HEAD', my suggestion falls short.
Cheers,
Rafael Ascensão
On Thu, Sep 27, 2018 at 03:35:59PM -0400, Jeff King wrote:
> On Thu, Sep 27, 2018 at 08:28:04PM +0100, Rafael Ascensão wrote:
> > But if we're open to change how branches are displayed maybe a config
> > option like branch.format (probably not the best name choice) that can
&g
.
>
I still defend using green and dim green for this case. Because all
these worktrees are in a sense active. They're checked out in some
place. It's just the case that the particular one that we are in is
probably more relevant than the others.
--
Cheers
Rafael Ascensão
mbol and dimmed color would be a nice addition,
but I am leaning towards giving the user the ultimate choice on how they
want to format their output. (Maybe with dimmed plus symbol as default).
--
Cheers,
Rafael Ascensão
On Tue, Jun 19, 2018 at 11:28 AM Heiko Voigt wrote:
>
> Interesting and nobody complained to the mailinglist?
>
On Wed, Jun 20, 2018 at 3:57 PM Duy Nguyen wrote:
>
> Abusing a long standing bug does not make it a feature.
>
To make things clear, I wasn't defending if this should be considered a
On Wed, Jun 20, 2018 at 5:39 AM Kevin Daudt wrote:
>
> What this is about that when doing `git add path/` (with trailing /),
>
This is what I was referring to. If you search for 'Fake Submodules',
you'll see that some people were/are intentionally using this instead of
subtrees or submodules. Unf
On Tue, Jun 19, 2018 at 11:28 AM Heiko Voigt wrote:
>
> Interesting and nobody complained to the mailinglist?
>
For reference this was sometimes called "Fake Submodules" online.
specifying them again and again.
If the path is adding just couple of OPT_PASSTRHU, I could do it. But
I'll wait and see if someone picks your parse-options suggestion.
Thanks for the review.
--
Rafael Ascensão
ation consistent with present behaviour by hiding
unavailable options only.
Reported-by: Marius Giurgi
Signed-off-by: Rafael Ascensão
---
Marius asked on freenode.#git if pull supported `--prune`, upon
inspection seems like the man page was missing some of the supported
options and listing others that ar
`git pull`'s documentation mentions that `--edit` can be used with short
option `-e`. But `git pull` doesn't understand `-e`.
To make things consistent, teach `git pull` `-e` for `--edit`
Signed-off-by: Rafael Ascensão
---
builtin/pull.c | 2 +-
1 file changed, 1 insertion(+),
00 &&
test $A = $(cat .git/PSEUDOREF)
'
fails/succeeds appropriately in my limited testing.
I am busy this weekend, but can try to write some if no one writes it
until after the weekend.
Cumprimentos,
Rafael Ascensão
f: check return values from read_ref(), 2015-07-15)
Thanks,
Rafael Ascensão
efs and shorthand refs)
yet remaining compatible with existent commands.
Helped-by: Kevin Daudt
Helped-by: Junio C Hamano
Signed-off-by: Rafael Ascensão
---
Notable changes since v1:
* Do not change refs.c:for_each_glob_ref. Those changes were meant
to address inconsistencies betwee
On 07/11/17 00:18, Junio C Hamano wrote:
> Jacob Keller writes:
>
> I would have to say that the describe's one is wrong if it does not
> match what for_each_glob_ref() does for the log family of commands'
> "--branches=" etc. describe.c::get_name() uses positive
> and negative patterns, just li
Would checking the output of ref_exists() make sense here?
By that I mean, only add a trailing '/*' if the ref doesn't exist.
Unless I am missing something obvious this would allow us to keep both
shortcuts and exact patterns.
On 06/11/17 01:23, Junio C Hamano wrote:
> Michael Haggerty writes:
>
>> [1] I say "almost entirely" because putting them in one function means
>> that only `pattern` needs to be scanned for glob characters. But that is
>> an unimportant detail.
>
> That could actually be an important detail, in
On 04/11/17 03:49, Junio C Hamano wrote:
Rafael Ascensão writes:
Using `--exclude=` can help mitigate that verboseness by
removing unnecessary 'branches' from the output. However, if the tip of
an excluded ref points to an ancestor of a non-excluded ref, git will
decorate it regard
On 04/11/17 02:27, Junio C Hamano wrote:
Rafael Ascensão writes:
Signed-off-by: Kevin Daudt
Signed-off-by: Rafael Ascensão
Could you explain Kevin's sign-off we see above? It is a bit
unusual (I am not yet saying it is wrong---I cannot judge until I
find out why it is there) to
ltiple times.
Signed-off-by: Kevin Daudt
Signed-off-by: Rafael Ascensão
---
Documentation/git-log.txt | 12 ++
builtin/log.c | 10 -
log-tree.c| 37 ++---
log-tree.h| 6 ++-
pretty.c | 4 +-
revision.c
which can be reused elsewhere
where the same behaviour is needed, and add an ENSURE_GLOB flag
to toggle if a trailing '/*' is to be appended to the result.
Signed-off-by: Kevin Daudt
Signed-off-by: Rafael Ascensão
---
refs.c | 34 --
refs.h |
ike this is worth 5+ command
line options. I personally find that those two are enough.
---
Rafael Ascensão
Rafael Ascensão (2):
refs: extract function to normalize partial refs
log: add option to choose which refs to decorate
Documentation/git-log.txt | 12 ++
built
43 matches
Mail list logo