forked from ycardon/gigaset-elements-proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.js
More file actions
30 lines (23 loc) · 742 Bytes
/
Copy pathbuild.js
File metadata and controls
30 lines (23 loc) · 742 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// build script for gigaset-elements-proxy
//
// run with 'npm run build'
const replace = require('replace-in-file');
const version = require("./package.json").version;
console.info('builing gigaset-elements-proxy : v' + version)
console.info('> replacing version in:')
console.log(replace.sync({
files: 'README.md',
from: /# gigaset-elements-proxy v(.*)/g,
to: '# gigaset-elements-proxy v' + version,
}))
console.log(replace.sync({
files: 'src/environment/environment.ts',
from: /version: '(.*)'/g,
to: 'version: \''+ version + '\'',
}))
console.log(replace.sync({
files: 'package-lock.json',
from: /"version": "(.*)"/,
to: '"version": "'+ version + '"',
}))
console.info('> buiding done')