問題タブ [rugged]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票する
0 に答える
417 参照

ruby - 頑丈なものはインストールされていますが、バンドラーはインストールに失敗します

Gitorious をインストールしようとしていますが、Gitorious に必要な gem をインストールしたいと考えています。現在、ruby 2.0.0 パッチレベル 247 (取得できる限り最新のもの) と ruby​​gems バージョン 2.0.3 を実行しています。また、この wiki ページhttp://wiki.dreamhost.com/Gitoriousを使用して、共有の Dreamhost 共有プラットフォームを使用しています。これは少し時代遅れですが、まだ機能しています。実行するgem install rugged -v '0.19.0'と返さ れ、メインライン リポジトリのクローンを作成した後に実行すると、`Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension Building native extensions. This could take a while... Successfully installed rugged-0.19.0 unable to convert "\x85" from ASCII-8BIT to UTF-8 for test/fixtures/alternate/objects/14/6ae76773c91e3b1d00cf7a338ec55ae58297e2, skipping unable to convert "\xAD" from ASCII-8BIT to UTF-8 for test/fixtures/alternate/objects/14/9c32d47e99d0a3572ff1e70a2e0051bbf347a9, skipping unable to convert "\xED" from ASCII-8BIT to UTF-8 for test/fixtures/alternate/objects/14/fb3108588f9421bf764041e5e3ac305eb6277f, skipping unable to convert "\xE5" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/index, skipping unable to convert "\x8C" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/0c/37a5391bbff43c37f0d0371823a5509eed5b1d, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/13/85f264afb75a56a5bec74243be9b367ba4ca08, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/18/1037049a54a1eb5fab404658a3a250b44335d7, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/18/10dff58d8a660512d4832e740f692884338ccd, skipping unable to convert "\x95" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/2d/2eff63372b08adf0a9eb84109ccf7d19e2f3a2, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/36/060c58702ed4c2a40832c51758d5344201d89a, skipping unable to convert "\xA5" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/44/1034f860c1d5d90e4188d11ae0d325176869a8, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/45/b983be36b73c0788dc9cbcb76cbb80fc7bb057, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/4a/202b346bb0fb0db7eff3cffeb3c70babbd2045, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/5b/5b025afb0b4c913b4c338a42934a3863bf3644, skipping unable to convert "\xB3" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/60/d415052a33de2150bf68757f6461df4f563ae4, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/61/9f9935957e010c419cb9d15621916ddfcc0b96, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/68/8a8f4ef7496901d15322972f96e212a9e466cc, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/75/057dd4114e74cca1d750d0aee1647c903cb60a, skipping unable to convert "\xED" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/77/71329dfa3002caf8c61a0ceb62a31d09023f37, skipping unable to convert "\xB3" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/81/4889a078c031f61ed08ab5fa863aea9314344d, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/84/96071c1b46c854b31185ea97743be6a8774479, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/94/eca2de348d5f672faf56b0decafa5937e3235e, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/9b/7384fe1676186192842f5d3e129457b62db9e3, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/9f/d738e8f7967c078dceed8190330fc8648ee56a, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/a4/a7dce85cf63874e984719f4fdd239f5145052f, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/a7/1586c1dfe8a71c6cbf6c129f404c5642ff31bd, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/a8/233120f6ad708f843d861ce2b7228ec4e3dec6, skipping unable to convert "\xA5" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/b7/4713326bc972cc15751ed504dca6f6f3b91f7a, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/be/3563ae3f795b2b4353bcce3a527ad0a4f7f644, skipping unable to convert "\x9D" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/c4/7800c7266a2be04c571c04d5a6614691ea99bd, skipping unable to convert "\xF1" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/c4/dc1555e4d4fa0e0c9c3fc46734c7c35b3ce90b, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391, skipping unable to convert "\xB3" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/f6/0079018b664e4e79329a7ef9559c8d9e0378d1, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/fa/49b077972391ad58037050f2a75f74e3671e92, skipping unable to convert "\xB3" from ASCII-8BIT to UTF-8 for test/fixtures/testrepo.git/objects/fd/093bff70906175335656e6ce6ae05783708765, skipping unable to convert "\xF0" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/08/8b64704e0d6b8bd061dea879418cb5442a3fbf, skipping unable to convert "\xB2" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/13/a5e939bca25940c069fd2169d993dba328e30b, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/19/bf568e59e3a0b363cafb4106226e62d4a4c41c, skipping unable to convert "\xBF" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/58/1fadd35b4cf320d102a152f918729011604773, skipping unable to convert "\x85" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/5c/87b6791e8b13da658a14d1ef7e09b5dc3bac8c, skipping unable to convert "\x85" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/6f/e5f5398af85fb3de8a6aba0339b6d3bfa26a27, skipping unable to convert "\x95" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/7f/ccd75616ec188b8f1b23d67506a334cc34a49d, skipping unable to convert "\x95" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/80/6999882bf91d24241e4077906b9017605eb1f3, skipping unable to convert "\xB2" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/83/7d176303c5005505ec1e4a30231c40930c0230, skipping unable to convert "\x95" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/a8/595ccca04f40818ae0155c8f9c77a230e597b6, skipping unable to convert "\xF0" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/cf/8f1cf5cce859c438d6cc067284cb5e161206e7, skipping unable to convert "\x85" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/d5/278d05c8607ec420bfee4cf219fbc0eeebfd6a, skipping unable to convert "\xB2" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/f4/e16fb76536591a41454194058d048d8e4dd2e9, skipping unable to convert "\xCA" from ASCII-8BIT to UTF-8 for test/fixtures/unsymlinked.git/objects/f9/e65619d93fdf2673882e0a261c5e93b1a84006, skipping 1 gem installed .bundle install

