Skip to content

Commit

Permalink
chore: Require node v10 or above (#177)
Browse files Browse the repository at this point in the history
  • Loading branch information
LukasHechenberger committed Mar 30, 2020
2 parents 0020840 + a472f18 commit 97af441
Show file tree
Hide file tree
Showing 29 changed files with 4,030 additions and 2,661 deletions.
15 changes: 15 additions & 0 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"presets": [
[
"@babel/env",
{
"targets": { "node": 10 }
}
]
],
"env": {
"test": {
"plugins": ["istanbul"]
}
}
}
33 changes: 6 additions & 27 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ version: 2
jobs:
build:
docker:
- image: circleci/node:8
- image: circleci/node:10
steps:
- checkout
- restore_cache:
keys:
- v1-npm-deps-{{ checksum "package-lock.json" }}
- v2-npm-deps-{{ checksum "package-lock.json" }}
- run:
name: Installing npm dependencies
command: npm install
command: npm ci
- run:
name: Setting up deployment environment
command: |
Expand All @@ -19,27 +19,11 @@ jobs:
echo "Logging in to npm"
echo "$NPM_TOKEN" > ~/.npmrc
- run:
name: Handling package-lock changes
command: |
if git diff --exit-code package-lock.json; then
echo "package-lock did not change"
else
if [[ $CIRCLE_BRANCH = *"greenkeeper/"* ]]; then
echo "Committing package-lock changes"
git add package-lock.json
git commit -m 'chore(package): Update lockfile [ci skip]';
else
echo "Resetting package-lock changes"
git checkout -- package-lock.json
fi
fi
echo "Done"
- save_cache:
key: v1-npm-deps-{{ checksum "package-lock.json" }}
key: v2-npm-deps-{{ checksum "package-lock.json" }}
paths:
- node_modules
- ~/.npm
- ~/.cache

# Code Quality checks
# TODO: Lint commit message
Expand Down Expand Up @@ -84,16 +68,11 @@ jobs:
# Store Results
- store_test_results:
path: ~/reports
when: always
- store_artifacts:
path: ~/reports
when: always

# Deployment
- add_ssh_keys
- deploy:
name: Updating lockfile
command: git push origin $CIRCLE_BRANCH
- deploy:
name: Deploy changes
command: |
Expand Down
1 change: 0 additions & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 100
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

## Installation

This module can be installed via [npm](https://www.npmjs.com). With [node.js](https://nodejs.org/en/) **version 8 or later** installed run:
This module can be installed via [npm](https://www.npmjs.com). With [node.js](https://nodejs.org/en/) **version 10 or later** installed run:

```bash
# Install atscm-cli globally
Expand Down
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
environment:
nodejs_version: '8'
nodejs_version: '10'

# Install scripts. (runs after repo cloning)
install:
Expand Down
2 changes: 1 addition & 1 deletion docs/helpers/createReadme.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ readFile(join(__dirname, '../../README.md'), 'utf8', (readErr, data) => {

const path = join(__dirname, '../README.md');

writeFile(path, result, writeErr => {
writeFile(path, result, (writeErr) => {
if (writeErr) {
console.error('Error writing README', readErr.message);
process.exitCode = 1;
Expand Down
2 changes: 1 addition & 1 deletion docs/manual/usage/API.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ import AtSCMCli from 'atscm-cli';
new AtSCMCli(['--version'])
.launch() // Note: AtSCMCli#launch returns a Promise
.then(() => console.log('success!'))
.catch(err => console.error(`Oops! An error occured: ${err.message}`));
.catch((err) => console.error(`Oops! An error occured: ${err.message}`));
```

---
Expand Down
Loading

0 comments on commit 97af441

Please sign in to comment.