Commit Graph

125 Commits

Author SHA1 Message Date
Tim Schaub
2dd3fbf307 Renaming and docs for clarity 2015-04-17 16:09:43 -06:00
Tim Schaub
bc1bde6a86 Index what the examples require 2015-04-17 16:03:55 -06:00
Marc Jansen
fedceb9a05 Automatically add links to API-docs in examples
When we create the examples, we know exactly which specific `ol.…` symbols
we `goog.require(…)`. We can create links to the API documentation of these
symbols automatically.
2015-04-17 21:50:50 +02:00
Tim Schaub
c5cf709c55 The common.js script makes a "common" object available 2015-04-17 09:49:53 -06:00
Tim Schaub
84f3bea766 Upgrade Metalsmith to get new concurrency option 2015-04-17 06:22:38 -06:00
Tim Schaub
89f5e711e6 Example sources in the examples dir 2015-04-17 06:22:38 -06:00
Tim Schaub
8fd2e9f79f Untangle resources and put built examples in the build dir 2015-04-17 06:22:38 -06:00
Tim Schaub
5dfa9e0a67 Merge pull request #3548 from tschaub/slimer-error
Write the error stack instead of the error itself.
2015-04-13 06:49:28 -06:00
Tim Schaub
b9198f1f7b Write the stack instead of an error 2015-04-13 06:32:36 -06:00
Tim Schaub
8ddec98075 Rebuild examples when the sources change 2015-04-12 15:42:55 -06:00
Tim Schaub
aaba58ceb0 Generate index.js when building examples 2015-04-12 15:42:48 -06:00
Tim Schaub
0789604e88 Merge pull request #3504 from tschaub/build-examples
Rework build-examples.js task.
2015-04-06 11:27:00 -06:00
Tim Schaub
121a83f19e Explicitly helper use instead of implicitly converting from markdown 2015-04-06 11:13:45 -06:00
Tim Schaub
3b96071096 Metadata names 2015-04-06 11:13:45 -06:00
Tim Schaub
30c04cf8ab Maintain resource list order (principle of least surprise) 2015-04-06 11:13:45 -06:00
Tim Schaub
75fcec15ec Simplify plugin
The augmentExamples just adds metadata to the example markup files.  If we also want to support example markdown files, we can use the metalsmith-markdown plugin before this one.
2015-04-06 11:13:32 -06:00
Tim Schaub
9f1e0f001a Proper lists for example resources 2015-04-06 09:18:32 -06:00
Tim Schaub
6d318dce78 Rework plugin 2015-04-06 09:18:28 -06:00
Tobias Sauerwein
c36c67779e Merge pull request #3470 from tsauerwein/rendering-tests
Add rendering tests
2015-04-06 13:49:51 +02:00
Tim Schaub
c265676f67 Avoid reading css and js files twice 2015-04-06 04:21:12 -06:00
Tim Schaub
cdc4283cbf Use global metadata for ol version 2015-04-06 04:10:17 -06:00
Tim Schaub
8afb5698f1 Allow script to be run from anywhere 2015-04-06 04:09:46 -06:00
tsauerwein
8e0c21eb58 Add test-suite using SlimerJS 2015-04-04 17:30:38 +02:00
tsauerwein
921fd3ed3b Support generic ext. modules with browserify 2015-04-04 09:17:11 +02:00
Andreas Hocevar
cd266f35ab Add verbatim template and throw error on invalid front-matter 2015-04-02 20:28:32 +02:00
Andreas Hocevar
78ce9de4af Better error reporting 2015-04-02 19:10:14 +02:00
Andreas Hocevar
4cce0f4936 Move documentation to the right place 2015-04-02 19:10:13 +02:00
Bart van den Eijnden
4ebceab51a Remove extra double quote when writing resources 2015-04-02 19:10:12 +02:00
Andreas Hocevar
6cc806f164 Add documentation for build-examples.js 2015-04-02 19:10:12 +02:00
Andreas Hocevar
bc617e8135 Add support for additonal js and css resources 2015-04-02 19:10:12 +02:00
Andreas Hocevar
ff1ee78ddd Build and parse examples from examples_src/ 2015-04-02 19:10:09 +02:00
Andreas Hocevar
1d940898b5 Add Task and template for building examples 2015-04-02 19:10:02 +02:00
Marc Jansen
245aec8eba Fix typos in doc-comments. 2015-04-02 09:45:25 +02:00
Marc Jansen
17ea9ecef5 Run the istanbul code-coverage via node script. 2015-04-02 09:16:43 +02:00
Marc Jansen
6a9c8f36f7 Refactor tasks/test.js to be more modular.
This way the main functionality of the script can be reused in the
tasks/test-coverage.js script, which has to run the testsuite as well.
2015-04-02 09:13:17 +02:00
Bart van den Eijnden
7c9795ba35 Integrate istanbul for test coverage 2015-04-02 08:57:53 +02:00
Andreas Hocevar
9462c2148d Listen on localhost to avoid phantomjs browsing 0.0.0.0 2015-03-17 14:39:00 +01:00
Andreas Hocevar
1b640870b1 Add css to dist directory 2015-03-06 11:20:01 +01:00
Stefan Weil
829569c6b5 Fix typo in documentation of function getInfo
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2015-02-12 17:53:53 +01:00
Stefan Weil
e812f2435e Fix typos found by codespell
Most of them are in comments, some in strings.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2015-02-12 16:39:55 +01:00
Tim Schaub
62854f6e32 Add script to standardize changelog ceation 2014-12-22 13:02:27 -05:00
Tim Schaub
9b0349f2d5 Variable for builds directory 2014-12-20 02:55:56 -07:00
Tim Schaub
d4763a0fe7 Set CLOSURE_NO_DEPS globally 2014-12-20 02:35:05 -07:00
Tim Schaub
3582445755 Add task for publishing to npm
This task publishes an existing tag to the npm registry.  To publish a new release, create a commit that updates the version number in package.json (e.g. to "3.1.0").  Then create a tag, push to GitHub, and run the publish task.  Assuming "openlayers" is the remote for the canonical repo, this would look like the following:

    git tag -a v3.1.0 -m "3.1.0"
    git push --tags openlayers
    ./tasks/publish.sh 3.1.0

