How to pass command-line variable in package.json script, in NPM?

Solution 1:

I found the magic recipe

I simply have this in my package.json

  "scripts": {
    "build": "npm ci && gulp build"
  }

and use the following command line

$ npm run build -- --gitTag 1.0.0

and get the wanted packageName-1.0.0.zip artifact.