74 Commits (8cf81b47b7fef478d950d4cf602c3380a112cca7)

Author SHA1 Message Date
Futago-za Ryuu 8856913ae8 Updated maintainer #503 7 years ago
David Majda 9f36131637 Use https: in links to majda.cz
This avoids redirects.
7 years ago
David Majda 95d1e0decf package.json: Use exact version of run-sequence
The package was added with a version range ("^") by mistake.
7 years ago
David Majda 73de2c9384 Switch from Jasmine to Mocha & Chai
The switch is mostly mechanical, with assertions translated 1:1. The
biggest non-mechanical part is rewriting Jasmine custom matchers as Chai
helpers. The matchers were streamlined and simplified in the process and
their messages were made more in line with messages produced by built-in
Chai helpers.

Fixes #409.
7 years ago
David Majda 266f17d11c Adapt to using HTTPS on PEG.js website
PEG.js website is now served exclusively using HTTPS. Change protocol in
all links to it to avoid redirects.
7 years ago
David Majda b5bd30c813 gulpfile.js: Use "run-sequence" to run default tasks
Instead of specifying tasks that are part of the "default" task using
dependencies and running them in parallel, execute them serially using
"run-sequence". This makes things deterministic and ensures that all
messages from all tasks are seen in the output (which wasn't the case
before, leading to confusion).
8 years ago
David Majda b33f2b2d24 Remove VERSION
Version information is already present in package.json and no code uses
the VERSION file anymore. It doesn't make sense too keep it just for the
sake of following an old convention as it is a maintenance burden.
8 years ago
David Majda 9956b42392 Switch from Make to Gulp
The core of the transition is getting rid of Makefile and replacing it
with gulpfile.js. The rest is details (fixing dependencies, changing all
references to "make", etc.).

Target/task names mostly stay the same, so in most cases "gulp foo" does
what "make foo" did before. The only exceptions are "make browser" and
"make browserclean", which are now "gulp browser:build" and "gulp
browser:clean" (it feels more systematic).

