We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bda252e commit 568bcbdCopy full SHA for 568bcbd
1 file changed
index.js
@@ -87,9 +87,9 @@ NodePreGypGithub.prototype.uploadAsset = function(cfg){
87
id: this.release.id,
88
repo: this.repo,
89
name: cfg.fileName,
90
- file: cfg.filePath,
91
- contentType: mime.contentType(cfg.fileName) || 'application/octet-stream',
92
- contentLength: fs.statSync(cfg.filePath).size,
+ file: fs.createReadStream(cfg.filePath),
+ contentType: mime.contentType(cfg.fileName) || 'application/octet-stream',
+ contentLength: fs.statSync(cfg.filePath).size
93
}, function(err){
94
if(err) throw err;
95
consoleLog('Staged file ' + cfg.fileName + ' saved to ' + this.owner + '/' + this.repo + ' release ' + this.release.tag_name + ' successfully.');
0 commit comments