Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

configfile: convert to es6 class #57

Merged
merged 6 commits into from
Mar 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .codeclimate.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
engines:
eslint:
enabled: true
channel: "eslint-4"
channel: "eslint-6"
config:
config: ".eslintrc.yaml"

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/coveralls.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ jobs:
with:
fetch-depth: 1

- name: Use Node.js 10
- name: Use Node.js 12
uses: actions/setup-node@master
with:
version: 10.x
version: 12.x

- name: install, run
run: |
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,5 @@ jobs:
run: npm run lint

env:
CI: true
CI: true

6 changes: 6 additions & 0 deletions Changes.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@

## 1.N.NN - 20YY-MM-DD

## 1.0.19 - 2019-MM-DD

- configfile: convert to es6 class
- configfile.read_dir: promisify
- configfile: use simpler es6 `for..in` and `for..of`


## 1.0.18 - 2019-10-11

Expand Down
4 changes: 3 additions & 1 deletion config.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ class Config {
}

getDir (name, opts, done) {
cfreader.read_dir(path.resolve(this.root_path, name), opts, done);
cfreader.read_dir(path.resolve(this.root_path, name), opts).then((files) => {
done(null, files) // keep the API consistent
}).catch(done)
}

arrange_args (args) {
Expand Down
Loading