Skip to content

Commit ba7470b

Browse files
authored
Merge pull request #495 from chmelevskij/master
chore: use node 14
2 parents 5eed5da + 1fc8583 commit ba7470b

File tree

7 files changed

+653
-385
lines changed

7 files changed

+653
-385
lines changed

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
14.18.2

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ git:
1717
language: node_js
1818

1919
node_js:
20-
- 8.11.2
20+
- 14.8.2
2121

2222
before_install:
2323
- npm i -g [email protected]

azure-pipelines.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,11 @@ stages:
4848
vmImage: 'windows-2022'
4949

5050
steps:
51-
- task: UseNode@1
51+
- task: NodeTool@0
5252
inputs:
53-
version: '10.16.3'
54-
displayName: 'Install Node.js 10.16.3'
55-
- script: yarn install
53+
versionSpec: '14.18.2'
54+
displayName: 'Install Node.js 14.18.2'
55+
- script: yarn install --ignore-optional
5656
displayName: 'Run yarn install'
5757
- script: yarn gulp release --win64
5858
displayName: 'Run yarn release for win64'
@@ -71,10 +71,10 @@ stages:
7171
vmImage: 'macos-10.15'
7272

7373
steps:
74-
- task: UseNode@1
74+
- task: NodeTool@0
7575
inputs:
76-
version: '10.16.3'
77-
displayName: 'Install Node.js 10.16.3'
76+
versionSpec: '14.18.2'
77+
displayName: 'Install Node.js 14.18.2'
7878
- script: npm install -g gulp
7979
displayName: 'Install Gulp'
8080
- script: yarn install
@@ -96,11 +96,11 @@ stages:
9696
vmImage: '$(linuxVmImage)'
9797

9898
steps:
99-
- task: UseNode@1
99+
- task: NodeTool@0
100100
inputs:
101-
version: '10.16.3'
102-
displayName: 'Install Node.js 10.16.3'
103-
- script: yarn install
101+
versionSpec: '14.18.2'
102+
displayName: 'Install Node.js 14.18.2'
103+
- script: yarn install --ignore-optional
104104
displayName: 'Run yarn install'
105105
- script: yarn gulp release --linux64
106106
displayName: 'Run yarn release for linux'

gulp-appdmg.js

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
2+
const appdmg = require('appdmg');
3+
const through = require('through2');
4+
const gutil = require('gulp-util');
5+
6+
const PluginError = gutil.PluginError;
7+
const PLUGIN_NAME = 'gulp-appdmg';
8+
9+
module.exports = function(options) {
10+
const stream = through.obj(function(file, encoding, next) {
11+
next();
12+
}, function(callback) {
13+
const self = this;
14+
const ee = appdmg(options);
15+
16+
ee.on('progress', function(info) {
17+
gutil.log(info.current + '/' + info.total + ' ' + info.type + ' ' + (info.title || info.status));
18+
});
19+
20+
ee.on('error', function(err) {
21+
self.emit('error', new PluginError(PLUGIN_NAME, err));
22+
callback();
23+
});
24+
25+
ee.on('finish', callback);
26+
});
27+
28+
// returning the file stream
29+
stream.resume();
30+
return stream;
31+
};

gulpfile.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
const pkg = require('./package.json');
44

5-
const child_process = require('child_process');
65
const fs = require('fs');
76
const path = require('path');
87

@@ -15,7 +14,6 @@ const buildRpm = require('rpm-builder')
1514
const commandExistsSync = require('command-exists').sync;
1615

1716
const gulp = require('gulp');
18-
const concat = require('gulp-concat');
1917
const yarn = require("gulp-yarn");
2018
const rename = require('gulp-rename');
2119
const os = require('os');
@@ -517,7 +515,7 @@ function release_rpm(arch, appDirectory, done) {
517515

518516
// Create distribution package for macOS platform
519517
function release_osx64(appDirectory) {
520-
var appdmg = require('gulp-appdmg');
518+
var appdmg = require('./gulp-appdmg');
521519

522520
// The appdmg does not generate the folder correctly, manually
523521
createDirIfNotExists(RELEASE_DIR);

package.json

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
"default_locale": "en",
99
"scripts": {
1010
"start": "gulp debug",
11-
"postinstall": "platform-dependent-modules",
1211
"gulp": "gulp",
1312
"release": "gulp release"
1413
},
@@ -35,27 +34,26 @@
3534
"command-exists": "^1.2.8",
3635
"del": "^5.0.0",
3736
"gulp": "^4.0.1",
38-
"gulp-concat": "~2.6.1",
3937
"gulp-debian": "~0.1.8",
4038
"gulp-rename": "^2.0.0",
41-
"gulp-yarn": "^2.0.0",
39+
"gulp-util": "3.0.8",
40+
"gulp-yarn": "^3.0.0",
4241
"gulp-zip": "^5.0.0",
4342
"inflection": "1.12.0",
4443
"nw-builder": "^3.5.7",
4544
"os": "^0.1.1",
46-
"platform-dependent-modules": "0.0.14",
4745
"rpm-builder": "^1.0.0",
4846
"temp": "^0.9.0",
47+
"through2": "4.0.2",
4948
"yarn": "^1.22.0"
5049
},
50+
"optionalDependencies": {
51+
"appdmg": "^0.6.2"
52+
},
5153
"resolutions": {
5254
"**/**/lodash.template": "^4.5.0"
5355
},
54-
"config": {
55-
"platformDependentModules": {
56-
"darwin": [
57-
58-
]
59-
}
56+
"engines": {
57+
"node": "14.x"
6058
}
6159
}

0 commit comments

Comments
 (0)