git-p4 を使用して git をローカルで操作し、変更を perforce サーバーに送信しようとしています。私が失敗している変更をサーバーに送信することです。
クライアントにすべてのライブラリ依存関係が含まれるようにクライアントをセットアップしました (「git-p4 を使用して perforce クライアントの git clone をセットアップする」の推奨事項に従ってください) 。
//depot/libA/... //workspace/libA/...
//depot/libB/... //workspace/libB/...
ただし、メインのライン ソースについては、ワークスペース ディレクトリで次のことを行っています。
git-p4 clone //depot/my_project
これにより、ワークスペースに my_project ディレクトリが作成され、データが取り込まれます。
src のコードがライブラリを参照できるようにします。
問題は、git-p4 rebase を実行すると、次のエラーが発生することです。
$git-p4 rebase
Traceback (most recent call last):
File "/home/user/bin/git-p4", line 2362, in <module>
main()
File "/home/user/bin/git-p4", line 2357, in main
if not cmd.run(args):
File "/home/user/bin/git-p4", line 2051, in run
sync.run([])
File "/home/user/bin/git-p4", line 2004, in run
changes = self.p4.p4ChangesForPaths(self.depotPaths, self.changeRange)
File "/home/user/bin/git-p4", line 232, in p4ChangesForPaths
assert depotPaths
AssertionError
git-p4 submit を実行すると (単一の変更を行って git commit -a -m "test" を実行した後):
$ git-p4 submit --verbose
Reading pipe: git name-rev HEAD
Reading pipe: git config git-p4.allowSubmit
Reading pipe: git rev-parse --symbolic --remotes
Reading pipe: git rev-parse p4/master
Reading pipe: git notes --ref=git-p4 show 6b75260b956cb72102014783fcfcb2e0da6eb637
Reading pipe: git notes --ref=git-p4 show HEAD~0
Reading pipe: git notes --ref=git-p4 show HEAD~1
Reading pipe: git notes --ref=git-p4 show HEAD~2
Reading pipe: git notes --ref=git-p4 show HEAD~3
.....
それは永遠にかかります (サーバーにすべての変更セットを要求していますか??)、エラーで失敗します: Traceback (most recent call last):
File "/home/user/bin/git-p4", line 2362, in <module>
main()
File "/home/user/bin/git-p4", line 2357, in main
if not cmd.run(args):
File "/home/user/bin/git-p4", line 1088, in run
self.depotPath = settings['depot-paths'][0]
KeyError: 'depot-paths'
git config を使用して git-p4 オプションを設定していないことに注意してください ( https://git.wiki.kernel.org/index.php/Git-p4_Usageのウィキでは、が必要です)。