0
0

More than 3 years have passed since last update.

インストールするgemのリモートリポジトリを追加する

Last updated at Posted at 2020-03-29

環境

Ubuntu 16.04.5 LTS
Windows10
Vagrant

手順

gemをインストールする時、gem installでインストールするが、どこからインストールしているのだろうか?ダウンロード元のリモートリポジトリを確認するコマンドがあります。

$gem sources -l
https://rubygems.org/

では、rubygems にないgemをインストールしたい場合はどうすればいいのだろうか?
インストールしたいgemが、GitHubにある場合、リモートリポジトリのリストにGitHubを追加します。

$gem sources -a http://gems.github.com/
$gem sources -l
https://rubygems.org/
http://gems.github.com/

これで、インストールしたいgemが、rubygemsになかった場合は、githubを検索して、ダウンロードしてくれるようになります。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0