You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by Sam Ruby <ru...@apache.org> on 2016/03/10 13:57:42 UTC

[whimsy.git] [1/1] Commit 7d81d25: try harder to strip whitespace

Commit 7d81d25a38dcc6afba6ef82f87b1e029a69eb714:
    try harder to strip whitespace
    I'll admit that I can see no reason why this should be necessary, and
    yet it seems to occur in log files.  ¯\_(ツ)_/¯


Branch: refs/heads/master
Author: Sam Ruby <ru...@intertwingly.net>
Committer: Sam Ruby <ru...@intertwingly.net>
Pusher: rubys <ru...@apache.org>

------------------------------------------------------------
lib/whimsy/asf.rb                                            | ++ -
------------------------------------------------------------
3 changes: 2 additions, 1 deletions.
------------------------------------------------------------


diff --git a/lib/whimsy/asf.rb b/lib/whimsy/asf.rb
index 9e37ab0..b813d0e 100644
--- a/lib/whimsy/asf.rb
+++ b/lib/whimsy/asf.rb
@@ -19,8 +19,9 @@ def self.library_mtime
     times = sources.map {|source| File.mtime(source)}
     times.max.gmtime
   end
+
   def self.library_gitinfo
     return @info if @info
-    @info = `git show --format="%h  %ci"  -s HEAD`.chomp
+    @info = `git show --format="%h  %ci"  -s HEAD`.strip
   end
 end

Re: [whimsy.git] [1/1] Commit 7d81d25: try harder to strip whitespace

Posted by sebb <se...@gmail.com>.
On 10 March 2016 at 16:07, Sam Ruby <ru...@intertwingly.net> wrote:
> On Thu, Mar 10, 2016 at 10:58 AM, sebb <se...@gmail.com> wrote:
>> On 10 March 2016 at 12:57, Sam Ruby <ru...@apache.org> wrote:
>>> Commit 7d81d25a38dcc6afba6ef82f87b1e029a69eb714:
>>>     try harder to strip whitespace
>>>     I'll admit that I can see no reason why this should be necessary, and
>>>     yet it seems to occur in log files.  ¯\_(ツ)_/¯
>>
>> Thanks, that seems to have fixed it.
>>
>> It's rather odd that this only started happening recently.
>>
>> AFAICT that piece of code has not been changed for ages; perhaps the
>> git client has been updated?
>> The only other possibility I can think of is that $/ has been changed somewhere?
>
> Beats me.  FWIW, I can't reproduce on Whimsy either:
>
> www-data@whimsy-vm2:/srv/whimsy$ irb
> irb(main):001:0> `git show --format="%h  %ci"  -s HEAD`.chomp
> => "7d81d25  2016-03-10 07:57:37 -0500"
> irb(main):002:0>

That tends to suggest the issue may be with $/ ?

>  ¯\_(ツ)_/¯
>
> - Sam Ruby

Re: [whimsy.git] [1/1] Commit 7d81d25: try harder to strip whitespace

Posted by Sam Ruby <ru...@intertwingly.net>.
On Thu, Mar 10, 2016 at 10:58 AM, sebb <se...@gmail.com> wrote:
> On 10 March 2016 at 12:57, Sam Ruby <ru...@apache.org> wrote:
>> Commit 7d81d25a38dcc6afba6ef82f87b1e029a69eb714:
>>     try harder to strip whitespace
>>     I'll admit that I can see no reason why this should be necessary, and
>>     yet it seems to occur in log files.  ¯\_(ツ)_/¯
>
> Thanks, that seems to have fixed it.
>
> It's rather odd that this only started happening recently.
>
> AFAICT that piece of code has not been changed for ages; perhaps the
> git client has been updated?
> The only other possibility I can think of is that $/ has been changed somewhere?

Beats me.  FWIW, I can't reproduce on Whimsy either:

www-data@whimsy-vm2:/srv/whimsy$ irb
irb(main):001:0> `git show --format="%h  %ci"  -s HEAD`.chomp
=> "7d81d25  2016-03-10 07:57:37 -0500"
irb(main):002:0>

 ¯\_(ツ)_/¯

- Sam Ruby

Re: [whimsy.git] [1/1] Commit 7d81d25: try harder to strip whitespace

Posted by sebb <se...@gmail.com>.
On 10 March 2016 at 12:57, Sam Ruby <ru...@apache.org> wrote:
> Commit 7d81d25a38dcc6afba6ef82f87b1e029a69eb714:
>     try harder to strip whitespace
>     I'll admit that I can see no reason why this should be necessary, and
>     yet it seems to occur in log files.  ¯\_(ツ)_/¯

Thanks, that seems to have fixed it.

It's rather odd that this only started happening recently.

AFAICT that piece of code has not been changed for ages; perhaps the
git client has been updated?
The only other possibility I can think of is that $/ has been changed somewhere?

>
> Branch: refs/heads/master
> Author: Sam Ruby <ru...@intertwingly.net>
> Committer: Sam Ruby <ru...@intertwingly.net>
> Pusher: rubys <ru...@apache.org>
>
> ------------------------------------------------------------
> lib/whimsy/asf.rb                                            | ++ -
> ------------------------------------------------------------
> 3 changes: 2 additions, 1 deletions.
> ------------------------------------------------------------
>
>
> diff --git a/lib/whimsy/asf.rb b/lib/whimsy/asf.rb
> index 9e37ab0..b813d0e 100644
> --- a/lib/whimsy/asf.rb
> +++ b/lib/whimsy/asf.rb
> @@ -19,8 +19,9 @@ def self.library_mtime
>      times = sources.map {|source| File.mtime(source)}
>      times.max.gmtime
>    end
> +
>    def self.library_gitinfo
>      return @info if @info
> -    @info = `git show --format="%h  %ci"  -s HEAD`.chomp
> +    @info = `git show --format="%h  %ci"  -s HEAD`.strip
>    end
>  end