2020-05-17 19:08:20 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) Sapphirecode - All Rights Reserved
|
|
|
|
* This file is part of eslint-config-vue which is released under MIT.
|
|
|
|
* See file 'LICENSE' for full license details.
|
|
|
|
* Created by Timo Hocker <timo@scode.ovh>, May 2020
|
|
|
|
*/
|
|
|
|
|
2020-05-13 16:03:36 +02:00
|
|
|
'use strict';
|
|
|
|
|
2020-05-15 13:17:08 +02:00
|
|
|
const https = require ('https');
|
2020-05-13 16:03:36 +02:00
|
|
|
const fs = require ('fs');
|
2020-05-15 13:17:08 +02:00
|
|
|
const { execSync: exec_sync } = require ('child_process');
|
2020-05-13 16:03:36 +02:00
|
|
|
|
2020-05-15 13:17:08 +02:00
|
|
|
const run_file = fs.createWriteStream ('.jenkins.run.js');
|
2020-05-13 16:03:36 +02:00
|
|
|
|
2020-05-15 13:17:08 +02:00
|
|
|
const [
|
|
|
|
,, ...args
|
|
|
|
] = process.argv;
|
2020-05-13 16:03:36 +02:00
|
|
|
|
2020-05-15 13:17:08 +02:00
|
|
|
run_file.on ('close', () => {
|
|
|
|
exec_sync (`node .jenkins.run.js ${args.join (' ')}`, { stdio: 'inherit' });
|
|
|
|
});
|
2020-05-13 16:03:36 +02:00
|
|
|
|
2020-05-15 13:17:08 +02:00
|
|
|
https.get (
|
|
|
|
'https://git.scode.ovh/Timo/standard/raw/branch/master/jenkins.run.js',
|
|
|
|
(msg) => {
|
|
|
|
msg.pipe (run_file);
|
2020-05-13 15:52:38 +02:00
|
|
|
}
|
2020-05-15 13:17:08 +02:00
|
|
|
);
|