mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2024-12-23 17:40:23 +03:00
13 lines
402 B
JavaScript
13 lines
402 B
JavaScript
const argv = process.argv.slice(2);
|
|
const [ homepage ] = argv;
|
|
|
|
if (!homepage) {
|
|
throw new Error('Homepage has to be provided as the first arg for this script');
|
|
}
|
|
|
|
const packageJsonPath = `${__dirname}/../package.json`;
|
|
const packageJson = require(packageJsonPath);
|
|
const fs = require('fs');
|
|
|
|
packageJson.homepage = homepage;
|
|
fs.writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2));
|