what does gulp-“cli” stands for?

蹲街弑〆低调 提交于 2019-11-29 21:24:58
N. Brun

The goal of gulp-cli is to let you use gulp like a global program, but without installing gulp globally.

For example if you installed gulp 3.9.1 globally and your project testGulp4 has gulp 4.0 installed locally, what would happen if you run gulp -v into testGulp4?

  • Without gulp-cli globally installed :

    CLI version 3.9.1
    

    In this case the version displayed is the global version of gulp. The local version 4.0 is totally ignored.

  • With gulp-cli globally installed :

    CLI version 1.2.1
    Local version 4.0.0-alpha.2
    

    In this case the version displayed is the global version of gulp-cli and the local version of gulp. The global gulp 3.9.1 is totally ignored.

Conclusion :

  • gulp-cli: is preferred because it allows you to use different versions of gulp.
  • gulp: needs a local version of gulp installed.

CLI stands for Command Line Interface.

gulp is a JavaScript library. It lets you use gulp from JavaScript code.

gulp-cli is a utility program that lets you access gulp from your shell.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!