Skip to content

Commit 1ca442c

Browse files
author
retrohacker
committed
fix lint
1 parent cfd9572 commit 1ca442c

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

index.js

+2-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ var async = require('async')
55
var distros = require('./os.json')
66
var fs = require('fs')
77
var os = require('os')
8-
var path = require('path')
98

109
/**
1110
* Begin definition of globals.
@@ -21,7 +20,7 @@ module.exports = function getOs (cb) {
2120
// Linux is a special case.
2221
if (osName === 'linux') return getLinuxDistro(cb)
2322
// Else, node's builtin is acceptable.
24-
return cb(null, {'os': osName})
23+
return cb(null, { 'os': osName })
2524
}
2625

2726
/**
@@ -121,7 +120,7 @@ function getName (candidate) {
121120
* Loads a custom logic module to populate additional distribution information
122121
*/
123122
function customLogic (os, name, file, cb) {
124-
var logic = './logic/' + name + '.js';
123+
var logic = './logic/' + name + '.js'
125124
try { require(logic)(os, file, cb) } catch (e) { cb(null, os) }
126125
}
127126

tests/runTest.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ distros.forEach(function (v1) {
2727
// Build the docker image using the dockerfile
2828
process.stdout.write('Building version ' + v2 + ' of ' + capitalize(v1) + '... ')
2929
try {
30-
var dockerResult = execSync('docker build -t "getos:' + v1 + v2 + '" .', {stdio: []})
30+
var dockerResult = execSync('docker build -t "getos:' + v1 + v2 + '" .', { stdio: [] })
3131
} catch (e) {
3232
dockerResult = dockerResult || {}
3333
dockerResult.code = e
@@ -40,7 +40,7 @@ distros.forEach(function (v1) {
4040
process.stdout.write('Running container... ')
4141
// Show output from distribution
4242
try {
43-
var nodeResult = execSync('docker run -d getos:' + v1 + v2, {stdio: []})
43+
var nodeResult = execSync('docker run -d getos:' + v1 + v2, { stdio: [] })
4444
} catch (e) {
4545
nodeResult = nodeResult || {}
4646
nodeResult.code = e
@@ -50,7 +50,7 @@ distros.forEach(function (v1) {
5050
process.stdout.write('[' + color.red('FAILED!') + ']\n')
5151
} else {
5252
try {
53-
var dockerLog = execSync('sleep 2s && docker logs ' + (nodeResult.stdout || nodeResult.toString()), {stdio: []})
53+
var dockerLog = execSync('sleep 2s && docker logs ' + (nodeResult.stdout || nodeResult.toString()), { stdio: [] })
5454
} catch (e) {
5555
dockerLog = dockerLog || {}
5656
dockerLog.code = e

0 commit comments

Comments
 (0)