mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-14 02:06:29 +00:00
Enable to set configs in ~/.boostnoterc
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import _ from 'lodash'
|
||||
|
||||
const path = require('path')
|
||||
const sander = require('sander')
|
||||
|
||||
@@ -7,6 +9,15 @@ function parse (boostnotercPath) {
|
||||
return config
|
||||
}
|
||||
|
||||
export default {
|
||||
parse
|
||||
function exec (boostnotercPath) {
|
||||
const config = this.parse(boostnotercPath)
|
||||
if (config.execs === undefined) return
|
||||
_.forEach(config.execs, (exec) => {
|
||||
eval(exec)
|
||||
})
|
||||
}
|
||||
|
||||
export default {
|
||||
parse,
|
||||
exec
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user