JA Gemfile を編集して gem 'cowsay' という行を追加し、cowsay gem の依存関係を含めます。
JA Gemfile を編集して gem 'cowsay' という行を追加し、cowsay gem の依存関係を含めます。
EN Modify Gemfile to include a dependency for the cowsay gem by including a line gem 'cowsay':
JA Gemfile を編集して gem 'cowsay' という行を追加し、cowsay gem の依存関係を含めます。
EN Modify Gemfile to include a dependency for the cowsay gem by including a line gem 'cowsay':
JA 以前に therubyracer または therubyracer-heroku を使用していた場合、これらの gem は不要になりました。また、これらの gem はメモリ使用量が多すぎるため、使用しないことを強く推奨します。
EN If you were previously using therubyracer or therubyracer-heroku, these gems are no longer required and strongly discouraged as these gems use a very large amount of memory.
JA MemCachier の記事で述べたように、アドオンと dalli gem をインストールする必要があります。オプションの memcachier gem も推奨されます。
EN As noted in the MemCachier article, you need to install the add-on and the dalli gem. The optional memcachier gem is also recommended.
JA ネイティブ拡張機能を持つ一部の gem については、インストール時に追加のフラグを gem に直接指定することが必要な場合があります。
EN Some gems that have native extensions may need additional flags provided directly to the gem at install time.
JA The foo gem enables you to upload static assets transparently at deploy time. (foo gem を使用すると、デプロイ時に静的アセットを透過的にアップロードできます。)
EN The foo gem enables you to upload static assets transparently at deploy time.
JA Dragonfly gem for Ruby の 1.4.0 より前のバージョンに、リモートの攻撃者に任意のファイルを読み書きされる可能性のある引数インジェクションの脆弱性が開示されました。
EN Before the 1.4.0 version of Dragonfly gem for Ruby, Dragonfly gem disclosed an argument injection vulnerability that allows remote attackers to read and write arbitrary files. It crafts the URL using base64 encode when the
JA ローカルにインストールされた Bundler。gem install bundler を実行します。
EN Bundler installed locally - run gem install bundler.
JA この gem を使用するように app/views/welcome/index.erb を編集します。ファイルの最初の数行を次のように変更します。
EN Modify app/views/welcome/index.erb so that it uses this gem, by changing the file so that its first few lines read as follows:
JA これにより、Gemfile に pg gem がインストールされ、正しい config/database.yml 設定がローカルに書き込まれます。
EN This will install the pg gem in your Gemfile and write the correct config/database.yml configuration locally.
JA pg gem をインストールし、config/database.yml ファイルを移行したたら、データベースを作成し、それに対して既存の移行をすべて実行する必要があります。
EN Once you’ve installed the pg gem and migrated your config/database.yml file you will need to create your database and run any pre existing migrations against it:
JA Bundler をインストールします。これには、コマンドプロンプトを開いて jruby -S gem install bundler と入力します。
EN Install Bundler. To do this, open a command prompt and type: jruby -S gem install bundler.
JA No such file or directory -- bundle (LoadError) というエラーが表示された場合は、「はじめに」に記述されているように、jruby -S gem install bundler を実行していることを確認してください。
EN If you receive the error No such file or directory -- bundle (LoadError), then make sure you have run jruby -S gem install bundler as described in the introduction.
JA Gemfile を編集して、cowsay gem の依存関係を追加します。ファイルは次のようになります。
EN Modify Gemfile to include a dependency for the cowsay gem. Your file will look something like this:
JA この gem を使用するように app/views/welcome/index.erb を編集します。最終的に、コードは次のようになります。
EN Modify app/views/welcome/index.erb so that it uses this gem. Your final code should look like this:
JA --database=postgresql を指定せずに作成された既存のアプリを使用している場合は、Rails プロジェクトに pg gem を追加する必要があります。Gemfile を編集し、以下の行を変更します。
EN If you’re using an existing app that was created without specifying --database=postgresql, you need to add the pg gem to your Rails project. Edit your Gemfile and change this line:
japonês | inglês |
---|---|
postgresql | postgresql |
JA pg gem の使用に加えて、config/database.yml ファイルで postgresql アダプターが使用されていることも確認します。config/database.yml ファイルの開発セクションの外観は次のようになります。
EN In addition to using the pg gem, ensure that your config/database.yml file is using the postgresql adapter. The development section of your config/database.yml file should look something like this:
japonês | inglês |
---|---|
postgresql | postgresql |
JA 注意: .env ファイルを使用してローカルで環境変数を使用するもう 1 つの代替方法が dotenv gem です。
EN Note: Another alternative to using environment variables locally with a .env file is the dotenv gem.
JA これらの Rake タスクを gem のロード時に条件付きにすることで、問題を解消できます。次に例を示します。
EN Now you can fix it by making these Rake tasks conditional on the gem load. For example:
JA --database=postgresql を指定せずに作成されたアプリがある場合は、Rails プロジェクトに pg gem を追加する必要があります。Gemfile を編集し、以下の行を変更します。
EN If already have an app that was created without specifying --database=postgresql you will need to add the pg gem to your Rails project. Edit your Gemfile and change this line:
japonês | inglês |
---|---|
postgresql | postgresql |
JA pg gem の使用に加えて、config/database.yml で postgresql アダプターが使用されていることも確認する必要があります。
EN In addition to using the pg gem, you’ll also need to ensure the config/database.yml is using the postgresql adapter.
japonês | inglês |
---|---|
postgresql | postgresql |
JA これらの Rake タスクを gem のロード時に条件付きにすることで、問題を解消できます。たとえば、次のようになります。
EN Now you can fix it by making these Rake tasks conditional on the gem load. For example:
JA ローカルにインストールされた Bundler。gem install bundler を実行します。
EN Bundler installed locally - run gem install bundler.
JA この gem を使用するように app/views/welcome/index.erb を編集します。ファイルの最初の数行を次のように変更します。
EN Modify app/views/welcome/index.erb so that it uses this gem, by changing the file so that its first few lines read as follows:
JA --database=postgresql を指定せずに作成されたアプリがある場合は、Rails プロジェクトに pg gem を追加する必要があります。Gemfile を編集し、以下の行を変更します。
EN If already have an app that was created without specifying --database=postgresql you will need to add the pg gem to your Rails project. Edit your Gemfile and change this line:
japonês | inglês |
---|---|
postgresql | postgresql |
JA pg gem の使用に加えて、config/database.yml で postgresql アダプターが使用されていることも確認する必要があります。
EN In addition to using the pg gem, you’ll also need to ensure the config/database.yml is using the postgresql adapter.
japonês | inglês |
---|---|
postgresql | postgresql |
JA これらの Rake タスクを gem のロード時に条件付きにすることで、問題を解消できます。たとえば、次のようになります。
EN Now you can fix it by making these Rake tasks conditional on the gem load. For example:
JA Dragonfly gem for Ruby の 1.4.0 より前のバージョンに、リモートの攻撃者に任意のファイルを読み書きされる可能性のある引数インジェクションの脆弱性が開示されました。
EN Before the 1.4.0 version of Dragonfly gem for Ruby, Dragonfly gem disclosed an argument injection vulnerability that allows remote attackers to read and write arbitrary files. It crafts the URL using base64 encode when the
JA これにより、Gemfile に pg gem がインストールされ、正しい config/database.yml 設定がローカルに書き込まれます。
EN This will install the pg gem in your Gemfile and write the correct config/database.yml configuration locally.
JA pg gem をインストールし、config/database.yml ファイルを移行したたら、データベースを作成し、それに対して既存の移行をすべて実行する必要があります。
EN Once you’ve installed the pg gem and migrated your config/database.yml file you will need to create your database and run any pre existing migrations against it:
JA ラックタイムアウト gem をプロジェクトに追加してから、タイムアウト値を環境変数から設定します。
EN Add the Rack Timeout gem to your project then set your timeout value via an environment variable
JA Rack::Cache gem と、推奨の memcached クライアントである Dalli をインストールする必要があります。Gemfile で、次の内容を追加します。
EN You should install the Rack::Cache gem as well as the recommended memcached client, Dalli. In your Gemfile add:
japonês | inglês |
---|---|
memcached | memcached |
JA MemCachier が設定する環境変数のプレフィックスは MEMCACHIER です (MEMCACHE ではありません)。ただしこれは、memcachier gem によって自動的に修正されます。これを gemfile に含めます。
EN MemCachier sets environment variables prefixed with MEMCACHIER rather than MEMCACHE. The memcachier gem, however, fixes this for you. Include it in your gemfile.
japonês | inglês |
---|---|
memcache | memcache |
JA Bundler をインストールします。これには、コマンドプロンプトを開いて jruby -S gem install bundler と入力します。
EN Install Bundler. To do this, open a command prompt and type: jruby -S gem install bundler.
JA No such file or directory -- bundle (LoadError) というエラーが表示された場合は、「はじめに」に記述されているように、jruby -S gem install bundler を実行していることを確認してください。
EN If you receive the error No such file or directory -- bundle (LoadError), then make sure you have run jruby -S gem install bundler as described in the introduction.
JA Gemfile を編集して、cowsay gem の依存関係を追加します。ファイルは次のようになります。
EN Modify Gemfile to include a dependency for the cowsay gem. Your file will look something like this:
JA この gem を使用するように app/views/welcome/index.erb を編集します。最終的に、コードは次のようになります。
EN Modify app/views/welcome/index.erb so that it uses this gem. Your final code should look like this:
JA デフォルトでは、pg gem 依存関係を持つすべての Ruby アプリには、最下位の無料 Heroku Postgres プランが初回デプロイ時に追加されます。
EN By default, the lowest, free Heroku Postgres plan will be added to any Ruby app that has the pg gem dependency, when deployed for the first time.
JA 誤ってこのプロセスで pg gem なしでデプロイが成功した場合、この buildpack は、後続のデプロイで Heroku Postgres を自動的にプロビジョニングできなくなります。
EN If they accidentally get a successful deploy in this process without the pg gem, then the buildpack would never be able to automatically provision Heroku Postgres on subsequent deploys.
JA これは、この gem がプラットフォーム x86-mingw32 または Windows 向けのカスタム版であることを示しています。
EN This indicates that this gem is custom for the platform x86-mingw32 or windows.
JA インストールされた Ruby と Bundler gem。
EN Ruby and the Bundler gem installed
JA Paperclip では、Gemfile に次の gem を追加する必要があります。
EN Paperclip requires the following gems added to your Gemfile.
JA これは単なる例であり、このケースの原因は unf_ext gem ではありませんでした。しかし、バックトレースに記録されているので、調査する価値はあります。
EN This is just an example: this case was not caused by the unf_ext gem. But as it shows up in the backtrace it’s worth looking into.
JA Bundler が環境を認識しているので、特定の環境で特定の gem だけをロードできます。
EN Bundler is environment aware and will allow you to only load certain gems in certain environments:
JA 環境固有コードに加えて、Bundler が RAILS_ENV=staging 環境で実行したときターゲットを :production にした gem をロードしません。
EN In addition to environment-specific code, bundler will not load gems targeted to :production when run in the RAILS_ENV=staging environment.
JA Gemfile.lock ファイルを更新します。--without production オプションを指定すると、pg gem がローカルにインストールされなくなります。
EN to update your Gemfile.lock file. The --without production option will prevent the pg gem from being installed locally.
JA Gemfile を変更して、memcache クライアントライブラリ dalli と、セットアップに役立つ単純な gem である memcachier を含めます。
EN Modify your Gemfile to include dalli, a memcache client library, and memcachier, a simple gem that helps with setup:
japonês | inglês |
---|---|
memcache | memcache |
JA これにより、追加された gem がインストールされ、Gemfile.lock ファイルが更新されます。
EN to install the added gems and update your Gemfile.lock file.
JA アクションキャッシングを使用するには、actionpack-action_caching gem を Gemfile に追加して bundle install を実行する必要があります。
EN To use action caching you need to add the actionpack-action_caching gem to your Gemfile and run bundle install:
JA JRuby と互換性のない gem を置き換える
EN Replace jRuby Incompatible Gems
Mostrando 50 de 50 traduções