Functionality is mostly unchanged (modulo Gulp clutter in the console),
but there are two small exceptions:

  gulp spec

    The reporter now displays just dots while previously it displayed
    spec descriptions. There is also a deprecation warning (most likely
    because I used an old version of gulp-jasmine in order to support
    Jasmine 1.x). I kept these issues unfixed because I plan to switch
    to Mocha soon (#409).

  gulp browser:build

    The copyright header is now added manually both to the development
    and minified build. Before, it was added only to the development
    build and the minified build relied on preserving it using "uglify
    --comments". This was broken since switching to //-style comments.

    There is now also an empty line between the header and the source
    code.

Fixes #444.
8 years ago
David Majda 6f34b542b4 Code style: Use eslint-config-dmajda ESLint configuration
This change leads to quite some errors being reported by ESLint. These
will be fixed in subsequent commits.

Part of #407.
8 years ago
David Majda b5eb1a0ec4 Use eslint 3.6.1 8 years ago
Mingun fcddfbebdd Add `glob` dev dependency used in spec and benchmark servers 8 years ago
David Majda b2a9dabcff Remove now unused lib/utils/objects.js
See #442.
8 years ago
David Majda c344460855 Remove now unused lib/utils/arrays.js
See #442.
8 years ago
David Majda 5822596ab8 Replace classes.subclass with native classes
See #442.
8 years ago
David Majda 4a49e910ac package.json: Remove http-server
It is no longer used after introducing spec/server and benchmark/server.

See #442.
8 years ago
David Majda d239bf0107 package.json: Add packages that will be needed soon
Add "express" and "morgan" packages, which will be needed by
soon-to-be-introduced spec server and benchmark server.

See #442.
8 years ago
David Majda 4e38617748 Pass the browser version through Babel
This will allow to use ES2015 constructs in PEG.js code.

See #442.
8 years ago
David Majda 16f38f6380 Drop Node 0.10.x & 0.12.x support
See #442.
8 years ago
David Majda 671166bbe8 Update version to 0.10.0 8 years ago
David Majda 0478f8a6cf package.json: Sort files alphabetically 8 years ago
David Majda 5c0f0add95 Downgrade eslint to 2.13.1
It turns out ESLint 3.x works only with Node.js >= 4, which breaks Travis
CI builds:

  https://travis-ci.org/pegjs/pegjs/builds/149205616
8 years ago
David Majda 9446e07f6a Use uglify-js 2.7.0 8 years ago
David Majda a8d01e1834 Use eslint 3.2.0
Note the update required disabling the "no-control-regex" rule, which
started reporting following errors:

  /Users/dmajda/Programming/PEG.js/pegjs/lib/compiler/js.js
    22:16  error  Unexpected control character in regular expression  no-control-regex
    27:16  error  Unexpected control character in regular expression  no-control-regex
    28:16  error  Unexpected control character in regular expression  no-control-regex
    51:16  error  Unexpected control character in regular expression  no-control-regex
    52:16  error  Unexpected control character in regular expression  no-control-regex

  /Users/dmajda/Programming/PEG.js/pegjs/lib/parser.js
    76:16  error  Unexpected control character in regular expression  no-control-regex
    77:16  error  Unexpected control character in regular expression  no-control-regex
    90:16  error  Unexpected control character in regular expression  no-control-regex
    91:16  error  Unexpected control character in regular expression  no-control-regex
8 years ago
David Majda e6c3e7180f Use browserify 13.1.0 8 years ago
David Majda 67d85f2de8 Align names of compiler passes that detect infinite loops
Rename compiler passes as follows:

  reportLeftRecursion -> reportInfiniteRecursion
  reportInfiniteLoops -> reportInfiniteRepetition

This reflects the fact that both passes detect different ways of causing
the same problem (possible infinite loop when parsing).
8 years ago
David Majda 9717dc3417 Talk about "undefined rules" instead of "missing rules" internally
The new terminology is more precise and in line with commonly used
programming languages.

The change involves mainly renaming related compiler pass and files
associated with it.
8 years ago
David Majda eb67cbedb4 Report duplicate labels as errors
Resolves #270.
8 years ago
David Majda f9bc0fe619 package.json: Sort files alphabetically 8 years ago
David Majda eb5875bc6a Report duplicate rule definitions as errors
Based on a pull request by Futago-za Ryuu (@futagoza):

  https://github.com/pegjs/pegjs/pull/329

Resolves #318.
8 years ago
David Majda 930877c3ba Move lib/compiler.js to lib/compiler/index.js
This makes "compiler" a regular Node.js module.
8 years ago
David Majda c50ad15461 Use http-server to serve specs and benchmarks to the browser
Previously, the instructions recommended using Python's SimpleHTTPServer
module, which created unnecessary dependency on Python.
8 years ago
David Majda 768ece28e6 Use ESLint instead of JSHint
Implement the swap and change various directives in the source code. The
"make hint" target becomes "make lint".

The change leads to quite some errors being reported by ESLint. These
will be fixed in subsequent commits.

Note the configuration enables just the recommended rules. Later I plan
to enable more rules to enforce the coding standard. The configuration
also sets the environment to "node", which is far from ideal as the
codebase contains a mix of CommonJS, Node.js and browser code. I hope to
clean this up at some point.
8 years ago
David Majda 3a80933430 package.json: Update the "engine" field
* Use just 0.10 instead of 0.10.0 (it's shorter).

  * Remove space after >= (it is apparently conventionally not used in
    the npm world).
8 years ago
David Majda 3796cbfbad package.json: Reformat to formatting used by npm
This makes it possible to do e.g. "npm install --save" without a lot of
whitespace noise in the resulting diff.
8 years ago
Joseph Frazier 0d8c045823 Use browserify for building the browser version
This resolves https://github.com/pegjs/pegjs/issues/373 and,
since `browserify` produces a UMD bundle (due to `--standalone PEG`),
addresses the first part of https://github.com/pegjs/pegjs/issues/362,

> 1. Making PEG.js itself UMD module.

This also adds a MAIN_FILE variable to the Makefile, as specified by
7fe3aeb999 (commitcomment-13817973)
9 years ago
David Majda efb420479e Tweak package.json 9 years ago
David Majda 48fe4d6580 Rename generate-javascript.js to generate-js.js
Short & sweet.
9 years ago
David Majda 575883586f Rename javascript.js to js.js
Short & sweet.
9 years ago
David Majda 20a4fb2e7f Update version to 0.9.0 9 years ago
David Majda ae407572e6 Use jshint 2.8.0 9 years ago
David Majda 9cea4502f0 Use uglify-js 2.4.24 9 years ago
David Majda 698dba299a Use jasmine-node 1.14.5 9 years ago
David Majda 9eb62051be package.json: Add the "license" attribute
Based on a pull request by Peter deHaan (@pdehaan):

  https://github.com/pegjs/pegjs/pull/338
9 years ago
Arlo Breault c71f723b3f Run `make hint` before testing 9 years ago
David Majda d7fc0b5c3b Implement infinite loop detection
Fixes #26.
9 years ago
David Majda fb7de36051 Update website URL
PEG.js website was moved from http://pegjs.majda.cz/ to http://pegjs.org/.
9 years ago
David Majda 178d56699a Update GitHub project URLs
See https://groups.google.com/d/msg/pegjs/4a6zWKQSG6U/n8Pm257Lz6wJ.

I didn't update CHANGELOG.md as I consider issue URLs there historical artifacts
;-)
10 years ago
David Majda 4a3b9cbb8d Require Node.js >= 0.10.0
Travis CI builds with Node.js 0.8.x started to fail:

  https://travis-ci.org/dmajda/pegjs/jobs/26691570

Rather than investigating what's wrong I decided to stop supporting Node
0.8.x. Node.js 0.10.x is here for over a year, which should be enough
time for everyone to upgrade in the fast-paced Node.js world.
10 years ago
David Majda 5adad3ae12 Utility functions cleanup: Split lib/utils.js
Split lib/utils.js into multiple files. Some of the functions were
generic, these were moved into files in lib/utils. Other funtions were
specific for the compiler, these were moved to files in lib/compiler.

This commit only moves functions around -- there is no renaming and
cleanup performed. Both will come later.
10 years ago
David Majda 2263a30034 Update version to 0.8.0 10 years ago