Skip to content

Commit ede25ee

Browse files
committed
Added a couple commands to README. Version bump.
1 parent 7bde0c6 commit ede25ee

File tree

2 files changed

+11
-9
lines changed

2 files changed

+11
-9
lines changed

README.md

+9-7
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,16 @@ Scripts built into [`package.json`](package.json):
1919

2020
| Command | Description
2121
|---------------|-------------------
22-
|npm run start| Will run both `npm run lift` and `npm run open:client` in parallel.
22+
|npm run start | Will run both `npm run lift` and `npm run open:client` in parallel.
2323
|npm run open:client | Will run the [Webpack Dev Server](https://webpack.js.org/configuration/dev-server/) and open a browser tab / window.
24-
|npm run lift | The same thing as `sails lift` or `node app.js`; will "[lift our Sails](https://sailsjs.com/documentation/reference/command-line-interface/sails-lift)" instance.
25-
|npm run debug | Alias for `node --inspect app.js`.
26-
|npm run build | Will run `npm run clean`, then will build production-ready files with Webpack in the `.tmp/public` folder.
27-
|npm run build:dev | Same thing as `npm run build`, except that it will not optimize the files, retaining newlines and empty spaces.
28-
|npm run clean | Will basically delete everything in the `.tmp` folder.
29-
|npm run lines | Will count the lines of code in the project, minus `.gitignore`'d files, for funzies.
24+
|npm run lift | The same thing as `sails lift` or `node app.js`; will "[lift our Sails](https://sailsjs.com/documentation/reference/command-line-interface/sails-lift)" instance.
25+
|npm run debug | Alias for `node --inspect app.js`.
26+
|npm run build | Will run `npm run clean`, then will build production-ready files with Webpack in the `.tmp/public` folder.
27+
|npm run build:dev | Same thing as `npm run build`, except that it will not optimize the files, retaining newlines and empty spaces.
28+
|npm run clean | Will basically delete everything in the `.tmp` folder.
29+
|npm run lines | Will count the lines of code in the project, minus `.gitignore`'d files, for funzies. There are currently about **6k** custom lines in this repo (views, controllers, helpers, hooks, etc).
30+
|npm run test | Run [Mocha](https://mochajs.org/) tests. Everything starts in the [`test/hooks.js`](test/hooks.js) file.
31+
|npm run coverage | Runs [NYC](https://www.npmjs.com/package/nyc) coverage reporting of the Mocha tests, which generates HTML in `test/coverage`.
3032

3133
## Request Logging
3234
Automatic incoming request logging, is a 2 part process. First, the [`request-logger` hook](api/hooks/request-logger.js) gathers info from the quest, and creates a new [`RequestLog` record](api/models/RequestLog.js), making sure to mask anything that may be sensitive, such as passwords. Then, a custom response gathers information from the response, again, scrubbing sensitive data (using the [customToJSON](https://sailsjs.com/documentation/concepts/models-and-orm/model-settings?identity=#customtojson) feature of Sails models) to prevent leaking of password hashes, or anything else that should never be publicly accessible. The [`keepModelsSafe` helper](api/helpers/keep-models-safe.js) and the custom responses (such as [ok](api/responses/ok.js) or [serverError](api/responses/serverError.js)) are responsible for the final leg of request logs.

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "sails-react-bootstrap-webpack",
3-
"version": "1.2.1",
3+
"version": "1.2.2",
44
"description": "An opinionated base configuration of Sails, with Webpack for React support, and Bootstrap for styling.",
55
"keywords": [
66
"sails",
@@ -75,7 +75,7 @@
7575
"clean": "rimraf .tmp && mkdirp .tmp/public",
7676
"lift": "node app.js",
7777
"debug": "node --inspect app.js",
78-
"lines": "git ls-files --exclude-standard -- ':!:**/*.[pjs][npv]g' ':!:**/*.ai' ':!:.idea' ':!:**/*.eslintrc' ':!:package-lock.json' | xargs wc -l"
78+
"lines": "git ls-files --exclude-standard -- ':!:**/*.[pjs][npv]g' ':!:**/*.ai' ':!:.idea' ':!:test/coverage/*' ':!:config/*' ':!:.babelrc' ':!:.editorconfig' ':!:.eslintrc' ':!:.eslintignore' ':!:.gitignore' ':!:.mocharc.yaml' ':!:.npmrc' ':!:.nycrc' ':!:.sailsrc' ':!:LICENSE' ':!:package-lock.json' | xargs wc -l"
7979
},
8080
"main": "app.js",
8181
"repository": {

0 commit comments

Comments
 (0)