You've already forked hugo-extended
mirror of
https://github.com/jakejarvis/hugo-extended.git
synced 2025-09-13 06:25:32 -04:00
Minor lint tweaks. (#69)
This commit is contained in:
2
cli.js
2
cli.js
@@ -1,8 +1,8 @@
|
|||||||
#!/usr/bin/env node
|
#!/usr/bin/env node
|
||||||
|
|
||||||
const spawn = require('child_process').spawn;
|
const spawn = require('child_process').spawn;
|
||||||
|
const hugo = require('.');
|
||||||
const input = process.argv.slice(2);
|
const input = process.argv.slice(2);
|
||||||
const hugo = require('./');
|
|
||||||
|
|
||||||
spawn(hugo, input, {stdio: 'inherit'})
|
spawn(hugo, input, {stdio: 'inherit'})
|
||||||
.on('exit', process.exit);
|
.on('exit', process.exit);
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
const path = require('path');
|
const path = require('path');
|
||||||
const bin = require('./');
|
|
||||||
const log = require('logalot');
|
const log = require('logalot');
|
||||||
|
const bin = require('.');
|
||||||
|
|
||||||
function getProjectRoot() {
|
function getProjectRoot() {
|
||||||
// projectRoot on postinstall could be INIT_CWD introduced in npm>=5.4
|
// projectRoot on postinstall could be INIT_CWD introduced in npm>=5.4
|
||||||
@@ -21,10 +21,10 @@ function getProjectRoot() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bin(getProjectRoot()).run(['version'])
|
bin(getProjectRoot()).run(['version'])
|
||||||
.then(() => {
|
.then(() => {
|
||||||
log.success('Hugo binary is installed successfully');
|
log.success('Hugo binary is installed successfully');
|
||||||
})
|
})
|
||||||
.catch(err => {
|
.catch(err => {
|
||||||
log.error(err.message);
|
log.error(err.message);
|
||||||
log.error('Hugo binary installation failed');
|
log.error('Hugo binary installation failed');
|
||||||
});
|
});
|
||||||
|
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
const assert = require('assert');
|
const assert = require('assert');
|
||||||
const binCheck = require('bin-check');
|
const binCheck = require('bin-check');
|
||||||
const hugoBin = require('../');
|
const hugoBin = require('..');
|
||||||
|
|
||||||
describe('hugo-bin', () => {
|
describe('hugo-bin', () => {
|
||||||
it('should return path to binary and work', () => {
|
it('should return path to binary and work', () => {
|
||||||
|
Reference in New Issue
Block a user