Re: [PATCH v4 2/5] unpack-trees: add performance tracing

2018-08-12 Thread Thomas Adam
On Sun, 12 Aug 2018 at 09:19, Nguyễn Thái Ngọc Duy wrote: Hi, > + trace_performance_leave("cache_tree_update"); I would suggest trace_performance_leave() calls use __func__ instead. That way, there's no ambiguity if the function name ever changes. Kindly, Thomas

Re: [PATCH] git-send-email: fix get_maintainer.pl regression

2017-12-12 Thread Thomas Adam
ore perl modules. Every perl program does this, and they don't go down this route of having copies of various CPAN modules just in case. So why should we? We're not a special snowflake. -- Thomas Adam

Re: [PATCH] git-send-email: fix get_maintainer.pl regression

2017-12-11 Thread Thomas Adam
n spare time hacking ;-) > > I guess the full solution is to make Mail::Address a hard dependency? This is what I was suggesting, and then as a follow-up, addressing the point that there's a bunch of require() hacks to also get around needing hard-dependencies. -- Thomas Adam

Re: [PATCH v4 0/2] launch_editor(): indicate that Git waits for user input

2017-11-30 Thread Thomas Adam
On Thu, Nov 30, 2017 at 03:12:17PM -0500, Jeff King wrote: > On Wed, Nov 29, 2017 at 06:35:16PM +0000, Thomas Adam wrote: > > > On Wed, Nov 29, 2017 at 03:37:50PM +0100, lars.schnei...@autodesk.com wrote: > > > + if (print_waiting_for_editor) { > > > +

Re: [PATCH v4 0/2] launch_editor(): indicate that Git waits for user input

2017-11-30 Thread Thomas Adam
On Thu, Nov 30, 2017 at 02:55:35PM +0100, Lars Schneider wrote: > > > On 29 Nov 2017, at 19:35, Thomas Adam wrote: > > > > On Wed, Nov 29, 2017 at 03:37:50PM +0100, lars.schnei...@autodesk.com wrote: > >> + if (print_waiting_for_editor) { > >> +

Re: [PATCH v4 0/2] launch_editor(): indicate that Git waits for user input

2017-11-29 Thread Thomas Adam
ypically unbuffered on most systems I've used, and although the call to fflush() is harmless, I suspect it's not having any effect. That said, there's plenty of other places in Git which seems to think fflush()ing stderr actually does something. -- Thomas Adam

Re: [PATCH] git-send-email: fix get_maintainer.pl regression

2017-11-22 Thread Thomas Adam
ay not have additional functionality depending on which modules are installed. Given the pretty good state of packaging across those platforms which Git runs on, I would argue we're now in a much better position to explicitly check for non-core modules at BEGIN{} time, and moan loudly if they're not installed. -- Thomas Adam

Re: [PATCH] git-send-email: fix get_maintainer.pl regression

2017-11-21 Thread Thomas Adam
to the > appropriate bits. Maybe Matthieu or Remi (CC'ed) might want to chime in > on other options? Trying to come up with a reinvention of regexps for email addresses is asking for trouble, not to mention a crappy rod for your own back. Don't do that. This is why people use Mail::Address. https://metacpan.org/pod/distribution/MailTools/lib/Mail/Address.pod -- Thomas Adam

Re: [PATCH v4 3/7] remote-mediawiki: show known namespace choices on failure

2017-11-07 Thread Thomas Adam
id; Oops. This was my typo from my original suggestion. The hash is '%namespace_id', not '%namespaces_id'. However, how did this slip through testing? I'm assuming you blindly copied this from my example, which although quick to do, is only being caught because of my sharp eyes... -- Thomas Adam

Re: [PATCH v4 2/7] remote-mediawiki: allow fetching namespaces with spaces

2017-11-06 Thread Thomas Adam
; s/_/ /g; $_; } split(/[ \n]/, run_git("config --get-all remote.${remotename}.namespaces")); This would, once again, avoid creating @tracked_namespaces, and iterating over it. Note that this isn't about trying to 'golf' this; it's a performance consideration. Kindly, Thomas Adam

Re: [PATCH 3/4] remote-mediawiki: show known namespace choices on failure

2017-11-04 Thread Thomas Adam
paces) { s/ /_/g; } I am sure we can improve upon the need to process @namespaces twice: my @namespaces = map { s/ /_/g; $_; } sort keys %namespaces_id; -- Thomas Adam

Re: [PATCH v3 7/7] remote-mediawiki: show progress while fetching namespaces

2017-11-04 Thread Thomas Adam
bly wiser to transition this to using Carp in the long run -- it would decrease the round-trip time to debugging should there be a situation where that was needed, and hence I would recommend using "warn" for less-severe errors/debugging. -- Thomas Adam

Re: [PATCH v3 7/7] remote-mediawiki: show progress while fetching namespaces

2017-11-02 Thread Thomas Adam
On Thu, Nov 02, 2017 at 06:26:43PM -0400, Antoine Beaupré wrote: > On 2017-11-02 22:18:07, Thomas Adam wrote: > > Hi, > > > > On Thu, Nov 02, 2017 at 05:25:18PM -0400, Antoine Beaupré wrote: > >> +print {*STDERR} "$#{$mw_pages} found in namespace >

Re: [PATCH v3 7/7] remote-mediawiki: show progress while fetching namespaces

2017-11-02 Thread Thomas Adam
Hi, On Thu, Nov 02, 2017 at 05:25:18PM -0400, Antoine Beaupré wrote: > +print {*STDERR} "$#{$mw_pages} found in namespace $local_namespace > ($namespace_id)\n"; How is this any different to using warn()? I appreciate you're using a globbed filehandle, but it seems superfluous to me. Ki

Ascertaining amount of "original" code across files/repo

2017-10-22 Thread Thomas Adam
:' -k2 -nr Given this, I then did some maths on the total lines from each of those files and to work out a percentage by file, and over all. What I'm curious to know is whether this approach of using "git blame" is a good approach or not. Thanks for your time. -- Thomas Adam

Re: When does git check for branch-X being uptodate with origin/branch-X?

2016-03-21 Thread Thomas Adam
that removing it is a bad idea, then good, we don't have to > bother discussing that option. :) Ah, oops! I was meaning more, whether to print the message in the case where the branch was uptodate, but now I appreciate it's cached. Apologies for the confusion. -- Thomas A

Re: When does git check for branch-X being uptodate with origin/branch-X?

2016-03-21 Thread Thomas Adam
cache was last updated? That is: "branch-X is uptodate with origin/branch-X (as of DD-MM-YY HH:MM:SS)" No one's suggesting that this message is removed, I'm not sure where you got that from? -- Thomas Adam -- To unsubscribe from this list: send the line "unsubscr

Re: When does git check for branch-X being uptodate with origin/branch-X?

2016-03-21 Thread Thomas Adam
understand how to use git-fetch, it's more a case of whether even printing that message is useful? I appreciate it can only go on the cached value, but it is still misleading to print that in the case where the cache might not be up to date. Of course, determining that is a different pro

When does git check for branch-X being uptodate with origin/branch-X?

2016-03-21 Thread Thomas Adam
ward [...] Clearly, it's obvious that "Your branch is up-to-date with 'fvwmorg/master'." is misleading. Note that in this case, there's no passwords or other hindrances to Git being able to work out that a branch is behind another. Any light that can be shed on t

Re: [RFC] Code reorgnization

2016-03-19 Thread Thomas Adam
llowing new subdirs I wonder whether previous discussions on this still count? See: http://marc.info/?l=git&m=129650572621523&w=1 -- Thomas Adam -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More m

Re: Question about rerere

2014-11-06 Thread Thomas Adam
ter that. Have a look at contrib/rerere-train.sh -- Thomas Adam -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v1 1/2] Remove 'git archimport'

