netlify.js 565 B

1234567891011121314151617181920
  1. const shell = require('shelljs');
  2. // clone vhs
  3. shell.exec('git clone https://github.com/videojs/http-streaming');
  4. shell.cd('http-streaming');
  5. // install vhs and link in the local version of mux.js
  6. shell.exec('npm ci');
  7. shell.exec('npm link ../');
  8. // run the vhs netlify script so that we can use
  9. // the vhs netlify page with this local mux.js
  10. shell.exec('npm run netlify');
  11. // move the vhs deploy directory to the project root
  12. shell.cp('-R', 'deploy', '../');
  13. // cleanup by removing the cloned vhs directory
  14. shell.cd('..');
  15. shell.rm('-rf', 'http-streaming');