Module: Utils::YarnWrapper
- Included in:
- PuppetPdf::PdfCreator
- Defined in:
- lib/utils/yarn_wrapper.rb
Instance Method Summary collapse
Instance Method Details
#run_yarn(command, *args) ⇒ Object
5 6 7 8 9 10 |
# File 'lib/utils/yarn_wrapper.rb', line 5 def run_yarn(command, *args) sh_command = " cd \#{gem_path} && yarn \#{Shellwords.escape(command)} \#{prepare_args(args)}\n SH\n system(sh_command)\nend\n" |
#validate_yarn_installation ⇒ Object
12 13 14 15 16 |
# File 'lib/utils/yarn_wrapper.rb', line 12 def validate_yarn_installation which_yarn_output = `which yarn` raise 'Yarn not installed!' if which_yarn_output.empty? end |