Skip to content
This repository was archived by the owner on Jan 8, 2025. It is now read-only.

Commit 03b2dab

Browse files
committed
Merge branch 'release/1.2.3'
2 parents a5c8344 + f7b0f5d commit 03b2dab

File tree

10 files changed

+12545
-4176
lines changed

10 files changed

+12545
-4176
lines changed

.circleci/config.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616

1717
- restore_cache:
1818
keys:
19-
- dependencies-{{ checksum "package.json" }}
19+
- dependencies-v2-{{ checksum "package.json" }}
2020

2121
- run:
2222
name: Install global packages
@@ -27,7 +27,7 @@ jobs:
2727
command: npm install
2828

2929
- save_cache:
30-
key: dependencies-{{ checksum "package.json" }}
30+
key: dependencies-v2-{{ checksum "package.json" }}
3131
paths:
3232
- node_modules
3333

.eslintrc.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module.exports = {
22
extends: ['standard', 'prettier', 'prettier/standard', 'plugin:promise/recommended'],
3-
plugins: ['standard', 'prettier', 'promise'],
3+
plugins: ['prettier', 'promise'],
44
parserOptions: {
55
sourceType: 'module'
66
},

.husky/.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
_

.husky/pre-commit

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
npx --no-install lint-staged

README.md

+15-4
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ This is a GitHub Template so either click the ['use this template'](https://gith
5454
- standardised [`node-http-error`](https://github.com/carsondarling/node-http-error) and [`http-status-codes`](https://github.com/prettymuchbryce/http-status-codes) and simple `generic` and `notFound` error handlers
5555
- [`dotenv`](https://github.com/motdotla/dotenv) support
5656
- the swagger editor as an easy to invoke docker image
57+
- simple `project.toml` [buildpacks](https://buildpacks.io) config.
5758

5859
### Code quality
5960

@@ -68,7 +69,6 @@ This is a GitHub Template so either click the ['use this template'](https://gith
6869
- 100% unit test coverage using [`nyc`](https://github.com/istanbuljs/nyc)
6970
- integration testing using [`supertest`](https://github.com/visionmedia/supertest)
7071
- code quality using [`eslint`](https://eslint.org) and [`prettier`](https://prettier.io)
71-
- mutation testing with [`stryker-mutator`](https://stryker-mutator.io)
7272
- [`circleci`](https://circleci.com) integration
7373
- [`snyk`](https://snyk.io) integration
7474

@@ -95,8 +95,9 @@ I've paired this right back to the simplest, most generic API I could, so there'
9595

9696
### Prerequisites
9797

98-
- [NodeJS](htps://nodejs.org), version 12.18.4 (LTS) or better. (I use [`nvm`](https://github.com/creationix/nvm) to manage Node versions — `brew install nvm`.)
99-
- [Docker](https://www.docker.com) if you want to use the Swagger Editor. (Use [Docker for Mac](https://docs.docker.com/docker-for-mac/), not the `homebrew` version)
98+
- [NodeJS](htps://nodejs.org), I use [`nvm`](https://github.com/creationix/nvm) to manage Node versions — `brew install nvm`.
99+
- [Docker](https://www.docker.com) if you want to use the Swagger Editor, or you wish to use a `buildpack`. Use [Docker for Mac](https://docs.docker.com/docker-for-mac/), not the `homebrew` version.
100+
- [Pack](https://buildpacks.io) to use `buildpacks``brew install buildpacks/tap/pack`
100101

101102
### To build and run locally
102103

@@ -113,6 +114,17 @@ You can then go to [localhost:8282/docs](http://127.0.0.1:8282/docs) to see the
113114

114115
You can put environment variables in a `.env` file.
115116

117+
### Buildpacks.
118+
119+
You can use an `heroku buildpack` as follows:
120+
121+
```sh
122+
pack build api-server-boilerplate --builder heroku/buildpacks:18
123+
docker run api-server-boilerplate
124+
```
125+
126+
Or tweak the `project.toml` file to use whatever buildpacks and environment variables you wish.
127+
116128
### Development Helpers
117129

118130
| Service | Port | Command | Notes |
@@ -128,7 +140,6 @@ Copy and paste the `api.yml` file into the editor to edit it.
128140
- `npm run lint` will lint it
129141
- `npm run prettier` will prettify it
130142
- `npm run test:unit:cov` will run the unit tests with code coverage
131-
- `npm run test:mutants` will run the unit tests with mutation testing
132143

133144
## Contributing
134145

0 commit comments

Comments
 (0)