gitlabhq / grit

Grit gives you object oriented read/write access to Git repositories via Ruby. Patched for GitLab
gitlab.org
MIT License
59 stars 55 forks source link

force utf-8 encoding on object name #3

Closed NARKOZ closed 12 years ago

NARKOZ commented 12 years ago

Forces object name to utf-8 to support some more exotic characters.

Fixes: gitlabhq/gitlabhq#175 gitlabhq/gitlabhq#473

dzaporozhets commented 12 years ago

please test for this one. We should be careful with this grit

blmarket commented 12 years ago

This patch seems not work at ruby 1.8.7 because 1.8.7 doesn't support force_encoding.

dzaporozhets commented 12 years ago

We dont need 1.8.7 support.

SaitoWu commented 12 years ago

I think its not a good idea, eg: windows use 'gbk' or others encoding for filename/path.

What we really need to do is force_encoding('ascii-8bit') at models/Tree, I think.

Maybe a dup of string.

SaitoWu commented 12 years ago

@randx Also, I think we can merge /mojombo/grit/#85 to speed up our grit.

dzaporozhets commented 12 years ago

@SaitoWu Create an issue please as reminder for me

SaitoWu commented 12 years ago

@randx u should open gitlabhq/grit 's issues first. :smile:

dzaporozhets commented 12 years ago

@SaitoWu :)

NARKOZ commented 12 years ago

Closing in favor of gitlabhq/gitlabhq#1438