Skip to content

Commit ad17ec3

Browse files
committed
chore: update build commands documentation
1 parent 823f377 commit ad17ec3

File tree

9 files changed

+36
-33
lines changed

9 files changed

+36
-33
lines changed

docs/api/plugins/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ define([
7272

7373
As we mentioned above, when SourceJS plugin is installed through NPM, main client-side module of your plugin (`index.js`) is connected by default.
7474

75-
To achieve this, we generate custom RequireJS configuration through default Grunt task and dynamically extend `options.js`, filling installed modules to `assets.npmPluginsEnabled` with `true`.
75+
To achieve this, we generate custom RequireJS configuration through default build task and dynamically extend `options.js`, filling installed modules to `assets.npmPluginsEnabled` with `true`.
7676

7777
To disable client-side module of any installed npm Plugins, you can edit the module definition in `user/options.js`:
7878

docs/base/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ During the initial set-up, generator will build everything for you. To re-build
8181
npm run build
8282
```
8383

84-
It will trigger `npm i` and `grunt default` commands for updating dependencies and building SourceJS assets. See the full list of [all Grunt tasks available](/docs/grunt).
84+
It will trigger `npm i` and default build task for updating dependencies and building SourceJS assets. See the full list of [all build tasks available](/docs/build-tasks).
8585

8686
### Update
8787

docs/build-tasks/info.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"title": "Build Tasks",
3+
"template": "doc"
4+
}

docs/build-tasks/readme.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
Note that these commands are related only to SourceJS engine build and development cycle.
2+
3+
For building specs and other project related content use own build tasks from `sourcejs/user` folder.
4+
5+
## Scripts
6+
7+
All automation tasks are triggered through NPM scripts listed in `package.json`.
8+
9+
Here's a list of most common commands:
10+
11+
```js
12+
$ npm run build
13+
$ npm start
14+
15+
$ npm run watch
16+
$ npm run watch:css
17+
18+
$ npm run lint
19+
20+
$ npm test
21+
$ npm run test:unit
22+
$ npm run test:func
23+
```
24+
25+
* `npm run build` - default build command for preparing SourceJS assets, used as a post-install hook and after plugin installation
26+
* `npm start` - runs the engine
27+
* `npm run watch` - runs engine sources watcher, used in core client-side modules development

docs/grunt/info.json

Lines changed: 0 additions & 4 deletions
This file was deleted.

docs/grunt/readme.md

Lines changed: 0 additions & 26 deletions
This file was deleted.

docs/grunt/thumbnail.png

-18.8 KB
Binary file not shown.

docs/migration/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ Here you will find migration instructions from different Source versions
22

33
## From 0.4.0-beta to 0.4.0-rc
44

5-
* Update engine files, run `npm i` and `grunt` at root of engine
5+
* Update engine files, run `npm run build` in the root of engine
66
* If you have custom `user/core/views`, then add `info.*` namespace to all data in template that is taken from `info.json` (`info.author`, `info.title`, `info.keywords`)
77
* Set at your views and `*.html` spec files new path to main client-side file: `/source/assets/js/enter-the-source.js`

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,8 @@
6565
"build": "npm i",
6666
"lint": "grunt jshint",
6767
"start": "node app",
68+
"watch": "grunt watch-all",
69+
"watch:css": "grunt watch-css",
6870
"test": "grunt ci-pre-run && node app.js --test",
6971
"test:unit": "grunt test",
7072
"test:func": "grunt test-func",

0 commit comments

Comments
 (0)