/home/harborcn/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/shellwords.rb:73:in 'shellsplit': 未定義のメソッド 'scan' for true:TrueClass (NoMethodError) from /home/harborcn/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/mkmf.rb:2409:in '' from /home/harborcn/.rvm/rubies/ruby-2.0. 0-p247/lib/ruby/2.0.0/mkmf.rb:47:in '' from /home/harborcn/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/ rubygems/core_ext/kernel_require.rb:45:in 'require' from /home/harborcn/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb :45:in 'require' from extconf.rb:1:in ''

Gem ファイルは、検査のために /home/harborcn/.rvm/gems/ruby-2.0.0-p247/bundler/gems/rugged-76f3382f7eb0 にインストールされたままになります。/home/harborcn/.rvm/gems/ruby-2.0.0-p247/bundler/gems/rugged-76f3382f7eb0/ext/rugged/gem_make.out に記録された結果続行できません。バンドルする前に、gem install rugged -v '0.19.0' が成功することを確認してください。

これを修正するにはどうすればよいですか? ありがとう!

0 投票する
1 に答える
421 参照

rugged - clone_at および Rugged::NetworkError を返すフェッチ: このトランスポートは実装されていません。ごめん

そのため、私は rugged を使用してレポのフェッチとクローンの両方を行う機能を組み込むことを試みてきました。私は次のことを試しました

この

これも

これらはすべてエラーで返されます

さて、通常、まだ実装されていないため、エラーを受け取ります。しかし、このように尋ねられた質問を見たことがあります。私はその誤りの正確性に疑問を持っています。

このコードを実行しているローカル システムに libgit2 と libssh2 の両方がインストールされていることを確認しました。

また、このエラーが生成された場所を見つけようとしてソースを調べましたが、見つけることができませんでした。私にとって、これは意味がありません。なぜなら、エラーは、失敗した場所を具体的に指摘するほど説明的ではないからです。

私の質問は、これは意図された動作ですか? これに関して私が見つけた質問と回答に基づいて、そうではないと思います。その場合、これが一般的な問題であるかどうか誰かが知っていますか? どんな助けでも大歓迎です。

0 投票する
2 に答える
579 参照

git - 「git ls-tree」と同等の堅牢

裸のリポジトリで入力できます$ git ls-tree -r master。(これは、コマンドを使用して裸のリポジトリで取得できるのと同じようなものですgit ls-files)

git リポジトリ内のファイルとその sha ref の完全なリストについては、

Rugged では、特定のブランチまたはマスターにあるファイルのリストを取得するにはどうすればよいですか?

0 投票する
1 に答える
110 参照

git - Rugged::Repository #status は、Rugged を使用してインデックスにファイルを追加すると、クリアされたステータスを報告します

Rugged::Index #add を使用して新しいファイルをインデックスに追加しようとしています。インデックスに正常に追加されたように見えますが、関連する Rugged::Repository #status が特定のファイルに対してクリアされています。

ファイル「TEST_JJV_IRB1」を追加しようとした IRB セッションの例

新しく作成されたファイル「TEST_JJV_IRB1」は、Rugged::Repository #status によって正しく報告されます

Rugged::Index に正しく含まれていません

ここで、新しいファイルをインデックスに追加しようとします。

追加されたファイル「TEST_JJV_IRB1」は、インデックスに正しく含まれるようになりました。

しかし、Rugged::Repository #status によってクリアされたと報告されたステータスです。

Rugged::Repository #status が [:index_new] を報告することを期待します

奇妙なことに、コマンドラインから発行するgit statusと、新しいファイル「TEST_JJV_IRB1」が「コミットされる変更:」として表示されます。

0 投票する
1 に答える
191 参照

ruby - "git ブランチ -- マージ済み"Rugged libgit2バインディング経由?

ネイティブの git コマンドと同じ情報を取得する方法はありますか

Ruby のRugged libgit2 バインディング経由で?

0 投票する
1 に答える
128 参照

ruby - Rugged を使用してすべてを Git に追加する特定のプロトコルはありますか?

最近 Rugged を使い始めましたが、すでにいくつかの問題に遭遇しています。基本的にやりたいことは、すべてを Git リポジトリに追加し、ステージングされた変更をコミットして、すべてをブランチにプッシュすることだけです。私は次のように最初のステップから始めました:

しかし、コンソールは私に向かって叫んでしまいます。libgit2 のドキュメントを参照しましたが、リポジトリにすべてを追加する例は見つかりませんでした。徹底的なグーグル検索でも同様の結果が得られました。@repo.workdir.entriespathパラメータとしてa を詰め込んだだけかもしれindex.addませんが、よくわかりません。これについてもっと良い方法はありますか?

0 投票する
1 に答える
336 参照

ruby - Rugged/libgit2 でコミットを作成するときに作業ディレクトリを更新する方法は?

次のテスト スクリプトを使用して、rugged でコミットを作成しようとしています。

コミットが作成され、スクリプトが出力します773d97f453a6df6e8bb5099dc0b3fc8aba5ebaa7(新しいコミットの SHA)。生成されたコミットとツリーは、次のようになります。

ただし、作業ディレクトリは更新されません。

git reset --hard HEAD不足しているファイルtest.mdを作業ディレクトリに表示するには、 a を実行する必要があります。Rugged コミットを作成し、 を設定すると:update_ref => "HEAD"、作業ディレクトリが自動的に更新されるはずだと思っていましたが、実行しても効果がないため、何かが間違っているに違いありr.checkout_headません。ただし、頑丈な例に正しく従っていると思います。ここで何が欠けていますか?

編集: