Permalink
Browse files

Annotation changes,

- annotations are no longer commited
- annotations are now stored in /docs/
- /docs/ is now on the ignore list
- annotations are made for ALL scripts in the lib
- License looses .txt
- eslintignore cleaned down
- Readme modified with correct spacing and tidying
  • Loading branch information...
1 parent 8f112a1 commit 8cc28098b3ba83722145de930b550d17e5ce1bf2 @mcdonnelldean mcdonnelldean committed Aug 11, 2016
Showing with 107 additions and 6,402 deletions.
  1. +2 −3 .eslintignore
  2. +3 −3 .gitignore
  3. +0 −16 CONTRIBUTING.md
  4. 0 LICENSE.txt → LICENSE
  5. +88 −89 README.md
  6. +0 −18 doc/conventions.txt
  7. +0 −132 doc/data-store.md
  8. +0 −518 doc/docco.css
  9. +0 −12 doc/examples/README.txt
  10. +0 −11 doc/examples/config-server.js
  11. +0 −11 doc/examples/sales-tax-app-client.js
  12. +0 −21 doc/examples/sales-tax-app.js
  13. +0 −22 doc/examples/sales-tax-client.js
  14. +0 −47 doc/examples/sales-tax-complex.js
  15. +0 −27 doc/examples/sales-tax-config-pin.js
  16. +0 −23 doc/examples/sales-tax-config.js
  17. +0 −6 doc/examples/sales-tax-error.js
  18. +0 −21 doc/examples/sales-tax-log-handler.js
  19. +0 −12 doc/examples/sales-tax-log.js
  20. +0 −28 doc/examples/sales-tax-logentries.js
  21. +0 −34 doc/examples/sales-tax-plugin.js
  22. +0 −12 doc/examples/sales-tax.js
  23. +0 −18 doc/examples/testrun.correct
  24. +0 −35 doc/examples/testrun.sh
  25. +0 −4 doc/examples/write-a-plugin/README.md
  26. +0 −30 doc/examples/write-a-plugin/bad.js
  27. +0 −11 doc/examples/write-a-plugin/bar.js
  28. +0 −20 doc/examples/write-a-plugin/deepextend.js
  29. +0 −5 doc/examples/write-a-plugin/dev.options.js
  30. +0 −6 doc/examples/write-a-plugin/echo.js
  31. +0 −24 doc/examples/write-a-plugin/foo-defopts.js
  32. +0 −10 doc/examples/write-a-plugin/foo.js
  33. +0 −24 doc/examples/write-a-plugin/init.js
  34. +0 −12 doc/examples/write-a-plugin/module-defopts.js
  35. +0 −7 doc/examples/write-a-plugin/module.js
  36. +0 −15 doc/examples/write-a-plugin/name0.js
  37. +0 −13 doc/examples/write-a-plugin/name1.js
  38. +0 −10 doc/examples/write-a-plugin/seneca.options.js
  39. +0 −16 doc/examples/write-a-plugin/simple.js
  40. +0 −9 doc/examples/write-a-plugin/tags.js
  41. +0 −8 doc/examples/write-a-plugin/zed-access.js
  42. +0 −9 doc/examples/write-a-plugin/zed-dev.js
  43. +0 −9 doc/examples/write-a-plugin/zed-tag.js
  44. +0 −8 doc/examples/write-a-plugin/zed.js
  45. BIN doc/public/fonts/aller-bold.eot
  46. BIN doc/public/fonts/aller-bold.ttf
  47. BIN doc/public/fonts/aller-bold.woff
  48. BIN doc/public/fonts/aller-light.eot
  49. BIN doc/public/fonts/aller-light.ttf
  50. BIN doc/public/fonts/aller-light.woff
  51. BIN doc/public/fonts/novecento-bold.eot
  52. BIN doc/public/fonts/novecento-bold.ttf
  53. BIN doc/public/fonts/novecento-bold.woff
  54. BIN doc/public/fonts/roboto-black.eot
  55. BIN doc/public/fonts/roboto-black.ttf
  56. BIN doc/public/fonts/roboto-black.woff
  57. +0 −375 doc/public/stylesheets/normalize.css
  58. +0 −13 doc/release.txt
  59. +0 −4,242 doc/seneca.html
  60. +0 −388 doc/transport.md
  61. +14 −15 package.json
