2016-07-28 5 views

答えて

1

あなたは&&でそれらを連結することpostinstallから複数のスクリプトを呼び出します。

{ 
    "scripts": { 
    "script1": "", 
    "script2": "", 
    "postinstall": "script1 && script2" 
    } 
} 

これは、両方のWindowsとUnix(Linuxでは、MacOSの)端末上で動作するはずです。

+0

いいえ私はどのようにnpmをインストールしたら、postinstall以外のスクリプトを呼び出すのでしょうか? – Jasmine

+1

@ジャスミン何がポイントですか?他のスクリプトのものを '' postinstall '''に入れてください。本当に気にしていたら '' postinstall ":" npm postinstall2 "'を実行してください。 –

関連する問題