The task creates a build for each of the `PROFILES` in `publish.sh` (these correspond to `.json` files in the `config` directory).  Builds are generated in the `dist` directory.  Our `package.json` specifies `dist/ol.js` as the "main" build.  So when people use a module loader to `require('openlayers')`, they get the full build.  It is also possible to load a debug build (e.g. `require('openlayers/dist/ol-debug')`), and we can publish additional builds by adding `config` files and updating `PROFILES` in `publish.sh`.

The `.npmignore` file determines what is *not* included in the package (note that `node_modules` are always ignored).  So if additional items are added to `.gitignore` that should not be included in the npm package, they need to go in `.npmignore` as well (ideally, we don't need to generate anything else outside of the `build` directory that doesn't belong in the package).
2014-12-19 17:45:48 -07:00
Tim Schaub
a95327f18e Define goog and assign to global
When concatenating the Closure Library, base.js creates a new `goog` object if there is not already one in scope.  Later, `goog.global` is assigned the value of `this`.  Calls to `goog.provide` create "namespace" objects by assigning to `goog.global`.  To ensure that `goog` is the same as `goog.global.goog`, we need to create a new `goog` object in the scope of base.js and assign it to `this.goog`.
2014-12-19 14:41:47 -07:00
Tim Schaub
b60b0ecdb0 Add support for wrapping the build in UMD syntax. 2014-12-13 13:23:10 -08:00
Tim Schaub
4c504ede74 Doc fix regarding externs 2014-12-07 16:35:58 -08:00
Tim Schaub
32a67801e5 Include correct path in error message 2014-12-07 16:27:31 -08:00
Tim Schaub
c6b172aef2 Work with modules that assign to exports
CommonJS style modules will either assign `exports` to `module` or will assign properties to `exports`.  This allows us to work with either style:

    module.exports = Foo;

or

    exports.Foo = Foo;

Support for additional properties that are assigned to `exports` (or non-function values assigned to `module.exports`) will likely take additional typedef work in the wrapper.
2014-10-24 08:45:59 -06:00
Tim Schaub
120ace5cef Minimal typedef 2014-10-24 08:45:31 -06:00