View
@@ -1,5 +1,4 @@
node_modules
-docpad
-doc
+docs
+
test/plugin/bad-syntax-plugin.js
-tmp
View
@@ -1,5 +1,6 @@
*~
.DS_Store
+docs
test/db
*.old
*.bak
@@ -9,10 +10,9 @@ node_modules*
README.html
*.off
*-off
-.DS_Store
npm-debug.log
mem.json
out
-testcov.html
+coverage.html
.idea
-tmp
+tmp
View
@@ -1,16 +0,0 @@
-# How to contribute
-We welcome contributions from the community and are pleased to have them. Please follow this guide when logging issues or making code changes. If unsure about anything, you can refer to our [indepth contributing guidelines here](http://senecajs.org/contribute/).
-
-## Logging Issues
-All issues should be created using the [new issue form](https://github.com/senecajs/seneca/issues/new). Clearly describe the issue including steps to reproduce if there are any. Also, make sure to indicate the earliest version that has the issue being reported.
-
-## Patching Code
-Code changes are welcome and should follow the guidelines below.
-
-* Fork the repository on GitHub.
-* Fix the issue ensuring that your code follows the [style guide](http://senecajs.org/contribute/details/styleguide.html).
-* Add tests for your new code ensuring that you have 100% code coverage (we can help you reach 100% but will not merge without it).
- * Run `npm run test-cov-html` to generate a report of test coverage
-* [Pull requests](http://help.github.com/send-pull-requests/) should be made to the [master branch](https://github.com/senecajs/seneca/tree/master).
-
-[Adapted with permission from Hapijs.](https://github.com/hapijs/hapi/)
File renamed without changes.
View
@@ -1,55 +1,51 @@
-![Seneca](http://senecajs.org/files/assets/seneca-logo.png)
-> A Node.js toolkit for Micro-Service Architectures
+![Logo][]
+> A Node.js toolkit for Microservice architectures
# seneca
-[![npm version][npm-badge]][npm-url]
-[![npm downloads][npm-downloads-badge]][npm-url]
-[![Build Status][travis-badge]][travis-url]
-[![Coverage Status][coveralls-badge]][coveralls-url]
-[![Gitter][gitter-badge]][gitter-url]
+[![Npm][BadgeNpm]][Npm]
+[![NpmFigs][BadgeNpmFigs]][Npm]
+[![Travis][BadgeTravis]][Travis]
+[![Coveralls][BadgeCoveralls]][Coveralls]
+[![Gitter][BadgeGitter]][Gitter]
-## About Seneca
-_Seneca_ is a toolkit for organizing the business logic of your app. You can break down your app into "stuff that happens", rather than focusing on data models or managing dependencies.
+- __Lead Maintainer:__ [Richard Rodger][Lead]
+- __Sponsor:__ [nearForm][Sponsor]
+- __Node:__ 4.x, 5.x
-_Seneca_ provides a toolkit for writing micro-services in Node.js.
+Seneca is a toolkit for writing microservices and organizing the business logic of your
+app. You can break down your app into "stuff that happens", rather than focusing on data
+models or managing dependencies.
-_Seneca_ provides:
+Seneca provides,
- __pattern matching:__ a wonderfully flexible way to handle business requirements
-- __transport independence:__ how messages get to the right server is not something you should have to worry about
+- __transport independence:__ how messages get to the right server is not something you
+should have to worry about
-- __maturity:__ 5 years in production (before we called it _micro-services_), but was once taken out by [lightning][]
+- __maturity:__ 5 years in production (before we called it _microservices_), but was
+once taken out by [lightning][]
- __plus:__ a deep and wide ecosystem of [plugins][]
-Use this module to define commands that work by taking in some JSON, and, optionally, returning some JSON.
-The command to run is selected by pattern-matching on the the input JSON.
-There are built-in and optional sets of commands that help you build Minimum Viable Products:
-data storage, user management, distributed logic, caching, logging, etc.
-And you can define your own product by breaking it into a set of commands - "stuff that happens".
-
-That's pretty much it. ;)
-
-## About Seneca Support
-
-- __Node:__ 0.10, 0.12, 4, 5
-
-Seneca's source can be read in an annotated fashion by,
-
-- viewing [online](http://senecajs.org/annotations/seneca.html).
-- running `npm run annotate`
-
-The annotated source can be found locally at [./doc/seneca.html]().
+Use this module to define commands that work by taking in some JSON, and, optionally,
+returning some JSON. The command to run is selected by pattern-matching on the the input
+JSON. There are built-in and optional sets of commands that help you build Minimum Viable
+Products: data storage, user management, distributed logic, caching, logging, etc. And you
+can define your own product by breaking it into a set of commands - "stuff that happens".
+That's pretty much it.
If you're using this module, and need help, you can:
-- Post a [github issue][],
-- Tweet to [@senecajs][],
-- Ask on the [Gitter][gitter-url].
+- Post a [github issue][Issue],
+- Tweet to [@senecajs][Tweet],
+- Ask on the [Gitter][Gitter].
+
+If you are new to Seneca in general, please take a look at [senecajs.org][Org]. We have
+everything from tutorials to sample apps to help get you up and running quickly.
-If you are new to Seneca in general, please take a look at [senecajs.org][]. We have everything from
-tutorials to sample apps to help get you up and running quickly.
+Seneca's source can be read in an annotated fashion by running `npm run annotate`. An
+annotated version of each file will be generated in `./docs/`.
## Install
To install, simply use npm.
@@ -65,6 +61,13 @@ To run tests, simply use npm:
npm run test
```
+### Coverage
+To obtain a coverage report run,
+
+```
+npm run coverage; open coverage.html
+```
+
## Why we built this?
@@ -93,19 +96,19 @@ seneca.act({ cmd: 'salestax', net: 100 }, function (err, result) {
})
```
-In this code, whenever seneca sees the pattern
-`{cmd:'salestax'}`, it executes the function associated
-with this pattern, which calculates sales tax. There is nothing special about the property `cmd` .
-It is simply the property we want to pattern match. You could look for `foo` for all seneca cares!
- Yah!
+In this code, whenever seneca sees the pattern `{cmd:'salestax'}`, it executes the
+function associated with this pattern, which calculates sales tax. There is nothing
+special about the property `cmd` . It is simply the property we want to pattern match.
+You could look for `foo` for all seneca cares! Yah!
-The `seneca.add` method adds a new pattern, and the function to execute whenever that pattern occurs.
+The `seneca.add` method adds a new pattern, and the function to execute whenever that
+pattern occurs.
The `seneca.act` method accepts an object, and runs the command, if any, that matches.
Where does the sales tax rate come from? Let's try it again:
-```javascript
+```js
seneca.add({ cmd: 'config' }, function (args, callback) {
var config = {
rate: 0.23
@@ -127,10 +130,10 @@ seneca.act({ cmd: 'salestax', net: 100 }, function (err, result) {
})
```
-The `config` command provides you with your configuration. This is
-cool because it doesn't matter _where_ it gets the configuration from
-- hard-coded, file system, database, network service, whatever. Did
-you have to define an abstraction API to make this work? Nope.
+The `config` command provides you with your configuration. This is cool because it
+doesn't matter _where_ it gets the configuration from - hard-coded, file system,
+database, network service, whatever. Did you have to define an abstraction API to make
+this work? Nope.
There's a little but too much verbosity here, don't you think? Let's fix that:
@@ -142,7 +145,7 @@ seneca.act('cmd:salestax,net:100', function (err, result) {
```
Instead of providing an object, you can provide a string using an
-[abbreviated form of JSON](//github.com/rjrodger/jsonic). In fact, you
+[abbreviated form] of JSON[Jsonic]. In fact, you
can provide both:
```javascript
@@ -271,48 +274,44 @@ seneca.act('cmd:salestax,net:100,country:IE,category:reduced', function (err, re
```
-In this case, you provide different implementations for different
-patterns. This lets you isolate complexity into well-defined
-places. It also means you can deal with special cases very easily.
-
-
-## Examples
-
-For more examples of Seneca in action, take a look at:
-
- * [seneca-examples](//github.com/senecajs/getting-started)
- * [nodezoo.com](//nodezoo.com/#q=seneca)
- * [Well!](//github.com/nearform/well)
-
+In this case, you provide different implementations for different patterns. This lets you
+isolate complexity into well-defined places. It also means you can deal with special
+cases very easily.
## Contributing
-The [Senecajs org][] __encourages open participation__. If you feel you can help in any way, be it with
-bug reporting, documentation, examples, extra testing, or new features feel free to [create an issue][github issue],
-or better yet, [submit a pull request][github pull request].
-
-We have 2 main forms of documention for getting started with contributing:
- - [Our very brief, and to the point, contributing.md](./CONTRIBUTING.md)
- - [Our much more comprehensive contributing documentation.][contributing]
+The [Senecajs org][Org] encourages participation. If you feel you can help in any way, be
+it with bug reporting, documentation, examples, extra testing, or new features feel free
+to [create an issue][Issue], or better yet, [submit a [Pull Request][Pull]. For more
+information on contribution please see our [Contributing][Contrib] guide.
## License
-Copyright Richard Rodger and other contributors 2015, Licensed under [MIT][].
-
-[travis-badge]: https://travis-ci.org/senecajs/seneca.svg?branch=master
-[travis-url]: https://travis-ci.org/senecajs/seneca?branch=master
-[coveralls-badge]: https://coveralls.io/repos/senecajs/seneca/badge.svg?branch=master&service=github
-[coveralls-url]: https://coveralls.io/github/senecajs/seneca?branch=master
-[gitter-badge]: https://badges.gitter.im/Join%20Chat.svg
-[gitter-url]: https://gitter.im/senecajs/seneca
-[npm-badge]: https://badge.fury.io/js/seneca.svg
-[npm-url]: https://badge.fury.io/js/seneca
-[npm-downloads-badge]: https://img.shields.io/npm/dm/seneca.svg?maxAge=2592000
-
-[MIT]: ./LICENSE
-[Senecajs org]: https://github.com/senecajs/
-[senecajs.org]: http://senecajs.org/
-[github issue]: https://github.com/senecajs/seneca/issues
-[github pull request]: https://github.com/senecajs/seneca/pulls
-[@senecajs]: http://twitter.com/senecajs
-[lightning]: http://aws.amazon.com/message/67457/
-[plugins]: https://github.com/search?utf8=%E2%9C%93&q=seneca&type=Repositories&ref=searchresults
-[contributing]: http://senecajs.org/contribute/
+Copyright (c) 2015-2016 Richard Rodger and other contributors;
+Licensed under __[MIT][Lic]__.
+
+
+
+[BadgeCoveralls]: https://coveralls.io/repos/senecajs/seneca/badge.svg?branch=master&service=github
+[BadgeNpm]: https://badge.fury.io/js/seneca.svg
+[BadgeGitter]: https://badges.gitter.im/senecajs/seneca.svg
+[BadgeNpmFigs]: https://img.shields.io/npm/dm/seneca.svg?maxAge=2592000
+[BadgeTravis]: https://travis-ci.org/senecajs/seneca.svg?branch=master
+[CoC]: http://senecajs.org/code-of-conduct
+[Contrib]: http://senecajs.org/contribute
+[Coveralls]: https://coveralls.io/github/senecajs/seneca?branch=master
+[Gitter]: https://gitter.im/senecajs/seneca
+[Issue]: https://github.com/senecajs/seneca/issues/new
+[Lead]: https://github.com/rjrodger
+[Lic]: ./LICENSE
+[Logo]: http://senecajs.org/files/assets/seneca-logo.jpg
+[Npm]: https://www.npmjs.com/package/seneca
+[Org]: https://github.com/senecajs/issues
+[Pull]: https://github.com/senecajs/seneca/pulls
+[Sponsor]: http://nearform.com
+[Travis]: https://travis-ci.org/senecajs/seneca?branch=master
+[Tweet]: https://twitter.com/senecajs
+
+
+
+[Jsonic]: https//github.com/rjrodger/jsonic
+[Lightning]: http://aws.amazon.com/message/67457/
+[Plugins]: https://github.com/search?utf8=%E2%9C%93&q=seneca&type=Repositories&ref=searchresults
View
@@ -1,18 +0,0 @@
-
-
-Data Stores:
-
-- Plugins should always have -store suffix
-- Date objects should not be used - behaviour on load is undef - might be an ISO string, might be a date
-- Close should force sync of underlying data store
-- Custom actions should use role:<plugin>, not role:entity. e.g. role:mem-store, cmd:dump
-
-- to document
- - canonical order of ent designation parts: zone,base,name
- - stores handle base and name as base_name
- - stores do not handle zones
-
-
-
-
-
Oops, something went wrong.

0 comments on commit 8cc2809

Please sign in to comment.