Mina: bundler2.1.2を使用すると次の警告が表示されます

作成日 2020年01月03日  ·  8コメント  ·  ソース: mina-deploy/mina

[DEPRECATED] The `--deployment` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set deployment 'true'`, and stop using this flag
[DEPRECATED] The `--path` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set path 'vendor/bundle'`, and stop using this flag
[DEPRECATED] The `--without` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set without 'development test'`, and stop using this flag

最も参考になるコメント

@Haelleアップグレードが推奨されるため、最新の安定したBundlerとの互換性が望ましいでしょう。 ミナは、新しい、したがってより安定したバージョンのBundlerを推奨する可能性があります。 現在、ミナは最新のプロダクションBundlerでは使用できません。

全てのコメント8件

Bundler2.1.4でも同じ警告が表示されます

そして、 bundle:clean失敗します:

$ /usr/local/rbenv/shims/bundle clean --without development test --path "vendor/bundle" --deployment
       Unknown switches "--without", "--path", "--deployment"
 !     ERROR: Deploy failed.

これについてさらに情報はありますか?

ここに到着する人のために、私は次の解決策を使用しています:

まず、デフォルトのバンドラーオプションを削除します。

set :bundle_options, -> { '' }

次に、 setupタスクに以下を追加します。

command "#{fetch(:bundle_bin)} config set deployment 'true'"
command "#{fetch(:bundle_bin)} config set path '#{fetch(:bundle_path)}'"
command "#{fetch(:bundle_bin)} config set without '#{fetch(:bundle_withouts)}'"

これにより、減価償却の警告が解決され、バンドル構成がグローバルに設定されます。 マージされるものであれば、このパッチを作成できれば幸いです。

ここのブログ投稿: Bundlerの減価償却警告を引き起こすMinaの展開

これは、Bundler1を使用している人にとっては壊れます。

そして、ミナチームがif bundler_1? do xxx esle do yyyコードを処理したいかどうかはわかりません

彼らからの意見はPRの方向性を助けるでしょう

@Haelleアップグレードが推奨されるため、最新の安定したBundlerとの互換性が望ましいでしょう。 ミナは、新しい、したがってより安定したバージョンのBundlerを推奨する可能性があります。 現在、ミナは最新のプロダクションBundlerでは使用できません。

+1

こんにちは@thelucidあなたはそれをより詳細に説明できますか。
このセット:bundle_options、-> {''}オプションはどこにありますか?
そして、上記のコマンドを追加する場所に。 アプリの配布にgitlabrunnerとfastlineを使用しています。 だから私はここにgitlab-ci.ymlファイルを持っています

  • バンドルインストール--path./tmp-fastlane-ci-bundle

@thelucidは言った:

ここに到着する人のために、私は次の解決策を使用しています:

command "#{fetch(:bundle_bin)} config set deployment 'true'"
command "#{fetch(:bundle_bin)} config set path '#{fetch(:bundle_path)}'"
command "#{fetch(:bundle_bin)} config set without '#{fetch(:bundle_withouts)}'"

これにより、減価償却の警告が解決され、バンドル構成がグローバルに設定されます。 マージされるものであれば、このパッチを作成できれば幸いです。

使用する方が理にかなっていますか?

namespace :bundle do
  desc 'Sets the Bundler config options.'
  task :config do
    comment %{Setting the Bundler config options}
    command %{#{fetch(:bundle_bin)} config set --local deployment 'true'}
    command %{#{fetch(:bundle_bin)} config set --local path '#{fetch(:bundle_path)}'}
    command %{#{fetch(:bundle_bin)} config set --local without '#{fetch(:bundle_withouts)}'}
  end
end

…すべてのデプロイで( --local注意してください)? たとえば、リリース間でwithout変わることを想像できます。

このページは役に立ちましたか?
0 / 5 - 0 評価