You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@whimsical.apache.org by Sam Ruby <ru...@intertwingly.net> on 2018/06/26 05:53:49 UTC
Re: [whimsy] branch master updated: Eeek!
Perhaps this would help?
https://github.com/apache/whimsy/blob/master/lib/whimsy/asf/person.rb#L14
- Sam Ruby
On Mon, Jun 25, 2018 at 10:15 PM, <se...@apache.org> wrote:
> This is an automated email from the ASF dual-hosted git repository.
>
> sebb pushed a commit to branch master
> in repository https://gitbox.apache.org/repos/asf/whimsy.git
>
>
> The following commit(s) were added to refs/heads/master by this push:
> new b583508 Eeek!
> b583508 is described below
>
> commit b583508af2140d1b5576c9de635abc96074d9501
> Author: Sebb <se...@apache.org>
> AuthorDate: Tue Jun 26 03:15:01 2018 +0100
>
> Eeek!
> ---
> lib/whimsy/asf/memapps.rb | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lib/whimsy/asf/memapps.rb b/lib/whimsy/asf/memapps.rb
> index 3f4ef47..64a7a8d 100644
> --- a/lib/whimsy/asf/memapps.rb
> +++ b/lib/whimsy/asf/memapps.rb
> @@ -40,7 +40,7 @@ module MemApps
> name.strip.downcase.
> gsub(/[.,()"]/,''). # drop punctuation (keep ')
> # drop most accents
> - gsub('ú','u').gsub(/[óøò]/,'o').gsub(/[čć]/,'c').gsub('é','e').gsub('á','a').gsub('ž','z').gsub('í','i').
> + gsub('ú','u').gsub(/[óøò]/,'o').gsub(/[čć]/,'c').gsub(/[éëè]/,'e').gsub('á','a').gsub('ž','z').gsub('í','i').
> gsub(/\s+/, '-').untaint # space to '-'
> end
>
>
Re: [whimsy] branch master updated: Eeek!
Posted by sebb <se...@gmail.com>.
Just noticed the final line of asciize:
name.strip.gsub /[^\w]+/, '-'
At present apostrophes (single-quotes) are preserved in names such as O'Hare.
That can result in quoting issues when using the command-line so maybe
those need to be renamed as well.
On 26 June 2018 at 11:15, sebb <se...@gmail.com> wrote:
> On 26 June 2018 at 06:53, Sam Ruby <ru...@intertwingly.net> wrote:
>> Perhaps this would help?
>
> I saw that, however sometimes ä, ö and ü are converted to ae, oe & ue
> and sometimes just to a, o & u (etc).
> Also the source names themselves are not always consistent.
>
> But maybe it would be better to just use that code and rename any
> files that don't fit the pattern.
> I suspect there will still be some exceptions...
>
> I'll give it a try.
>
>> https://github.com/apache/whimsy/blob/master/lib/whimsy/asf/person.rb#L14
>>
>> - Sam Ruby
>>
>> On Mon, Jun 25, 2018 at 10:15 PM, <se...@apache.org> wrote:
>>> This is an automated email from the ASF dual-hosted git repository.
>>>
>>> sebb pushed a commit to branch master
>>> in repository https://gitbox.apache.org/repos/asf/whimsy.git
>>>
>>>
>>> The following commit(s) were added to refs/heads/master by this push:
>>> new b583508 Eeek!
>>> b583508 is described below
>>>
>>> commit b583508af2140d1b5576c9de635abc96074d9501
>>> Author: Sebb <se...@apache.org>
>>> AuthorDate: Tue Jun 26 03:15:01 2018 +0100
>>>
>>> Eeek!
>>> ---
>>> lib/whimsy/asf/memapps.rb | 2 +-
>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/lib/whimsy/asf/memapps.rb b/lib/whimsy/asf/memapps.rb
>>> index 3f4ef47..64a7a8d 100644
>>> --- a/lib/whimsy/asf/memapps.rb
>>> +++ b/lib/whimsy/asf/memapps.rb
>>> @@ -40,7 +40,7 @@ module MemApps
>>> name.strip.downcase.
>>> gsub(/[.,()"]/,''). # drop punctuation (keep ')
>>> # drop most accents
>>> - gsub('ú','u').gsub(/[óøò]/,'o').gsub(/[čć]/,'c').gsub('é','e').gsub('á','a').gsub('ž','z').gsub('í','i').
>>> + gsub('ú','u').gsub(/[óøò]/,'o').gsub(/[čć]/,'c').gsub(/[éëè]/,'e').gsub('á','a').gsub('ž','z').gsub('í','i').
>>> gsub(/\s+/, '-').untaint # space to '-'
>>> end
>>>
>>>
Re: [whimsy] branch master updated: Eeek!
Posted by sebb <se...@gmail.com>.
On 26 June 2018 at 06:53, Sam Ruby <ru...@intertwingly.net> wrote:
> Perhaps this would help?
I saw that, however sometimes ä, ö and ü are converted to ae, oe & ue
and sometimes just to a, o & u (etc).
Also the source names themselves are not always consistent.
But maybe it would be better to just use that code and rename any
files that don't fit the pattern.
I suspect there will still be some exceptions...
I'll give it a try.
> https://github.com/apache/whimsy/blob/master/lib/whimsy/asf/person.rb#L14
>
> - Sam Ruby
>
> On Mon, Jun 25, 2018 at 10:15 PM, <se...@apache.org> wrote:
>> This is an automated email from the ASF dual-hosted git repository.
>>
>> sebb pushed a commit to branch master
>> in repository https://gitbox.apache.org/repos/asf/whimsy.git
>>
>>
>> The following commit(s) were added to refs/heads/master by this push:
>> new b583508 Eeek!
>> b583508 is described below
>>
>> commit b583508af2140d1b5576c9de635abc96074d9501
>> Author: Sebb <se...@apache.org>
>> AuthorDate: Tue Jun 26 03:15:01 2018 +0100
>>
>> Eeek!
>> ---
>> lib/whimsy/asf/memapps.rb | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/lib/whimsy/asf/memapps.rb b/lib/whimsy/asf/memapps.rb
>> index 3f4ef47..64a7a8d 100644
>> --- a/lib/whimsy/asf/memapps.rb
>> +++ b/lib/whimsy/asf/memapps.rb
>> @@ -40,7 +40,7 @@ module MemApps
>> name.strip.downcase.
>> gsub(/[.,()"]/,''). # drop punctuation (keep ')
>> # drop most accents
>> - gsub('ú','u').gsub(/[óøò]/,'o').gsub(/[čć]/,'c').gsub('é','e').gsub('á','a').gsub('ž','z').gsub('í','i').
>> + gsub('ú','u').gsub(/[óøò]/,'o').gsub(/[čć]/,'c').gsub(/[éëè]/,'e').gsub('á','a').gsub('ž','z').gsub('í','i').
>> gsub(/\s+/, '-').untaint # space to '-'
>> end
>>
>>