前準備
試したこと
cygwin terminal で
$ pwd
/cygdrive/d/tmp
$ mkdir gittest
$ cd gittest
$ git init
Initialized empty Git repository in /cygdrive/d/tmp/gittest/.git/
コマンドプロンプト で
> cd
d:\tmp
> mkdir bzrgittest
> cd bzrgittest
> bzr branch ..\gittest
Branched 0 revision(s).
> cd gittest
適当なエディタで test.txt と テスト.txt を作成する
> bzr add *.txt
adding test.txt
adding "テスト.txt"
> bzr ci -m "test"
Committing to: D:/tmp/bzrgittest/gittest/
added test.txt
added テスト.txt
Committed revision 1.
> bzr push ..\..\gittest
bzr: ERROR: Push is not yet supported for bzr-git. Try dpush instead. (pushコマンドはサポートされてないから変わりに dpush コマンド使ってって)
> bzr dpush ..\..\gittest
Pushed up to revision 1.
cygwin terminalに戻って
$ ls -a
. .. .git
$ git status
# Not currently on any branch.
# Changes to be committed:
# (use "git reset HEAD <file>..." to unstage)
#
# deleted: test.txt
# deleted: "\343\203\206\343\202\271\343\203\210.txt"
#
(pushしたはずなのに消されてるとか言われてよく分からないので、とりあえず git help resetを見てみる。)
$ git reset --hard
HEAD is now at 99f266a test (最後の"test"は bzr ciした時のメッセージかな..)
ls -a
. .. .git test.txt テスト.txt
適当なエディタで テスト2.txt を作る。
$ git add *2.txt
$ git commit -m "test2"
[detached HEAD febb046] test2
1 files changed, 1 insertions(+), 0 deletions(-)
create mode 100755 "\343\203\206\343\202\271\343\203\2102.txt"
コマンドプロンプトに戻って
> bzr pull
bzr: ERROR: sqlite3.ProgrammingError: You must not use 8-bit bytestrings unless
you use a text_factory that can interpret 8-bit bytestrings (like text_factory =
str). It is highly recommended that you instead just switch your application to
Unicode strings.
(以下スタックトレースとか略)
ありゃりゃ..
... まぁ、gitコマンドの日本語ファイル関連のログの見た目が既にやばいしなぁ..
結論: git で日本語ファイルは危なさそう。
宣伝: Bazaar なら日本語ファイルでも問題なく扱えます。





コメントする