2014-05-09 Thread Thomas Adam
getting your own way. You have a fork of git which you created, go away and use it. -- Thomas Adam -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] contrib/diff-highlight: multibyte characters diff

2014-02-12 Thread Thomas Adam
ed $decoded check. > + ($decoded, sub { encode_utf8(shift) }) : > + ($orig, sub { shift }); > +} > + -- Thomas Adam -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] status: display the SHA1 of the commit being currently processed

2013-06-17 Thread Thomas Adam
*/ > + if (!stopped_sha) { > + stopped_sha = "a commit"; > + must_free_stopped_sha = 0; > + } Rather than having to assign a toggle of deciding when to free stopped_sha, how much overhead would be introduced by just doing: if (!stopped_sha) stopped_sha = st

Re: [PATCH] Documentation/CommunityGuidelines

2013-06-13 Thread Thomas Adam
problem is still here, and isn't going to go away, no matter how much referring to these guidelines might help. That is why I think this is the wrong thing to do. -- Thomas Adam -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v3] Add new @ shortcut for HEAD

2013-05-01 Thread Thomas Adam
nflicts with this idea, so lets > > s/lets/let's/ (contraction of "let us") Ah, the contraction versus the first person singular. In this case where the context is concluding in decision, rather than making a statement ("Let's go to the shops", for example) then

[RFC PATCH 1/1] status: Allow for short-form via config option

2012-11-11 Thread Thomas Adam
It is currently not possible to use the short-form output of git status without declaring an alias to do so. This isn't always desirable therfore, define a git config option which can be set to display the short-form: status.shortwithbranch Signed-off-by: Thomas Adam --- builtin/commit.c

[RFC PATCH 0/1] status: Allow for short-form output by default

2012-11-11 Thread Thomas Adam
this would relate to that, if at all? Kindly, Thomas Adam (1): status: Allow for short-form via config option builtin/commit.c | 12 1 file changed, 12 insertions(+) -- 1.7.11.4 -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a mess

Re: [PATCH v4 00/13] New remote-hg helper

2012-11-02 Thread Thomas Adam
. And no, you cannot philosophise this, or wriggle out of it through idealism or some other "charter" or "code of conduct" -- as reviewers of your code, we have to interact with you to be able to better it. But you seem very reluctant to do that. The fact that we're even ha

Re: Wrap commit messages on `git commit -m`

2012-11-01 Thread Thomas Adam
nd the > resulting `git log` output is ugly. So, I was wondering if it would > be a good idea to wrap these one-liners to 72 characters > automatically. Can't you do this already? From "git-log(1)": %w([[,[,]]]): switch line wrapping, like the -w option of git-shortlog(1).