diff --git a/.DS_Store b/.DS_Store
new file mode 100644
index 00000000..f699b4ec
Binary files /dev/null and b/.DS_Store differ
diff --git a/README.md b/README.md
index 71a9296d..ee68ea7f 100644
--- a/README.md
+++ b/README.md
@@ -1,112 +1,166 @@
-# CIS700 Procedural Graphics: Final Project
+# Voxel Run: Procedural Graphics Final Project
-Time to show off your new bag of procedural tricks by creating one polished final project. For this assignment you will have four weeks to create and document a portfolio piece that demonstrates your mastery of procedural thinking and implementation. You may work in groups of up to three (working alone is fine too). You may use any language / platform you choose for this assignment (given our approval if it’s not JavaScript/WebGL or C++/OpenGL).
+## Design Document:
-As usual with this class, we want to encourage you to take this opportunity to explore and experiment. To get you started, however, we’ve provided a few open-ended prompts below. Interesting and complex visuals are the goal in all of these prompts, but they encourage focus on different aspects of proceduralism.
+ - ### Introduction
+ * Always wanted to make a technically challenging and aesthetically pleasing puzzle game. Had this game idea written down, and has been sitting there for a solid year or so. Want to actually make this game happen.
-## Prompts:
+ - ### Goal
+ * Create a challenging, addictive, isometric puzzle game using simple geometry and gradient colors.
-- ### A classic 4k demo
- * In the spirit of the demo scene, create an animation that fits into a 4k executable that runs in real-time. Feel free to take inspiration from the many existing demos. Focus on efficiency and elegance in your implementation.
- * Examples: [cdak by Quite & orange](https://www.youtube.com/watch?v=RCh3Q08HMfs&list=PLA5E2FF8E143DA58C)
+ - ### Inspiration
+ * Monument Valley
-- ### A forgery
- * Taking inspiration from a particular natural phenomenon or distinctive set of visuals, implement a detailed, procedural recreation of that aesthetic. This includes modeling, texturing and object placement within your scene. Does not need to be real-time. Focus on detail and visual accuracy in your implementation.
- * Examples:
- - [Snail](https://www.shadertoy.com/view/ld3Gz2), [Journey](https://www.shadertoy.com/view/ldlcRf), Big Hero 6 Wormhole: [Image 1](http://2.bp.blogspot.com/-R-6AN2cWjwg/VTyIzIQSQfI/AAAAAAAABLA/GC0yzzz4wHw/s1600/big-hero-6-disneyscreencaps.com-10092.jpg) , [Image 2](https://i.stack.imgur.com/a9RGL.jpg)
+ 
+
+ * Euclidean Lands
-- ### A game level
- * Like generations of game makers before us, create a game which generates an navigable environment (eg. a roguelike dungeon, platforms) and some sort of goal or conflict (eg. enemy agents to avoid or items to collect). Must run in real-time. Aim to create an experience that will challenge players and vary noticeably in different playthroughs, whether that means complex dungeon generation, careful resource management or a sophisticated AI model. Focus on designing a system that will generate complex challenges and goals.
- * Examples: Spore, Dwarf Fortress, Minecraft, Rogue
+ 
-- ### An animated environment / music visualizer
- * Create an environment full of interactive procedural animation. The goal of this project is to create an environment that feels responsive and alive. Whether or not animations are musically-driven, sound should be an important component. Focus on user interactions, motion design and experimental interfaces.
- * Examples: [Panoramical](https://www.youtube.com/watch?v=gBTTMNFXHTk), [Bound](https://www.youtube.com/watch?v=aE37l6RvF-c)
-- ### Own proposal
- * You are of course **welcome to propose your own topic**. Regardless of what you choose, you and your team must research your topic and relevant techniques and come up with a detailed plan of execution. You will meet with some subset of the procedural staff before starting implementation for approval.
+ * Skyward
+
+ 
-**Final grading will be individual** and will be based on both the final product and how well you were able to achieve your intended effect according to your execution plan. Plans change of course, and we don’t expect you to follow your execution plan to a T, but if your final project looks pretty good, but you cut corners and only did 30% of what you outlined in your design doc, you will be penalized.
+ - ### Specification
+ * This procedurally-generated puzzle game has a simple objective: flip a cube from grid cell to grid cell until you reach the finish cell. Each grid cell can be one of six colors corresponding to the six distinct face colors of the cube. What makes this game challenging is that the current cell the cube is on must have the same color as the bottom face of the cube. Once the cube lands on a grid cell, the cell color turns grey and the player cannot go back. There will only be one path to the finish, so the player must plan his or her moves accordingly.
-But overall, have fun! This is your opportunity to work on whatever procedural project inspires you. The best way to ensure a good result is to pick something you’re passionate about. :)
+ - ### Techniques
+ * The main technical challenge is generating each level. I have to make sure that each level has only one solution, and the path from start to finish is not a simple and straightforward line. In order to check that each level has only one solution, the alternative and incorrect paths cannot cannot provide the cube a way to walk back on the correct path. In a sense, this is a graph theory problem, where each vertex is a grid cell, and each edge is a possible path from grid cell to grid cell. As long as there are no cycles, there can only be one solution. Generating a windy and complicated solution is another beast to handle. Currently considering a Perlin Worms algorithm to generate the solution to each level, but this is subject to change. As the levels progress, the grid size will become bigger, making the level much harder. However, my algorithm should be flexible enough to generate a reasonable path for each grid size.
-## Timeline
+ - ### Structure
+ * Player Class: Class containing the state of the player, including the six faces and the direction the cube is facing.
+ * Grid Class: Class containing the grid of grid cells, and a level generator to compute a reasonable puzzle for the player.
+ * Main Class: Puts Cube and Grid class together, orchestrating the interaction between the two classes.
-- 4/08 Design doc due / Have met with procedural staff
-- 4/18 Milestone 1 (short write-up + demo)
-- 4/25 Milestone 2 (short write-up + demo)
-- 5/3 Final presentations (3-5 pm, Siglab), final reports due
+ - ### Timeline
+ * April 18, 2017: Finish setting up the player and grid, be able to generate a path from start to finish, but do not have to fill in alternative paths yet.
+ * April 25, 2017: Finish level generator with only a single solution to each level. Alternative, incorrect paths should be misleading to make the game difficult.
+ * May 3, 2017: Polishing up the project. Fixing bugs, adding sound effects and animation, adjusting color pallette and aesthetics.
-## Design Doc
+## Milestones:
-Your design doc should follow the following template. Note, each section can be pretty short, but cover them all! This will serve as valuable documentation when showing this project off in the future AND doing a good job will make it much easier for you to succeed, so please take this seriously.
+ - ### Milestone 1
+ * Finished setting up the player and grid class, where the player is able to rotate the cube using the arrow keys. For the player class, ran into the same problem with the turtle class in L-Systems project, where rotating the turtle using rotation.x, rotation.y, rotation.z has some issues. Still have to fix this by using quaternions instead. For the grid class, used Depth First Search to generate the whole level, instead of generating one single path. This part is currently operating, but will add more complexity to the Depth First Search level generation to make it more interesting.
-### Design Doc Template:
+ - ### Milestone 2
+ * Fixed cube rotation by using quaternions instead of mesh.rotation. Found out that it is because there is a local rotation and world rotation for each THREE.Mesh that can be easily mixed up. Better to just use matricies in a scene graph style. Adjusted camera placement so that it is centered at the grid center, no matter what the dimensions of the grid is. Made multiple checks so that the cube can only flip if the color of the cube face that is going to face down matches the grid cell color. Added levels, where after crossing the finish cell, a new level appears with an increase in grid dimension. Realized that the plain Depth First Search level generation is too simple because on the edge of the grid, there is a 50 percent chance that it remains on the edge of the grid. Often the level generated has an easy path along the edge to the finish cell. Added a Gaussian Distribution Function to weigh the cells closer to the center more, so that the Depth First Search generator tends to go toward the center, making the level more complicated.
-- #### Introduction
- * What motivates this project?
-- #### Goal
- * What do you intend to achieve with this project?
-- #### Inspiration/reference:
- * Attach some materials, visual or otherwise you intend as reference
-- #### Specification:
- * Outline the main features of your project
-- #### Techniques:
- * What are the main technical/algorithmic tools you’ll be using? Give an overview, citing specific papers/articles
-- #### Design:
- * How will your program fit together? Make a simple free-body diagram illustrating the pieces.
-- #### Timeline:
- * Create a week-by-week set of milestones for each person in your group.
+ - ### Milestone 3
+ * Added a finish cell cube, or else a new player of the game doesn't know where the finish line is. Realized that the Depth First Search and Gaussian Distribution function level generator still does not work quite as expected. Now the level generator tends to go in a snake path, toward the center of the grid, then toward the edge, then toward the center again. Added a "throughput" that starts off as 1.0 and slowly decreases to 0.0 the more often the generator walks straight. This makes the paths generated more twisty and complicated. Added animation so that, to the player, it makes sense how the cube is flipping. Used a gain function to make the animation more realistic and lively. Added sound effects so that when the cube impacts on the ground, there is a "thump," and also added dream-like background music. Used raymarching so that the user no longer has to use arrow keys to move the cube. Instead, the user can use his or her mouse to select the grid cell to move to. Used cosine waves to procedurally generate the color for each level.
+ - ### Final Tweaks
+ * Changed the color of the raymarching grid cell selection depending if it is a movable grid cell or not. Realized that the game is too easy because the player can always move back if he makes a mistake, and there is no game over case. Made it so that once the user steps off a grid cell, the grid cell falls into an abyss. No more take-back-sies. If the user is stuck, he or she must take his or her own life by jumping into the abyss. Then it is game over. Added a start menu and game over screen so that there actually is a clear/definite start and end to the game. Made it so that not only does the grid dimension increase as the levels get harder, but also adjusted the throughput value so that the level generated paths are more twisty as the levels get harder. Changed the camera from orthographic to perspective in order to give depth to the grid cells falling.
-Along with your final project demo, you will submit a final report, in which you will update correct your original design doc as needed and add a few post-mortem items.
+## Final Report
-## Milestones
+ - ### Introduction
+ * I always wanted to make a technically challenging, yet aesthetically pleasing puzzle game. I had this particular game idea written down, and it had been sitting on my desk for a solid year or so. Took this procedural final project as an opportunity to make this game actually happen and come to life.
-To keep you honest / on-track, we will be checking on your progress at weekly intervals, according to milestones you’ll define at the outset (pending our approval). For each of the two milestones prior to the final submission, you will submit a short write up explaining whether or not you individually achieved your goals (specifying the files where the work happened), along with a link to a demo / images. These don’t have to be super polished -- we just want to see that you’re getting things done.
+ - ### Goal
+ * Create a challenging, addictive, isometric puzzle game using simple geometry and gradient colors.
-Example:
+ - ### Inspiration
+ * Monument Valley
-“Milestone 1:
- Adam:
-Made some procedural terrain code in src/terrain.js. Implemented 3D simplex noise to do it. Also applied coloring via custom shader based on this cool paper X (see src/shaders/dirt.glsl). IMAGE
+ 
+
+ * Euclidean Lands
-Austin:
-I managed to set up my voronoi diagram shader (see src/shaders/voronoi.glsl).
-Experimented with different scattering techniques. It’s working with the euclidean distance metric. I’m using it in src/main.js to color stones. IMAGE
+ 
-Rachel:
-I tried really hard to make my toon shader work (src/shaders/toon.glsl), but I still have a bug! T_T BUGGY IMAGE. DEMO LINK”
+ * Skyward
+
+ 
-## Final Report
+ - ### Specification
+ * This procedurally-generated puzzle game has a simple objective: flip a cube from grid cell to grid cell until you reach the finish cell. Each grid cell can be one of six colors corresponding to the six distinct face colors of the cube. What makes this game challenging is that the current grid cell the cube is on must have the same color as the bottom face of the cube. Once the cube lands on a grid cell, the previous grid cell falls into an abyss and the player cannot go back. The player must plan his or her moves accordingly. In essence, this game is a maze without walls.
+
+ - ### Techniques
+ * Level Generation:
+ * Started off with a Depth First Search level generation algorithm where a simulated cube walks on a random path until all its neighboring grid cells are visited. Then the cube takes a step back, and checks if there are any neighboring grid cells that are not visited. If so, the cube walks on a random path again. This repeats until the simulated cube reaches its starting position. An emergent behavior that came out of this algorithm was that very frequently, a generated path would continue along the edge of the grid. This is because on an edge of a grid, there are only two possible directions the simulated cube can move: along the edge again, or toward the center of the grid. Since I weighed both choices equally, a grid-edge path was very common. In order to fix this, I tried using a Gaussian Distribution Function to weigh the choices of the simulated cube unequally; the grid cells near the center of the grid will have higher probability of being chosen. I picked the variance based on the empirical rule of the normal distribution, where the grid dimensions span from (mean-2sigma) to (mean+2sigma).
+
+ 
+
+ 
+
+ * I ran into another problem with this modification of the Depth First Search level generation algorithm. Because I picked such a large variance, the probability of the center grid cells is significantly higher than the edge grid cells. This ended up causing my simulated cube to walk straight toward the center of the grid, then around the center of the grid until there are no more unvisited grid cells, then along the grid edges. Again, grid-edge paths became very common. I decided to pick a smaller variance and this fixed the problem.
+
+ * The next emergent behavior I noticed was that the paths generated were too straight. I applied what I learned in Advanced Computer Graphics of a throughput variable that starts off at 1.0 and decreases over time to 0.0. Now, every time the simulated cube walks in the same direction as the previous step, the throughput variable is decreased by a factor of 0.5 and then multipled to the probability of the upcoming same-direction grid cell choice. In other words, the more consecutive straightforward steps the simulated cube takes, the least likely the next step will be straightforwarc. I later realized that depending on the throughput factor, the paths can be more or less twisty. I decided to have a smaller throughput factor at the start of the game and slowly increase it in each proceeding level.
+
+ * My original worry of making sure the player cannot cross though "walls" between generated paths quickly disappeared after I realized that even though the player can cross through "walls," it is very unlikely for the player to continue along the crossed path because the cube must be in a certain orientation/rotation. What I mean by this is that the bottom face of the cube may match with the grid cell after crossing through a "wall," but there are 4 possible ways the cube can be orientated, and only one orientation can allow the player to continue to move along the crossed path. And even if the player can move along the crossed path, the crossed path does not necessairly lead to the finish cell. As a result, I chose to ignore this case because it actually benefits my game by adding an extra layer of complexity: 3 out of the 4 times crossinb through a "wall" will lead to a dead end due to the incorrect orientation of the cube.
+
+ * Color:
+ * Originally, I was hand-picking color gradients using IQ's idea of a color palette based on three cosine functions corresponding to R, G, and B. However, this limited the possibilities of color to a finite, hand-picked amount. I thought to myself, since R, G, and B are represented as cosine functions anyway, why not generate the color procedurally? I first decided what general color the procedurally generated gradients should be. Basing my decision on the computer graphics concept of a yellow key light (from sun), and a blue fill light (from sky), I wanted the grid colors to have a general red to yellow gradient since the background was nice shade of blue already. Playing around with the equations, I noticed that the R and G cosine functions should be similar, but not equivalent in phase to produce a yellow shade. The R and G cosine functions should have high amplitude so that there is a visible change in color gradient, or else the 6 face colors of the cube will be too similar in hue. The B cosine function should generally be close to 0.1 because when B is too high, it causes the red to turn purple and yellow to turn brown, and when B is 0, the shades of red and yellow do not seem realistic enough (there is no such thing as perfectly red/green with no blue in real life). I also made sure that the R, G, and B functions do not get exceed the 0 to 1 range given the y-displacement and amplitude because this will cause some section of the color gradient to receive a consistent contribution of R, G, or B, making the gradient sections less distinctive for the 6 face colors. Here is a visualization of how my procedural color gradient generator looks like:
+
+ 
+
+ * Animation:
+ * In order for the cube rotations to make sense in the eyes of the viewer, there should be animation. The cube shouldn't "jump" from grid cell to grid cell. Rather, there should be some smooth transition. I originally thought of LERPing the start and final positions of the cube flip, and SLURPing the start and final quaternion rotations of the cube flip. To my surprise, the cube center does not remain at the same height when flipped, thus LERPing the start and final positions (which are at the same y height) would not work.
+
+ 
+
+ * SLURPing the start and final quaternions works for rotation about the center of an object, but SLURPING at an axis of rotation that is not the cube center (but a cube edge) requires extra translation transformation. I decided to manually use a T*R*T matrix transformation every time onUpdate is called, where the R matrix is a SLURP of the two quaternions. After getting the animation to work, I felt as though something was missing. The cube did not have character. I decided to add a Toolbox Function I learned, the gain function, to distort the speed at which the cube rotates, given a certain t value between 0 and 1. The first GIF below is an animation of a cube WITHOUT the gain function applied, and the second GIF below is an animation of a cube WITH the gain function.
+
+ 
+
+ 
+
+ * Raymarching:
+ * Originally I thought that fixing the camera rotation to a specific angle and allowing the user to view the back faces of the cube by hovering over the cube with a mouse was a good idea. That way, the arrow keys can stay in the same orientation. My good ol' pal Adam suggested to use ray marching to select a grid cell to move the cube instead. Then the user can rotate the grid to his or her discretion, while viewing all sides of the cube. That was a great idea. Thanks Adam! In the onUpdate function, I raymarch a ray originating at the mouse with a direction of the camera forward vector to find the closest intersected object. If the intersected object is a grid cell, then I highlight the top face light gray or dark gray, depending on if it is a valid move or not.
+
+ 
+
+ - ### Structure
+ * Player Class: Class containing the state of the player, including the six faces and the direction the cube is facing.
+ * Grid Class: Class containing the grid of grid cells, and a level generator to compute a reasonable puzzle for the player.
+ * Main Class: Puts Cube and Grid class together, orchestrating the interaction between the two classes. Also handles the logic for the game.
+
+ - ### Timeline
+ * April 18, 2017: Finish setting up the player and grid, be able to generate a path from start to finish, but do not have to fill in alternative paths yet.
+ * April 25, 2017: Finish level generator with only a single solution to each level. Alternative, incorrect paths should be misleading to make the game difficult.
+ * May 3, 2017: Polishing up the project. Fixing bugs, adding sound effects and animation, adjusting color pallette and aesthetics.
+
+ - ### Results:
+
+ 
+
+ 
+
+ 
+
+ - ### Evaluation:
+ * Overall, I feel like I have come a long way. I started this project thinking it will be almost impossible to generate the types of levels I imagined, but I took clever approaches and applied a lot of what I learned to solve difficult situations, such as keeping track of which face color is facing which direction in the world without the need of a rotation matrix but only 6 variables, fixing the unwanted emergent behavior of the Depth First Search level generator, and applying color and toolbox functions to make the game more aesthetically pleasing.
+
+ There were many tweaks that had to be made throughout the process. I changed the camera from orthographic to perspective in order to give depth to the falling grid cells, added a finish cube or else a new player doesn't know where the finish line is, used raymarching so that the user no longer has to use arrow keys to move the cube, used cosine waves to procedurally generate the color for each level, and changed the color of the raymarching grid cell selection depending if it is a movable grid cell or not. I also realized that the game is too easy because the player can always move back if he makes a mistake, and there is no game over case. I then made it so that once the user steps off a grid cell, the grid cell falls into an abyss. No more take-back-sies. If the user is stuck, he or she must take his or her own life by jumping into the abyss. Then it is game over. I also added a start menu and game over screen so that there actually is a clear/definite start and end to the game. Lastly, I modified the game design so that not only does the grid dimension increase as the levels get harder, but throughput factor decreases so that the level generated paths are more twisty as the levels get harder.
+
+ 
-In addition to your demo, you will create a final report documenting your project overall. This document should be clear enough to explain the value and details of your project to a random computer graphics person with no knowledge of this class.
+ 
-### Final Report Template:
+ - ### Future work:
+ * Given more time, I would add more complexity to the game, such as not only making the level a 2D grid. Instead, the cube can walk on walls and ceilings, as long as the cube face colors are matching both surfaces at the corner of the wall. In addition, I would want to add a way for users to keep track of their thought process, such as being able to add "flags" on the grid surface, similar to Minesweeper. This would keep the interest of the players rather than having them give up when the grid dimension becomes too big.
-- #### Updated design doc:
- * All the sections of your original design doc, corrected if necessary
-- #### Results:
- * Provide images of your finished project
-- #### Evaluation (this is a big one!):
- * How well did you do? What parameters did you tune along the way? Include some WIP shots that compare intermediate results to your final. Explain why you made the decisions you did.
-- #### Future work:
- * Given more time, what would you add/improve
-- #### Acknowledgements:
- * Cite _EVERYTHING_. Implemented a paper? Used some royalty-free music? Talked to classmates / a professor in a way that influenced your project? Attribute everything!
+ - ### Acknowledgements:
+ * Special thanks to Rachel Hwang, Adam Mally, Sally Kong, Trung Le, and Austin Eng for being so supportive throughout the semester, and especially throughout this project!
-## Logistics
+ * Gaussian Distribution
+ * https://en.wikipedia.org/wiki/Gaussian_function#Two-dimensional_Gaussian_function
+ * https://en.wikipedia.org/wiki/Normal_distribution#/media/File:Empirical_Rule.PNG
-Like every prior project, your code will be submitted via github. Fork the empty final project repo and start your code base from there. Take this as an opportunity to practice using git properly in a team setting if you’re a new user. For each weekly submission, provide a link to your pull request. Your repo will contain all the code and documentation associated with your project. The readme for your repo will eventually be your final report. At the top level, include a folder called “documentation”, where you’ll put your design doc and milestone write-ups.
+ * Colors
+ * http://www.iquilezles.org/www/articles/palettes/palettes.htm
+ * http://dev.thi.ng/gradients/
-Don’t wait to merge your code! Seriously, there be dragons. Try to have a working version including all your code so that compatibility and merge issues don’t sneak up on you near the end.
+ * Raymarching
+ * https://stemkoski.github.io/Three.js/Mouse-Over.html
+ * https://github.com/mrdoob/three.js/issues/5587
+ * http://stackoverflow.com/questions/20361776/orthographic-camera-and-pickingray
-## Grading
+ * Mouse Detection
+ * https://threejs.org/examples/?q=out#webgl_postprocessing_outline
-- 15% Design Doc (graded as a group)
-- 15% Milestone 1 (graded as a group)
-- 15% Milestone 2 (graded as a group)
-- 55% Final demo + report (graded individually)
+ * Camera Orbit Controls
+ * https://searchcode.com/codesearch/view/58375664/
-NOTE: We’ve been pretty lax about our late policy throughout the semester, but our margins on the final project are tight, therefore late submissions will NOT be accepted. If you have a significant reason for being unable to complete your goals, talk to us, and we’ll discuss getting you an incomplete and figure out an adjusted work plan with your group.
diff --git a/deploy.js b/deploy.js
new file mode 100644
index 00000000..9defe7c3
--- /dev/null
+++ b/deploy.js
@@ -0,0 +1,38 @@
+var colors = require('colors');
+var path = require('path');
+var git = require('simple-git')(__dirname);
+var deploy = require('gh-pages-deploy');
+var packageJSON = require('require-module')('./package.json');
+
+var success = 1;
+git.fetch('origin', 'master', function(err) {
+ if (err) throw err;
+ git.status(function(err, status) {
+ if (err) throw err;
+ if (!status.isClean()) {
+ success = 0;
+ console.error('Error: You have uncommitted changes! Please commit them first'.red);
+ }
+
+ if (status.current !== 'master') {
+ success = 0;
+ console.warn('Warning: Please deploy from the master branch!'.yellow)
+ }
+
+ git.diffSummary(['origin/master'], function(err, diff) {
+ if (err) throw err;
+
+ if (diff.files.length || diff.insertions || diff.deletions) {
+ success = 0;
+ console.error('Error: Current branch is different from origin/master! Please push all changes first'.red)
+ }
+
+ if (success) {
+ var cfg = packageJSON['gh-pages-deploy'] || {};
+ var buildCmd = deploy.getFullCmd(cfg);
+ deploy.displayCmds(deploy.getFullCmd(cfg));
+ deploy.execBuild(buildCmd, cfg);
+ }
+ })
+ })
+})
\ No newline at end of file
diff --git a/images/.DS_Store b/images/.DS_Store
new file mode 100644
index 00000000..5008ddfc
Binary files /dev/null and b/images/.DS_Store differ
diff --git a/images/WIP1.png b/images/WIP1.png
new file mode 100644
index 00000000..820c439b
Binary files /dev/null and b/images/WIP1.png differ
diff --git a/images/WIP2.png b/images/WIP2.png
new file mode 100644
index 00000000..bc7c895f
Binary files /dev/null and b/images/WIP2.png differ
diff --git a/images/gameover.png b/images/gameover.png
new file mode 100644
index 00000000..9516271d
Binary files /dev/null and b/images/gameover.png differ
diff --git a/images/menu.png b/images/menu.png
new file mode 100644
index 00000000..6b0e6409
Binary files /dev/null and b/images/menu.png differ
diff --git a/images/raymarch.gif b/images/raymarch.gif
new file mode 100644
index 00000000..7867e971
Binary files /dev/null and b/images/raymarch.gif differ
diff --git a/images/ref1.jpg b/images/ref1.jpg
new file mode 100644
index 00000000..e416e5ca
Binary files /dev/null and b/images/ref1.jpg differ
diff --git a/images/ref2.jpg b/images/ref2.jpg
new file mode 100644
index 00000000..85f738fc
Binary files /dev/null and b/images/ref2.jpg differ
diff --git a/images/ref3.jpg b/images/ref3.jpg
new file mode 100644
index 00000000..efba3f46
Binary files /dev/null and b/images/ref3.jpg differ
diff --git a/images/ref4.png b/images/ref4.png
new file mode 100644
index 00000000..b91719d5
Binary files /dev/null and b/images/ref4.png differ
diff --git a/images/ref5.png b/images/ref5.png
new file mode 100644
index 00000000..c100b55f
Binary files /dev/null and b/images/ref5.png differ
diff --git a/images/ref6.png b/images/ref6.png
new file mode 100644
index 00000000..300ddc8c
Binary files /dev/null and b/images/ref6.png differ
diff --git a/images/ref7.png b/images/ref7.png
new file mode 100644
index 00000000..d5912173
Binary files /dev/null and b/images/ref7.png differ
diff --git a/images/ref8.gif b/images/ref8.gif
new file mode 100644
index 00000000..6960ec61
Binary files /dev/null and b/images/ref8.gif differ
diff --git a/images/ref9.gif b/images/ref9.gif
new file mode 100644
index 00000000..dc12a420
Binary files /dev/null and b/images/ref9.gif differ
diff --git a/images/result1.png b/images/result1.png
new file mode 100644
index 00000000..652acf95
Binary files /dev/null and b/images/result1.png differ
diff --git a/images/result2.png b/images/result2.png
new file mode 100644
index 00000000..8e7e46c5
Binary files /dev/null and b/images/result2.png differ
diff --git a/images/result3.png b/images/result3.png
new file mode 100644
index 00000000..25a47e7d
Binary files /dev/null and b/images/result3.png differ
diff --git a/index.html b/index.html
new file mode 100644
index 00000000..07b8e2b7
--- /dev/null
+++ b/index.html
@@ -0,0 +1,25 @@
+
+
+
+ Voxel Run
+
+
+
+
+
+
diff --git a/node_modules/.bin/acorn b/node_modules/.bin/acorn
new file mode 120000
index 00000000..cf767603
--- /dev/null
+++ b/node_modules/.bin/acorn
@@ -0,0 +1 @@
+../acorn/bin/acorn
\ No newline at end of file
diff --git a/node_modules/.bin/babylon b/node_modules/.bin/babylon
new file mode 120000
index 00000000..c2adc01b
--- /dev/null
+++ b/node_modules/.bin/babylon
@@ -0,0 +1 @@
+../babylon/bin/babylon.js
\ No newline at end of file
diff --git a/node_modules/.bin/errno b/node_modules/.bin/errno
new file mode 120000
index 00000000..5a98e539
--- /dev/null
+++ b/node_modules/.bin/errno
@@ -0,0 +1 @@
+../errno/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/gasket b/node_modules/.bin/gasket
new file mode 120000
index 00000000..e9a96b9d
--- /dev/null
+++ b/node_modules/.bin/gasket
@@ -0,0 +1 @@
+../gasket/bin.js
\ No newline at end of file
diff --git a/node_modules/.bin/gh-pages-deploy b/node_modules/.bin/gh-pages-deploy
new file mode 120000
index 00000000..c7f6f8f5
--- /dev/null
+++ b/node_modules/.bin/gh-pages-deploy
@@ -0,0 +1 @@
+../gh-pages-deploy/bin/gh-pages-deploy
\ No newline at end of file
diff --git a/node_modules/.bin/jsesc b/node_modules/.bin/jsesc
new file mode 120000
index 00000000..7237604c
--- /dev/null
+++ b/node_modules/.bin/jsesc
@@ -0,0 +1 @@
+../jsesc/bin/jsesc
\ No newline at end of file
diff --git a/node_modules/.bin/json5 b/node_modules/.bin/json5
new file mode 120000
index 00000000..217f3798
--- /dev/null
+++ b/node_modules/.bin/json5
@@ -0,0 +1 @@
+../json5/lib/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/loose-envify b/node_modules/.bin/loose-envify
new file mode 120000
index 00000000..ed9009c5
--- /dev/null
+++ b/node_modules/.bin/loose-envify
@@ -0,0 +1 @@
+../loose-envify/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/mime b/node_modules/.bin/mime
new file mode 120000
index 00000000..fbb7ee0e
--- /dev/null
+++ b/node_modules/.bin/mime
@@ -0,0 +1 @@
+../mime/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/mkdirp b/node_modules/.bin/mkdirp
new file mode 120000
index 00000000..017896ce
--- /dev/null
+++ b/node_modules/.bin/mkdirp
@@ -0,0 +1 @@
+../mkdirp/bin/cmd.js
\ No newline at end of file
diff --git a/node_modules/.bin/ncp b/node_modules/.bin/ncp
new file mode 120000
index 00000000..1c026480
--- /dev/null
+++ b/node_modules/.bin/ncp
@@ -0,0 +1 @@
+../ncp/bin/ncp
\ No newline at end of file
diff --git a/node_modules/.bin/ndjson b/node_modules/.bin/ndjson
new file mode 120000
index 00000000..88b0e189
--- /dev/null
+++ b/node_modules/.bin/ndjson
@@ -0,0 +1 @@
+../ndjson/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/npm-execspawn b/node_modules/.bin/npm-execspawn
new file mode 120000
index 00000000..1198974f
--- /dev/null
+++ b/node_modules/.bin/npm-execspawn
@@ -0,0 +1 @@
+../npm-execspawn/bin.js
\ No newline at end of file
diff --git a/node_modules/.bin/regjsparser b/node_modules/.bin/regjsparser
new file mode 120000
index 00000000..91cec777
--- /dev/null
+++ b/node_modules/.bin/regjsparser
@@ -0,0 +1 @@
+../regjsparser/bin/parser
\ No newline at end of file
diff --git a/node_modules/.bin/rimraf b/node_modules/.bin/rimraf
new file mode 120000
index 00000000..4cd49a49
--- /dev/null
+++ b/node_modules/.bin/rimraf
@@ -0,0 +1 @@
+../rimraf/bin.js
\ No newline at end of file
diff --git a/node_modules/.bin/sha.js b/node_modules/.bin/sha.js
new file mode 120000
index 00000000..3c761051
--- /dev/null
+++ b/node_modules/.bin/sha.js
@@ -0,0 +1 @@
+../sha.js/bin.js
\ No newline at end of file
diff --git a/node_modules/.bin/uglifyjs b/node_modules/.bin/uglifyjs
new file mode 120000
index 00000000..fef3468b
--- /dev/null
+++ b/node_modules/.bin/uglifyjs
@@ -0,0 +1 @@
+../uglify-js/bin/uglifyjs
\ No newline at end of file
diff --git a/node_modules/.bin/webpack b/node_modules/.bin/webpack
new file mode 120000
index 00000000..d462c1d1
--- /dev/null
+++ b/node_modules/.bin/webpack
@@ -0,0 +1 @@
+../webpack/bin/webpack.js
\ No newline at end of file
diff --git a/node_modules/.bin/webpack-dev-server b/node_modules/.bin/webpack-dev-server
new file mode 120000
index 00000000..242fe0a6
--- /dev/null
+++ b/node_modules/.bin/webpack-dev-server
@@ -0,0 +1 @@
+../webpack-dev-server/bin/webpack-dev-server.js
\ No newline at end of file
diff --git a/node_modules/accepts/HISTORY.md b/node_modules/accepts/HISTORY.md
new file mode 100644
index 00000000..0477ed71
--- /dev/null
+++ b/node_modules/accepts/HISTORY.md
@@ -0,0 +1,212 @@
+1.3.3 / 2016-05-02
+==================
+
+ * deps: mime-types@~2.1.11
+ - deps: mime-db@~1.23.0
+ * deps: negotiator@0.6.1
+ - perf: improve `Accept` parsing speed
+ - perf: improve `Accept-Charset` parsing speed
+ - perf: improve `Accept-Encoding` parsing speed
+ - perf: improve `Accept-Language` parsing speed
+
+1.3.2 / 2016-03-08
+==================
+
+ * deps: mime-types@~2.1.10
+ - Fix extension of `application/dash+xml`
+ - Update primary extension for `audio/mp4`
+ - deps: mime-db@~1.22.0
+
+1.3.1 / 2016-01-19
+==================
+
+ * deps: mime-types@~2.1.9
+ - deps: mime-db@~1.21.0
+
+1.3.0 / 2015-09-29
+==================
+
+ * deps: mime-types@~2.1.7
+ - deps: mime-db@~1.19.0
+ * deps: negotiator@0.6.0
+ - Fix including type extensions in parameters in `Accept` parsing
+ - Fix parsing `Accept` parameters with quoted equals
+ - Fix parsing `Accept` parameters with quoted semicolons
+ - Lazy-load modules from main entry point
+ - perf: delay type concatenation until needed
+ - perf: enable strict mode
+ - perf: hoist regular expressions
+ - perf: remove closures getting spec properties
+ - perf: remove a closure from media type parsing
+ - perf: remove property delete from media type parsing
+
+1.2.13 / 2015-09-06
+===================
+
+ * deps: mime-types@~2.1.6
+ - deps: mime-db@~1.18.0
+
+1.2.12 / 2015-07-30
+===================
+
+ * deps: mime-types@~2.1.4
+ - deps: mime-db@~1.16.0
+
+1.2.11 / 2015-07-16
+===================
+
+ * deps: mime-types@~2.1.3
+ - deps: mime-db@~1.15.0
+
+1.2.10 / 2015-07-01
+===================
+
+ * deps: mime-types@~2.1.2
+ - deps: mime-db@~1.14.0
+
+1.2.9 / 2015-06-08
+==================
+
+ * deps: mime-types@~2.1.1
+ - perf: fix deopt during mapping
+
+1.2.8 / 2015-06-07
+==================
+
+ * deps: mime-types@~2.1.0
+ - deps: mime-db@~1.13.0
+ * perf: avoid argument reassignment & argument slice
+ * perf: avoid negotiator recursive construction
+ * perf: enable strict mode
+ * perf: remove unnecessary bitwise operator
+
+1.2.7 / 2015-05-10
+==================
+
+ * deps: negotiator@0.5.3
+ - Fix media type parameter matching to be case-insensitive
+
+1.2.6 / 2015-05-07
+==================
+
+ * deps: mime-types@~2.0.11
+ - deps: mime-db@~1.9.1
+ * deps: negotiator@0.5.2
+ - Fix comparing media types with quoted values
+ - Fix splitting media types with quoted commas
+
+1.2.5 / 2015-03-13
+==================
+
+ * deps: mime-types@~2.0.10
+ - deps: mime-db@~1.8.0
+
+1.2.4 / 2015-02-14
+==================
+
+ * Support Node.js 0.6
+ * deps: mime-types@~2.0.9
+ - deps: mime-db@~1.7.0
+ * deps: negotiator@0.5.1
+ - Fix preference sorting to be stable for long acceptable lists
+
+1.2.3 / 2015-01-31
+==================
+
+ * deps: mime-types@~2.0.8
+ - deps: mime-db@~1.6.0
+
+1.2.2 / 2014-12-30
+==================
+
+ * deps: mime-types@~2.0.7
+ - deps: mime-db@~1.5.0
+
+1.2.1 / 2014-12-30
+==================
+
+ * deps: mime-types@~2.0.5
+ - deps: mime-db@~1.3.1
+
+1.2.0 / 2014-12-19
+==================
+
+ * deps: negotiator@0.5.0
+ - Fix list return order when large accepted list
+ - Fix missing identity encoding when q=0 exists
+ - Remove dynamic building of Negotiator class
+
+1.1.4 / 2014-12-10
+==================
+
+ * deps: mime-types@~2.0.4
+ - deps: mime-db@~1.3.0
+
+1.1.3 / 2014-11-09
+==================
+
+ * deps: mime-types@~2.0.3
+ - deps: mime-db@~1.2.0
+
+1.1.2 / 2014-10-14
+==================
+
+ * deps: negotiator@0.4.9
+ - Fix error when media type has invalid parameter
+
+1.1.1 / 2014-09-28
+==================
+
+ * deps: mime-types@~2.0.2
+ - deps: mime-db@~1.1.0
+ * deps: negotiator@0.4.8
+ - Fix all negotiations to be case-insensitive
+ - Stable sort preferences of same quality according to client order
+
+1.1.0 / 2014-09-02
+==================
+
+ * update `mime-types`
+
+1.0.7 / 2014-07-04
+==================
+
+ * Fix wrong type returned from `type` when match after unknown extension
+
+1.0.6 / 2014-06-24
+==================
+
+ * deps: negotiator@0.4.7
+
+1.0.5 / 2014-06-20
+==================
+
+ * fix crash when unknown extension given
+
+1.0.4 / 2014-06-19
+==================
+
+ * use `mime-types`
+
+1.0.3 / 2014-06-11
+==================
+
+ * deps: negotiator@0.4.6
+ - Order by specificity when quality is the same
+
+1.0.2 / 2014-05-29
+==================
+
+ * Fix interpretation when header not in request
+ * deps: pin negotiator@0.4.5
+
+1.0.1 / 2014-01-18
+==================
+
+ * Identity encoding isn't always acceptable
+ * deps: negotiator@~0.4.0
+
+1.0.0 / 2013-12-27
+==================
+
+ * Genesis
diff --git a/node_modules/accepts/LICENSE b/node_modules/accepts/LICENSE
new file mode 100644
index 00000000..06166077
--- /dev/null
+++ b/node_modules/accepts/LICENSE
@@ -0,0 +1,23 @@
+(The MIT License)
+
+Copyright (c) 2014 Jonathan Ong
+Copyright (c) 2015 Douglas Christopher Wilson
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/accepts/README.md b/node_modules/accepts/README.md
new file mode 100644
index 00000000..ae36676f
--- /dev/null
+++ b/node_modules/accepts/README.md
@@ -0,0 +1,135 @@
+# accepts
+
+[![NPM Version][npm-image]][npm-url]
+[![NPM Downloads][downloads-image]][downloads-url]
+[![Node.js Version][node-version-image]][node-version-url]
+[![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
+
+Higher level content negotiation based on [negotiator](https://www.npmjs.com/package/negotiator). Extracted from [koa](https://www.npmjs.com/package/koa) for general use.
+
+In addition to negotiator, it allows:
+
+- Allows types as an array or arguments list, ie `(['text/html', 'application/json'])` as well as `('text/html', 'application/json')`.
+- Allows type shorthands such as `json`.
+- Returns `false` when no types match
+- Treats non-existent headers as `*`
+
+## Installation
+
+```sh
+npm install accepts
+```
+
+## API
+
+```js
+var accepts = require('accepts')
+```
+
+### accepts(req)
+
+Create a new `Accepts` object for the given `req`.
+
+#### .charset(charsets)
+
+Return the first accepted charset. If nothing in `charsets` is accepted,
+then `false` is returned.
+
+#### .charsets()
+
+Return the charsets that the request accepts, in the order of the client's
+preference (most preferred first).
+
+#### .encoding(encodings)
+
+Return the first accepted encoding. If nothing in `encodings` is accepted,
+then `false` is returned.
+
+#### .encodings()
+
+Return the encodings that the request accepts, in the order of the client's
+preference (most preferred first).
+
+#### .language(languages)
+
+Return the first accepted language. If nothing in `languages` is accepted,
+then `false` is returned.
+
+#### .languages()
+
+Return the languages that the request accepts, in the order of the client's
+preference (most preferred first).
+
+#### .type(types)
+
+Return the first accepted type (and it is returned as the same text as what
+appears in the `types` array). If nothing in `types` is accepted, then `false`
+is returned.
+
+The `types` array can contain full MIME types or file extensions. Any value
+that is not a full MIME types is passed to `require('mime-types').lookup`.
+
+#### .types()
+
+Return the types that the request accepts, in the order of the client's
+preference (most preferred first).
+
+## Examples
+
+### Simple type negotiation
+
+This simple example shows how to use `accepts` to return a different typed
+respond body based on what the client wants to accept. The server lists it's
+preferences in order and will get back the best match between the client and
+server.
+
+```js
+var accepts = require('accepts')
+var http = require('http')
+
+function app(req, res) {
+ var accept = accepts(req)
+
+ // the order of this list is significant; should be server preferred order
+ switch(accept.type(['json', 'html'])) {
+ case 'json':
+ res.setHeader('Content-Type', 'application/json')
+ res.write('{"hello":"world!"}')
+ break
+ case 'html':
+ res.setHeader('Content-Type', 'text/html')
+ res.write('hello, world! ')
+ break
+ default:
+ // the fallback is text/plain, so no need to specify it above
+ res.setHeader('Content-Type', 'text/plain')
+ res.write('hello, world!')
+ break
+ }
+
+ res.end()
+}
+
+http.createServer(app).listen(3000)
+```
+
+You can test this out with the cURL program:
+```sh
+curl -I -H'Accept: text/html' http://localhost:3000/
+```
+
+## License
+
+[MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/accepts.svg
+[npm-url]: https://npmjs.org/package/accepts
+[node-version-image]: https://img.shields.io/node/v/accepts.svg
+[node-version-url]: http://nodejs.org/download/
+[travis-image]: https://img.shields.io/travis/jshttp/accepts/master.svg
+[travis-url]: https://travis-ci.org/jshttp/accepts
+[coveralls-image]: https://img.shields.io/coveralls/jshttp/accepts/master.svg
+[coveralls-url]: https://coveralls.io/r/jshttp/accepts
+[downloads-image]: https://img.shields.io/npm/dm/accepts.svg
+[downloads-url]: https://npmjs.org/package/accepts
diff --git a/node_modules/accepts/index.js b/node_modules/accepts/index.js
new file mode 100644
index 00000000..e80192ab
--- /dev/null
+++ b/node_modules/accepts/index.js
@@ -0,0 +1,231 @@
+/*!
+ * accepts
+ * Copyright(c) 2014 Jonathan Ong
+ * Copyright(c) 2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict'
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var Negotiator = require('negotiator')
+var mime = require('mime-types')
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = Accepts
+
+/**
+ * Create a new Accepts object for the given req.
+ *
+ * @param {object} req
+ * @public
+ */
+
+function Accepts(req) {
+ if (!(this instanceof Accepts))
+ return new Accepts(req)
+
+ this.headers = req.headers
+ this.negotiator = new Negotiator(req)
+}
+
+/**
+ * Check if the given `type(s)` is acceptable, returning
+ * the best match when true, otherwise `undefined`, in which
+ * case you should respond with 406 "Not Acceptable".
+ *
+ * The `type` value may be a single mime type string
+ * such as "application/json", the extension name
+ * such as "json" or an array `["json", "html", "text/plain"]`. When a list
+ * or array is given the _best_ match, if any is returned.
+ *
+ * Examples:
+ *
+ * // Accept: text/html
+ * this.types('html');
+ * // => "html"
+ *
+ * // Accept: text/*, application/json
+ * this.types('html');
+ * // => "html"
+ * this.types('text/html');
+ * // => "text/html"
+ * this.types('json', 'text');
+ * // => "json"
+ * this.types('application/json');
+ * // => "application/json"
+ *
+ * // Accept: text/*, application/json
+ * this.types('image/png');
+ * this.types('png');
+ * // => undefined
+ *
+ * // Accept: text/*;q=.5, application/json
+ * this.types(['html', 'json']);
+ * this.types('html', 'json');
+ * // => "json"
+ *
+ * @param {String|Array} types...
+ * @return {String|Array|Boolean}
+ * @public
+ */
+
+Accepts.prototype.type =
+Accepts.prototype.types = function (types_) {
+ var types = types_
+
+ // support flattened arguments
+ if (types && !Array.isArray(types)) {
+ types = new Array(arguments.length)
+ for (var i = 0; i < types.length; i++) {
+ types[i] = arguments[i]
+ }
+ }
+
+ // no types, return all requested types
+ if (!types || types.length === 0) {
+ return this.negotiator.mediaTypes()
+ }
+
+ if (!this.headers.accept) return types[0];
+ var mimes = types.map(extToMime);
+ var accepts = this.negotiator.mediaTypes(mimes.filter(validMime));
+ var first = accepts[0];
+ if (!first) return false;
+ return types[mimes.indexOf(first)];
+}
+
+/**
+ * Return accepted encodings or best fit based on `encodings`.
+ *
+ * Given `Accept-Encoding: gzip, deflate`
+ * an array sorted by quality is returned:
+ *
+ * ['gzip', 'deflate']
+ *
+ * @param {String|Array} encodings...
+ * @return {String|Array}
+ * @public
+ */
+
+Accepts.prototype.encoding =
+Accepts.prototype.encodings = function (encodings_) {
+ var encodings = encodings_
+
+ // support flattened arguments
+ if (encodings && !Array.isArray(encodings)) {
+ encodings = new Array(arguments.length)
+ for (var i = 0; i < encodings.length; i++) {
+ encodings[i] = arguments[i]
+ }
+ }
+
+ // no encodings, return all requested encodings
+ if (!encodings || encodings.length === 0) {
+ return this.negotiator.encodings()
+ }
+
+ return this.negotiator.encodings(encodings)[0] || false
+}
+
+/**
+ * Return accepted charsets or best fit based on `charsets`.
+ *
+ * Given `Accept-Charset: utf-8, iso-8859-1;q=0.2, utf-7;q=0.5`
+ * an array sorted by quality is returned:
+ *
+ * ['utf-8', 'utf-7', 'iso-8859-1']
+ *
+ * @param {String|Array} charsets...
+ * @return {String|Array}
+ * @public
+ */
+
+Accepts.prototype.charset =
+Accepts.prototype.charsets = function (charsets_) {
+ var charsets = charsets_
+
+ // support flattened arguments
+ if (charsets && !Array.isArray(charsets)) {
+ charsets = new Array(arguments.length)
+ for (var i = 0; i < charsets.length; i++) {
+ charsets[i] = arguments[i]
+ }
+ }
+
+ // no charsets, return all requested charsets
+ if (!charsets || charsets.length === 0) {
+ return this.negotiator.charsets()
+ }
+
+ return this.negotiator.charsets(charsets)[0] || false
+}
+
+/**
+ * Return accepted languages or best fit based on `langs`.
+ *
+ * Given `Accept-Language: en;q=0.8, es, pt`
+ * an array sorted by quality is returned:
+ *
+ * ['es', 'pt', 'en']
+ *
+ * @param {String|Array} langs...
+ * @return {Array|String}
+ * @public
+ */
+
+Accepts.prototype.lang =
+Accepts.prototype.langs =
+Accepts.prototype.language =
+Accepts.prototype.languages = function (languages_) {
+ var languages = languages_
+
+ // support flattened arguments
+ if (languages && !Array.isArray(languages)) {
+ languages = new Array(arguments.length)
+ for (var i = 0; i < languages.length; i++) {
+ languages[i] = arguments[i]
+ }
+ }
+
+ // no languages, return all requested languages
+ if (!languages || languages.length === 0) {
+ return this.negotiator.languages()
+ }
+
+ return this.negotiator.languages(languages)[0] || false
+}
+
+/**
+ * Convert extnames to mime.
+ *
+ * @param {String} type
+ * @return {String}
+ * @private
+ */
+
+function extToMime(type) {
+ return type.indexOf('/') === -1
+ ? mime.lookup(type)
+ : type
+}
+
+/**
+ * Check if mime is valid.
+ *
+ * @param {String} type
+ * @return {String}
+ * @private
+ */
+
+function validMime(type) {
+ return typeof type === 'string';
+}
diff --git a/node_modules/accepts/package.json b/node_modules/accepts/package.json
new file mode 100644
index 00000000..b634d580
--- /dev/null
+++ b/node_modules/accepts/package.json
@@ -0,0 +1,114 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "accepts@~1.3.3",
+ "scope": null,
+ "escapedName": "accepts",
+ "name": "accepts",
+ "rawSpec": "~1.3.3",
+ "spec": ">=1.3.3 <1.4.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/compression"
+ ]
+ ],
+ "_from": "accepts@>=1.3.3 <1.4.0",
+ "_id": "accepts@1.3.3",
+ "_inCache": true,
+ "_location": "/accepts",
+ "_nodeVersion": "4.4.3",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/accepts-1.3.3.tgz_1462251932032_0.7092335098423064"
+ },
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "2.15.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "accepts@~1.3.3",
+ "scope": null,
+ "escapedName": "accepts",
+ "name": "accepts",
+ "rawSpec": "~1.3.3",
+ "spec": ">=1.3.3 <1.4.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/compression",
+ "/express",
+ "/serve-index"
+ ],
+ "_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.3.tgz",
+ "_shasum": "c3ca7434938648c3e0d9c1e328dd68b622c284ca",
+ "_shrinkwrap": null,
+ "_spec": "accepts@~1.3.3",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/compression",
+ "bugs": {
+ "url": "https://github.com/jshttp/accepts/issues"
+ },
+ "contributors": [
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ },
+ {
+ "name": "Jonathan Ong",
+ "email": "me@jongleberry.com",
+ "url": "http://jongleberry.com"
+ }
+ ],
+ "dependencies": {
+ "mime-types": "~2.1.11",
+ "negotiator": "0.6.1"
+ },
+ "description": "Higher-level content negotiation",
+ "devDependencies": {
+ "istanbul": "0.4.3",
+ "mocha": "~1.21.5"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "c3ca7434938648c3e0d9c1e328dd68b622c284ca",
+ "tarball": "https://registry.npmjs.org/accepts/-/accepts-1.3.3.tgz"
+ },
+ "engines": {
+ "node": ">= 0.6"
+ },
+ "files": [
+ "LICENSE",
+ "HISTORY.md",
+ "index.js"
+ ],
+ "gitHead": "3e925b1e65ed7da2798849683d49814680dfa426",
+ "homepage": "https://github.com/jshttp/accepts#readme",
+ "keywords": [
+ "content",
+ "negotiation",
+ "accept",
+ "accepts"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "accepts",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jshttp/accepts.git"
+ },
+ "scripts": {
+ "test": "mocha --reporter spec --check-leaks --bail test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
+ },
+ "version": "1.3.3"
+}
diff --git a/node_modules/acorn/.editorconfig b/node_modules/acorn/.editorconfig
new file mode 100644
index 00000000..c14d5c67
--- /dev/null
+++ b/node_modules/acorn/.editorconfig
@@ -0,0 +1,7 @@
+root = true
+
+[*]
+indent_style = space
+indent_size = 2
+end_of_line = lf
+insert_final_newline = true
diff --git a/node_modules/acorn/.gitattributes b/node_modules/acorn/.gitattributes
new file mode 100644
index 00000000..fcadb2cf
--- /dev/null
+++ b/node_modules/acorn/.gitattributes
@@ -0,0 +1 @@
+* text eol=lf
diff --git a/node_modules/acorn/.npmignore b/node_modules/acorn/.npmignore
new file mode 100644
index 00000000..ecba2911
--- /dev/null
+++ b/node_modules/acorn/.npmignore
@@ -0,0 +1,3 @@
+/.tern-port
+/test
+/local
diff --git a/node_modules/acorn/.tern-project b/node_modules/acorn/.tern-project
new file mode 100644
index 00000000..6718ce07
--- /dev/null
+++ b/node_modules/acorn/.tern-project
@@ -0,0 +1,6 @@
+{
+ "plugins": {
+ "node": true,
+ "es_modules": true
+ }
+}
\ No newline at end of file
diff --git a/node_modules/acorn/.travis.yml b/node_modules/acorn/.travis.yml
new file mode 100644
index 00000000..d9ee88ba
--- /dev/null
+++ b/node_modules/acorn/.travis.yml
@@ -0,0 +1,7 @@
+language: node_js
+sudo: false
+node_js:
+ - '0.12'
+ - '4'
+ - '5'
+ - '6'
diff --git a/node_modules/acorn/AUTHORS b/node_modules/acorn/AUTHORS
new file mode 100644
index 00000000..1b2061cd
--- /dev/null
+++ b/node_modules/acorn/AUTHORS
@@ -0,0 +1,59 @@
+List of Acorn contributors. Updated before every release.
+
+Adrian Rakovsky
+Alistair Braidwood
+Amila Welihinda
+Andres Suarez
+Angelo
+Aparajita Fishman
+Arian Stolwijk
+Artem Govorov
+Brandon Mills
+Charles Hughes
+Conrad Irwin
+Daniel Tschinder
+David Bonnet
+Domenico Matteo
+ForbesLindesay
+Forbes Lindesay
+Gilad Peleg
+impinball
+Ingvar Stepanyan
+Jackson Ray Hamilton
+Jesse McCarthy
+Jiaxing Wang
+Joel Kemp
+Johannes Herr
+Jordan Klassen
+Jürg Lehni
+keeyipchan
+Keheliya Gallaba
+Kevin Irish
+Kevin Kwok
+krator
+Marijn Haverbeke
+Martin Carlberg
+Mathias Bynens
+Mathieu 'p01' Henri
+Matthew Bastien
+Max Schaefer
+Max Zerzouri
+Mihai Bazon
+Mike Rennie
+Nicholas C. Zakas
+Nick Fitzgerald
+Olivier Thomann
+Oskar Schöldström
+Paul Harper
+Peter Rust
+PlNG
+Prayag Verma
+ReadmeCritic
+r-e-d
+Richard Gibson
+Rich Harris
+Rich-Harris
+Sebastian McKenzie
+Timothy Gu
+Toru Nagashima
+zsjforcn
diff --git a/node_modules/acorn/CHANGELOG.md b/node_modules/acorn/CHANGELOG.md
new file mode 100644
index 00000000..16b8212e
--- /dev/null
+++ b/node_modules/acorn/CHANGELOG.md
@@ -0,0 +1,159 @@
+## 3.3.0 (2016-07-25)
+
+### Bug fixes
+
+Fix bug in tokenizing of regexp operator after a function declaration.
+
+Fix parser crash when parsing an array pattern with a hole.
+
+### New features
+
+Implement check against complex argument lists in functions that
+enable strict mode in ES7.
+
+## 3.2.0 (2016-06-07)
+
+### Bug fixes
+
+Improve handling of lack of unicode regexp support in host
+environment.
+
+Properly reject shorthand properties whose name is a keyword.
+
+Don't crash when the loose parser is called without options object.
+
+### New features
+
+Visitors created with `visit.make` now have their base as _prototype_,
+rather than copying properties into a fresh object.
+
+Make it possible to use `visit.ancestor` with a walk state.
+
+## 3.1.0 (2016-04-18)
+
+### Bug fixes
+
+Fix issue where the loose parser created invalid TemplateElement nodes
+for unclosed template literals.
+
+Properly tokenize the division operator directly after a function
+expression.
+
+Allow trailing comma in destructuring arrays.
+
+### New features
+
+The walker now allows defining handlers for `CatchClause` nodes.
+
+## 3.0.4 (2016-02-25)
+
+### Fixes
+
+Allow update expressions as left-hand-side of the ES7 exponential
+operator.
+
+## 3.0.2 (2016-02-10)
+
+### Fixes
+
+Fix bug that accidentally made `undefined` a reserved word when
+parsing ES7.
+
+## 3.0.0 (2016-02-10)
+
+### Breaking changes
+
+The default value of the `ecmaVersion` option is now 6 (used to be 5).
+
+Support for comprehension syntax (which was dropped from the draft
+spec) has been removed.
+
+### Fixes
+
+`let` and `yield` are now “contextual keywords”, meaning you can
+mostly use them as identifiers in ES5 non-strict code.
+
+A parenthesized class or function expression after `export default` is
+now parsed correctly.
+
+### New features
+
+When `ecmaVersion` is set to 7, Acorn will parse the exponentiation
+operator (`**`).
+
+The identifier character ranges are now based on Unicode 8.0.0.
+
+Plugins can now override the `raiseRecoverable` method to override the
+way non-critical errors are handled.
+
+## 2.7.0 (2016-01-04)
+
+### Fixes
+
+Stop allowing rest parameters in setters.
+
+Make sure the loose parser always attaches a `local` property to
+`ImportNamespaceSpecifier` nodes.
+
+Disallow `y` rexexp flag in ES5.
+
+Disallow `\00` and `\000` escapes in strict mode.
+
+Raise an error when an import name is a reserved word.
+
+## 2.6.4 (2015-11-12)
+
+### Fixes
+
+Fix crash in loose parser when parsing invalid object pattern.
+
+### New features
+
+Support plugins in the loose parser.
+
+## 2.6.2 (2015-11-10)
+
+### Fixes
+
+Don't crash when no options object is passed.
+
+## 2.6.0 (2015-11-09)
+
+### Fixes
+
+Add `await` as a reserved word in module sources.
+
+Disallow `yield` in a parameter default value for a generator.
+
+Forbid using a comma after a rest pattern in an array destructuring.
+
+### New features
+
+Support parsing stdin in command-line tool.
+
+## 2.5.2 (2015-10-27)
+
+### Fixes
+
+Fix bug where the walker walked an exported `let` statement as an
+expression.
+
+## 2.5.0 (2015-10-27)
+
+### Fixes
+
+Fix tokenizer support in the command-line tool.
+
+In the loose parser, don't allow non-string-literals as import
+sources.
+
+Stop allowing `new.target` outside of functions.
+
+Remove legacy `guard` and `guardedHandler` properties from try nodes.
+
+Stop allowing multiple `__proto__` properties on an object literal in
+strict mode.
+
+Don't allow rest parameters to be non-identifier patterns.
+
+Check for duplicate paramter names in arrow functions.
diff --git a/node_modules/acorn/LICENSE b/node_modules/acorn/LICENSE
new file mode 100644
index 00000000..a35ebf44
--- /dev/null
+++ b/node_modules/acorn/LICENSE
@@ -0,0 +1,19 @@
+Copyright (C) 2012-2016 by various contributors (see AUTHORS)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/acorn/README.md b/node_modules/acorn/README.md
new file mode 100644
index 00000000..0c514d5e
--- /dev/null
+++ b/node_modules/acorn/README.md
@@ -0,0 +1,407 @@
+# Acorn
+
+[](https://travis-ci.org/ternjs/acorn)
+[](https://www.npmjs.com/package/acorn)
+[Author funding status: ](https://marijnhaverbeke.nl/fund/)
+
+A tiny, fast JavaScript parser, written completely in JavaScript.
+
+## Community
+
+Acorn is open source software released under an
+[MIT license](https://github.com/ternjs/acorn/blob/master/LICENSE).
+
+You are welcome to
+[report bugs](https://github.com/ternjs/acorn/issues) or create pull
+requests on [github](https://github.com/ternjs/acorn). For questions
+and discussion, please use the
+[Tern discussion forum](https://discuss.ternjs.net).
+
+## Installation
+
+The easiest way to install acorn is with [`npm`][npm].
+
+[npm]: https://www.npmjs.com/
+
+```sh
+npm install acorn
+```
+
+Alternately, download the source.
+
+```sh
+git clone https://github.com/ternjs/acorn.git
+```
+
+## Components
+
+When run in a CommonJS (node.js) or AMD environment, exported values
+appear in the interfaces exposed by the individual files, as usual.
+When loaded in the browser (Acorn works in any JS-enabled browser more
+recent than IE5) without any kind of module management, a single
+global object `acorn` will be defined, and all the exported properties
+will be added to that.
+
+### Main parser
+
+This is implemented in `dist/acorn.js`, and is what you get when you
+`require("acorn")` in node.js.
+
+**parse**`(input, options)` is used to parse a JavaScript program.
+The `input` parameter is a string, `options` can be undefined or an
+object setting some of the options listed below. The return value will
+be an abstract syntax tree object as specified by the
+[ESTree spec][estree].
+
+When encountering a syntax error, the parser will raise a
+`SyntaxError` object with a meaningful message. The error object will
+have a `pos` property that indicates the character offset at which the
+error occurred, and a `loc` object that contains a `{line, column}`
+object referring to that same position.
+
+[estree]: https://github.com/estree/estree
+
+- **ecmaVersion**: Indicates the ECMAScript version to parse. Must be
+ either 3, 5, 6, or 7. This influences support for strict mode, the set
+ of reserved words, and support for new syntax features. Default is 6.
+
+ **NOTE**: Only 'stage 4' (finalized) ECMAScript 7 features are being
+ implemented by Acorn. That means that most of the draft standard is
+ not yet being parsed.
+
+- **sourceType**: Indicate the mode the code should be parsed in. Can be
+ either `"script"` or `"module"`.
+
+- **onInsertedSemicolon**: If given a callback, that callback will be
+ called whenever a missing semicolon is inserted by the parser. The
+ callback will be given the character offset of the point where the
+ semicolon is inserted as argument, and if `locations` is on, also a
+ `{line, column}` object representing this position.
+
+- **onTrailingComma**: Like `onInsertedSemicolon`, but for trailing
+ commas.
+
+- **allowReserved**: If `false`, using a reserved word will generate
+ an error. Defaults to `true` for `ecmaVersion` 3, `false` for higher
+ versions. When given the value `"never"`, reserved words and
+ keywords can also not be used as property names (as in Internet
+ Explorer's old parser).
+
+- **allowReturnOutsideFunction**: By default, a return statement at
+ the top level raises an error. Set this to `true` to accept such
+ code.
+
+- **allowImportExportEverywhere**: By default, `import` and `export`
+ declarations can only appear at a program's top level. Setting this
+ option to `true` allows them anywhere where a statement is allowed.
+
+- **allowHashBang**: When this is enabled (off by default), if the
+ code starts with the characters `#!` (as in a shellscript), the
+ first line will be treated as a comment.
+
+- **locations**: When `true`, each node has a `loc` object attached
+ with `start` and `end` subobjects, each of which contains the
+ one-based line and zero-based column numbers in `{line, column}`
+ form. Default is `false`.
+
+- **onToken**: If a function is passed for this option, each found
+ token will be passed in same format as tokens returned from
+ `tokenizer().getToken()`.
+
+ If array is passed, each found token is pushed to it.
+
+ Note that you are not allowed to call the parser from the
+ callback—that will corrupt its internal state.
+
+- **onComment**: If a function is passed for this option, whenever a
+ comment is encountered the function will be called with the
+ following parameters:
+
+ - `block`: `true` if the comment is a block comment, false if it
+ is a line comment.
+ - `text`: The content of the comment.
+ - `start`: Character offset of the start of the comment.
+ - `end`: Character offset of the end of the comment.
+
+ When the `locations` options is on, the `{line, column}` locations
+ of the comment’s start and end are passed as two additional
+ parameters.
+
+ If array is passed for this option, each found comment is pushed
+ to it as object in Esprima format:
+
+ ```javascript
+ {
+ "type": "Line" | "Block",
+ "value": "comment text",
+ "start": Number,
+ "end": Number,
+ // If `locations` option is on:
+ "loc": {
+ "start": {line: Number, column: Number}
+ "end": {line: Number, column: Number}
+ },
+ // If `ranges` option is on:
+ "range": [Number, Number]
+ }
+ ```
+
+ Note that you are not allowed to call the parser from the
+ callback—that will corrupt its internal state.
+
+- **ranges**: Nodes have their start and end characters offsets
+ recorded in `start` and `end` properties (directly on the node,
+ rather than the `loc` object, which holds line/column data. To also
+ add a [semi-standardized][range] `range` property holding a
+ `[start, end]` array with the same numbers, set the `ranges` option
+ to `true`.
+
+- **program**: It is possible to parse multiple files into a single
+ AST by passing the tree produced by parsing the first file as the
+ `program` option in subsequent parses. This will add the toplevel
+ forms of the parsed file to the "Program" (top) node of an existing
+ parse tree.
+
+- **sourceFile**: When the `locations` option is `true`, you can pass
+ this option to add a `source` attribute in every node’s `loc`
+ object. Note that the contents of this option are not examined or
+ processed in any way; you are free to use whatever format you
+ choose.
+
+- **directSourceFile**: Like `sourceFile`, but a `sourceFile` property
+ will be added (regardless of the `location` option) directly to the
+ nodes, rather than the `loc` object.
+
+- **preserveParens**: If this option is `true`, parenthesized expressions
+ are represented by (non-standard) `ParenthesizedExpression` nodes
+ that have a single `expression` property containing the expression
+ inside parentheses.
+
+[range]: https://bugzilla.mozilla.org/show_bug.cgi?id=745678
+
+**parseExpressionAt**`(input, offset, options)` will parse a single
+expression in a string, and return its AST. It will not complain if
+there is more of the string left after the expression.
+
+**getLineInfo**`(input, offset)` can be used to get a `{line,
+column}` object for a given program string and character offset.
+
+**tokenizer**`(input, options)` returns an object with a `getToken`
+method that can be called repeatedly to get the next token, a `{start,
+end, type, value}` object (with added `loc` property when the
+`locations` option is enabled and `range` property when the `ranges`
+option is enabled). When the token's type is `tokTypes.eof`, you
+should stop calling the method, since it will keep returning that same
+token forever.
+
+In ES6 environment, returned result can be used as any other
+protocol-compliant iterable:
+
+```javascript
+for (let token of acorn.tokenizer(str)) {
+ // iterate over the tokens
+}
+
+// transform code to array of tokens:
+var tokens = [...acorn.tokenizer(str)];
+```
+
+**tokTypes** holds an object mapping names to the token type objects
+that end up in the `type` properties of tokens.
+
+#### Note on using with [Escodegen][escodegen]
+
+Escodegen supports generating comments from AST, attached in
+Esprima-specific format. In order to simulate same format in
+Acorn, consider following example:
+
+```javascript
+var comments = [], tokens = [];
+
+var ast = acorn.parse('var x = 42; // answer', {
+ // collect ranges for each node
+ ranges: true,
+ // collect comments in Esprima's format
+ onComment: comments,
+ // collect token ranges
+ onToken: tokens
+});
+
+// attach comments using collected information
+escodegen.attachComments(ast, comments, tokens);
+
+// generate code
+console.log(escodegen.generate(ast, {comment: true}));
+// > 'var x = 42; // answer'
+```
+
+[escodegen]: https://github.com/estools/escodegen
+
+### dist/acorn_loose.js ###
+
+This file implements an error-tolerant parser. It exposes a single
+function. The loose parser is accessible in node.js via `require("acorn/dist/acorn_loose")`.
+
+**parse_dammit**`(input, options)` takes the same arguments and
+returns the same syntax tree as the `parse` function in `acorn.js`,
+but never raises an error, and will do its best to parse syntactically
+invalid code in as meaningful a way as it can. It'll insert identifier
+nodes with name `"✖"` as placeholders in places where it can't make
+sense of the input. Depends on `acorn.js`, because it uses the same
+tokenizer.
+
+### dist/walk.js ###
+
+Implements an abstract syntax tree walker. Will store its interface in
+`acorn.walk` when loaded without a module system.
+
+**simple**`(node, visitors, base, state)` does a 'simple' walk over
+a tree. `node` should be the AST node to walk, and `visitors` an
+object with properties whose names correspond to node types in the
+[ESTree spec][estree]. The properties should contain functions
+that will be called with the node object and, if applicable the state
+at that point. The last two arguments are optional. `base` is a walker
+algorithm, and `state` is a start state. The default walker will
+simply visit all statements and expressions and not produce a
+meaningful state. (An example of a use of state is to track scope at
+each point in the tree.)
+
+**ancestor**`(node, visitors, base, state)` does a 'simple' walk over
+a tree, building up an array of ancestor nodes (including the current node)
+and passing the array to the callbacks as a third parameter.
+
+**recursive**`(node, state, functions, base)` does a 'recursive'
+walk, where the walker functions are responsible for continuing the
+walk on the child nodes of their target node. `state` is the start
+state, and `functions` should contain an object that maps node types
+to walker functions. Such functions are called with `(node, state, c)`
+arguments, and can cause the walk to continue on a sub-node by calling
+the `c` argument on it with `(node, state)` arguments. The optional
+`base` argument provides the fallback walker functions for node types
+that aren't handled in the `functions` object. If not given, the
+default walkers will be used.
+
+**make**`(functions, base)` builds a new walker object by using the
+walker functions in `functions` and filling in the missing ones by
+taking defaults from `base`.
+
+**findNodeAt**`(node, start, end, test, base, state)` tries to
+locate a node in a tree at the given start and/or end offsets, which
+satisfies the predicate `test`. `start` and `end` can be either `null`
+(as wildcard) or a number. `test` may be a string (indicating a node
+type) or a function that takes `(nodeType, node)` arguments and
+returns a boolean indicating whether this node is interesting. `base`
+and `state` are optional, and can be used to specify a custom walker.
+Nodes are tested from inner to outer, so if two nodes match the
+boundaries, the inner one will be preferred.
+
+**findNodeAround**`(node, pos, test, base, state)` is a lot like
+`findNodeAt`, but will match any node that exists 'around' (spanning)
+the given position.
+
+**findNodeAfter**`(node, pos, test, base, state)` is similar to
+`findNodeAround`, but will match all nodes *after* the given position
+(testing outer nodes before inner nodes).
+
+## Command line interface
+
+The `bin/acorn` utility can be used to parse a file from the command
+line. It accepts as arguments its input file and the following
+options:
+
+- `--ecma3|--ecma5|--ecma6|--ecma7`: Sets the ECMAScript version to parse. Default is
+ version 5.
+
+- `--module`: Sets the parsing mode to `"module"`. Is set to `"script"` otherwise.
+
+- `--locations`: Attaches a "loc" object to each node with "start" and
+ "end" subobjects, each of which contains the one-based line and
+ zero-based column numbers in `{line, column}` form.
+
+- `--allow-hash-bang`: If the code starts with the characters #! (as in a shellscript), the first line will be treated as a comment.
+
+- `--compact`: No whitespace is used in the AST output.
+
+- `--silent`: Do not output the AST, just return the exit status.
+
+- `--help`: Print the usage information and quit.
+
+The utility spits out the syntax tree as JSON data.
+
+## Build system
+
+Acorn is written in ECMAScript 6, as a set of small modules, in the
+project's `src` directory, and compiled down to bigger ECMAScript 3
+files in `dist` using [Browserify](http://browserify.org) and
+[Babel](http://babeljs.io/). If you are already using Babel, you can
+consider including the modules directly.
+
+The command-line test runner (`npm test`) uses the ES6 modules. The
+browser-based test page (`test/index.html`) uses the compiled modules.
+The `bin/build-acorn.js` script builds the latter from the former.
+
+If you are working on Acorn, you'll probably want to try the code out
+directly, without an intermediate build step. In your scripts, you can
+register the Babel require shim like this:
+
+ require("babel-core/register")
+
+That will allow you to directly `require` the ES6 modules.
+
+## Plugins
+
+Acorn is designed support allow plugins which, within reasonable
+bounds, redefine the way the parser works. Plugins can add new token
+types and new tokenizer contexts (if necessary), and extend methods in
+the parser object. This is not a clean, elegant API—using it requires
+an understanding of Acorn's internals, and plugins are likely to break
+whenever those internals are significantly changed. But still, it is
+_possible_, in this way, to create parsers for JavaScript dialects
+without forking all of Acorn. And in principle it is even possible to
+combine such plugins, so that if you have, for example, a plugin for
+parsing types and a plugin for parsing JSX-style XML literals, you
+could load them both and parse code with both JSX tags and types.
+
+A plugin should register itself by adding a property to
+`acorn.plugins`, which holds a function. Calling `acorn.parse`, a
+`plugins` option can be passed, holding an object mapping plugin names
+to configuration values (or just `true` for plugins that don't take
+options). After the parser object has been created, the initialization
+functions for the chosen plugins are called with `(parser,
+configValue)` arguments. They are expected to use the `parser.extend`
+method to extend parser methods. For example, the `readToken` method
+could be extended like this:
+
+```javascript
+parser.extend("readToken", function(nextMethod) {
+ return function(code) {
+ console.log("Reading a token!")
+ return nextMethod.call(this, code)
+ }
+})
+```
+
+The `nextMethod` argument passed to `extend`'s second argument is the
+previous value of this method, and should usually be called through to
+whenever the extended method does not handle the call itself.
+
+Similarly, the loose parser allows plugins to register themselves via
+`acorn.pluginsLoose`. The extension mechanism is the same as for the
+normal parser:
+
+```javascript
+looseParser.extend("readToken", function(nextMethod) {
+ return function() {
+ console.log("Reading a token in the loose parser!")
+ return nextMethod.call(this)
+ }
+})
+```
+
+### Existing plugins
+
+ - [`acorn-jsx`](https://github.com/RReverser/acorn-jsx): Parse [Facebook JSX syntax extensions](https://github.com/facebook/jsx)
+ - [`acorn-es7-plugin`](https://github.com/MatAtBread/acorn-es7-plugin/): Parse [async/await syntax proposal](https://github.com/tc39/ecmascript-asyncawait)
+ - [`acorn-object-spread`](https://github.com/UXtemple/acorn-object-spread): Parse [object spread syntax proposal](https://github.com/sebmarkbage/ecmascript-rest-spread)
+ - [`acorn-es7`](https://www.npmjs.com/package/acorn-es7): Parse [decorator syntax proposal](https://github.com/wycats/javascript-decorators)
+ - [`acorn-objj`](https://www.npmjs.com/package/acorn-objj): [Objective-J](http://www.cappuccino-project.org/learn/objective-j.html) language parser built as Acorn plugin
diff --git a/node_modules/acorn/bin/acorn b/node_modules/acorn/bin/acorn
new file mode 100755
index 00000000..cf4acd56
--- /dev/null
+++ b/node_modules/acorn/bin/acorn
@@ -0,0 +1,65 @@
+#!/usr/bin/env node
+'use strict';
+
+var path = require('path');
+var fs = require('fs');
+var acorn = require('../dist/acorn.js');
+
+var infile;
+var forceFile;
+var silent = false;
+var compact = false;
+var tokenize = false;
+var options = {}
+
+function help(status) {
+ var print = (status == 0) ? console.log : console.error
+ print("usage: " + path.basename(process.argv[1]) + " [--ecma3|--ecma5|--ecma6|--ecma7]")
+ print(" [--tokenize] [--locations] [---allow-hash-bang] [--compact] [--silent] [--module] [--help] [--] [infile]")
+ process.exit(status)
+}
+
+for (var i = 2; i < process.argv.length; ++i) {
+ var arg = process.argv[i]
+ if ((arg == "-" || arg[0] != "-") && !infile) infile = arg
+ else if (arg == "--" && !infile && i + 2 == process.argv.length) forceFile = infile = process.argv[++i]
+ else if (arg == "--ecma3") options.ecmaVersion = 3
+ else if (arg == "--ecma5") options.ecmaVersion = 5
+ else if (arg == "--ecma6") options.ecmaVersion = 6
+ else if (arg == "--ecma7") options.ecmaVersion = 7
+ else if (arg == "--locations") options.locations = true
+ else if (arg == "--allow-hash-bang") options.allowHashBang = true
+ else if (arg == "--silent") silent = true
+ else if (arg == "--compact") compact = true
+ else if (arg == "--help") help(0)
+ else if (arg == "--tokenize") tokenize = true
+ else if (arg == "--module") options.sourceType = 'module'
+ else help(1)
+}
+
+function run(code) {
+ var result
+ if (!tokenize) {
+ try { result = acorn.parse(code, options) }
+ catch(e) { console.error(e.message); process.exit(1) }
+ } else {
+ result = []
+ var tokenizer = acorn.tokenizer(code, options), token
+ while (true) {
+ try { token = tokenizer.getToken() }
+ catch(e) { console.error(e.message); process.exit(1) }
+ result.push(token)
+ if (token.type == acorn.tokTypes.eof) break
+ }
+ }
+ if (!silent) console.log(JSON.stringify(result, null, compact ? null : 2))
+}
+
+if (forceFile || infile && infile != "-") {
+ run(fs.readFileSync(infile, "utf8"))
+} else {
+ var code = ""
+ process.stdin.resume()
+ process.stdin.on("data", function (chunk) { return code += chunk; })
+ process.stdin.on("end", function () { return run(code); })
+}
\ No newline at end of file
diff --git a/node_modules/acorn/bin/generate-identifier-regex.js b/node_modules/acorn/bin/generate-identifier-regex.js
new file mode 100644
index 00000000..100e8cf2
--- /dev/null
+++ b/node_modules/acorn/bin/generate-identifier-regex.js
@@ -0,0 +1,55 @@
+'use strict';
+
+// Which Unicode version should be used?
+var version = '9.0.0';
+
+var start = require('unicode-' + version + '/Binary_Property/ID_Start/code-points.js')
+ .filter(function(ch) { return ch > 0x7f; });
+var last = -1;
+var cont = [0x200c, 0x200d].concat(require('unicode-' + version + '/Binary_Property/ID_Continue/code-points.js')
+ .filter(function(ch) { return ch > 0x7f && search(start, ch, last + 1) == -1; }));
+
+function search(arr, ch, starting) {
+ for (var i = starting; arr[i] <= ch && i < arr.length; last = i++)
+ if (arr[i] === ch)
+ return i;
+ return -1;
+}
+
+function pad(str, width) {
+ while (str.length < width) str = "0" + str;
+ return str;
+}
+
+function esc(code) {
+ var hex = code.toString(16);
+ if (hex.length <= 2) return "\\x" + pad(hex, 2);
+ else return "\\u" + pad(hex, 4);
+}
+
+function generate(chars) {
+ var astral = [], re = "";
+ for (var i = 0, at = 0x10000; i < chars.length; i++) {
+ var from = chars[i], to = from;
+ while (i < chars.length - 1 && chars[i + 1] == to + 1) {
+ i++;
+ to++;
+ }
+ if (to <= 0xffff) {
+ if (from == to) re += esc(from);
+ else if (from + 1 == to) re += esc(from) + esc(to);
+ else re += esc(from) + "-" + esc(to);
+ } else {
+ astral.push(from - at, to - from);
+ at = to;
+ }
+ }
+ return {nonASCII: re, astral: astral};
+}
+
+var startData = generate(start), contData = generate(cont);
+
+console.log("let nonASCIIidentifierStartChars = \"" + startData.nonASCII + "\"");
+console.log("let nonASCIIidentifierChars = \"" + contData.nonASCII + "\"");
+console.log("const astralIdentifierStartCodes = " + JSON.stringify(startData.astral));
+console.log("const astralIdentifierCodes = " + JSON.stringify(contData.astral));
diff --git a/node_modules/acorn/bin/update_authors.sh b/node_modules/acorn/bin/update_authors.sh
new file mode 100755
index 00000000..466c8db5
--- /dev/null
+++ b/node_modules/acorn/bin/update_authors.sh
@@ -0,0 +1,6 @@
+# Combine existing list of authors with everyone known in git, sort, add header.
+tail --lines=+3 AUTHORS > AUTHORS.tmp
+git log --format='%aN' | grep -v abraidwood >> AUTHORS.tmp
+echo -e "List of Acorn contributors. Updated before every release.\n" > AUTHORS
+sort -u AUTHORS.tmp >> AUTHORS
+rm -f AUTHORS.tmp
diff --git a/node_modules/acorn/dist/.keep b/node_modules/acorn/dist/.keep
new file mode 100644
index 00000000..e69de29b
diff --git a/node_modules/acorn/dist/acorn.es.js b/node_modules/acorn/dist/acorn.es.js
new file mode 100644
index 00000000..4460957f
--- /dev/null
+++ b/node_modules/acorn/dist/acorn.es.js
@@ -0,0 +1,3112 @@
+// Reserved word lists for various dialects of the language
+
+var reservedWords = {
+ 3: "abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",
+ 5: "class enum extends super const export import",
+ 6: "enum",
+ 7: "enum",
+ strict: "implements interface let package private protected public static yield",
+ strictBind: "eval arguments"
+}
+
+// And the keywords
+
+var ecma5AndLessKeywords = "break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this"
+
+var keywords = {
+ 5: ecma5AndLessKeywords,
+ 6: ecma5AndLessKeywords + " const class extends export import super"
+}
+
+// ## Character categories
+
+// Big ugly regular expressions that match characters in the
+// whitespace, identifier, and identifier-start categories. These
+// are only applied when a character is found to actually have a
+// code point above 128.
+// Generated by `bin/generate-identifier-regex.js`.
+
+var nonASCIIidentifierStartChars = "\xaa\xb5\xba\xc0-\xd6\xd8-\xf6\xf8-\u02c1\u02c6-\u02d1\u02e0-\u02e4\u02ec\u02ee\u0370-\u0374\u0376\u0377\u037a-\u037d\u037f\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481\u048a-\u052f\u0531-\u0556\u0559\u0561-\u0587\u05d0-\u05ea\u05f0-\u05f2\u0620-\u064a\u066e\u066f\u0671-\u06d3\u06d5\u06e5\u06e6\u06ee\u06ef\u06fa-\u06fc\u06ff\u0710\u0712-\u072f\u074d-\u07a5\u07b1\u07ca-\u07ea\u07f4\u07f5\u07fa\u0800-\u0815\u081a\u0824\u0828\u0840-\u0858\u08a0-\u08b4\u08b6-\u08bd\u0904-\u0939\u093d\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bd\u09ce\u09dc\u09dd\u09df-\u09e1\u09f0\u09f1\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35\u0a36\u0a38\u0a39\u0a59-\u0a5c\u0a5e\u0a72-\u0a74\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2\u0ab3\u0ab5-\u0ab9\u0abd\u0ad0\u0ae0\u0ae1\u0af9\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33\u0b35-\u0b39\u0b3d\u0b5c\u0b5d\u0b5f-\u0b61\u0b71\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4\u0ba8-\u0baa\u0bae-\u0bb9\u0bd0\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c39\u0c3d\u0c58-\u0c5a\u0c60\u0c61\u0c80\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9\u0cbd\u0cde\u0ce0\u0ce1\u0cf1\u0cf2\u0d05-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d\u0d4e\u0d54-\u0d56\u0d5f-\u0d61\u0d7a-\u0d7f\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb\u0dbd\u0dc0-\u0dc6\u0e01-\u0e30\u0e32\u0e33\u0e40-\u0e46\u0e81\u0e82\u0e84\u0e87\u0e88\u0e8a\u0e8d\u0e94-\u0e97\u0e99-\u0e9f\u0ea1-\u0ea3\u0ea5\u0ea7\u0eaa\u0eab\u0ead-\u0eb0\u0eb2\u0eb3\u0ebd\u0ec0-\u0ec4\u0ec6\u0edc-\u0edf\u0f00\u0f40-\u0f47\u0f49-\u0f6c\u0f88-\u0f8c\u1000-\u102a\u103f\u1050-\u1055\u105a-\u105d\u1061\u1065\u1066\u106e-\u1070\u1075-\u1081\u108e\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310\u1312-\u1315\u1318-\u135a\u1380-\u138f\u13a0-\u13f5\u13f8-\u13fd\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f8\u1700-\u170c\u170e-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176c\u176e-\u1770\u1780-\u17b3\u17d7\u17dc\u1820-\u1877\u1880-\u18a8\u18aa\u18b0-\u18f5\u1900-\u191e\u1950-\u196d\u1970-\u1974\u1980-\u19ab\u19b0-\u19c9\u1a00-\u1a16\u1a20-\u1a54\u1aa7\u1b05-\u1b33\u1b45-\u1b4b\u1b83-\u1ba0\u1bae\u1baf\u1bba-\u1be5\u1c00-\u1c23\u1c4d-\u1c4f\u1c5a-\u1c7d\u1c80-\u1c88\u1ce9-\u1cec\u1cee-\u1cf1\u1cf5\u1cf6\u1d00-\u1dbf\u1e00-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4\u1ff6-\u1ffc\u2071\u207f\u2090-\u209c\u2102\u2107\u210a-\u2113\u2115\u2118-\u211d\u2124\u2126\u2128\u212a-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2c2e\u2c30-\u2c5e\u2c60-\u2ce4\u2ceb-\u2cee\u2cf2\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d80-\u2d96\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303c\u3041-\u3096\u309b-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312d\u3131-\u318e\u31a0-\u31ba\u31f0-\u31ff\u3400-\u4db5\u4e00-\u9fd5\ua000-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua61f\ua62a\ua62b\ua640-\ua66e\ua67f-\ua69d\ua6a0-\ua6ef\ua717-\ua71f\ua722-\ua788\ua78b-\ua7ae\ua7b0-\ua7b7\ua7f7-\ua801\ua803-\ua805\ua807-\ua80a\ua80c-\ua822\ua840-\ua873\ua882-\ua8b3\ua8f2-\ua8f7\ua8fb\ua8fd\ua90a-\ua925\ua930-\ua946\ua960-\ua97c\ua984-\ua9b2\ua9cf\ua9e0-\ua9e4\ua9e6-\ua9ef\ua9fa-\ua9fe\uaa00-\uaa28\uaa40-\uaa42\uaa44-\uaa4b\uaa60-\uaa76\uaa7a\uaa7e-\uaaaf\uaab1\uaab5\uaab6\uaab9-\uaabd\uaac0\uaac2\uaadb-\uaadd\uaae0-\uaaea\uaaf2-\uaaf4\uab01-\uab06\uab09-\uab0e\uab11-\uab16\uab20-\uab26\uab28-\uab2e\uab30-\uab5a\uab5c-\uab65\uab70-\uabe2\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d\ufa70-\ufad9\ufb00-\ufb06\ufb13-\ufb17\ufb1d\ufb1f-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44\ufb46-\ufbb1\ufbd3-\ufd3d\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe70-\ufe74\ufe76-\ufefc\uff21-\uff3a\uff41-\uff5a\uff66-\uffbe\uffc2-\uffc7\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc"
+var nonASCIIidentifierChars = "\u200c\u200d\xb7\u0300-\u036f\u0387\u0483-\u0487\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u0669\u0670\u06d6-\u06dc\u06df-\u06e4\u06e7\u06e8\u06ea-\u06ed\u06f0-\u06f9\u0711\u0730-\u074a\u07a6-\u07b0\u07c0-\u07c9\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0859-\u085b\u08d4-\u08e1\u08e3-\u0903\u093a-\u093c\u093e-\u094f\u0951-\u0957\u0962\u0963\u0966-\u096f\u0981-\u0983\u09bc\u09be-\u09c4\u09c7\u09c8\u09cb-\u09cd\u09d7\u09e2\u09e3\u09e6-\u09ef\u0a01-\u0a03\u0a3c\u0a3e-\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a66-\u0a71\u0a75\u0a81-\u0a83\u0abc\u0abe-\u0ac5\u0ac7-\u0ac9\u0acb-\u0acd\u0ae2\u0ae3\u0ae6-\u0aef\u0b01-\u0b03\u0b3c\u0b3e-\u0b44\u0b47\u0b48\u0b4b-\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b66-\u0b6f\u0b82\u0bbe-\u0bc2\u0bc6-\u0bc8\u0bca-\u0bcd\u0bd7\u0be6-\u0bef\u0c00-\u0c03\u0c3e-\u0c44\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0c66-\u0c6f\u0c81-\u0c83\u0cbc\u0cbe-\u0cc4\u0cc6-\u0cc8\u0cca-\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0ce6-\u0cef\u0d01-\u0d03\u0d3e-\u0d44\u0d46-\u0d48\u0d4a-\u0d4d\u0d57\u0d62\u0d63\u0d66-\u0d6f\u0d82\u0d83\u0dca\u0dcf-\u0dd4\u0dd6\u0dd8-\u0ddf\u0de6-\u0def\u0df2\u0df3\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0e50-\u0e59\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0ed0-\u0ed9\u0f18\u0f19\u0f20-\u0f29\u0f35\u0f37\u0f39\u0f3e\u0f3f\u0f71-\u0f84\u0f86\u0f87\u0f8d-\u0f97\u0f99-\u0fbc\u0fc6\u102b-\u103e\u1040-\u1049\u1056-\u1059\u105e-\u1060\u1062-\u1064\u1067-\u106d\u1071-\u1074\u1082-\u108d\u108f-\u109d\u135d-\u135f\u1369-\u1371\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b4-\u17d3\u17dd\u17e0-\u17e9\u180b-\u180d\u1810-\u1819\u18a9\u1920-\u192b\u1930-\u193b\u1946-\u194f\u19d0-\u19da\u1a17-\u1a1b\u1a55-\u1a5e\u1a60-\u1a7c\u1a7f-\u1a89\u1a90-\u1a99\u1ab0-\u1abd\u1b00-\u1b04\u1b34-\u1b44\u1b50-\u1b59\u1b6b-\u1b73\u1b80-\u1b82\u1ba1-\u1bad\u1bb0-\u1bb9\u1be6-\u1bf3\u1c24-\u1c37\u1c40-\u1c49\u1c50-\u1c59\u1cd0-\u1cd2\u1cd4-\u1ce8\u1ced\u1cf2-\u1cf4\u1cf8\u1cf9\u1dc0-\u1df5\u1dfb-\u1dff\u203f\u2040\u2054\u20d0-\u20dc\u20e1\u20e5-\u20f0\u2cef-\u2cf1\u2d7f\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua620-\ua629\ua66f\ua674-\ua67d\ua69e\ua69f\ua6f0\ua6f1\ua802\ua806\ua80b\ua823-\ua827\ua880\ua881\ua8b4-\ua8c5\ua8d0-\ua8d9\ua8e0-\ua8f1\ua900-\ua909\ua926-\ua92d\ua947-\ua953\ua980-\ua983\ua9b3-\ua9c0\ua9d0-\ua9d9\ua9e5\ua9f0-\ua9f9\uaa29-\uaa36\uaa43\uaa4c\uaa4d\uaa50-\uaa59\uaa7b-\uaa7d\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uaaeb-\uaaef\uaaf5\uaaf6\uabe3-\uabea\uabec\uabed\uabf0-\uabf9\ufb1e\ufe00-\ufe0f\ufe20-\ufe2f\ufe33\ufe34\ufe4d-\ufe4f\uff10-\uff19\uff3f"
+
+var nonASCIIidentifierStart = new RegExp("[" + nonASCIIidentifierStartChars + "]")
+var nonASCIIidentifier = new RegExp("[" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + "]")
+
+nonASCIIidentifierStartChars = nonASCIIidentifierChars = null
+
+// These are a run-length and offset encoded representation of the
+// >0xffff code points that are a valid part of identifiers. The
+// offset starts at 0x10000, and each pair of numbers represents an
+// offset to the next range, and then a size of the range. They were
+// generated by bin/generate-identifier-regex.js
+var astralIdentifierStartCodes = [0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,17,26,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,157,310,10,21,11,7,153,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,26,45,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,785,52,76,44,33,24,27,35,42,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,85,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,54,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,86,25,391,63,32,0,449,56,264,8,2,36,18,0,50,29,881,921,103,110,18,195,2749,1070,4050,582,8634,568,8,30,114,29,19,47,17,3,32,20,6,18,881,68,12,0,67,12,65,0,32,6124,20,754,9486,1,3071,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,4149,196,60,67,1213,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42710,42,4148,12,221,3,5761,10591,541]
+var astralIdentifierCodes = [509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,1306,2,54,14,32,9,16,3,46,10,54,9,7,2,37,13,2,9,52,0,13,2,49,13,10,2,4,9,83,11,7,0,161,11,6,9,7,3,57,0,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,87,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,423,9,838,7,2,7,17,9,57,21,2,13,19882,9,135,4,60,6,26,9,1016,45,17,3,19723,1,5319,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,2214,6,110,6,6,9,792487,239]
+
+// This has a complexity linear to the value of the code. The
+// assumption is that looking up astral identifier characters is
+// rare.
+function isInAstralSet(code, set) {
+ var pos = 0x10000
+ for (var i = 0; i < set.length; i += 2) {
+ pos += set[i]
+ if (pos > code) return false
+ pos += set[i + 1]
+ if (pos >= code) return true
+ }
+}
+
+// Test whether a given character code starts an identifier.
+
+function isIdentifierStart(code, astral) {
+ if (code < 65) return code === 36
+ if (code < 91) return true
+ if (code < 97) return code === 95
+ if (code < 123) return true
+ if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code))
+ if (astral === false) return false
+ return isInAstralSet(code, astralIdentifierStartCodes)
+}
+
+// Test whether a given character is part of an identifier.
+
+function isIdentifierChar(code, astral) {
+ if (code < 48) return code === 36
+ if (code < 58) return true
+ if (code < 65) return false
+ if (code < 91) return true
+ if (code < 97) return code === 95
+ if (code < 123) return true
+ if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code))
+ if (astral === false) return false
+ return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes)
+}
+
+// ## Token types
+
+// The assignment of fine-grained, information-carrying type objects
+// allows the tokenizer to store the information it has about a
+// token in a way that is very cheap for the parser to look up.
+
+// All token type variables start with an underscore, to make them
+// easy to recognize.
+
+// The `beforeExpr` property is used to disambiguate between regular
+// expressions and divisions. It is set on all token types that can
+// be followed by an expression (thus, a slash after them would be a
+// regular expression).
+//
+// The `startsExpr` property is used to check if the token ends a
+// `yield` expression. It is set on all token types that either can
+// directly start an expression (like a quotation mark) or can
+// continue an expression (like the body of a string).
+//
+// `isLoop` marks a keyword as starting a loop, which is important
+// to know when parsing a label, in order to allow or disallow
+// continue jumps to that label.
+
+var TokenType = function TokenType(label, conf) {
+ if ( conf === void 0 ) conf = {};
+
+ this.label = label
+ this.keyword = conf.keyword
+ this.beforeExpr = !!conf.beforeExpr
+ this.startsExpr = !!conf.startsExpr
+ this.isLoop = !!conf.isLoop
+ this.isAssign = !!conf.isAssign
+ this.prefix = !!conf.prefix
+ this.postfix = !!conf.postfix
+ this.binop = conf.binop || null
+ this.updateContext = null
+};
+
+function binop(name, prec) {
+ return new TokenType(name, {beforeExpr: true, binop: prec})
+}
+var beforeExpr = {beforeExpr: true};
+var startsExpr = {startsExpr: true};
+// Map keyword names to token types.
+
+var keywordTypes = {}
+
+// Succinct definitions of keyword token types
+function kw(name, options) {
+ if ( options === void 0 ) options = {};
+
+ options.keyword = name
+ return keywordTypes[name] = new TokenType(name, options)
+}
+
+var tt = {
+ num: new TokenType("num", startsExpr),
+ regexp: new TokenType("regexp", startsExpr),
+ string: new TokenType("string", startsExpr),
+ name: new TokenType("name", startsExpr),
+ eof: new TokenType("eof"),
+
+ // Punctuation token types.
+ bracketL: new TokenType("[", {beforeExpr: true, startsExpr: true}),
+ bracketR: new TokenType("]"),
+ braceL: new TokenType("{", {beforeExpr: true, startsExpr: true}),
+ braceR: new TokenType("}"),
+ parenL: new TokenType("(", {beforeExpr: true, startsExpr: true}),
+ parenR: new TokenType(")"),
+ comma: new TokenType(",", beforeExpr),
+ semi: new TokenType(";", beforeExpr),
+ colon: new TokenType(":", beforeExpr),
+ dot: new TokenType("."),
+ question: new TokenType("?", beforeExpr),
+ arrow: new TokenType("=>", beforeExpr),
+ template: new TokenType("template"),
+ ellipsis: new TokenType("...", beforeExpr),
+ backQuote: new TokenType("`", startsExpr),
+ dollarBraceL: new TokenType("${", {beforeExpr: true, startsExpr: true}),
+
+ // Operators. These carry several kinds of properties to help the
+ // parser use them properly (the presence of these properties is
+ // what categorizes them as operators).
+ //
+ // `binop`, when present, specifies that this operator is a binary
+ // operator, and will refer to its precedence.
+ //
+ // `prefix` and `postfix` mark the operator as a prefix or postfix
+ // unary operator.
+ //
+ // `isAssign` marks all of `=`, `+=`, `-=` etcetera, which act as
+ // binary operators with a very low precedence, that should result
+ // in AssignmentExpression nodes.
+
+ eq: new TokenType("=", {beforeExpr: true, isAssign: true}),
+ assign: new TokenType("_=", {beforeExpr: true, isAssign: true}),
+ incDec: new TokenType("++/--", {prefix: true, postfix: true, startsExpr: true}),
+ prefix: new TokenType("prefix", {beforeExpr: true, prefix: true, startsExpr: true}),
+ logicalOR: binop("||", 1),
+ logicalAND: binop("&&", 2),
+ bitwiseOR: binop("|", 3),
+ bitwiseXOR: binop("^", 4),
+ bitwiseAND: binop("&", 5),
+ equality: binop("==/!=", 6),
+ relational: binop(">", 7),
+ bitShift: binop("<>>", 8),
+ plusMin: new TokenType("+/-", {beforeExpr: true, binop: 9, prefix: true, startsExpr: true}),
+ modulo: binop("%", 10),
+ star: binop("*", 10),
+ slash: binop("/", 10),
+ starstar: new TokenType("**", {beforeExpr: true}),
+
+ // Keyword token types.
+ _break: kw("break"),
+ _case: kw("case", beforeExpr),
+ _catch: kw("catch"),
+ _continue: kw("continue"),
+ _debugger: kw("debugger"),
+ _default: kw("default", beforeExpr),
+ _do: kw("do", {isLoop: true, beforeExpr: true}),
+ _else: kw("else", beforeExpr),
+ _finally: kw("finally"),
+ _for: kw("for", {isLoop: true}),
+ _function: kw("function", startsExpr),
+ _if: kw("if"),
+ _return: kw("return", beforeExpr),
+ _switch: kw("switch"),
+ _throw: kw("throw", beforeExpr),
+ _try: kw("try"),
+ _var: kw("var"),
+ _const: kw("const"),
+ _while: kw("while", {isLoop: true}),
+ _with: kw("with"),
+ _new: kw("new", {beforeExpr: true, startsExpr: true}),
+ _this: kw("this", startsExpr),
+ _super: kw("super", startsExpr),
+ _class: kw("class"),
+ _extends: kw("extends", beforeExpr),
+ _export: kw("export"),
+ _import: kw("import"),
+ _null: kw("null", startsExpr),
+ _true: kw("true", startsExpr),
+ _false: kw("false", startsExpr),
+ _in: kw("in", {beforeExpr: true, binop: 7}),
+ _instanceof: kw("instanceof", {beforeExpr: true, binop: 7}),
+ _typeof: kw("typeof", {beforeExpr: true, prefix: true, startsExpr: true}),
+ _void: kw("void", {beforeExpr: true, prefix: true, startsExpr: true}),
+ _delete: kw("delete", {beforeExpr: true, prefix: true, startsExpr: true})
+}
+
+// Matches a whole line break (where CRLF is considered a single
+// line break). Used to count lines.
+
+var lineBreak = /\r\n?|\n|\u2028|\u2029/
+var lineBreakG = new RegExp(lineBreak.source, "g")
+
+function isNewLine(code) {
+ return code === 10 || code === 13 || code === 0x2028 || code == 0x2029
+}
+
+var nonASCIIwhitespace = /[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/
+
+var skipWhiteSpace = /(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g
+
+function isArray(obj) {
+ return Object.prototype.toString.call(obj) === "[object Array]"
+}
+
+// Checks if an object has a property.
+
+function has(obj, propName) {
+ return Object.prototype.hasOwnProperty.call(obj, propName)
+}
+
+// These are used when `options.locations` is on, for the
+// `startLoc` and `endLoc` properties.
+
+var Position = function Position(line, col) {
+ this.line = line
+ this.column = col
+};
+
+Position.prototype.offset = function offset (n) {
+ return new Position(this.line, this.column + n)
+};
+
+var SourceLocation = function SourceLocation(p, start, end) {
+ this.start = start
+ this.end = end
+ if (p.sourceFile !== null) this.source = p.sourceFile
+};
+
+// The `getLineInfo` function is mostly useful when the
+// `locations` option is off (for performance reasons) and you
+// want to find the line/column position for a given character
+// offset. `input` should be the code string that the offset refers
+// into.
+
+function getLineInfo(input, offset) {
+ for (var line = 1, cur = 0;;) {
+ lineBreakG.lastIndex = cur
+ var match = lineBreakG.exec(input)
+ if (match && match.index < offset) {
+ ++line
+ cur = match.index + match[0].length
+ } else {
+ return new Position(line, offset - cur)
+ }
+ }
+}
+
+// A second optional argument can be given to further configure
+// the parser process. These options are recognized:
+
+var defaultOptions = {
+ // `ecmaVersion` indicates the ECMAScript version to parse. Must
+ // be either 3, or 5, or 6. This influences support for strict
+ // mode, the set of reserved words, support for getters and
+ // setters and other features. The default is 6.
+ ecmaVersion: 6,
+ // Source type ("script" or "module") for different semantics
+ sourceType: "script",
+ // `onInsertedSemicolon` can be a callback that will be called
+ // when a semicolon is automatically inserted. It will be passed
+ // th position of the comma as an offset, and if `locations` is
+ // enabled, it is given the location as a `{line, column}` object
+ // as second argument.
+ onInsertedSemicolon: null,
+ // `onTrailingComma` is similar to `onInsertedSemicolon`, but for
+ // trailing commas.
+ onTrailingComma: null,
+ // By default, reserved words are only enforced if ecmaVersion >= 5.
+ // Set `allowReserved` to a boolean value to explicitly turn this on
+ // an off. When this option has the value "never", reserved words
+ // and keywords can also not be used as property names.
+ allowReserved: null,
+ // When enabled, a return at the top level is not considered an
+ // error.
+ allowReturnOutsideFunction: false,
+ // When enabled, import/export statements are not constrained to
+ // appearing at the top of the program.
+ allowImportExportEverywhere: false,
+ // When enabled, hashbang directive in the beginning of file
+ // is allowed and treated as a line comment.
+ allowHashBang: false,
+ // When `locations` is on, `loc` properties holding objects with
+ // `start` and `end` properties in `{line, column}` form (with
+ // line being 1-based and column 0-based) will be attached to the
+ // nodes.
+ locations: false,
+ // A function can be passed as `onToken` option, which will
+ // cause Acorn to call that function with object in the same
+ // format as tokens returned from `tokenizer().getToken()`. Note
+ // that you are not allowed to call the parser from the
+ // callback—that will corrupt its internal state.
+ onToken: null,
+ // A function can be passed as `onComment` option, which will
+ // cause Acorn to call that function with `(block, text, start,
+ // end)` parameters whenever a comment is skipped. `block` is a
+ // boolean indicating whether this is a block (`/* */`) comment,
+ // `text` is the content of the comment, and `start` and `end` are
+ // character offsets that denote the start and end of the comment.
+ // When the `locations` option is on, two more parameters are
+ // passed, the full `{line, column}` locations of the start and
+ // end of the comments. Note that you are not allowed to call the
+ // parser from the callback—that will corrupt its internal state.
+ onComment: null,
+ // Nodes have their start and end characters offsets recorded in
+ // `start` and `end` properties (directly on the node, rather than
+ // the `loc` object, which holds line/column data. To also add a
+ // [semi-standardized][range] `range` property holding a `[start,
+ // end]` array with the same numbers, set the `ranges` option to
+ // `true`.
+ //
+ // [range]: https://bugzilla.mozilla.org/show_bug.cgi?id=745678
+ ranges: false,
+ // It is possible to parse multiple files into a single AST by
+ // passing the tree produced by parsing the first file as
+ // `program` option in subsequent parses. This will add the
+ // toplevel forms of the parsed file to the `Program` (top) node
+ // of an existing parse tree.
+ program: null,
+ // When `locations` is on, you can pass this to record the source
+ // file in every node's `loc` object.
+ sourceFile: null,
+ // This value, if given, is stored in every node, whether
+ // `locations` is on or off.
+ directSourceFile: null,
+ // When enabled, parenthesized expressions are represented by
+ // (non-standard) ParenthesizedExpression nodes
+ preserveParens: false,
+ plugins: {}
+}
+
+// Interpret and default an options object
+
+function getOptions(opts) {
+ var options = {}
+ for (var opt in defaultOptions)
+ options[opt] = opts && has(opts, opt) ? opts[opt] : defaultOptions[opt]
+ if (options.allowReserved == null)
+ options.allowReserved = options.ecmaVersion < 5
+
+ if (isArray(options.onToken)) {
+ var tokens = options.onToken
+ options.onToken = function (token) { return tokens.push(token); }
+ }
+ if (isArray(options.onComment))
+ options.onComment = pushComment(options, options.onComment)
+
+ return options
+}
+
+function pushComment(options, array) {
+ return function (block, text, start, end, startLoc, endLoc) {
+ var comment = {
+ type: block ? 'Block' : 'Line',
+ value: text,
+ start: start,
+ end: end
+ }
+ if (options.locations)
+ comment.loc = new SourceLocation(this, startLoc, endLoc)
+ if (options.ranges)
+ comment.range = [start, end]
+ array.push(comment)
+ }
+}
+
+// Registered plugins
+var plugins = {}
+
+function keywordRegexp(words) {
+ return new RegExp("^(" + words.replace(/ /g, "|") + ")$")
+}
+
+var Parser = function Parser(options, input, startPos) {
+ this.options = options = getOptions(options)
+ this.sourceFile = options.sourceFile
+ this.keywords = keywordRegexp(keywords[options.ecmaVersion >= 6 ? 6 : 5])
+ var reserved = options.allowReserved ? "" :
+ reservedWords[options.ecmaVersion] + (options.sourceType == "module" ? " await" : "")
+ this.reservedWords = keywordRegexp(reserved)
+ var reservedStrict = (reserved ? reserved + " " : "") + reservedWords.strict
+ this.reservedWordsStrict = keywordRegexp(reservedStrict)
+ this.reservedWordsStrictBind = keywordRegexp(reservedStrict + " " + reservedWords.strictBind)
+ this.input = String(input)
+
+ // Used to signal to callers of `readWord1` whether the word
+ // contained any escape sequences. This is needed because words with
+ // escape sequences must not be interpreted as keywords.
+ this.containsEsc = false
+
+ // Load plugins
+ this.loadPlugins(options.plugins)
+
+ // Set up token state
+
+ // The current position of the tokenizer in the input.
+ if (startPos) {
+ this.pos = startPos
+ this.lineStart = Math.max(0, this.input.lastIndexOf("\n", startPos))
+ this.curLine = this.input.slice(0, this.lineStart).split(lineBreak).length
+ } else {
+ this.pos = this.lineStart = 0
+ this.curLine = 1
+ }
+
+ // Properties of the current token:
+ // Its type
+ this.type = tt.eof
+ // For tokens that include more information than their type, the value
+ this.value = null
+ // Its start and end offset
+ this.start = this.end = this.pos
+ // And, if locations are used, the {line, column} object
+ // corresponding to those offsets
+ this.startLoc = this.endLoc = this.curPosition()
+
+ // Position information for the previous token
+ this.lastTokEndLoc = this.lastTokStartLoc = null
+ this.lastTokStart = this.lastTokEnd = this.pos
+
+ // The context stack is used to superficially track syntactic
+ // context to predict whether a regular expression is allowed in a
+ // given position.
+ this.context = this.initialContext()
+ this.exprAllowed = true
+
+ // Figure out if it's a module code.
+ this.strict = this.inModule = options.sourceType === "module"
+
+ // Used to signify the start of a potential arrow function
+ this.potentialArrowAt = -1
+
+ // Flags to track whether we are in a function, a generator.
+ this.inFunction = this.inGenerator = false
+ // Labels in scope.
+ this.labels = []
+
+ // If enabled, skip leading hashbang line.
+ if (this.pos === 0 && options.allowHashBang && this.input.slice(0, 2) === '#!')
+ this.skipLineComment(2)
+};
+
+// DEPRECATED Kept for backwards compatibility until 3.0 in case a plugin uses them
+Parser.prototype.isKeyword = function isKeyword (word) { return this.keywords.test(word) };
+Parser.prototype.isReservedWord = function isReservedWord (word) { return this.reservedWords.test(word) };
+
+Parser.prototype.extend = function extend (name, f) {
+ this[name] = f(this[name])
+};
+
+Parser.prototype.loadPlugins = function loadPlugins (pluginConfigs) {
+ var this$1 = this;
+
+ for (var name in pluginConfigs) {
+ var plugin = plugins[name]
+ if (!plugin) throw new Error("Plugin '" + name + "' not found")
+ plugin(this$1, pluginConfigs[name])
+ }
+};
+
+Parser.prototype.parse = function parse () {
+ var node = this.options.program || this.startNode()
+ this.nextToken()
+ return this.parseTopLevel(node)
+};
+
+var pp = Parser.prototype
+
+// ## Parser utilities
+
+// Test whether a statement node is the string literal `"use strict"`.
+
+pp.isUseStrict = function(stmt) {
+ return this.options.ecmaVersion >= 5 && stmt.type === "ExpressionStatement" &&
+ stmt.expression.type === "Literal" &&
+ stmt.expression.raw.slice(1, -1) === "use strict"
+}
+
+// Predicate that tests whether the next token is of the given
+// type, and if yes, consumes it as a side effect.
+
+pp.eat = function(type) {
+ if (this.type === type) {
+ this.next()
+ return true
+ } else {
+ return false
+ }
+}
+
+// Tests whether parsed token is a contextual keyword.
+
+pp.isContextual = function(name) {
+ return this.type === tt.name && this.value === name
+}
+
+// Consumes contextual keyword if possible.
+
+pp.eatContextual = function(name) {
+ return this.value === name && this.eat(tt.name)
+}
+
+// Asserts that following token is given contextual keyword.
+
+pp.expectContextual = function(name) {
+ if (!this.eatContextual(name)) this.unexpected()
+}
+
+// Test whether a semicolon can be inserted at the current position.
+
+pp.canInsertSemicolon = function() {
+ return this.type === tt.eof ||
+ this.type === tt.braceR ||
+ lineBreak.test(this.input.slice(this.lastTokEnd, this.start))
+}
+
+pp.insertSemicolon = function() {
+ if (this.canInsertSemicolon()) {
+ if (this.options.onInsertedSemicolon)
+ this.options.onInsertedSemicolon(this.lastTokEnd, this.lastTokEndLoc)
+ return true
+ }
+}
+
+// Consume a semicolon, or, failing that, see if we are allowed to
+// pretend that there is a semicolon at this position.
+
+pp.semicolon = function() {
+ if (!this.eat(tt.semi) && !this.insertSemicolon()) this.unexpected()
+}
+
+pp.afterTrailingComma = function(tokType) {
+ if (this.type == tokType) {
+ if (this.options.onTrailingComma)
+ this.options.onTrailingComma(this.lastTokStart, this.lastTokStartLoc)
+ this.next()
+ return true
+ }
+}
+
+// Expect a token of a given type. If found, consume it, otherwise,
+// raise an unexpected token error.
+
+pp.expect = function(type) {
+ this.eat(type) || this.unexpected()
+}
+
+// Raise an unexpected token error.
+
+pp.unexpected = function(pos) {
+ this.raise(pos != null ? pos : this.start, "Unexpected token")
+}
+
+var DestructuringErrors = function DestructuringErrors() {
+ this.shorthandAssign = 0
+ this.trailingComma = 0
+};
+
+pp.checkPatternErrors = function(refDestructuringErrors, andThrow) {
+ var trailing = refDestructuringErrors && refDestructuringErrors.trailingComma
+ if (!andThrow) return !!trailing
+ if (trailing) this.raise(trailing, "Comma is not permitted after the rest element")
+}
+
+pp.checkExpressionErrors = function(refDestructuringErrors, andThrow) {
+ var pos = refDestructuringErrors && refDestructuringErrors.shorthandAssign
+ if (!andThrow) return !!pos
+ if (pos) this.raise(pos, "Shorthand property assignments are valid only in destructuring patterns")
+}
+
+var pp$1 = Parser.prototype
+
+// ### Statement parsing
+
+// Parse a program. Initializes the parser, reads any number of
+// statements, and wraps them in a Program node. Optionally takes a
+// `program` argument. If present, the statements will be appended
+// to its body instead of creating a new node.
+
+pp$1.parseTopLevel = function(node) {
+ var this$1 = this;
+
+ var first = true
+ if (!node.body) node.body = []
+ while (this.type !== tt.eof) {
+ var stmt = this$1.parseStatement(true, true)
+ node.body.push(stmt)
+ if (first) {
+ if (this$1.isUseStrict(stmt)) this$1.setStrict(true)
+ first = false
+ }
+ }
+ this.next()
+ if (this.options.ecmaVersion >= 6) {
+ node.sourceType = this.options.sourceType
+ }
+ return this.finishNode(node, "Program")
+}
+
+var loopLabel = {kind: "loop"};
+var switchLabel = {kind: "switch"};
+pp$1.isLet = function() {
+ if (this.type !== tt.name || this.options.ecmaVersion < 6 || this.value != "let") return false
+ skipWhiteSpace.lastIndex = this.pos
+ var skip = skipWhiteSpace.exec(this.input)
+ var next = this.pos + skip[0].length, nextCh = this.input.charCodeAt(next)
+ if (nextCh === 91 || nextCh == 123) return true // '{' and '['
+ if (isIdentifierStart(nextCh, true)) {
+ for (var pos = next + 1; isIdentifierChar(this.input.charCodeAt(pos), true); ++pos) {}
+ var ident = this.input.slice(next, pos)
+ if (!this.isKeyword(ident)) return true
+ }
+ return false
+}
+
+// Parse a single statement.
+//
+// If expecting a statement and finding a slash operator, parse a
+// regular expression literal. This is to handle cases like
+// `if (foo) /blah/.exec(foo)`, where looking at the previous token
+// does not help.
+
+pp$1.parseStatement = function(declaration, topLevel) {
+ var starttype = this.type, node = this.startNode(), kind
+
+ if (this.isLet()) {
+ starttype = tt._var
+ kind = "let"
+ }
+
+ // Most types of statements are recognized by the keyword they
+ // start with. Many are trivial to parse, some require a bit of
+ // complexity.
+
+ switch (starttype) {
+ case tt._break: case tt._continue: return this.parseBreakContinueStatement(node, starttype.keyword)
+ case tt._debugger: return this.parseDebuggerStatement(node)
+ case tt._do: return this.parseDoStatement(node)
+ case tt._for: return this.parseForStatement(node)
+ case tt._function:
+ if (!declaration && this.options.ecmaVersion >= 6) this.unexpected()
+ return this.parseFunctionStatement(node)
+ case tt._class:
+ if (!declaration) this.unexpected()
+ return this.parseClass(node, true)
+ case tt._if: return this.parseIfStatement(node)
+ case tt._return: return this.parseReturnStatement(node)
+ case tt._switch: return this.parseSwitchStatement(node)
+ case tt._throw: return this.parseThrowStatement(node)
+ case tt._try: return this.parseTryStatement(node)
+ case tt._const: case tt._var:
+ kind = kind || this.value
+ if (!declaration && kind != "var") this.unexpected()
+ return this.parseVarStatement(node, kind)
+ case tt._while: return this.parseWhileStatement(node)
+ case tt._with: return this.parseWithStatement(node)
+ case tt.braceL: return this.parseBlock()
+ case tt.semi: return this.parseEmptyStatement(node)
+ case tt._export:
+ case tt._import:
+ if (!this.options.allowImportExportEverywhere) {
+ if (!topLevel)
+ this.raise(this.start, "'import' and 'export' may only appear at the top level")
+ if (!this.inModule)
+ this.raise(this.start, "'import' and 'export' may appear only with 'sourceType: module'")
+ }
+ return starttype === tt._import ? this.parseImport(node) : this.parseExport(node)
+
+ // If the statement does not start with a statement keyword or a
+ // brace, it's an ExpressionStatement or LabeledStatement. We
+ // simply start parsing an expression, and afterwards, if the
+ // next token is a colon and the expression was a simple
+ // Identifier node, we switch to interpreting it as a label.
+ default:
+ var maybeName = this.value, expr = this.parseExpression()
+ if (starttype === tt.name && expr.type === "Identifier" && this.eat(tt.colon))
+ return this.parseLabeledStatement(node, maybeName, expr)
+ else return this.parseExpressionStatement(node, expr)
+ }
+}
+
+pp$1.parseBreakContinueStatement = function(node, keyword) {
+ var this$1 = this;
+
+ var isBreak = keyword == "break"
+ this.next()
+ if (this.eat(tt.semi) || this.insertSemicolon()) node.label = null
+ else if (this.type !== tt.name) this.unexpected()
+ else {
+ node.label = this.parseIdent()
+ this.semicolon()
+ }
+
+ // Verify that there is an actual destination to break or
+ // continue to.
+ for (var i = 0; i < this.labels.length; ++i) {
+ var lab = this$1.labels[i]
+ if (node.label == null || lab.name === node.label.name) {
+ if (lab.kind != null && (isBreak || lab.kind === "loop")) break
+ if (node.label && isBreak) break
+ }
+ }
+ if (i === this.labels.length) this.raise(node.start, "Unsyntactic " + keyword)
+ return this.finishNode(node, isBreak ? "BreakStatement" : "ContinueStatement")
+}
+
+pp$1.parseDebuggerStatement = function(node) {
+ this.next()
+ this.semicolon()
+ return this.finishNode(node, "DebuggerStatement")
+}
+
+pp$1.parseDoStatement = function(node) {
+ this.next()
+ this.labels.push(loopLabel)
+ node.body = this.parseStatement(false)
+ this.labels.pop()
+ this.expect(tt._while)
+ node.test = this.parseParenExpression()
+ if (this.options.ecmaVersion >= 6)
+ this.eat(tt.semi)
+ else
+ this.semicolon()
+ return this.finishNode(node, "DoWhileStatement")
+}
+
+// Disambiguating between a `for` and a `for`/`in` or `for`/`of`
+// loop is non-trivial. Basically, we have to parse the init `var`
+// statement or expression, disallowing the `in` operator (see
+// the second parameter to `parseExpression`), and then check
+// whether the next token is `in` or `of`. When there is no init
+// part (semicolon immediately after the opening parenthesis), it
+// is a regular `for` loop.
+
+pp$1.parseForStatement = function(node) {
+ this.next()
+ this.labels.push(loopLabel)
+ this.expect(tt.parenL)
+ if (this.type === tt.semi) return this.parseFor(node, null)
+ var isLet = this.isLet()
+ if (this.type === tt._var || this.type === tt._const || isLet) {
+ var init$1 = this.startNode(), kind = isLet ? "let" : this.value
+ this.next()
+ this.parseVar(init$1, true, kind)
+ this.finishNode(init$1, "VariableDeclaration")
+ if ((this.type === tt._in || (this.options.ecmaVersion >= 6 && this.isContextual("of"))) && init$1.declarations.length === 1 &&
+ !(kind !== "var" && init$1.declarations[0].init))
+ return this.parseForIn(node, init$1)
+ return this.parseFor(node, init$1)
+ }
+ var refDestructuringErrors = new DestructuringErrors
+ var init = this.parseExpression(true, refDestructuringErrors)
+ if (this.type === tt._in || (this.options.ecmaVersion >= 6 && this.isContextual("of"))) {
+ this.checkPatternErrors(refDestructuringErrors, true)
+ this.toAssignable(init)
+ this.checkLVal(init)
+ return this.parseForIn(node, init)
+ } else {
+ this.checkExpressionErrors(refDestructuringErrors, true)
+ }
+ return this.parseFor(node, init)
+}
+
+pp$1.parseFunctionStatement = function(node) {
+ this.next()
+ return this.parseFunction(node, true)
+}
+
+pp$1.parseIfStatement = function(node) {
+ this.next()
+ node.test = this.parseParenExpression()
+ node.consequent = this.parseStatement(false)
+ node.alternate = this.eat(tt._else) ? this.parseStatement(false) : null
+ return this.finishNode(node, "IfStatement")
+}
+
+pp$1.parseReturnStatement = function(node) {
+ if (!this.inFunction && !this.options.allowReturnOutsideFunction)
+ this.raise(this.start, "'return' outside of function")
+ this.next()
+
+ // In `return` (and `break`/`continue`), the keywords with
+ // optional arguments, we eagerly look for a semicolon or the
+ // possibility to insert one.
+
+ if (this.eat(tt.semi) || this.insertSemicolon()) node.argument = null
+ else { node.argument = this.parseExpression(); this.semicolon() }
+ return this.finishNode(node, "ReturnStatement")
+}
+
+pp$1.parseSwitchStatement = function(node) {
+ var this$1 = this;
+
+ this.next()
+ node.discriminant = this.parseParenExpression()
+ node.cases = []
+ this.expect(tt.braceL)
+ this.labels.push(switchLabel)
+
+ // Statements under must be grouped (by label) in SwitchCase
+ // nodes. `cur` is used to keep the node that we are currently
+ // adding statements to.
+
+ for (var cur, sawDefault = false; this.type != tt.braceR;) {
+ if (this$1.type === tt._case || this$1.type === tt._default) {
+ var isCase = this$1.type === tt._case
+ if (cur) this$1.finishNode(cur, "SwitchCase")
+ node.cases.push(cur = this$1.startNode())
+ cur.consequent = []
+ this$1.next()
+ if (isCase) {
+ cur.test = this$1.parseExpression()
+ } else {
+ if (sawDefault) this$1.raiseRecoverable(this$1.lastTokStart, "Multiple default clauses")
+ sawDefault = true
+ cur.test = null
+ }
+ this$1.expect(tt.colon)
+ } else {
+ if (!cur) this$1.unexpected()
+ cur.consequent.push(this$1.parseStatement(true))
+ }
+ }
+ if (cur) this.finishNode(cur, "SwitchCase")
+ this.next() // Closing brace
+ this.labels.pop()
+ return this.finishNode(node, "SwitchStatement")
+}
+
+pp$1.parseThrowStatement = function(node) {
+ this.next()
+ if (lineBreak.test(this.input.slice(this.lastTokEnd, this.start)))
+ this.raise(this.lastTokEnd, "Illegal newline after throw")
+ node.argument = this.parseExpression()
+ this.semicolon()
+ return this.finishNode(node, "ThrowStatement")
+}
+
+// Reused empty array added for node fields that are always empty.
+
+var empty = []
+
+pp$1.parseTryStatement = function(node) {
+ this.next()
+ node.block = this.parseBlock()
+ node.handler = null
+ if (this.type === tt._catch) {
+ var clause = this.startNode()
+ this.next()
+ this.expect(tt.parenL)
+ clause.param = this.parseBindingAtom()
+ this.checkLVal(clause.param, true)
+ this.expect(tt.parenR)
+ clause.body = this.parseBlock()
+ node.handler = this.finishNode(clause, "CatchClause")
+ }
+ node.finalizer = this.eat(tt._finally) ? this.parseBlock() : null
+ if (!node.handler && !node.finalizer)
+ this.raise(node.start, "Missing catch or finally clause")
+ return this.finishNode(node, "TryStatement")
+}
+
+pp$1.parseVarStatement = function(node, kind) {
+ this.next()
+ this.parseVar(node, false, kind)
+ this.semicolon()
+ return this.finishNode(node, "VariableDeclaration")
+}
+
+pp$1.parseWhileStatement = function(node) {
+ this.next()
+ node.test = this.parseParenExpression()
+ this.labels.push(loopLabel)
+ node.body = this.parseStatement(false)
+ this.labels.pop()
+ return this.finishNode(node, "WhileStatement")
+}
+
+pp$1.parseWithStatement = function(node) {
+ if (this.strict) this.raise(this.start, "'with' in strict mode")
+ this.next()
+ node.object = this.parseParenExpression()
+ node.body = this.parseStatement(false)
+ return this.finishNode(node, "WithStatement")
+}
+
+pp$1.parseEmptyStatement = function(node) {
+ this.next()
+ return this.finishNode(node, "EmptyStatement")
+}
+
+pp$1.parseLabeledStatement = function(node, maybeName, expr) {
+ var this$1 = this;
+
+ for (var i = 0; i < this.labels.length; ++i)
+ if (this$1.labels[i].name === maybeName) this$1.raise(expr.start, "Label '" + maybeName + "' is already declared")
+ var kind = this.type.isLoop ? "loop" : this.type === tt._switch ? "switch" : null
+ for (var i$1 = this.labels.length - 1; i$1 >= 0; i$1--) {
+ var label = this$1.labels[i$1]
+ if (label.statementStart == node.start) {
+ label.statementStart = this$1.start
+ label.kind = kind
+ } else break
+ }
+ this.labels.push({name: maybeName, kind: kind, statementStart: this.start})
+ node.body = this.parseStatement(true)
+ this.labels.pop()
+ node.label = expr
+ return this.finishNode(node, "LabeledStatement")
+}
+
+pp$1.parseExpressionStatement = function(node, expr) {
+ node.expression = expr
+ this.semicolon()
+ return this.finishNode(node, "ExpressionStatement")
+}
+
+// Parse a semicolon-enclosed block of statements, handling `"use
+// strict"` declarations when `allowStrict` is true (used for
+// function bodies).
+
+pp$1.parseBlock = function(allowStrict) {
+ var this$1 = this;
+
+ var node = this.startNode(), first = true, oldStrict
+ node.body = []
+ this.expect(tt.braceL)
+ while (!this.eat(tt.braceR)) {
+ var stmt = this$1.parseStatement(true)
+ node.body.push(stmt)
+ if (first && allowStrict && this$1.isUseStrict(stmt)) {
+ oldStrict = this$1.strict
+ this$1.setStrict(this$1.strict = true)
+ }
+ first = false
+ }
+ if (oldStrict === false) this.setStrict(false)
+ return this.finishNode(node, "BlockStatement")
+}
+
+// Parse a regular `for` loop. The disambiguation code in
+// `parseStatement` will already have parsed the init statement or
+// expression.
+
+pp$1.parseFor = function(node, init) {
+ node.init = init
+ this.expect(tt.semi)
+ node.test = this.type === tt.semi ? null : this.parseExpression()
+ this.expect(tt.semi)
+ node.update = this.type === tt.parenR ? null : this.parseExpression()
+ this.expect(tt.parenR)
+ node.body = this.parseStatement(false)
+ this.labels.pop()
+ return this.finishNode(node, "ForStatement")
+}
+
+// Parse a `for`/`in` and `for`/`of` loop, which are almost
+// same from parser's perspective.
+
+pp$1.parseForIn = function(node, init) {
+ var type = this.type === tt._in ? "ForInStatement" : "ForOfStatement"
+ this.next()
+ node.left = init
+ node.right = this.parseExpression()
+ this.expect(tt.parenR)
+ node.body = this.parseStatement(false)
+ this.labels.pop()
+ return this.finishNode(node, type)
+}
+
+// Parse a list of variable declarations.
+
+pp$1.parseVar = function(node, isFor, kind) {
+ var this$1 = this;
+
+ node.declarations = []
+ node.kind = kind
+ for (;;) {
+ var decl = this$1.startNode()
+ this$1.parseVarId(decl)
+ if (this$1.eat(tt.eq)) {
+ decl.init = this$1.parseMaybeAssign(isFor)
+ } else if (kind === "const" && !(this$1.type === tt._in || (this$1.options.ecmaVersion >= 6 && this$1.isContextual("of")))) {
+ this$1.unexpected()
+ } else if (decl.id.type != "Identifier" && !(isFor && (this$1.type === tt._in || this$1.isContextual("of")))) {
+ this$1.raise(this$1.lastTokEnd, "Complex binding patterns require an initialization value")
+ } else {
+ decl.init = null
+ }
+ node.declarations.push(this$1.finishNode(decl, "VariableDeclarator"))
+ if (!this$1.eat(tt.comma)) break
+ }
+ return node
+}
+
+pp$1.parseVarId = function(decl) {
+ decl.id = this.parseBindingAtom()
+ this.checkLVal(decl.id, true)
+}
+
+// Parse a function declaration or literal (depending on the
+// `isStatement` parameter).
+
+pp$1.parseFunction = function(node, isStatement, allowExpressionBody) {
+ this.initFunction(node)
+ if (this.options.ecmaVersion >= 6)
+ node.generator = this.eat(tt.star)
+ var oldInGen = this.inGenerator
+ this.inGenerator = node.generator
+ if (isStatement || this.type === tt.name)
+ node.id = this.parseIdent()
+ this.parseFunctionParams(node)
+ this.parseFunctionBody(node, allowExpressionBody)
+ this.inGenerator = oldInGen
+ return this.finishNode(node, isStatement ? "FunctionDeclaration" : "FunctionExpression")
+}
+
+pp$1.parseFunctionParams = function(node) {
+ this.expect(tt.parenL)
+ node.params = this.parseBindingList(tt.parenR, false, false, true)
+}
+
+// Parse a class declaration or literal (depending on the
+// `isStatement` parameter).
+
+pp$1.parseClass = function(node, isStatement) {
+ var this$1 = this;
+
+ this.next()
+ this.parseClassId(node, isStatement)
+ this.parseClassSuper(node)
+ var classBody = this.startNode()
+ var hadConstructor = false
+ classBody.body = []
+ this.expect(tt.braceL)
+ while (!this.eat(tt.braceR)) {
+ if (this$1.eat(tt.semi)) continue
+ var method = this$1.startNode()
+ var isGenerator = this$1.eat(tt.star)
+ var isMaybeStatic = this$1.type === tt.name && this$1.value === "static"
+ this$1.parsePropertyName(method)
+ method.static = isMaybeStatic && this$1.type !== tt.parenL
+ if (method.static) {
+ if (isGenerator) this$1.unexpected()
+ isGenerator = this$1.eat(tt.star)
+ this$1.parsePropertyName(method)
+ }
+ method.kind = "method"
+ var isGetSet = false
+ if (!method.computed) {
+ var key = method.key;
+ if (!isGenerator && key.type === "Identifier" && this$1.type !== tt.parenL && (key.name === "get" || key.name === "set")) {
+ isGetSet = true
+ method.kind = key.name
+ key = this$1.parsePropertyName(method)
+ }
+ if (!method.static && (key.type === "Identifier" && key.name === "constructor" ||
+ key.type === "Literal" && key.value === "constructor")) {
+ if (hadConstructor) this$1.raise(key.start, "Duplicate constructor in the same class")
+ if (isGetSet) this$1.raise(key.start, "Constructor can't have get/set modifier")
+ if (isGenerator) this$1.raise(key.start, "Constructor can't be a generator")
+ method.kind = "constructor"
+ hadConstructor = true
+ }
+ }
+ this$1.parseClassMethod(classBody, method, isGenerator)
+ if (isGetSet) {
+ var paramCount = method.kind === "get" ? 0 : 1
+ if (method.value.params.length !== paramCount) {
+ var start = method.value.start
+ if (method.kind === "get")
+ this$1.raiseRecoverable(start, "getter should have no params")
+ else
+ this$1.raiseRecoverable(start, "setter should have exactly one param")
+ }
+ if (method.kind === "set" && method.value.params[0].type === "RestElement")
+ this$1.raise(method.value.params[0].start, "Setter cannot use rest params")
+ }
+ }
+ node.body = this.finishNode(classBody, "ClassBody")
+ return this.finishNode(node, isStatement ? "ClassDeclaration" : "ClassExpression")
+}
+
+pp$1.parseClassMethod = function(classBody, method, isGenerator) {
+ method.value = this.parseMethod(isGenerator)
+ classBody.body.push(this.finishNode(method, "MethodDefinition"))
+}
+
+pp$1.parseClassId = function(node, isStatement) {
+ node.id = this.type === tt.name ? this.parseIdent() : isStatement ? this.unexpected() : null
+}
+
+pp$1.parseClassSuper = function(node) {
+ node.superClass = this.eat(tt._extends) ? this.parseExprSubscripts() : null
+}
+
+// Parses module export declaration.
+
+pp$1.parseExport = function(node) {
+ var this$1 = this;
+
+ this.next()
+ // export * from '...'
+ if (this.eat(tt.star)) {
+ this.expectContextual("from")
+ node.source = this.type === tt.string ? this.parseExprAtom() : this.unexpected()
+ this.semicolon()
+ return this.finishNode(node, "ExportAllDeclaration")
+ }
+ if (this.eat(tt._default)) { // export default ...
+ var parens = this.type == tt.parenL
+ var expr = this.parseMaybeAssign()
+ var needsSemi = true
+ if (!parens && (expr.type == "FunctionExpression" ||
+ expr.type == "ClassExpression")) {
+ needsSemi = false
+ if (expr.id) {
+ expr.type = expr.type == "FunctionExpression"
+ ? "FunctionDeclaration"
+ : "ClassDeclaration"
+ }
+ }
+ node.declaration = expr
+ if (needsSemi) this.semicolon()
+ return this.finishNode(node, "ExportDefaultDeclaration")
+ }
+ // export var|const|let|function|class ...
+ if (this.shouldParseExportStatement()) {
+ node.declaration = this.parseStatement(true)
+ node.specifiers = []
+ node.source = null
+ } else { // export { x, y as z } [from '...']
+ node.declaration = null
+ node.specifiers = this.parseExportSpecifiers()
+ if (this.eatContextual("from")) {
+ node.source = this.type === tt.string ? this.parseExprAtom() : this.unexpected()
+ } else {
+ // check for keywords used as local names
+ for (var i = 0; i < node.specifiers.length; i++) {
+ if (this$1.keywords.test(node.specifiers[i].local.name) || this$1.reservedWords.test(node.specifiers[i].local.name)) {
+ this$1.unexpected(node.specifiers[i].local.start)
+ }
+ }
+
+ node.source = null
+ }
+ this.semicolon()
+ }
+ return this.finishNode(node, "ExportNamedDeclaration")
+}
+
+pp$1.shouldParseExportStatement = function() {
+ return this.type.keyword || this.isLet()
+}
+
+// Parses a comma-separated list of module exports.
+
+pp$1.parseExportSpecifiers = function() {
+ var this$1 = this;
+
+ var nodes = [], first = true
+ // export { x, y as z } [from '...']
+ this.expect(tt.braceL)
+ while (!this.eat(tt.braceR)) {
+ if (!first) {
+ this$1.expect(tt.comma)
+ if (this$1.afterTrailingComma(tt.braceR)) break
+ } else first = false
+
+ var node = this$1.startNode()
+ node.local = this$1.parseIdent(this$1.type === tt._default)
+ node.exported = this$1.eatContextual("as") ? this$1.parseIdent(true) : node.local
+ nodes.push(this$1.finishNode(node, "ExportSpecifier"))
+ }
+ return nodes
+}
+
+// Parses import declaration.
+
+pp$1.parseImport = function(node) {
+ this.next()
+ // import '...'
+ if (this.type === tt.string) {
+ node.specifiers = empty
+ node.source = this.parseExprAtom()
+ } else {
+ node.specifiers = this.parseImportSpecifiers()
+ this.expectContextual("from")
+ node.source = this.type === tt.string ? this.parseExprAtom() : this.unexpected()
+ }
+ this.semicolon()
+ return this.finishNode(node, "ImportDeclaration")
+}
+
+// Parses a comma-separated list of module imports.
+
+pp$1.parseImportSpecifiers = function() {
+ var this$1 = this;
+
+ var nodes = [], first = true
+ if (this.type === tt.name) {
+ // import defaultObj, { x, y as z } from '...'
+ var node = this.startNode()
+ node.local = this.parseIdent()
+ this.checkLVal(node.local, true)
+ nodes.push(this.finishNode(node, "ImportDefaultSpecifier"))
+ if (!this.eat(tt.comma)) return nodes
+ }
+ if (this.type === tt.star) {
+ var node$1 = this.startNode()
+ this.next()
+ this.expectContextual("as")
+ node$1.local = this.parseIdent()
+ this.checkLVal(node$1.local, true)
+ nodes.push(this.finishNode(node$1, "ImportNamespaceSpecifier"))
+ return nodes
+ }
+ this.expect(tt.braceL)
+ while (!this.eat(tt.braceR)) {
+ if (!first) {
+ this$1.expect(tt.comma)
+ if (this$1.afterTrailingComma(tt.braceR)) break
+ } else first = false
+
+ var node$2 = this$1.startNode()
+ node$2.imported = this$1.parseIdent(true)
+ if (this$1.eatContextual("as")) {
+ node$2.local = this$1.parseIdent()
+ } else {
+ node$2.local = node$2.imported
+ if (this$1.isKeyword(node$2.local.name)) this$1.unexpected(node$2.local.start)
+ if (this$1.reservedWordsStrict.test(node$2.local.name)) this$1.raise(node$2.local.start, "The keyword '" + node$2.local.name + "' is reserved")
+ }
+ this$1.checkLVal(node$2.local, true)
+ nodes.push(this$1.finishNode(node$2, "ImportSpecifier"))
+ }
+ return nodes
+}
+
+var pp$2 = Parser.prototype
+
+// Convert existing expression atom to assignable pattern
+// if possible.
+
+pp$2.toAssignable = function(node, isBinding) {
+ var this$1 = this;
+
+ if (this.options.ecmaVersion >= 6 && node) {
+ switch (node.type) {
+ case "Identifier":
+ case "ObjectPattern":
+ case "ArrayPattern":
+ break
+
+ case "ObjectExpression":
+ node.type = "ObjectPattern"
+ for (var i = 0; i < node.properties.length; i++) {
+ var prop = node.properties[i]
+ if (prop.kind !== "init") this$1.raise(prop.key.start, "Object pattern can't contain getter or setter")
+ this$1.toAssignable(prop.value, isBinding)
+ }
+ break
+
+ case "ArrayExpression":
+ node.type = "ArrayPattern"
+ this.toAssignableList(node.elements, isBinding)
+ break
+
+ case "AssignmentExpression":
+ if (node.operator === "=") {
+ node.type = "AssignmentPattern"
+ delete node.operator
+ // falls through to AssignmentPattern
+ } else {
+ this.raise(node.left.end, "Only '=' operator can be used for specifying default value.")
+ break
+ }
+
+ case "AssignmentPattern":
+ if (node.right.type === "YieldExpression")
+ this.raise(node.right.start, "Yield expression cannot be a default value")
+ break
+
+ case "ParenthesizedExpression":
+ node.expression = this.toAssignable(node.expression, isBinding)
+ break
+
+ case "MemberExpression":
+ if (!isBinding) break
+
+ default:
+ this.raise(node.start, "Assigning to rvalue")
+ }
+ }
+ return node
+}
+
+// Convert list of expression atoms to binding list.
+
+pp$2.toAssignableList = function(exprList, isBinding) {
+ var this$1 = this;
+
+ var end = exprList.length
+ if (end) {
+ var last = exprList[end - 1]
+ if (last && last.type == "RestElement") {
+ --end
+ } else if (last && last.type == "SpreadElement") {
+ last.type = "RestElement"
+ var arg = last.argument
+ this.toAssignable(arg, isBinding)
+ if (arg.type !== "Identifier" && arg.type !== "MemberExpression" && arg.type !== "ArrayPattern")
+ this.unexpected(arg.start)
+ --end
+ }
+
+ if (isBinding && last && last.type === "RestElement" && last.argument.type !== "Identifier")
+ this.unexpected(last.argument.start)
+ }
+ for (var i = 0; i < end; i++) {
+ var elt = exprList[i]
+ if (elt) this$1.toAssignable(elt, isBinding)
+ }
+ return exprList
+}
+
+// Parses spread element.
+
+pp$2.parseSpread = function(refDestructuringErrors) {
+ var node = this.startNode()
+ this.next()
+ node.argument = this.parseMaybeAssign(false, refDestructuringErrors)
+ return this.finishNode(node, "SpreadElement")
+}
+
+pp$2.parseRest = function(allowNonIdent) {
+ var node = this.startNode()
+ this.next()
+
+ // RestElement inside of a function parameter must be an identifier
+ if (allowNonIdent) node.argument = this.type === tt.name ? this.parseIdent() : this.unexpected()
+ else node.argument = this.type === tt.name || this.type === tt.bracketL ? this.parseBindingAtom() : this.unexpected()
+
+ return this.finishNode(node, "RestElement")
+}
+
+// Parses lvalue (assignable) atom.
+
+pp$2.parseBindingAtom = function() {
+ if (this.options.ecmaVersion < 6) return this.parseIdent()
+ switch (this.type) {
+ case tt.name:
+ return this.parseIdent()
+
+ case tt.bracketL:
+ var node = this.startNode()
+ this.next()
+ node.elements = this.parseBindingList(tt.bracketR, true, true)
+ return this.finishNode(node, "ArrayPattern")
+
+ case tt.braceL:
+ return this.parseObj(true)
+
+ default:
+ this.unexpected()
+ }
+}
+
+pp$2.parseBindingList = function(close, allowEmpty, allowTrailingComma, allowNonIdent) {
+ var this$1 = this;
+
+ var elts = [], first = true
+ while (!this.eat(close)) {
+ if (first) first = false
+ else this$1.expect(tt.comma)
+ if (allowEmpty && this$1.type === tt.comma) {
+ elts.push(null)
+ } else if (allowTrailingComma && this$1.afterTrailingComma(close)) {
+ break
+ } else if (this$1.type === tt.ellipsis) {
+ var rest = this$1.parseRest(allowNonIdent)
+ this$1.parseBindingListItem(rest)
+ elts.push(rest)
+ if (this$1.type === tt.comma) this$1.raise(this$1.start, "Comma is not permitted after the rest element")
+ this$1.expect(close)
+ break
+ } else {
+ var elem = this$1.parseMaybeDefault(this$1.start, this$1.startLoc)
+ this$1.parseBindingListItem(elem)
+ elts.push(elem)
+ }
+ }
+ return elts
+}
+
+pp$2.parseBindingListItem = function(param) {
+ return param
+}
+
+// Parses assignment pattern around given atom if possible.
+
+pp$2.parseMaybeDefault = function(startPos, startLoc, left) {
+ left = left || this.parseBindingAtom()
+ if (this.options.ecmaVersion < 6 || !this.eat(tt.eq)) return left
+ var node = this.startNodeAt(startPos, startLoc)
+ node.left = left
+ node.right = this.parseMaybeAssign()
+ return this.finishNode(node, "AssignmentPattern")
+}
+
+// Verify that a node is an lval — something that can be assigned
+// to.
+
+pp$2.checkLVal = function(expr, isBinding, checkClashes) {
+ var this$1 = this;
+
+ switch (expr.type) {
+ case "Identifier":
+ if (this.strict && this.reservedWordsStrictBind.test(expr.name))
+ this.raiseRecoverable(expr.start, (isBinding ? "Binding " : "Assigning to ") + expr.name + " in strict mode")
+ if (checkClashes) {
+ if (has(checkClashes, expr.name))
+ this.raiseRecoverable(expr.start, "Argument name clash")
+ checkClashes[expr.name] = true
+ }
+ break
+
+ case "MemberExpression":
+ if (isBinding) this.raiseRecoverable(expr.start, (isBinding ? "Binding" : "Assigning to") + " member expression")
+ break
+
+ case "ObjectPattern":
+ for (var i = 0; i < expr.properties.length; i++)
+ this$1.checkLVal(expr.properties[i].value, isBinding, checkClashes)
+ break
+
+ case "ArrayPattern":
+ for (var i$1 = 0; i$1 < expr.elements.length; i$1++) {
+ var elem = expr.elements[i$1]
+ if (elem) this$1.checkLVal(elem, isBinding, checkClashes)
+ }
+ break
+
+ case "AssignmentPattern":
+ this.checkLVal(expr.left, isBinding, checkClashes)
+ break
+
+ case "RestElement":
+ this.checkLVal(expr.argument, isBinding, checkClashes)
+ break
+
+ case "ParenthesizedExpression":
+ this.checkLVal(expr.expression, isBinding, checkClashes)
+ break
+
+ default:
+ this.raise(expr.start, (isBinding ? "Binding" : "Assigning to") + " rvalue")
+ }
+}
+
+var pp$3 = Parser.prototype
+
+// Check if property name clashes with already added.
+// Object/class getters and setters are not allowed to clash —
+// either with each other or with an init property — and in
+// strict mode, init properties are also not allowed to be repeated.
+
+pp$3.checkPropClash = function(prop, propHash) {
+ if (this.options.ecmaVersion >= 6 && (prop.computed || prop.method || prop.shorthand))
+ return
+ var key = prop.key;
+ var name
+ switch (key.type) {
+ case "Identifier": name = key.name; break
+ case "Literal": name = String(key.value); break
+ default: return
+ }
+ var kind = prop.kind;
+ if (this.options.ecmaVersion >= 6) {
+ if (name === "__proto__" && kind === "init") {
+ if (propHash.proto) this.raiseRecoverable(key.start, "Redefinition of __proto__ property")
+ propHash.proto = true
+ }
+ return
+ }
+ name = "$" + name
+ var other = propHash[name]
+ if (other) {
+ var isGetSet = kind !== "init"
+ if ((this.strict || isGetSet) && other[kind] || !(isGetSet ^ other.init))
+ this.raiseRecoverable(key.start, "Redefinition of property")
+ } else {
+ other = propHash[name] = {
+ init: false,
+ get: false,
+ set: false
+ }
+ }
+ other[kind] = true
+}
+
+// ### Expression parsing
+
+// These nest, from the most general expression type at the top to
+// 'atomic', nondivisible expression types at the bottom. Most of
+// the functions will simply let the function(s) below them parse,
+// and, *if* the syntactic construct they handle is present, wrap
+// the AST node that the inner parser gave them in another node.
+
+// Parse a full expression. The optional arguments are used to
+// forbid the `in` operator (in for loops initalization expressions)
+// and provide reference for storing '=' operator inside shorthand
+// property assignment in contexts where both object expression
+// and object pattern might appear (so it's possible to raise
+// delayed syntax error at correct position).
+
+pp$3.parseExpression = function(noIn, refDestructuringErrors) {
+ var this$1 = this;
+
+ var startPos = this.start, startLoc = this.startLoc
+ var expr = this.parseMaybeAssign(noIn, refDestructuringErrors)
+ if (this.type === tt.comma) {
+ var node = this.startNodeAt(startPos, startLoc)
+ node.expressions = [expr]
+ while (this.eat(tt.comma)) node.expressions.push(this$1.parseMaybeAssign(noIn, refDestructuringErrors))
+ return this.finishNode(node, "SequenceExpression")
+ }
+ return expr
+}
+
+// Parse an assignment expression. This includes applications of
+// operators like `+=`.
+
+pp$3.parseMaybeAssign = function(noIn, refDestructuringErrors, afterLeftParse) {
+ if (this.inGenerator && this.isContextual("yield")) return this.parseYield()
+
+ var ownDestructuringErrors = false
+ if (!refDestructuringErrors) {
+ refDestructuringErrors = new DestructuringErrors
+ ownDestructuringErrors = true
+ }
+ var startPos = this.start, startLoc = this.startLoc
+ if (this.type == tt.parenL || this.type == tt.name)
+ this.potentialArrowAt = this.start
+ var left = this.parseMaybeConditional(noIn, refDestructuringErrors)
+ if (afterLeftParse) left = afterLeftParse.call(this, left, startPos, startLoc)
+ if (this.type.isAssign) {
+ this.checkPatternErrors(refDestructuringErrors, true)
+ if (!ownDestructuringErrors) DestructuringErrors.call(refDestructuringErrors)
+ var node = this.startNodeAt(startPos, startLoc)
+ node.operator = this.value
+ node.left = this.type === tt.eq ? this.toAssignable(left) : left
+ refDestructuringErrors.shorthandAssign = 0 // reset because shorthand default was used correctly
+ this.checkLVal(left)
+ this.next()
+ node.right = this.parseMaybeAssign(noIn)
+ return this.finishNode(node, "AssignmentExpression")
+ } else {
+ if (ownDestructuringErrors) this.checkExpressionErrors(refDestructuringErrors, true)
+ }
+ return left
+}
+
+// Parse a ternary conditional (`?:`) operator.
+
+pp$3.parseMaybeConditional = function(noIn, refDestructuringErrors) {
+ var startPos = this.start, startLoc = this.startLoc
+ var expr = this.parseExprOps(noIn, refDestructuringErrors)
+ if (this.checkExpressionErrors(refDestructuringErrors)) return expr
+ if (this.eat(tt.question)) {
+ var node = this.startNodeAt(startPos, startLoc)
+ node.test = expr
+ node.consequent = this.parseMaybeAssign()
+ this.expect(tt.colon)
+ node.alternate = this.parseMaybeAssign(noIn)
+ return this.finishNode(node, "ConditionalExpression")
+ }
+ return expr
+}
+
+// Start the precedence parser.
+
+pp$3.parseExprOps = function(noIn, refDestructuringErrors) {
+ var startPos = this.start, startLoc = this.startLoc
+ var expr = this.parseMaybeUnary(refDestructuringErrors, false)
+ if (this.checkExpressionErrors(refDestructuringErrors)) return expr
+ return this.parseExprOp(expr, startPos, startLoc, -1, noIn)
+}
+
+// Parse binary operators with the operator precedence parsing
+// algorithm. `left` is the left-hand side of the operator.
+// `minPrec` provides context that allows the function to stop and
+// defer further parser to one of its callers when it encounters an
+// operator that has a lower precedence than the set it is parsing.
+
+pp$3.parseExprOp = function(left, leftStartPos, leftStartLoc, minPrec, noIn) {
+ var prec = this.type.binop
+ if (prec != null && (!noIn || this.type !== tt._in)) {
+ if (prec > minPrec) {
+ var logical = this.type === tt.logicalOR || this.type === tt.logicalAND
+ var op = this.value
+ this.next()
+ var startPos = this.start, startLoc = this.startLoc
+ var right = this.parseExprOp(this.parseMaybeUnary(null, false), startPos, startLoc, prec, noIn)
+ var node = this.buildBinary(leftStartPos, leftStartLoc, left, right, op, logical)
+ return this.parseExprOp(node, leftStartPos, leftStartLoc, minPrec, noIn)
+ }
+ }
+ return left
+}
+
+pp$3.buildBinary = function(startPos, startLoc, left, right, op, logical) {
+ var node = this.startNodeAt(startPos, startLoc)
+ node.left = left
+ node.operator = op
+ node.right = right
+ return this.finishNode(node, logical ? "LogicalExpression" : "BinaryExpression")
+}
+
+// Parse unary operators, both prefix and postfix.
+
+pp$3.parseMaybeUnary = function(refDestructuringErrors, sawUnary) {
+ var this$1 = this;
+
+ var startPos = this.start, startLoc = this.startLoc, expr
+ if (this.type.prefix) {
+ var node = this.startNode(), update = this.type === tt.incDec
+ node.operator = this.value
+ node.prefix = true
+ this.next()
+ node.argument = this.parseMaybeUnary(null, true)
+ this.checkExpressionErrors(refDestructuringErrors, true)
+ if (update) this.checkLVal(node.argument)
+ else if (this.strict && node.operator === "delete" &&
+ node.argument.type === "Identifier")
+ this.raiseRecoverable(node.start, "Deleting local variable in strict mode")
+ else sawUnary = true
+ expr = this.finishNode(node, update ? "UpdateExpression" : "UnaryExpression")
+ } else {
+ expr = this.parseExprSubscripts(refDestructuringErrors)
+ if (this.checkExpressionErrors(refDestructuringErrors)) return expr
+ while (this.type.postfix && !this.canInsertSemicolon()) {
+ var node$1 = this$1.startNodeAt(startPos, startLoc)
+ node$1.operator = this$1.value
+ node$1.prefix = false
+ node$1.argument = expr
+ this$1.checkLVal(expr)
+ this$1.next()
+ expr = this$1.finishNode(node$1, "UpdateExpression")
+ }
+ }
+
+ if (!sawUnary && this.eat(tt.starstar))
+ return this.buildBinary(startPos, startLoc, expr, this.parseMaybeUnary(null, false), "**", false)
+ else
+ return expr
+}
+
+// Parse call, dot, and `[]`-subscript expressions.
+
+pp$3.parseExprSubscripts = function(refDestructuringErrors) {
+ var startPos = this.start, startLoc = this.startLoc
+ var expr = this.parseExprAtom(refDestructuringErrors)
+ var skipArrowSubscripts = expr.type === "ArrowFunctionExpression" && this.input.slice(this.lastTokStart, this.lastTokEnd) !== ")"
+ if (this.checkExpressionErrors(refDestructuringErrors) || skipArrowSubscripts) return expr
+ return this.parseSubscripts(expr, startPos, startLoc)
+}
+
+pp$3.parseSubscripts = function(base, startPos, startLoc, noCalls) {
+ var this$1 = this;
+
+ for (;;) {
+ if (this$1.eat(tt.dot)) {
+ var node = this$1.startNodeAt(startPos, startLoc)
+ node.object = base
+ node.property = this$1.parseIdent(true)
+ node.computed = false
+ base = this$1.finishNode(node, "MemberExpression")
+ } else if (this$1.eat(tt.bracketL)) {
+ var node$1 = this$1.startNodeAt(startPos, startLoc)
+ node$1.object = base
+ node$1.property = this$1.parseExpression()
+ node$1.computed = true
+ this$1.expect(tt.bracketR)
+ base = this$1.finishNode(node$1, "MemberExpression")
+ } else if (!noCalls && this$1.eat(tt.parenL)) {
+ var node$2 = this$1.startNodeAt(startPos, startLoc)
+ node$2.callee = base
+ node$2.arguments = this$1.parseExprList(tt.parenR, false)
+ base = this$1.finishNode(node$2, "CallExpression")
+ } else if (this$1.type === tt.backQuote) {
+ var node$3 = this$1.startNodeAt(startPos, startLoc)
+ node$3.tag = base
+ node$3.quasi = this$1.parseTemplate()
+ base = this$1.finishNode(node$3, "TaggedTemplateExpression")
+ } else {
+ return base
+ }
+ }
+}
+
+// Parse an atomic expression — either a single token that is an
+// expression, an expression started by a keyword like `function` or
+// `new`, or an expression wrapped in punctuation like `()`, `[]`,
+// or `{}`.
+
+pp$3.parseExprAtom = function(refDestructuringErrors) {
+ var node, canBeArrow = this.potentialArrowAt == this.start
+ switch (this.type) {
+ case tt._super:
+ if (!this.inFunction)
+ this.raise(this.start, "'super' outside of function or class")
+
+ case tt._this:
+ var type = this.type === tt._this ? "ThisExpression" : "Super"
+ node = this.startNode()
+ this.next()
+ return this.finishNode(node, type)
+
+ case tt.name:
+ var startPos = this.start, startLoc = this.startLoc
+ var id = this.parseIdent(this.type !== tt.name)
+ if (canBeArrow && !this.canInsertSemicolon() && this.eat(tt.arrow))
+ return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), [id])
+ return id
+
+ case tt.regexp:
+ var value = this.value
+ node = this.parseLiteral(value.value)
+ node.regex = {pattern: value.pattern, flags: value.flags}
+ return node
+
+ case tt.num: case tt.string:
+ return this.parseLiteral(this.value)
+
+ case tt._null: case tt._true: case tt._false:
+ node = this.startNode()
+ node.value = this.type === tt._null ? null : this.type === tt._true
+ node.raw = this.type.keyword
+ this.next()
+ return this.finishNode(node, "Literal")
+
+ case tt.parenL:
+ return this.parseParenAndDistinguishExpression(canBeArrow)
+
+ case tt.bracketL:
+ node = this.startNode()
+ this.next()
+ node.elements = this.parseExprList(tt.bracketR, true, true, refDestructuringErrors)
+ return this.finishNode(node, "ArrayExpression")
+
+ case tt.braceL:
+ return this.parseObj(false, refDestructuringErrors)
+
+ case tt._function:
+ node = this.startNode()
+ this.next()
+ return this.parseFunction(node, false)
+
+ case tt._class:
+ return this.parseClass(this.startNode(), false)
+
+ case tt._new:
+ return this.parseNew()
+
+ case tt.backQuote:
+ return this.parseTemplate()
+
+ default:
+ this.unexpected()
+ }
+}
+
+pp$3.parseLiteral = function(value) {
+ var node = this.startNode()
+ node.value = value
+ node.raw = this.input.slice(this.start, this.end)
+ this.next()
+ return this.finishNode(node, "Literal")
+}
+
+pp$3.parseParenExpression = function() {
+ this.expect(tt.parenL)
+ var val = this.parseExpression()
+ this.expect(tt.parenR)
+ return val
+}
+
+pp$3.parseParenAndDistinguishExpression = function(canBeArrow) {
+ var this$1 = this;
+
+ var startPos = this.start, startLoc = this.startLoc, val
+ if (this.options.ecmaVersion >= 6) {
+ this.next()
+
+ var innerStartPos = this.start, innerStartLoc = this.startLoc
+ var exprList = [], first = true
+ var refDestructuringErrors = new DestructuringErrors, spreadStart, innerParenStart
+ while (this.type !== tt.parenR) {
+ first ? first = false : this$1.expect(tt.comma)
+ if (this$1.type === tt.ellipsis) {
+ spreadStart = this$1.start
+ exprList.push(this$1.parseParenItem(this$1.parseRest()))
+ break
+ } else {
+ if (this$1.type === tt.parenL && !innerParenStart) {
+ innerParenStart = this$1.start
+ }
+ exprList.push(this$1.parseMaybeAssign(false, refDestructuringErrors, this$1.parseParenItem))
+ }
+ }
+ var innerEndPos = this.start, innerEndLoc = this.startLoc
+ this.expect(tt.parenR)
+
+ if (canBeArrow && !this.canInsertSemicolon() && this.eat(tt.arrow)) {
+ this.checkPatternErrors(refDestructuringErrors, true)
+ if (innerParenStart) this.unexpected(innerParenStart)
+ return this.parseParenArrowList(startPos, startLoc, exprList)
+ }
+
+ if (!exprList.length) this.unexpected(this.lastTokStart)
+ if (spreadStart) this.unexpected(spreadStart)
+ this.checkExpressionErrors(refDestructuringErrors, true)
+
+ if (exprList.length > 1) {
+ val = this.startNodeAt(innerStartPos, innerStartLoc)
+ val.expressions = exprList
+ this.finishNodeAt(val, "SequenceExpression", innerEndPos, innerEndLoc)
+ } else {
+ val = exprList[0]
+ }
+ } else {
+ val = this.parseParenExpression()
+ }
+
+ if (this.options.preserveParens) {
+ var par = this.startNodeAt(startPos, startLoc)
+ par.expression = val
+ return this.finishNode(par, "ParenthesizedExpression")
+ } else {
+ return val
+ }
+}
+
+pp$3.parseParenItem = function(item) {
+ return item
+}
+
+pp$3.parseParenArrowList = function(startPos, startLoc, exprList) {
+ return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), exprList)
+}
+
+// New's precedence is slightly tricky. It must allow its argument to
+// be a `[]` or dot subscript expression, but not a call — at least,
+// not without wrapping it in parentheses. Thus, it uses the noCalls
+// argument to parseSubscripts to prevent it from consuming the
+// argument list.
+
+var empty$1 = []
+
+pp$3.parseNew = function() {
+ var node = this.startNode()
+ var meta = this.parseIdent(true)
+ if (this.options.ecmaVersion >= 6 && this.eat(tt.dot)) {
+ node.meta = meta
+ node.property = this.parseIdent(true)
+ if (node.property.name !== "target")
+ this.raiseRecoverable(node.property.start, "The only valid meta property for new is new.target")
+ if (!this.inFunction)
+ this.raiseRecoverable(node.start, "new.target can only be used in functions")
+ return this.finishNode(node, "MetaProperty")
+ }
+ var startPos = this.start, startLoc = this.startLoc
+ node.callee = this.parseSubscripts(this.parseExprAtom(), startPos, startLoc, true)
+ if (this.eat(tt.parenL)) node.arguments = this.parseExprList(tt.parenR, false)
+ else node.arguments = empty$1
+ return this.finishNode(node, "NewExpression")
+}
+
+// Parse template expression.
+
+pp$3.parseTemplateElement = function() {
+ var elem = this.startNode()
+ elem.value = {
+ raw: this.input.slice(this.start, this.end).replace(/\r\n?/g, '\n'),
+ cooked: this.value
+ }
+ this.next()
+ elem.tail = this.type === tt.backQuote
+ return this.finishNode(elem, "TemplateElement")
+}
+
+pp$3.parseTemplate = function() {
+ var this$1 = this;
+
+ var node = this.startNode()
+ this.next()
+ node.expressions = []
+ var curElt = this.parseTemplateElement()
+ node.quasis = [curElt]
+ while (!curElt.tail) {
+ this$1.expect(tt.dollarBraceL)
+ node.expressions.push(this$1.parseExpression())
+ this$1.expect(tt.braceR)
+ node.quasis.push(curElt = this$1.parseTemplateElement())
+ }
+ this.next()
+ return this.finishNode(node, "TemplateLiteral")
+}
+
+// Parse an object literal or binding pattern.
+
+pp$3.parseObj = function(isPattern, refDestructuringErrors) {
+ var this$1 = this;
+
+ var node = this.startNode(), first = true, propHash = {}
+ node.properties = []
+ this.next()
+ while (!this.eat(tt.braceR)) {
+ if (!first) {
+ this$1.expect(tt.comma)
+ if (this$1.afterTrailingComma(tt.braceR)) break
+ } else first = false
+
+ var prop = this$1.startNode(), isGenerator, startPos, startLoc
+ if (this$1.options.ecmaVersion >= 6) {
+ prop.method = false
+ prop.shorthand = false
+ if (isPattern || refDestructuringErrors) {
+ startPos = this$1.start
+ startLoc = this$1.startLoc
+ }
+ if (!isPattern)
+ isGenerator = this$1.eat(tt.star)
+ }
+ this$1.parsePropertyName(prop)
+ this$1.parsePropertyValue(prop, isPattern, isGenerator, startPos, startLoc, refDestructuringErrors)
+ this$1.checkPropClash(prop, propHash)
+ node.properties.push(this$1.finishNode(prop, "Property"))
+ }
+ return this.finishNode(node, isPattern ? "ObjectPattern" : "ObjectExpression")
+}
+
+pp$3.parsePropertyValue = function(prop, isPattern, isGenerator, startPos, startLoc, refDestructuringErrors) {
+ if (this.eat(tt.colon)) {
+ prop.value = isPattern ? this.parseMaybeDefault(this.start, this.startLoc) : this.parseMaybeAssign(false, refDestructuringErrors)
+ prop.kind = "init"
+ } else if (this.options.ecmaVersion >= 6 && this.type === tt.parenL) {
+ if (isPattern) this.unexpected()
+ prop.kind = "init"
+ prop.method = true
+ prop.value = this.parseMethod(isGenerator)
+ } else if (this.options.ecmaVersion >= 5 && !prop.computed && prop.key.type === "Identifier" &&
+ (prop.key.name === "get" || prop.key.name === "set") &&
+ (this.type != tt.comma && this.type != tt.braceR)) {
+ if (isGenerator || isPattern) this.unexpected()
+ prop.kind = prop.key.name
+ this.parsePropertyName(prop)
+ prop.value = this.parseMethod(false)
+ var paramCount = prop.kind === "get" ? 0 : 1
+ if (prop.value.params.length !== paramCount) {
+ var start = prop.value.start
+ if (prop.kind === "get")
+ this.raiseRecoverable(start, "getter should have no params")
+ else
+ this.raiseRecoverable(start, "setter should have exactly one param")
+ }
+ if (prop.kind === "set" && prop.value.params[0].type === "RestElement")
+ this.raiseRecoverable(prop.value.params[0].start, "Setter cannot use rest params")
+ } else if (this.options.ecmaVersion >= 6 && !prop.computed && prop.key.type === "Identifier") {
+ if (this.keywords.test(prop.key.name) ||
+ (this.strict ? this.reservedWordsStrictBind : this.reservedWords).test(prop.key.name) ||
+ (this.inGenerator && prop.key.name == "yield"))
+ this.raiseRecoverable(prop.key.start, "'" + prop.key.name + "' can not be used as shorthand property")
+ prop.kind = "init"
+ if (isPattern) {
+ prop.value = this.parseMaybeDefault(startPos, startLoc, prop.key)
+ } else if (this.type === tt.eq && refDestructuringErrors) {
+ if (!refDestructuringErrors.shorthandAssign)
+ refDestructuringErrors.shorthandAssign = this.start
+ prop.value = this.parseMaybeDefault(startPos, startLoc, prop.key)
+ } else {
+ prop.value = prop.key
+ }
+ prop.shorthand = true
+ } else this.unexpected()
+}
+
+pp$3.parsePropertyName = function(prop) {
+ if (this.options.ecmaVersion >= 6) {
+ if (this.eat(tt.bracketL)) {
+ prop.computed = true
+ prop.key = this.parseMaybeAssign()
+ this.expect(tt.bracketR)
+ return prop.key
+ } else {
+ prop.computed = false
+ }
+ }
+ return prop.key = this.type === tt.num || this.type === tt.string ? this.parseExprAtom() : this.parseIdent(true)
+}
+
+// Initialize empty function node.
+
+pp$3.initFunction = function(node) {
+ node.id = null
+ if (this.options.ecmaVersion >= 6) {
+ node.generator = false
+ node.expression = false
+ }
+}
+
+// Parse object or class method.
+
+pp$3.parseMethod = function(isGenerator) {
+ var node = this.startNode(), oldInGen = this.inGenerator
+ this.inGenerator = isGenerator
+ this.initFunction(node)
+ this.expect(tt.parenL)
+ node.params = this.parseBindingList(tt.parenR, false, false)
+ if (this.options.ecmaVersion >= 6)
+ node.generator = isGenerator
+ this.parseFunctionBody(node, false)
+ this.inGenerator = oldInGen
+ return this.finishNode(node, "FunctionExpression")
+}
+
+// Parse arrow function expression with given parameters.
+
+pp$3.parseArrowExpression = function(node, params) {
+ var oldInGen = this.inGenerator
+ this.inGenerator = false
+ this.initFunction(node)
+ node.params = this.toAssignableList(params, true)
+ this.parseFunctionBody(node, true)
+ this.inGenerator = oldInGen
+ return this.finishNode(node, "ArrowFunctionExpression")
+}
+
+// Parse function body and check parameters.
+
+pp$3.parseFunctionBody = function(node, isArrowFunction) {
+ var isExpression = isArrowFunction && this.type !== tt.braceL
+
+ if (isExpression) {
+ node.body = this.parseMaybeAssign()
+ node.expression = true
+ } else {
+ // Start a new scope with regard to labels and the `inFunction`
+ // flag (restore them to their old value afterwards).
+ var oldInFunc = this.inFunction, oldLabels = this.labels
+ this.inFunction = true; this.labels = []
+ node.body = this.parseBlock(true)
+ node.expression = false
+ this.inFunction = oldInFunc; this.labels = oldLabels
+ }
+
+ // If this is a strict mode function, verify that argument names
+ // are not repeated, and it does not try to bind the words `eval`
+ // or `arguments`.
+ var useStrict = (!isExpression && node.body.body.length && this.isUseStrict(node.body.body[0])) ? node.body.body[0] : null;
+ if (this.strict || useStrict) {
+ var oldStrict = this.strict
+ this.strict = true
+ if (node.id)
+ this.checkLVal(node.id, true)
+ this.checkParams(node, useStrict)
+ this.strict = oldStrict
+ } else if (isArrowFunction) {
+ this.checkParams(node, useStrict)
+ }
+}
+
+// Checks function params for various disallowed patterns such as using "eval"
+// or "arguments" and duplicate parameters.
+
+pp$3.checkParams = function(node, useStrict) {
+ var this$1 = this;
+
+ var nameHash = {}
+ for (var i = 0; i < node.params.length; i++) {
+ if (useStrict && this$1.options.ecmaVersion >= 7 && node.params[i].type !== "Identifier")
+ this$1.raiseRecoverable(useStrict.start, "Illegal 'use strict' directive in function with non-simple parameter list");
+ this$1.checkLVal(node.params[i], true, nameHash)
+ }
+}
+
+// Parses a comma-separated list of expressions, and returns them as
+// an array. `close` is the token type that ends the list, and
+// `allowEmpty` can be turned on to allow subsequent commas with
+// nothing in between them to be parsed as `null` (which is needed
+// for array literals).
+
+pp$3.parseExprList = function(close, allowTrailingComma, allowEmpty, refDestructuringErrors) {
+ var this$1 = this;
+
+ var elts = [], first = true
+ while (!this.eat(close)) {
+ if (!first) {
+ this$1.expect(tt.comma)
+ if (allowTrailingComma && this$1.afterTrailingComma(close)) break
+ } else first = false
+
+ var elt
+ if (allowEmpty && this$1.type === tt.comma)
+ elt = null
+ else if (this$1.type === tt.ellipsis) {
+ elt = this$1.parseSpread(refDestructuringErrors)
+ if (this$1.type === tt.comma && refDestructuringErrors && !refDestructuringErrors.trailingComma) {
+ refDestructuringErrors.trailingComma = this$1.lastTokStart
+ }
+ } else
+ elt = this$1.parseMaybeAssign(false, refDestructuringErrors)
+ elts.push(elt)
+ }
+ return elts
+}
+
+// Parse the next token as an identifier. If `liberal` is true (used
+// when parsing properties), it will also convert keywords into
+// identifiers.
+
+pp$3.parseIdent = function(liberal) {
+ var node = this.startNode()
+ if (liberal && this.options.allowReserved == "never") liberal = false
+ if (this.type === tt.name) {
+ if (!liberal && (this.strict ? this.reservedWordsStrict : this.reservedWords).test(this.value) &&
+ (this.options.ecmaVersion >= 6 ||
+ this.input.slice(this.start, this.end).indexOf("\\") == -1))
+ this.raiseRecoverable(this.start, "The keyword '" + this.value + "' is reserved")
+ if (!liberal && this.inGenerator && this.value === "yield")
+ this.raiseRecoverable(this.start, "Can not use 'yield' as identifier inside a generator")
+ node.name = this.value
+ } else if (liberal && this.type.keyword) {
+ node.name = this.type.keyword
+ } else {
+ this.unexpected()
+ }
+ this.next()
+ return this.finishNode(node, "Identifier")
+}
+
+// Parses yield expression inside generator.
+
+pp$3.parseYield = function() {
+ var node = this.startNode()
+ this.next()
+ if (this.type == tt.semi || this.canInsertSemicolon() || (this.type != tt.star && !this.type.startsExpr)) {
+ node.delegate = false
+ node.argument = null
+ } else {
+ node.delegate = this.eat(tt.star)
+ node.argument = this.parseMaybeAssign()
+ }
+ return this.finishNode(node, "YieldExpression")
+}
+
+var pp$4 = Parser.prototype
+
+// This function is used to raise exceptions on parse errors. It
+// takes an offset integer (into the current `input`) to indicate
+// the location of the error, attaches the position to the end
+// of the error message, and then raises a `SyntaxError` with that
+// message.
+
+pp$4.raise = function(pos, message) {
+ var loc = getLineInfo(this.input, pos)
+ message += " (" + loc.line + ":" + loc.column + ")"
+ var err = new SyntaxError(message)
+ err.pos = pos; err.loc = loc; err.raisedAt = this.pos
+ throw err
+}
+
+pp$4.raiseRecoverable = pp$4.raise
+
+pp$4.curPosition = function() {
+ if (this.options.locations) {
+ return new Position(this.curLine, this.pos - this.lineStart)
+ }
+}
+
+var Node = function Node(parser, pos, loc) {
+ this.type = ""
+ this.start = pos
+ this.end = 0
+ if (parser.options.locations)
+ this.loc = new SourceLocation(parser, loc)
+ if (parser.options.directSourceFile)
+ this.sourceFile = parser.options.directSourceFile
+ if (parser.options.ranges)
+ this.range = [pos, 0]
+};
+
+// Start an AST node, attaching a start offset.
+
+var pp$5 = Parser.prototype
+
+pp$5.startNode = function() {
+ return new Node(this, this.start, this.startLoc)
+}
+
+pp$5.startNodeAt = function(pos, loc) {
+ return new Node(this, pos, loc)
+}
+
+// Finish an AST node, adding `type` and `end` properties.
+
+function finishNodeAt(node, type, pos, loc) {
+ node.type = type
+ node.end = pos
+ if (this.options.locations)
+ node.loc.end = loc
+ if (this.options.ranges)
+ node.range[1] = pos
+ return node
+}
+
+pp$5.finishNode = function(node, type) {
+ return finishNodeAt.call(this, node, type, this.lastTokEnd, this.lastTokEndLoc)
+}
+
+// Finish node at given position
+
+pp$5.finishNodeAt = function(node, type, pos, loc) {
+ return finishNodeAt.call(this, node, type, pos, loc)
+}
+
+var TokContext = function TokContext(token, isExpr, preserveSpace, override) {
+ this.token = token
+ this.isExpr = !!isExpr
+ this.preserveSpace = !!preserveSpace
+ this.override = override
+};
+
+var types = {
+ b_stat: new TokContext("{", false),
+ b_expr: new TokContext("{", true),
+ b_tmpl: new TokContext("${", true),
+ p_stat: new TokContext("(", false),
+ p_expr: new TokContext("(", true),
+ q_tmpl: new TokContext("`", true, true, function (p) { return p.readTmplToken(); }),
+ f_expr: new TokContext("function", true)
+}
+
+var pp$6 = Parser.prototype
+
+pp$6.initialContext = function() {
+ return [types.b_stat]
+}
+
+pp$6.braceIsBlock = function(prevType) {
+ if (prevType === tt.colon) {
+ var parent = this.curContext()
+ if (parent === types.b_stat || parent === types.b_expr)
+ return !parent.isExpr
+ }
+ if (prevType === tt._return)
+ return lineBreak.test(this.input.slice(this.lastTokEnd, this.start))
+ if (prevType === tt._else || prevType === tt.semi || prevType === tt.eof || prevType === tt.parenR)
+ return true
+ if (prevType == tt.braceL)
+ return this.curContext() === types.b_stat
+ return !this.exprAllowed
+}
+
+pp$6.updateContext = function(prevType) {
+ var update, type = this.type
+ if (type.keyword && prevType == tt.dot)
+ this.exprAllowed = false
+ else if (update = type.updateContext)
+ update.call(this, prevType)
+ else
+ this.exprAllowed = type.beforeExpr
+}
+
+// Token-specific context update code
+
+tt.parenR.updateContext = tt.braceR.updateContext = function() {
+ if (this.context.length == 1) {
+ this.exprAllowed = true
+ return
+ }
+ var out = this.context.pop()
+ if (out === types.b_stat && this.curContext() === types.f_expr) {
+ this.context.pop()
+ this.exprAllowed = false
+ } else if (out === types.b_tmpl) {
+ this.exprAllowed = true
+ } else {
+ this.exprAllowed = !out.isExpr
+ }
+}
+
+tt.braceL.updateContext = function(prevType) {
+ this.context.push(this.braceIsBlock(prevType) ? types.b_stat : types.b_expr)
+ this.exprAllowed = true
+}
+
+tt.dollarBraceL.updateContext = function() {
+ this.context.push(types.b_tmpl)
+ this.exprAllowed = true
+}
+
+tt.parenL.updateContext = function(prevType) {
+ var statementParens = prevType === tt._if || prevType === tt._for || prevType === tt._with || prevType === tt._while
+ this.context.push(statementParens ? types.p_stat : types.p_expr)
+ this.exprAllowed = true
+}
+
+tt.incDec.updateContext = function() {
+ // tokExprAllowed stays unchanged
+}
+
+tt._function.updateContext = function(prevType) {
+ if (prevType.beforeExpr && prevType !== tt.semi && prevType !== tt._else &&
+ !((prevType === tt.colon || prevType === tt.braceL) && this.curContext() === types.b_stat))
+ this.context.push(types.f_expr)
+ this.exprAllowed = false
+}
+
+tt.backQuote.updateContext = function() {
+ if (this.curContext() === types.q_tmpl)
+ this.context.pop()
+ else
+ this.context.push(types.q_tmpl)
+ this.exprAllowed = false
+}
+
+// Object type used to represent tokens. Note that normally, tokens
+// simply exist as properties on the parser object. This is only
+// used for the onToken callback and the external tokenizer.
+
+var Token = function Token(p) {
+ this.type = p.type
+ this.value = p.value
+ this.start = p.start
+ this.end = p.end
+ if (p.options.locations)
+ this.loc = new SourceLocation(p, p.startLoc, p.endLoc)
+ if (p.options.ranges)
+ this.range = [p.start, p.end]
+};
+
+// ## Tokenizer
+
+var pp$7 = Parser.prototype
+
+// Are we running under Rhino?
+var isRhino = typeof Packages == "object" && Object.prototype.toString.call(Packages) == "[object JavaPackage]"
+
+// Move to the next token
+
+pp$7.next = function() {
+ if (this.options.onToken)
+ this.options.onToken(new Token(this))
+
+ this.lastTokEnd = this.end
+ this.lastTokStart = this.start
+ this.lastTokEndLoc = this.endLoc
+ this.lastTokStartLoc = this.startLoc
+ this.nextToken()
+}
+
+pp$7.getToken = function() {
+ this.next()
+ return new Token(this)
+}
+
+// If we're in an ES6 environment, make parsers iterable
+if (typeof Symbol !== "undefined")
+ pp$7[Symbol.iterator] = function () {
+ var self = this
+ return {next: function () {
+ var token = self.getToken()
+ return {
+ done: token.type === tt.eof,
+ value: token
+ }
+ }}
+ }
+
+// Toggle strict mode. Re-reads the next number or string to please
+// pedantic tests (`"use strict"; 010;` should fail).
+
+pp$7.setStrict = function(strict) {
+ var this$1 = this;
+
+ this.strict = strict
+ if (this.type !== tt.num && this.type !== tt.string) return
+ this.pos = this.start
+ if (this.options.locations) {
+ while (this.pos < this.lineStart) {
+ this$1.lineStart = this$1.input.lastIndexOf("\n", this$1.lineStart - 2) + 1
+ --this$1.curLine
+ }
+ }
+ this.nextToken()
+}
+
+pp$7.curContext = function() {
+ return this.context[this.context.length - 1]
+}
+
+// Read a single token, updating the parser object's token-related
+// properties.
+
+pp$7.nextToken = function() {
+ var curContext = this.curContext()
+ if (!curContext || !curContext.preserveSpace) this.skipSpace()
+
+ this.start = this.pos
+ if (this.options.locations) this.startLoc = this.curPosition()
+ if (this.pos >= this.input.length) return this.finishToken(tt.eof)
+
+ if (curContext.override) return curContext.override(this)
+ else this.readToken(this.fullCharCodeAtPos())
+}
+
+pp$7.readToken = function(code) {
+ // Identifier or keyword. '\uXXXX' sequences are allowed in
+ // identifiers, so '\' also dispatches to that.
+ if (isIdentifierStart(code, this.options.ecmaVersion >= 6) || code === 92 /* '\' */)
+ return this.readWord()
+
+ return this.getTokenFromCode(code)
+}
+
+pp$7.fullCharCodeAtPos = function() {
+ var code = this.input.charCodeAt(this.pos)
+ if (code <= 0xd7ff || code >= 0xe000) return code
+ var next = this.input.charCodeAt(this.pos + 1)
+ return (code << 10) + next - 0x35fdc00
+}
+
+pp$7.skipBlockComment = function() {
+ var this$1 = this;
+
+ var startLoc = this.options.onComment && this.curPosition()
+ var start = this.pos, end = this.input.indexOf("*/", this.pos += 2)
+ if (end === -1) this.raise(this.pos - 2, "Unterminated comment")
+ this.pos = end + 2
+ if (this.options.locations) {
+ lineBreakG.lastIndex = start
+ var match
+ while ((match = lineBreakG.exec(this.input)) && match.index < this.pos) {
+ ++this$1.curLine
+ this$1.lineStart = match.index + match[0].length
+ }
+ }
+ if (this.options.onComment)
+ this.options.onComment(true, this.input.slice(start + 2, end), start, this.pos,
+ startLoc, this.curPosition())
+}
+
+pp$7.skipLineComment = function(startSkip) {
+ var this$1 = this;
+
+ var start = this.pos
+ var startLoc = this.options.onComment && this.curPosition()
+ var ch = this.input.charCodeAt(this.pos+=startSkip)
+ while (this.pos < this.input.length && ch !== 10 && ch !== 13 && ch !== 8232 && ch !== 8233) {
+ ++this$1.pos
+ ch = this$1.input.charCodeAt(this$1.pos)
+ }
+ if (this.options.onComment)
+ this.options.onComment(false, this.input.slice(start + startSkip, this.pos), start, this.pos,
+ startLoc, this.curPosition())
+}
+
+// Called at the start of the parse and after every token. Skips
+// whitespace and comments, and.
+
+pp$7.skipSpace = function() {
+ var this$1 = this;
+
+ loop: while (this.pos < this.input.length) {
+ var ch = this$1.input.charCodeAt(this$1.pos)
+ switch (ch) {
+ case 32: case 160: // ' '
+ ++this$1.pos
+ break
+ case 13:
+ if (this$1.input.charCodeAt(this$1.pos + 1) === 10) {
+ ++this$1.pos
+ }
+ case 10: case 8232: case 8233:
+ ++this$1.pos
+ if (this$1.options.locations) {
+ ++this$1.curLine
+ this$1.lineStart = this$1.pos
+ }
+ break
+ case 47: // '/'
+ switch (this$1.input.charCodeAt(this$1.pos + 1)) {
+ case 42: // '*'
+ this$1.skipBlockComment()
+ break
+ case 47:
+ this$1.skipLineComment(2)
+ break
+ default:
+ break loop
+ }
+ break
+ default:
+ if (ch > 8 && ch < 14 || ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch))) {
+ ++this$1.pos
+ } else {
+ break loop
+ }
+ }
+ }
+}
+
+// Called at the end of every token. Sets `end`, `val`, and
+// maintains `context` and `exprAllowed`, and skips the space after
+// the token, so that the next one's `start` will point at the
+// right position.
+
+pp$7.finishToken = function(type, val) {
+ this.end = this.pos
+ if (this.options.locations) this.endLoc = this.curPosition()
+ var prevType = this.type
+ this.type = type
+ this.value = val
+
+ this.updateContext(prevType)
+}
+
+// ### Token reading
+
+// This is the function that is called to fetch the next token. It
+// is somewhat obscure, because it works in character codes rather
+// than characters, and because operator parsing has been inlined
+// into it.
+//
+// All in the name of speed.
+//
+pp$7.readToken_dot = function() {
+ var next = this.input.charCodeAt(this.pos + 1)
+ if (next >= 48 && next <= 57) return this.readNumber(true)
+ var next2 = this.input.charCodeAt(this.pos + 2)
+ if (this.options.ecmaVersion >= 6 && next === 46 && next2 === 46) { // 46 = dot '.'
+ this.pos += 3
+ return this.finishToken(tt.ellipsis)
+ } else {
+ ++this.pos
+ return this.finishToken(tt.dot)
+ }
+}
+
+pp$7.readToken_slash = function() { // '/'
+ var next = this.input.charCodeAt(this.pos + 1)
+ if (this.exprAllowed) {++this.pos; return this.readRegexp()}
+ if (next === 61) return this.finishOp(tt.assign, 2)
+ return this.finishOp(tt.slash, 1)
+}
+
+pp$7.readToken_mult_modulo_exp = function(code) { // '%*'
+ var next = this.input.charCodeAt(this.pos + 1)
+ var size = 1
+ var tokentype = code === 42 ? tt.star : tt.modulo
+
+ // exponentiation operator ** and **=
+ if (this.options.ecmaVersion >= 7 && next === 42) {
+ ++size
+ tokentype = tt.starstar
+ next = this.input.charCodeAt(this.pos + 2)
+ }
+
+ if (next === 61) return this.finishOp(tt.assign, size + 1)
+ return this.finishOp(tokentype, size)
+}
+
+pp$7.readToken_pipe_amp = function(code) { // '|&'
+ var next = this.input.charCodeAt(this.pos + 1)
+ if (next === code) return this.finishOp(code === 124 ? tt.logicalOR : tt.logicalAND, 2)
+ if (next === 61) return this.finishOp(tt.assign, 2)
+ return this.finishOp(code === 124 ? tt.bitwiseOR : tt.bitwiseAND, 1)
+}
+
+pp$7.readToken_caret = function() { // '^'
+ var next = this.input.charCodeAt(this.pos + 1)
+ if (next === 61) return this.finishOp(tt.assign, 2)
+ return this.finishOp(tt.bitwiseXOR, 1)
+}
+
+pp$7.readToken_plus_min = function(code) { // '+-'
+ var next = this.input.charCodeAt(this.pos + 1)
+ if (next === code) {
+ if (next == 45 && this.input.charCodeAt(this.pos + 2) == 62 &&
+ lineBreak.test(this.input.slice(this.lastTokEnd, this.pos))) {
+ // A `-->` line comment
+ this.skipLineComment(3)
+ this.skipSpace()
+ return this.nextToken()
+ }
+ return this.finishOp(tt.incDec, 2)
+ }
+ if (next === 61) return this.finishOp(tt.assign, 2)
+ return this.finishOp(tt.plusMin, 1)
+}
+
+pp$7.readToken_lt_gt = function(code) { // '<>'
+ var next = this.input.charCodeAt(this.pos + 1)
+ var size = 1
+ if (next === code) {
+ size = code === 62 && this.input.charCodeAt(this.pos + 2) === 62 ? 3 : 2
+ if (this.input.charCodeAt(this.pos + size) === 61) return this.finishOp(tt.assign, size + 1)
+ return this.finishOp(tt.bitShift, size)
+ }
+ if (next == 33 && code == 60 && this.input.charCodeAt(this.pos + 2) == 45 &&
+ this.input.charCodeAt(this.pos + 3) == 45) {
+ if (this.inModule) this.unexpected()
+ // `` line comment
+ this.skipLineComment(3)
+ this.skipSpace()
+ return this.nextToken()
+ }
+ return this.finishOp(tt.incDec, 2)
+ }
+ if (next === 61) return this.finishOp(tt.assign, 2)
+ return this.finishOp(tt.plusMin, 1)
+ }
+
+ pp$7.readToken_lt_gt = function(code) { // '<>'
+ var next = this.input.charCodeAt(this.pos + 1)
+ var size = 1
+ if (next === code) {
+ size = code === 62 && this.input.charCodeAt(this.pos + 2) === 62 ? 3 : 2
+ if (this.input.charCodeAt(this.pos + size) === 61) return this.finishOp(tt.assign, size + 1)
+ return this.finishOp(tt.bitShift, size)
+ }
+ if (next == 33 && code == 60 && this.input.charCodeAt(this.pos + 2) == 45 &&
+ this.input.charCodeAt(this.pos + 3) == 45) {
+ if (this.inModule) this.unexpected()
+ // `` line comment
+ this.skipLineComment(3)
+ this.skipSpace()
+ return this.nextToken()
+ }
+ return this.finishOp(tt.incDec, 2)
+ }
+ if (next === 61) return this.finishOp(tt.assign, 2)
+ return this.finishOp(tt.plusMin, 1)
+}
+
+pp.readToken_lt_gt = function(code) { // '<>'
+ let next = this.input.charCodeAt(this.pos + 1)
+ let size = 1
+ if (next === code) {
+ size = code === 62 && this.input.charCodeAt(this.pos + 2) === 62 ? 3 : 2
+ if (this.input.charCodeAt(this.pos + size) === 61) return this.finishOp(tt.assign, size + 1)
+ return this.finishOp(tt.bitShift, size)
+ }
+ if (next == 33 && code == 60 && this.input.charCodeAt(this.pos + 2) == 45 &&
+ this.input.charCodeAt(this.pos + 3) == 45) {
+ if (this.inModule) this.unexpected()
+ // `
+
+### anyTypeAnnotation
+```javascript
+t.anyTypeAnnotation()
+```
+
+See also `t.isAnyTypeAnnotation(node, opts)` and `t.assertAnyTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### arrayExpression
+```javascript
+t.arrayExpression(elements)
+```
+
+See also `t.isArrayExpression(node, opts)` and `t.assertArrayExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `elements`: `Array` (default: `[]`)
+
+---
+
+### arrayPattern
+```javascript
+t.arrayPattern(elements, typeAnnotation)
+```
+
+See also `t.isArrayPattern(node, opts)` and `t.assertArrayPattern(node, opts)`.
+
+Aliases: `Pattern`, `LVal`
+
+ - `elements`: `Array` (required)
+ - `typeAnnotation` (required)
+ - `decorators`: `Array` (default: `null`)
+
+---
+
+### arrayTypeAnnotation
+```javascript
+t.arrayTypeAnnotation(elementType)
+```
+
+See also `t.isArrayTypeAnnotation(node, opts)` and `t.assertArrayTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `elementType` (required)
+
+---
+
+### arrowFunctionExpression
+```javascript
+t.arrowFunctionExpression(params, body, async)
+```
+
+See also `t.isArrowFunctionExpression(node, opts)` and `t.assertArrowFunctionExpression(node, opts)`.
+
+Aliases: `Scopable`, `Function`, `BlockParent`, `FunctionParent`, `Expression`, `Pureish`
+
+ - `params`: `Array` (required)
+ - `body`: `BlockStatement | Expression` (required)
+ - `async`: `boolean` (default: `false`)
+ - `returnType` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### assignmentExpression
+```javascript
+t.assignmentExpression(operator, left, right)
+```
+
+See also `t.isAssignmentExpression(node, opts)` and `t.assertAssignmentExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `operator`: `string` (required)
+ - `left`: `LVal` (required)
+ - `right`: `Expression` (required)
+
+---
+
+### assignmentPattern
+```javascript
+t.assignmentPattern(left, right)
+```
+
+See also `t.isAssignmentPattern(node, opts)` and `t.assertAssignmentPattern(node, opts)`.
+
+Aliases: `Pattern`, `LVal`
+
+ - `left`: `Identifier` (required)
+ - `right`: `Expression` (required)
+ - `decorators`: `Array` (default: `null`)
+
+---
+
+### awaitExpression
+```javascript
+t.awaitExpression(argument)
+```
+
+See also `t.isAwaitExpression(node, opts)` and `t.assertAwaitExpression(node, opts)`.
+
+Aliases: `Expression`, `Terminatorless`
+
+ - `argument`: `Expression` (required)
+
+---
+
+### binaryExpression
+```javascript
+t.binaryExpression(operator, left, right)
+```
+
+See also `t.isBinaryExpression(node, opts)` and `t.assertBinaryExpression(node, opts)`.
+
+Aliases: `Binary`, `Expression`
+
+ - `operator`: `'+' | '-' | '/' | '%' | '*' | '**' | '&' | '|' | '>>' | '>>>' | '<<' | '^' | '==' | '===' | '!=' | '!==' | 'in' | 'instanceof' | '>' | '<' | '>=' | '<='` (required)
+ - `left`: `Expression` (required)
+ - `right`: `Expression` (required)
+
+---
+
+### bindExpression
+```javascript
+t.bindExpression(object, callee)
+```
+
+See also `t.isBindExpression(node, opts)` and `t.assertBindExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `object` (required)
+ - `callee` (required)
+
+---
+
+### blockStatement
+```javascript
+t.blockStatement(body, directives)
+```
+
+See also `t.isBlockStatement(node, opts)` and `t.assertBlockStatement(node, opts)`.
+
+Aliases: `Scopable`, `BlockParent`, `Block`, `Statement`
+
+ - `body`: `Array` (required)
+ - `directives`: `Array` (default: `[]`)
+
+---
+
+### booleanLiteral
+```javascript
+t.booleanLiteral(value)
+```
+
+See also `t.isBooleanLiteral(node, opts)` and `t.assertBooleanLiteral(node, opts)`.
+
+Aliases: `Expression`, `Pureish`, `Literal`, `Immutable`
+
+ - `value`: `boolean` (required)
+
+---
+
+### booleanLiteralTypeAnnotation
+```javascript
+t.booleanLiteralTypeAnnotation()
+```
+
+See also `t.isBooleanLiteralTypeAnnotation(node, opts)` and `t.assertBooleanLiteralTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+
+---
+
+### booleanTypeAnnotation
+```javascript
+t.booleanTypeAnnotation()
+```
+
+See also `t.isBooleanTypeAnnotation(node, opts)` and `t.assertBooleanTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### breakStatement
+```javascript
+t.breakStatement(label)
+```
+
+See also `t.isBreakStatement(node, opts)` and `t.assertBreakStatement(node, opts)`.
+
+Aliases: `Statement`, `Terminatorless`, `CompletionStatement`
+
+ - `label`: `Identifier` (default: `null`)
+
+---
+
+### callExpression
+```javascript
+t.callExpression(callee, arguments)
+```
+
+See also `t.isCallExpression(node, opts)` and `t.assertCallExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `callee`: `Expression` (required)
+ - `arguments`: `Array` (required)
+
+---
+
+### catchClause
+```javascript
+t.catchClause(param, body)
+```
+
+See also `t.isCatchClause(node, opts)` and `t.assertCatchClause(node, opts)`.
+
+Aliases: `Scopable`
+
+ - `param`: `Identifier` (required)
+ - `body`: `BlockStatement` (required)
+
+---
+
+### classBody
+```javascript
+t.classBody(body)
+```
+
+See also `t.isClassBody(node, opts)` and `t.assertClassBody(node, opts)`.
+
+ - `body`: `Array` (required)
+
+---
+
+### classDeclaration
+```javascript
+t.classDeclaration(id, superClass, body, decorators)
+```
+
+See also `t.isClassDeclaration(node, opts)` and `t.assertClassDeclaration(node, opts)`.
+
+Aliases: `Scopable`, `Class`, `Statement`, `Declaration`, `Pureish`
+
+ - `id`: `Identifier` (required)
+ - `superClass`: `Expression` (default: `null`)
+ - `body`: `ClassBody` (required)
+ - `decorators`: `Array` (required)
+ - `implements` (default: `null`)
+ - `mixins` (default: `null`)
+ - `superTypeParameters` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### classExpression
+```javascript
+t.classExpression(id, superClass, body, decorators)
+```
+
+See also `t.isClassExpression(node, opts)` and `t.assertClassExpression(node, opts)`.
+
+Aliases: `Scopable`, `Class`, `Expression`, `Pureish`
+
+ - `id`: `Identifier` (default: `null`)
+ - `superClass`: `Expression` (default: `null`)
+ - `body`: `ClassBody` (required)
+ - `decorators`: `Array` (required)
+ - `implements` (default: `null`)
+ - `mixins` (default: `null`)
+ - `superTypeParameters` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### classImplements
+```javascript
+t.classImplements(id, typeParameters)
+```
+
+See also `t.isClassImplements(node, opts)` and `t.assertClassImplements(node, opts)`.
+
+Aliases: `Flow`
+
+ - `id` (required)
+ - `typeParameters` (required)
+
+---
+
+### classMethod
+```javascript
+t.classMethod(kind, key, params, body, computed, static)
+```
+
+See also `t.isClassMethod(node, opts)` and `t.assertClassMethod(node, opts)`.
+
+Aliases: `Function`, `Scopable`, `BlockParent`, `FunctionParent`, `Method`
+
+ - `kind`: `"get" | "set" | "method" | "constructor"` (default: `'method'`)
+ - `key`if computed then `Expression` else `Identifier | Literal` (required)
+ - `params`: `Array` (required)
+ - `body`: `BlockStatement` (required)
+ - `computed`: `boolean` (default: `false`)
+ - `static`: `boolean` (default: `false`)
+ - `async`: `boolean` (default: `false`)
+ - `decorators` (default: `null`)
+ - `generator`: `boolean` (default: `false`)
+ - `returnType` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### classProperty
+```javascript
+t.classProperty(key, value, typeAnnotation, decorators, computed)
+```
+
+See also `t.isClassProperty(node, opts)` and `t.assertClassProperty(node, opts)`.
+
+Aliases: `Property`
+
+ - `key` (required)
+ - `value` (required)
+ - `typeAnnotation` (required)
+ - `decorators` (required)
+ - `computed`: `boolean` (default: `false`)
+
+---
+
+### conditionalExpression
+```javascript
+t.conditionalExpression(test, consequent, alternate)
+```
+
+See also `t.isConditionalExpression(node, opts)` and `t.assertConditionalExpression(node, opts)`.
+
+Aliases: `Expression`, `Conditional`
+
+ - `test`: `Expression` (required)
+ - `consequent`: `Expression` (required)
+ - `alternate`: `Expression` (required)
+
+---
+
+### continueStatement
+```javascript
+t.continueStatement(label)
+```
+
+See also `t.isContinueStatement(node, opts)` and `t.assertContinueStatement(node, opts)`.
+
+Aliases: `Statement`, `Terminatorless`, `CompletionStatement`
+
+ - `label`: `Identifier` (default: `null`)
+
+---
+
+### debuggerStatement
+```javascript
+t.debuggerStatement()
+```
+
+See also `t.isDebuggerStatement(node, opts)` and `t.assertDebuggerStatement(node, opts)`.
+
+Aliases: `Statement`
+
+
+---
+
+### declareClass
+```javascript
+t.declareClass(id, typeParameters, extends, body)
+```
+
+See also `t.isDeclareClass(node, opts)` and `t.assertDeclareClass(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+ - `typeParameters` (required)
+ - `extends` (required)
+ - `body` (required)
+
+---
+
+### declareFunction
+```javascript
+t.declareFunction(id)
+```
+
+See also `t.isDeclareFunction(node, opts)` and `t.assertDeclareFunction(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+
+---
+
+### declareInterface
+```javascript
+t.declareInterface(id, typeParameters, extends, body)
+```
+
+See also `t.isDeclareInterface(node, opts)` and `t.assertDeclareInterface(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+ - `typeParameters` (required)
+ - `extends` (required)
+ - `body` (required)
+
+---
+
+### declareModule
+```javascript
+t.declareModule(id, body)
+```
+
+See also `t.isDeclareModule(node, opts)` and `t.assertDeclareModule(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+ - `body` (required)
+
+---
+
+### declareModuleExports
+```javascript
+t.declareModuleExports(typeAnnotation)
+```
+
+See also `t.isDeclareModuleExports(node, opts)` and `t.assertDeclareModuleExports(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `typeAnnotation` (required)
+
+---
+
+### declareTypeAlias
+```javascript
+t.declareTypeAlias(id, typeParameters, right)
+```
+
+See also `t.isDeclareTypeAlias(node, opts)` and `t.assertDeclareTypeAlias(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+ - `typeParameters` (required)
+ - `right` (required)
+
+---
+
+### declareVariable
+```javascript
+t.declareVariable(id)
+```
+
+See also `t.isDeclareVariable(node, opts)` and `t.assertDeclareVariable(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+
+---
+
+### decorator
+```javascript
+t.decorator(expression)
+```
+
+See also `t.isDecorator(node, opts)` and `t.assertDecorator(node, opts)`.
+
+ - `expression`: `Expression` (required)
+
+---
+
+### directive
+```javascript
+t.directive(value)
+```
+
+See also `t.isDirective(node, opts)` and `t.assertDirective(node, opts)`.
+
+ - `value`: `DirectiveLiteral` (required)
+
+---
+
+### directiveLiteral
+```javascript
+t.directiveLiteral(value)
+```
+
+See also `t.isDirectiveLiteral(node, opts)` and `t.assertDirectiveLiteral(node, opts)`.
+
+ - `value`: `string` (required)
+
+---
+
+### doExpression
+```javascript
+t.doExpression(body)
+```
+
+See also `t.isDoExpression(node, opts)` and `t.assertDoExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `body`: `BlockStatement` (required)
+
+---
+
+### doWhileStatement
+```javascript
+t.doWhileStatement(test, body)
+```
+
+See also `t.isDoWhileStatement(node, opts)` and `t.assertDoWhileStatement(node, opts)`.
+
+Aliases: `Statement`, `BlockParent`, `Loop`, `While`, `Scopable`
+
+ - `test`: `Expression` (required)
+ - `body`: `Statement` (required)
+
+---
+
+### emptyStatement
+```javascript
+t.emptyStatement()
+```
+
+See also `t.isEmptyStatement(node, opts)` and `t.assertEmptyStatement(node, opts)`.
+
+Aliases: `Statement`
+
+
+---
+
+### emptyTypeAnnotation
+```javascript
+t.emptyTypeAnnotation()
+```
+
+See also `t.isEmptyTypeAnnotation(node, opts)` and `t.assertEmptyTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### existentialTypeParam
+```javascript
+t.existentialTypeParam()
+```
+
+See also `t.isExistentialTypeParam(node, opts)` and `t.assertExistentialTypeParam(node, opts)`.
+
+Aliases: `Flow`
+
+
+---
+
+### exportAllDeclaration
+```javascript
+t.exportAllDeclaration(source)
+```
+
+See also `t.isExportAllDeclaration(node, opts)` and `t.assertExportAllDeclaration(node, opts)`.
+
+Aliases: `Statement`, `Declaration`, `ModuleDeclaration`, `ExportDeclaration`
+
+ - `source`: `StringLiteral` (required)
+
+---
+
+### exportDefaultDeclaration
+```javascript
+t.exportDefaultDeclaration(declaration)
+```
+
+See also `t.isExportDefaultDeclaration(node, opts)` and `t.assertExportDefaultDeclaration(node, opts)`.
+
+Aliases: `Statement`, `Declaration`, `ModuleDeclaration`, `ExportDeclaration`
+
+ - `declaration`: `FunctionDeclaration | ClassDeclaration | Expression` (required)
+
+---
+
+### exportDefaultSpecifier
+```javascript
+t.exportDefaultSpecifier(exported)
+```
+
+See also `t.isExportDefaultSpecifier(node, opts)` and `t.assertExportDefaultSpecifier(node, opts)`.
+
+Aliases: `ModuleSpecifier`
+
+ - `exported`: `Identifier` (required)
+
+---
+
+### exportNamedDeclaration
+```javascript
+t.exportNamedDeclaration(declaration, specifiers, source)
+```
+
+See also `t.isExportNamedDeclaration(node, opts)` and `t.assertExportNamedDeclaration(node, opts)`.
+
+Aliases: `Statement`, `Declaration`, `ModuleDeclaration`, `ExportDeclaration`
+
+ - `declaration`: `Declaration` (default: `null`)
+ - `specifiers`: `Array` (required)
+ - `source`: `StringLiteral` (default: `null`)
+
+---
+
+### exportNamespaceSpecifier
+```javascript
+t.exportNamespaceSpecifier(exported)
+```
+
+See also `t.isExportNamespaceSpecifier(node, opts)` and `t.assertExportNamespaceSpecifier(node, opts)`.
+
+Aliases: `ModuleSpecifier`
+
+ - `exported`: `Identifier` (required)
+
+---
+
+### exportSpecifier
+```javascript
+t.exportSpecifier(local, exported)
+```
+
+See also `t.isExportSpecifier(node, opts)` and `t.assertExportSpecifier(node, opts)`.
+
+Aliases: `ModuleSpecifier`
+
+ - `local`: `Identifier` (required)
+ - `exported`: `Identifier` (required)
+
+---
+
+### expressionStatement
+```javascript
+t.expressionStatement(expression)
+```
+
+See also `t.isExpressionStatement(node, opts)` and `t.assertExpressionStatement(node, opts)`.
+
+Aliases: `Statement`, `ExpressionWrapper`
+
+ - `expression`: `Expression` (required)
+
+---
+
+### file
+```javascript
+t.file(program, comments, tokens)
+```
+
+See also `t.isFile(node, opts)` and `t.assertFile(node, opts)`.
+
+ - `program`: `Program` (required)
+ - `comments` (required)
+ - `tokens` (required)
+
+---
+
+### forAwaitStatement
+```javascript
+t.forAwaitStatement(left, right, body)
+```
+
+See also `t.isForAwaitStatement(node, opts)` and `t.assertForAwaitStatement(node, opts)`.
+
+Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop`, `ForXStatement`
+
+ - `left`: `VariableDeclaration | LVal` (required)
+ - `right`: `Expression` (required)
+ - `body`: `Statement` (required)
+
+---
+
+### forInStatement
+```javascript
+t.forInStatement(left, right, body)
+```
+
+See also `t.isForInStatement(node, opts)` and `t.assertForInStatement(node, opts)`.
+
+Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop`, `ForXStatement`
+
+ - `left`: `VariableDeclaration | LVal` (required)
+ - `right`: `Expression` (required)
+ - `body`: `Statement` (required)
+
+---
+
+### forOfStatement
+```javascript
+t.forOfStatement(left, right, body)
+```
+
+See also `t.isForOfStatement(node, opts)` and `t.assertForOfStatement(node, opts)`.
+
+Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop`, `ForXStatement`
+
+ - `left`: `VariableDeclaration | LVal` (required)
+ - `right`: `Expression` (required)
+ - `body`: `Statement` (required)
+
+---
+
+### forStatement
+```javascript
+t.forStatement(init, test, update, body)
+```
+
+See also `t.isForStatement(node, opts)` and `t.assertForStatement(node, opts)`.
+
+Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop`
+
+ - `init`: `VariableDeclaration | Expression` (default: `null`)
+ - `test`: `Expression` (default: `null`)
+ - `update`: `Expression` (default: `null`)
+ - `body`: `Statement` (required)
+
+---
+
+### functionDeclaration
+```javascript
+t.functionDeclaration(id, params, body, generator, async)
+```
+
+See also `t.isFunctionDeclaration(node, opts)` and `t.assertFunctionDeclaration(node, opts)`.
+
+Aliases: `Scopable`, `Function`, `BlockParent`, `FunctionParent`, `Statement`, `Pureish`, `Declaration`
+
+ - `id`: `Identifier` (required)
+ - `params`: `Array` (required)
+ - `body`: `BlockStatement` (required)
+ - `generator`: `boolean` (default: `false`)
+ - `async`: `boolean` (default: `false`)
+ - `returnType` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### functionExpression
+```javascript
+t.functionExpression(id, params, body, generator, async)
+```
+
+See also `t.isFunctionExpression(node, opts)` and `t.assertFunctionExpression(node, opts)`.
+
+Aliases: `Scopable`, `Function`, `BlockParent`, `FunctionParent`, `Expression`, `Pureish`
+
+ - `id`: `Identifier` (default: `null`)
+ - `params`: `Array` (required)
+ - `body`: `BlockStatement` (required)
+ - `generator`: `boolean` (default: `false`)
+ - `async`: `boolean` (default: `false`)
+ - `returnType` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### functionTypeAnnotation
+```javascript
+t.functionTypeAnnotation(typeParameters, params, rest, returnType)
+```
+
+See also `t.isFunctionTypeAnnotation(node, opts)` and `t.assertFunctionTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `typeParameters` (required)
+ - `params` (required)
+ - `rest` (required)
+ - `returnType` (required)
+
+---
+
+### functionTypeParam
+```javascript
+t.functionTypeParam(name, typeAnnotation)
+```
+
+See also `t.isFunctionTypeParam(node, opts)` and `t.assertFunctionTypeParam(node, opts)`.
+
+Aliases: `Flow`
+
+ - `name` (required)
+ - `typeAnnotation` (required)
+
+---
+
+### genericTypeAnnotation
+```javascript
+t.genericTypeAnnotation(id, typeParameters)
+```
+
+See also `t.isGenericTypeAnnotation(node, opts)` and `t.assertGenericTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `id` (required)
+ - `typeParameters` (required)
+
+---
+
+### identifier
+```javascript
+t.identifier(name)
+```
+
+See also `t.isIdentifier(node, opts)` and `t.assertIdentifier(node, opts)`.
+
+Aliases: `Expression`, `LVal`
+
+ - `name``string` (required)
+ - `decorators`: `Array` (default: `null`)
+ - `typeAnnotation` (default: `null`)
+
+---
+
+### ifStatement
+```javascript
+t.ifStatement(test, consequent, alternate)
+```
+
+See also `t.isIfStatement(node, opts)` and `t.assertIfStatement(node, opts)`.
+
+Aliases: `Statement`, `Conditional`
+
+ - `test`: `Expression` (required)
+ - `consequent`: `Statement` (required)
+ - `alternate`: `Statement` (default: `null`)
+
+---
+
+### import
+```javascript
+t.import()
+```
+
+See also `t.isImport(node, opts)` and `t.assertImport(node, opts)`.
+
+Aliases: `Expression`
+
+
+---
+
+### importDeclaration
+```javascript
+t.importDeclaration(specifiers, source)
+```
+
+See also `t.isImportDeclaration(node, opts)` and `t.assertImportDeclaration(node, opts)`.
+
+Aliases: `Statement`, `Declaration`, `ModuleDeclaration`
+
+ - `specifiers`: `Array` (required)
+ - `source`: `StringLiteral` (required)
+
+---
+
+### importDefaultSpecifier
+```javascript
+t.importDefaultSpecifier(local)
+```
+
+See also `t.isImportDefaultSpecifier(node, opts)` and `t.assertImportDefaultSpecifier(node, opts)`.
+
+Aliases: `ModuleSpecifier`
+
+ - `local`: `Identifier` (required)
+
+---
+
+### importNamespaceSpecifier
+```javascript
+t.importNamespaceSpecifier(local)
+```
+
+See also `t.isImportNamespaceSpecifier(node, opts)` and `t.assertImportNamespaceSpecifier(node, opts)`.
+
+Aliases: `ModuleSpecifier`
+
+ - `local`: `Identifier` (required)
+
+---
+
+### importSpecifier
+```javascript
+t.importSpecifier(local, imported)
+```
+
+See also `t.isImportSpecifier(node, opts)` and `t.assertImportSpecifier(node, opts)`.
+
+Aliases: `ModuleSpecifier`
+
+ - `local`: `Identifier` (required)
+ - `imported`: `Identifier` (required)
+ - `importKind`: `null | 'type' | 'typeof'` (default: `null`)
+
+---
+
+### interfaceDeclaration
+```javascript
+t.interfaceDeclaration(id, typeParameters, extends, body)
+```
+
+See also `t.isInterfaceDeclaration(node, opts)` and `t.assertInterfaceDeclaration(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+ - `typeParameters` (required)
+ - `extends` (required)
+ - `body` (required)
+
+---
+
+### interfaceExtends
+```javascript
+t.interfaceExtends(id, typeParameters)
+```
+
+See also `t.isInterfaceExtends(node, opts)` and `t.assertInterfaceExtends(node, opts)`.
+
+Aliases: `Flow`
+
+ - `id` (required)
+ - `typeParameters` (required)
+
+---
+
+### intersectionTypeAnnotation
+```javascript
+t.intersectionTypeAnnotation(types)
+```
+
+See also `t.isIntersectionTypeAnnotation(node, opts)` and `t.assertIntersectionTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `types` (required)
+
+---
+
+### jSXAttribute
+```javascript
+t.jSXAttribute(name, value)
+```
+
+See also `t.isJSXAttribute(node, opts)` and `t.assertJSXAttribute(node, opts)`.
+
+Aliases: `JSX`, `Immutable`
+
+ - `name`: `JSXIdentifier | JSXNamespacedName` (required)
+ - `value`: `JSXElement | StringLiteral | JSXExpressionContainer` (default: `null`)
+
+---
+
+### jSXClosingElement
+```javascript
+t.jSXClosingElement(name)
+```
+
+See also `t.isJSXClosingElement(node, opts)` and `t.assertJSXClosingElement(node, opts)`.
+
+Aliases: `JSX`, `Immutable`
+
+ - `name`: `JSXIdentifier | JSXMemberExpression` (required)
+
+---
+
+### jSXElement
+```javascript
+t.jSXElement(openingElement, closingElement, children, selfClosing)
+```
+
+See also `t.isJSXElement(node, opts)` and `t.assertJSXElement(node, opts)`.
+
+Aliases: `JSX`, `Immutable`, `Expression`
+
+ - `openingElement`: `JSXOpeningElement` (required)
+ - `closingElement`: `JSXClosingElement` (default: `null`)
+ - `children`: `Array` (required)
+ - `selfClosing` (required)
+
+---
+
+### jSXEmptyExpression
+```javascript
+t.jSXEmptyExpression()
+```
+
+See also `t.isJSXEmptyExpression(node, opts)` and `t.assertJSXEmptyExpression(node, opts)`.
+
+Aliases: `JSX`, `Expression`
+
+
+---
+
+### jSXExpressionContainer
+```javascript
+t.jSXExpressionContainer(expression)
+```
+
+See also `t.isJSXExpressionContainer(node, opts)` and `t.assertJSXExpressionContainer(node, opts)`.
+
+Aliases: `JSX`, `Immutable`
+
+ - `expression`: `Expression` (required)
+
+---
+
+### jSXIdentifier
+```javascript
+t.jSXIdentifier(name)
+```
+
+See also `t.isJSXIdentifier(node, opts)` and `t.assertJSXIdentifier(node, opts)`.
+
+Aliases: `JSX`, `Expression`
+
+ - `name`: `string` (required)
+
+---
+
+### jSXMemberExpression
+```javascript
+t.jSXMemberExpression(object, property)
+```
+
+See also `t.isJSXMemberExpression(node, opts)` and `t.assertJSXMemberExpression(node, opts)`.
+
+Aliases: `JSX`, `Expression`
+
+ - `object`: `JSXMemberExpression | JSXIdentifier` (required)
+ - `property`: `JSXIdentifier` (required)
+
+---
+
+### jSXNamespacedName
+```javascript
+t.jSXNamespacedName(namespace, name)
+```
+
+See also `t.isJSXNamespacedName(node, opts)` and `t.assertJSXNamespacedName(node, opts)`.
+
+Aliases: `JSX`
+
+ - `namespace`: `JSXIdentifier` (required)
+ - `name`: `JSXIdentifier` (required)
+
+---
+
+### jSXOpeningElement
+```javascript
+t.jSXOpeningElement(name, attributes, selfClosing)
+```
+
+See also `t.isJSXOpeningElement(node, opts)` and `t.assertJSXOpeningElement(node, opts)`.
+
+Aliases: `JSX`, `Immutable`
+
+ - `name`: `JSXIdentifier | JSXMemberExpression` (required)
+ - `attributes`: `Array` (required)
+ - `selfClosing`: `boolean` (default: `false`)
+
+---
+
+### jSXSpreadAttribute
+```javascript
+t.jSXSpreadAttribute(argument)
+```
+
+See also `t.isJSXSpreadAttribute(node, opts)` and `t.assertJSXSpreadAttribute(node, opts)`.
+
+Aliases: `JSX`
+
+ - `argument`: `Expression` (required)
+
+---
+
+### jSXSpreadChild
+```javascript
+t.jSXSpreadChild(expression)
+```
+
+See also `t.isJSXSpreadChild(node, opts)` and `t.assertJSXSpreadChild(node, opts)`.
+
+Aliases: `JSX`, `Immutable`
+
+ - `expression`: `Expression` (required)
+
+---
+
+### jSXText
+```javascript
+t.jSXText(value)
+```
+
+See also `t.isJSXText(node, opts)` and `t.assertJSXText(node, opts)`.
+
+Aliases: `JSX`, `Immutable`
+
+ - `value`: `string` (required)
+
+---
+
+### labeledStatement
+```javascript
+t.labeledStatement(label, body)
+```
+
+See also `t.isLabeledStatement(node, opts)` and `t.assertLabeledStatement(node, opts)`.
+
+Aliases: `Statement`
+
+ - `label`: `Identifier` (required)
+ - `body`: `Statement` (required)
+
+---
+
+### logicalExpression
+```javascript
+t.logicalExpression(operator, left, right)
+```
+
+See also `t.isLogicalExpression(node, opts)` and `t.assertLogicalExpression(node, opts)`.
+
+Aliases: `Binary`, `Expression`
+
+ - `operator`: `'||' | '&&'` (required)
+ - `left`: `Expression` (required)
+ - `right`: `Expression` (required)
+
+---
+
+### memberExpression
+```javascript
+t.memberExpression(object, property, computed)
+```
+
+See also `t.isMemberExpression(node, opts)` and `t.assertMemberExpression(node, opts)`.
+
+Aliases: `Expression`, `LVal`
+
+ - `object`: `Expression` (required)
+ - `property`if computed then `Expression` else `Identifier` (required)
+ - `computed`: `boolean` (default: `false`)
+
+---
+
+### metaProperty
+```javascript
+t.metaProperty(meta, property)
+```
+
+See also `t.isMetaProperty(node, opts)` and `t.assertMetaProperty(node, opts)`.
+
+Aliases: `Expression`
+
+ - `meta`: `string` (required)
+ - `property`: `string` (required)
+
+---
+
+### mixedTypeAnnotation
+```javascript
+t.mixedTypeAnnotation()
+```
+
+See also `t.isMixedTypeAnnotation(node, opts)` and `t.assertMixedTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### newExpression
+```javascript
+t.newExpression(callee, arguments)
+```
+
+See also `t.isNewExpression(node, opts)` and `t.assertNewExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `callee`: `Expression` (required)
+ - `arguments`: `Array` (required)
+
+---
+
+### noop
+```javascript
+t.noop()
+```
+
+See also `t.isNoop(node, opts)` and `t.assertNoop(node, opts)`.
+
+
+---
+
+### nullLiteral
+```javascript
+t.nullLiteral()
+```
+
+See also `t.isNullLiteral(node, opts)` and `t.assertNullLiteral(node, opts)`.
+
+Aliases: `Expression`, `Pureish`, `Literal`, `Immutable`
+
+
+---
+
+### nullLiteralTypeAnnotation
+```javascript
+t.nullLiteralTypeAnnotation()
+```
+
+See also `t.isNullLiteralTypeAnnotation(node, opts)` and `t.assertNullLiteralTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### nullableTypeAnnotation
+```javascript
+t.nullableTypeAnnotation(typeAnnotation)
+```
+
+See also `t.isNullableTypeAnnotation(node, opts)` and `t.assertNullableTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `typeAnnotation` (required)
+
+---
+
+### numberTypeAnnotation
+```javascript
+t.numberTypeAnnotation()
+```
+
+See also `t.isNumberTypeAnnotation(node, opts)` and `t.assertNumberTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### numericLiteral
+```javascript
+t.numericLiteral(value)
+```
+
+See also `t.isNumericLiteral(node, opts)` and `t.assertNumericLiteral(node, opts)`.
+
+Aliases: `Expression`, `Pureish`, `Literal`, `Immutable`
+
+ - `value`: `number` (required)
+
+---
+
+### numericLiteralTypeAnnotation
+```javascript
+t.numericLiteralTypeAnnotation()
+```
+
+See also `t.isNumericLiteralTypeAnnotation(node, opts)` and `t.assertNumericLiteralTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+
+---
+
+### objectExpression
+```javascript
+t.objectExpression(properties)
+```
+
+See also `t.isObjectExpression(node, opts)` and `t.assertObjectExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `properties`: `Array` (required)
+
+---
+
+### objectMethod
+```javascript
+t.objectMethod(kind, key, params, body, computed)
+```
+
+See also `t.isObjectMethod(node, opts)` and `t.assertObjectMethod(node, opts)`.
+
+Aliases: `UserWhitespacable`, `Function`, `Scopable`, `BlockParent`, `FunctionParent`, `Method`, `ObjectMember`
+
+ - `kind`: `"method" | "get" | "set"` (default: `'method'`)
+ - `key`if computed then `Expression` else `Identifier | Literal` (required)
+ - `params` (required)
+ - `body`: `BlockStatement` (required)
+ - `computed`: `boolean` (default: `false`)
+ - `async`: `boolean` (default: `false`)
+ - `decorators`: `Array` (default: `null`)
+ - `generator`: `boolean` (default: `false`)
+ - `returnType` (default: `null`)
+ - `typeParameters` (default: `null`)
+
+---
+
+### objectPattern
+```javascript
+t.objectPattern(properties, typeAnnotation)
+```
+
+See also `t.isObjectPattern(node, opts)` and `t.assertObjectPattern(node, opts)`.
+
+Aliases: `Pattern`, `LVal`
+
+ - `properties`: `Array` (required)
+ - `typeAnnotation` (required)
+ - `decorators`: `Array` (default: `null`)
+
+---
+
+### objectProperty
+```javascript
+t.objectProperty(key, value, computed, shorthand, decorators)
+```
+
+See also `t.isObjectProperty(node, opts)` and `t.assertObjectProperty(node, opts)`.
+
+Aliases: `UserWhitespacable`, `Property`, `ObjectMember`
+
+ - `key`if computed then `Expression` else `Identifier | Literal` (required)
+ - `value`: `Expression` (required)
+ - `computed`: `boolean` (default: `false`)
+ - `shorthand`: `boolean` (default: `false`)
+ - `decorators`: `Array` (default: `null`)
+
+---
+
+### objectTypeAnnotation
+```javascript
+t.objectTypeAnnotation(properties, indexers, callProperties)
+```
+
+See also `t.isObjectTypeAnnotation(node, opts)` and `t.assertObjectTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `properties` (required)
+ - `indexers` (required)
+ - `callProperties` (required)
+
+---
+
+### objectTypeCallProperty
+```javascript
+t.objectTypeCallProperty(value)
+```
+
+See also `t.isObjectTypeCallProperty(node, opts)` and `t.assertObjectTypeCallProperty(node, opts)`.
+
+Aliases: `Flow`, `UserWhitespacable`
+
+ - `value` (required)
+
+---
+
+### objectTypeIndexer
+```javascript
+t.objectTypeIndexer(id, key, value)
+```
+
+See also `t.isObjectTypeIndexer(node, opts)` and `t.assertObjectTypeIndexer(node, opts)`.
+
+Aliases: `Flow`, `UserWhitespacable`
+
+ - `id` (required)
+ - `key` (required)
+ - `value` (required)
+
+---
+
+### objectTypeProperty
+```javascript
+t.objectTypeProperty(key, value)
+```
+
+See also `t.isObjectTypeProperty(node, opts)` and `t.assertObjectTypeProperty(node, opts)`.
+
+Aliases: `Flow`, `UserWhitespacable`
+
+ - `key` (required)
+ - `value` (required)
+
+---
+
+### parenthesizedExpression
+```javascript
+t.parenthesizedExpression(expression)
+```
+
+See also `t.isParenthesizedExpression(node, opts)` and `t.assertParenthesizedExpression(node, opts)`.
+
+Aliases: `Expression`, `ExpressionWrapper`
+
+ - `expression`: `Expression` (required)
+
+---
+
+### program
+```javascript
+t.program(body, directives)
+```
+
+See also `t.isProgram(node, opts)` and `t.assertProgram(node, opts)`.
+
+Aliases: `Scopable`, `BlockParent`, `Block`, `FunctionParent`
+
+ - `body`: `Array` (required)
+ - `directives`: `Array` (default: `[]`)
+
+---
+
+### qualifiedTypeIdentifier
+```javascript
+t.qualifiedTypeIdentifier(id, qualification)
+```
+
+See also `t.isQualifiedTypeIdentifier(node, opts)` and `t.assertQualifiedTypeIdentifier(node, opts)`.
+
+Aliases: `Flow`
+
+ - `id` (required)
+ - `qualification` (required)
+
+---
+
+### regExpLiteral
+```javascript
+t.regExpLiteral(pattern, flags)
+```
+
+See also `t.isRegExpLiteral(node, opts)` and `t.assertRegExpLiteral(node, opts)`.
+
+Aliases: `Expression`, `Literal`
+
+ - `pattern`: `string` (required)
+ - `flags`: `string` (default: `''`)
+
+---
+
+### restElement
+```javascript
+t.restElement(argument, typeAnnotation)
+```
+
+See also `t.isRestElement(node, opts)` and `t.assertRestElement(node, opts)`.
+
+Aliases: `LVal`
+
+ - `argument`: `LVal` (required)
+ - `typeAnnotation` (required)
+ - `decorators`: `Array` (default: `null`)
+
+---
+
+### restProperty
+```javascript
+t.restProperty(argument)
+```
+
+See also `t.isRestProperty(node, opts)` and `t.assertRestProperty(node, opts)`.
+
+Aliases: `UnaryLike`
+
+ - `argument`: `LVal` (required)
+
+---
+
+### returnStatement
+```javascript
+t.returnStatement(argument)
+```
+
+See also `t.isReturnStatement(node, opts)` and `t.assertReturnStatement(node, opts)`.
+
+Aliases: `Statement`, `Terminatorless`, `CompletionStatement`
+
+ - `argument`: `Expression` (default: `null`)
+
+---
+
+### sequenceExpression
+```javascript
+t.sequenceExpression(expressions)
+```
+
+See also `t.isSequenceExpression(node, opts)` and `t.assertSequenceExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `expressions`: `Array` (required)
+
+---
+
+### spreadElement
+```javascript
+t.spreadElement(argument)
+```
+
+See also `t.isSpreadElement(node, opts)` and `t.assertSpreadElement(node, opts)`.
+
+Aliases: `UnaryLike`
+
+ - `argument`: `Expression` (required)
+
+---
+
+### spreadProperty
+```javascript
+t.spreadProperty(argument)
+```
+
+See also `t.isSpreadProperty(node, opts)` and `t.assertSpreadProperty(node, opts)`.
+
+Aliases: `UnaryLike`
+
+ - `argument`: `Expression` (required)
+
+---
+
+### stringLiteral
+```javascript
+t.stringLiteral(value)
+```
+
+See also `t.isStringLiteral(node, opts)` and `t.assertStringLiteral(node, opts)`.
+
+Aliases: `Expression`, `Pureish`, `Literal`, `Immutable`
+
+ - `value`: `string` (required)
+
+---
+
+### stringLiteralTypeAnnotation
+```javascript
+t.stringLiteralTypeAnnotation()
+```
+
+See also `t.isStringLiteralTypeAnnotation(node, opts)` and `t.assertStringLiteralTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+
+---
+
+### stringTypeAnnotation
+```javascript
+t.stringTypeAnnotation()
+```
+
+See also `t.isStringTypeAnnotation(node, opts)` and `t.assertStringTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### super
+```javascript
+t.super()
+```
+
+See also `t.isSuper(node, opts)` and `t.assertSuper(node, opts)`.
+
+Aliases: `Expression`
+
+
+---
+
+### switchCase
+```javascript
+t.switchCase(test, consequent)
+```
+
+See also `t.isSwitchCase(node, opts)` and `t.assertSwitchCase(node, opts)`.
+
+ - `test`: `Expression` (default: `null`)
+ - `consequent`: `Array` (required)
+
+---
+
+### switchStatement
+```javascript
+t.switchStatement(discriminant, cases)
+```
+
+See also `t.isSwitchStatement(node, opts)` and `t.assertSwitchStatement(node, opts)`.
+
+Aliases: `Statement`, `BlockParent`, `Scopable`
+
+ - `discriminant`: `Expression` (required)
+ - `cases`: `Array` (required)
+
+---
+
+### taggedTemplateExpression
+```javascript
+t.taggedTemplateExpression(tag, quasi)
+```
+
+See also `t.isTaggedTemplateExpression(node, opts)` and `t.assertTaggedTemplateExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `tag`: `Expression` (required)
+ - `quasi`: `TemplateLiteral` (required)
+
+---
+
+### templateElement
+```javascript
+t.templateElement(value, tail)
+```
+
+See also `t.isTemplateElement(node, opts)` and `t.assertTemplateElement(node, opts)`.
+
+ - `value` (required)
+ - `tail`: `boolean` (default: `false`)
+
+---
+
+### templateLiteral
+```javascript
+t.templateLiteral(quasis, expressions)
+```
+
+See also `t.isTemplateLiteral(node, opts)` and `t.assertTemplateLiteral(node, opts)`.
+
+Aliases: `Expression`, `Literal`
+
+ - `quasis`: `Array` (required)
+ - `expressions`: `Array` (required)
+
+---
+
+### thisExpression
+```javascript
+t.thisExpression()
+```
+
+See also `t.isThisExpression(node, opts)` and `t.assertThisExpression(node, opts)`.
+
+Aliases: `Expression`
+
+
+---
+
+### thisTypeAnnotation
+```javascript
+t.thisTypeAnnotation()
+```
+
+See also `t.isThisTypeAnnotation(node, opts)` and `t.assertThisTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### throwStatement
+```javascript
+t.throwStatement(argument)
+```
+
+See also `t.isThrowStatement(node, opts)` and `t.assertThrowStatement(node, opts)`.
+
+Aliases: `Statement`, `Terminatorless`, `CompletionStatement`
+
+ - `argument`: `Expression` (required)
+
+---
+
+### tryStatement
+```javascript
+t.tryStatement(block, handler, finalizer)
+```
+
+See also `t.isTryStatement(node, opts)` and `t.assertTryStatement(node, opts)`.
+
+Aliases: `Statement`
+
+ - `block` (required)
+ - `handler` (default: `null`)
+ - `finalizer`: `BlockStatement` (default: `null`)
+ - `body`: `BlockStatement` (default: `null`)
+
+---
+
+### tupleTypeAnnotation
+```javascript
+t.tupleTypeAnnotation(types)
+```
+
+See also `t.isTupleTypeAnnotation(node, opts)` and `t.assertTupleTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `types` (required)
+
+---
+
+### typeAlias
+```javascript
+t.typeAlias(id, typeParameters, right)
+```
+
+See also `t.isTypeAlias(node, opts)` and `t.assertTypeAlias(node, opts)`.
+
+Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration`
+
+ - `id` (required)
+ - `typeParameters` (required)
+ - `right` (required)
+
+---
+
+### typeAnnotation
+```javascript
+t.typeAnnotation(typeAnnotation)
+```
+
+See also `t.isTypeAnnotation(node, opts)` and `t.assertTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `typeAnnotation` (required)
+
+---
+
+### typeCastExpression
+```javascript
+t.typeCastExpression(expression, typeAnnotation)
+```
+
+See also `t.isTypeCastExpression(node, opts)` and `t.assertTypeCastExpression(node, opts)`.
+
+Aliases: `Flow`, `ExpressionWrapper`, `Expression`
+
+ - `expression` (required)
+ - `typeAnnotation` (required)
+
+---
+
+### typeParameter
+```javascript
+t.typeParameter(bound)
+```
+
+See also `t.isTypeParameter(node, opts)` and `t.assertTypeParameter(node, opts)`.
+
+Aliases: `Flow`
+
+ - `bound` (required)
+
+---
+
+### typeParameterDeclaration
+```javascript
+t.typeParameterDeclaration(params)
+```
+
+See also `t.isTypeParameterDeclaration(node, opts)` and `t.assertTypeParameterDeclaration(node, opts)`.
+
+Aliases: `Flow`
+
+ - `params` (required)
+
+---
+
+### typeParameterInstantiation
+```javascript
+t.typeParameterInstantiation(params)
+```
+
+See also `t.isTypeParameterInstantiation(node, opts)` and `t.assertTypeParameterInstantiation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `params` (required)
+
+---
+
+### typeofTypeAnnotation
+```javascript
+t.typeofTypeAnnotation(argument)
+```
+
+See also `t.isTypeofTypeAnnotation(node, opts)` and `t.assertTypeofTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `argument` (required)
+
+---
+
+### unaryExpression
+```javascript
+t.unaryExpression(operator, argument, prefix)
+```
+
+See also `t.isUnaryExpression(node, opts)` and `t.assertUnaryExpression(node, opts)`.
+
+Aliases: `UnaryLike`, `Expression`
+
+ - `operator`: `'void' | 'delete' | '!' | '+' | '-' | '++' | '--' | '~' | 'typeof'` (required)
+ - `argument`: `Expression` (required)
+ - `prefix`: `boolean` (default: `true`)
+
+---
+
+### unionTypeAnnotation
+```javascript
+t.unionTypeAnnotation(types)
+```
+
+See also `t.isUnionTypeAnnotation(node, opts)` and `t.assertUnionTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`
+
+ - `types` (required)
+
+---
+
+### updateExpression
+```javascript
+t.updateExpression(operator, argument, prefix)
+```
+
+See also `t.isUpdateExpression(node, opts)` and `t.assertUpdateExpression(node, opts)`.
+
+Aliases: `Expression`
+
+ - `operator`: `'++' | '--'` (required)
+ - `argument`: `Expression` (required)
+ - `prefix`: `boolean` (default: `false`)
+
+---
+
+### variableDeclaration
+```javascript
+t.variableDeclaration(kind, declarations)
+```
+
+See also `t.isVariableDeclaration(node, opts)` and `t.assertVariableDeclaration(node, opts)`.
+
+Aliases: `Statement`, `Declaration`
+
+ - `kind`: `"var" | "let" | "const"` (required)
+ - `declarations`: `Array` (required)
+
+---
+
+### variableDeclarator
+```javascript
+t.variableDeclarator(id, init)
+```
+
+See also `t.isVariableDeclarator(node, opts)` and `t.assertVariableDeclarator(node, opts)`.
+
+ - `id`: `LVal` (required)
+ - `init`: `Expression` (default: `null`)
+
+---
+
+### voidTypeAnnotation
+```javascript
+t.voidTypeAnnotation()
+```
+
+See also `t.isVoidTypeAnnotation(node, opts)` and `t.assertVoidTypeAnnotation(node, opts)`.
+
+Aliases: `Flow`, `FlowBaseAnnotation`
+
+
+---
+
+### whileStatement
+```javascript
+t.whileStatement(test, body)
+```
+
+See also `t.isWhileStatement(node, opts)` and `t.assertWhileStatement(node, opts)`.
+
+Aliases: `Statement`, `BlockParent`, `Loop`, `While`, `Scopable`
+
+ - `test`: `Expression` (required)
+ - `body`: `BlockStatement | Statement` (required)
+
+---
+
+### withStatement
+```javascript
+t.withStatement(object, body)
+```
+
+See also `t.isWithStatement(node, opts)` and `t.assertWithStatement(node, opts)`.
+
+Aliases: `Statement`
+
+ - `object` (required)
+ - `body`: `BlockStatement | Statement` (required)
+
+---
+
+### yieldExpression
+```javascript
+t.yieldExpression(argument, delegate)
+```
+
+See also `t.isYieldExpression(node, opts)` and `t.assertYieldExpression(node, opts)`.
+
+Aliases: `Expression`, `Terminatorless`
+
+ - `argument`: `Expression` (default: `null`)
+ - `delegate`: `boolean` (default: `false`)
+
+---
+
+
+
+
diff --git a/node_modules/babel-types/lib/constants.js b/node_modules/babel-types/lib/constants.js
new file mode 100644
index 00000000..ba15090b
--- /dev/null
+++ b/node_modules/babel-types/lib/constants.js
@@ -0,0 +1,38 @@
+"use strict";
+
+exports.__esModule = true;
+exports.NOT_LOCAL_BINDING = exports.BLOCK_SCOPED_SYMBOL = exports.INHERIT_KEYS = exports.UNARY_OPERATORS = exports.STRING_UNARY_OPERATORS = exports.NUMBER_UNARY_OPERATORS = exports.BOOLEAN_UNARY_OPERATORS = exports.BINARY_OPERATORS = exports.NUMBER_BINARY_OPERATORS = exports.BOOLEAN_BINARY_OPERATORS = exports.COMPARISON_BINARY_OPERATORS = exports.EQUALITY_BINARY_OPERATORS = exports.BOOLEAN_NUMBER_BINARY_OPERATORS = exports.UPDATE_OPERATORS = exports.LOGICAL_OPERATORS = exports.COMMENT_KEYS = exports.FOR_INIT_KEYS = exports.FLATTENABLE_KEYS = exports.STATEMENT_OR_BLOCK_KEYS = undefined;
+
+var _for = require("babel-runtime/core-js/symbol/for");
+
+var _for2 = _interopRequireDefault(_for);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+var STATEMENT_OR_BLOCK_KEYS = exports.STATEMENT_OR_BLOCK_KEYS = ["consequent", "body", "alternate"];
+var FLATTENABLE_KEYS = exports.FLATTENABLE_KEYS = ["body", "expressions"];
+var FOR_INIT_KEYS = exports.FOR_INIT_KEYS = ["left", "init"];
+var COMMENT_KEYS = exports.COMMENT_KEYS = ["leadingComments", "trailingComments", "innerComments"];
+
+var LOGICAL_OPERATORS = exports.LOGICAL_OPERATORS = ["||", "&&"];
+var UPDATE_OPERATORS = exports.UPDATE_OPERATORS = ["++", "--"];
+
+var BOOLEAN_NUMBER_BINARY_OPERATORS = exports.BOOLEAN_NUMBER_BINARY_OPERATORS = [">", "<", ">=", "<="];
+var EQUALITY_BINARY_OPERATORS = exports.EQUALITY_BINARY_OPERATORS = ["==", "===", "!=", "!=="];
+var COMPARISON_BINARY_OPERATORS = exports.COMPARISON_BINARY_OPERATORS = [].concat(EQUALITY_BINARY_OPERATORS, ["in", "instanceof"]);
+var BOOLEAN_BINARY_OPERATORS = exports.BOOLEAN_BINARY_OPERATORS = [].concat(COMPARISON_BINARY_OPERATORS, BOOLEAN_NUMBER_BINARY_OPERATORS);
+var NUMBER_BINARY_OPERATORS = exports.NUMBER_BINARY_OPERATORS = ["-", "/", "%", "*", "**", "&", "|", ">>", ">>>", "<<", "^"];
+var BINARY_OPERATORS = exports.BINARY_OPERATORS = ["+"].concat(NUMBER_BINARY_OPERATORS, BOOLEAN_BINARY_OPERATORS);
+
+var BOOLEAN_UNARY_OPERATORS = exports.BOOLEAN_UNARY_OPERATORS = ["delete", "!"];
+var NUMBER_UNARY_OPERATORS = exports.NUMBER_UNARY_OPERATORS = ["+", "-", "++", "--", "~"];
+var STRING_UNARY_OPERATORS = exports.STRING_UNARY_OPERATORS = ["typeof"];
+var UNARY_OPERATORS = exports.UNARY_OPERATORS = ["void"].concat(BOOLEAN_UNARY_OPERATORS, NUMBER_UNARY_OPERATORS, STRING_UNARY_OPERATORS);
+
+var INHERIT_KEYS = exports.INHERIT_KEYS = {
+ optional: ["typeAnnotation", "typeParameters", "returnType"],
+ force: ["start", "loc", "end"]
+};
+
+var BLOCK_SCOPED_SYMBOL = exports.BLOCK_SCOPED_SYMBOL = (0, _for2.default)("var used to be block scoped");
+var NOT_LOCAL_BINDING = exports.NOT_LOCAL_BINDING = (0, _for2.default)("should not be considered a local binding");
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/converters.js b/node_modules/babel-types/lib/converters.js
new file mode 100644
index 00000000..94db954b
--- /dev/null
+++ b/node_modules/babel-types/lib/converters.js
@@ -0,0 +1,338 @@
+"use strict";
+
+exports.__esModule = true;
+
+var _maxSafeInteger = require("babel-runtime/core-js/number/max-safe-integer");
+
+var _maxSafeInteger2 = _interopRequireDefault(_maxSafeInteger);
+
+var _stringify = require("babel-runtime/core-js/json/stringify");
+
+var _stringify2 = _interopRequireDefault(_stringify);
+
+var _getIterator2 = require("babel-runtime/core-js/get-iterator");
+
+var _getIterator3 = _interopRequireDefault(_getIterator2);
+
+exports.toComputedKey = toComputedKey;
+exports.toSequenceExpression = toSequenceExpression;
+exports.toKeyAlias = toKeyAlias;
+exports.toIdentifier = toIdentifier;
+exports.toBindingIdentifierName = toBindingIdentifierName;
+exports.toStatement = toStatement;
+exports.toExpression = toExpression;
+exports.toBlock = toBlock;
+exports.valueToNode = valueToNode;
+
+var _isPlainObject = require("lodash/isPlainObject");
+
+var _isPlainObject2 = _interopRequireDefault(_isPlainObject);
+
+var _isRegExp = require("lodash/isRegExp");
+
+var _isRegExp2 = _interopRequireDefault(_isRegExp);
+
+var _index = require("./index");
+
+var t = _interopRequireWildcard(_index);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+function toComputedKey(node) {
+ var key = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : node.key || node.property;
+
+ if (!node.computed) {
+ if (t.isIdentifier(key)) key = t.stringLiteral(key.name);
+ }
+ return key;
+}
+
+function toSequenceExpression(nodes, scope) {
+ if (!nodes || !nodes.length) return;
+
+ var declars = [];
+ var bailed = false;
+
+ var result = convert(nodes);
+ if (bailed) return;
+
+ for (var i = 0; i < declars.length; i++) {
+ scope.push(declars[i]);
+ }
+
+ return result;
+
+ function convert(nodes) {
+ var ensureLastUndefined = false;
+ var exprs = [];
+
+ for (var _iterator = nodes, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : (0, _getIterator3.default)(_iterator);;) {
+ var _ref;
+
+ if (_isArray) {
+ if (_i >= _iterator.length) break;
+ _ref = _iterator[_i++];
+ } else {
+ _i = _iterator.next();
+ if (_i.done) break;
+ _ref = _i.value;
+ }
+
+ var node = _ref;
+
+ if (t.isExpression(node)) {
+ exprs.push(node);
+ } else if (t.isExpressionStatement(node)) {
+ exprs.push(node.expression);
+ } else if (t.isVariableDeclaration(node)) {
+ if (node.kind !== "var") return bailed = true;
+
+ for (var _iterator2 = node.declarations, _isArray2 = Array.isArray(_iterator2), _i2 = 0, _iterator2 = _isArray2 ? _iterator2 : (0, _getIterator3.default)(_iterator2);;) {
+ var _ref2;
+
+ if (_isArray2) {
+ if (_i2 >= _iterator2.length) break;
+ _ref2 = _iterator2[_i2++];
+ } else {
+ _i2 = _iterator2.next();
+ if (_i2.done) break;
+ _ref2 = _i2.value;
+ }
+
+ var declar = _ref2;
+
+ var bindings = t.getBindingIdentifiers(declar);
+ for (var key in bindings) {
+ declars.push({
+ kind: node.kind,
+ id: bindings[key]
+ });
+ }
+
+ if (declar.init) {
+ exprs.push(t.assignmentExpression("=", declar.id, declar.init));
+ }
+ }
+
+ ensureLastUndefined = true;
+ continue;
+ } else if (t.isIfStatement(node)) {
+ var consequent = node.consequent ? convert([node.consequent]) : scope.buildUndefinedNode();
+ var alternate = node.alternate ? convert([node.alternate]) : scope.buildUndefinedNode();
+ if (!consequent || !alternate) return bailed = true;
+
+ exprs.push(t.conditionalExpression(node.test, consequent, alternate));
+ } else if (t.isBlockStatement(node)) {
+ exprs.push(convert(node.body));
+ } else if (t.isEmptyStatement(node)) {
+ ensureLastUndefined = true;
+ continue;
+ } else {
+ return bailed = true;
+ }
+
+ ensureLastUndefined = false;
+ }
+
+ if (ensureLastUndefined || exprs.length === 0) {
+ exprs.push(scope.buildUndefinedNode());
+ }
+
+ if (exprs.length === 1) {
+ return exprs[0];
+ } else {
+ return t.sequenceExpression(exprs);
+ }
+ }
+}
+
+function toKeyAlias(node) {
+ var key = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : node.key;
+
+ var alias = void 0;
+
+ if (node.kind === "method") {
+ return toKeyAlias.increment() + "";
+ } else if (t.isIdentifier(key)) {
+ alias = key.name;
+ } else if (t.isStringLiteral(key)) {
+ alias = (0, _stringify2.default)(key.value);
+ } else {
+ alias = (0, _stringify2.default)(t.removePropertiesDeep(t.cloneDeep(key)));
+ }
+
+ if (node.computed) {
+ alias = "[" + alias + "]";
+ }
+
+ if (node.static) {
+ alias = "static:" + alias;
+ }
+
+ return alias;
+}
+
+toKeyAlias.uid = 0;
+
+toKeyAlias.increment = function () {
+ if (toKeyAlias.uid >= _maxSafeInteger2.default) {
+ return toKeyAlias.uid = 0;
+ } else {
+ return toKeyAlias.uid++;
+ }
+};
+
+function toIdentifier(name) {
+ name = name + "";
+
+ name = name.replace(/[^a-zA-Z0-9$_]/g, "-");
+
+ name = name.replace(/^[-0-9]+/, "");
+
+ name = name.replace(/[-\s]+(.)?/g, function (match, c) {
+ return c ? c.toUpperCase() : "";
+ });
+
+ if (!t.isValidIdentifier(name)) {
+ name = "_" + name;
+ }
+
+ return name || "_";
+}
+
+function toBindingIdentifierName(name) {
+ name = toIdentifier(name);
+ if (name === "eval" || name === "arguments") name = "_" + name;
+ return name;
+}
+
+function toStatement(node, ignore) {
+ if (t.isStatement(node)) {
+ return node;
+ }
+
+ var mustHaveId = false;
+ var newType = void 0;
+
+ if (t.isClass(node)) {
+ mustHaveId = true;
+ newType = "ClassDeclaration";
+ } else if (t.isFunction(node)) {
+ mustHaveId = true;
+ newType = "FunctionDeclaration";
+ } else if (t.isAssignmentExpression(node)) {
+ return t.expressionStatement(node);
+ }
+
+ if (mustHaveId && !node.id) {
+ newType = false;
+ }
+
+ if (!newType) {
+ if (ignore) {
+ return false;
+ } else {
+ throw new Error("cannot turn " + node.type + " to a statement");
+ }
+ }
+
+ node.type = newType;
+
+ return node;
+}
+
+function toExpression(node) {
+ if (t.isExpressionStatement(node)) {
+ node = node.expression;
+ }
+
+ if (t.isExpression(node)) {
+ return node;
+ }
+
+ if (t.isClass(node)) {
+ node.type = "ClassExpression";
+ } else if (t.isFunction(node)) {
+ node.type = "FunctionExpression";
+ }
+
+ if (!t.isExpression(node)) {
+ throw new Error("cannot turn " + node.type + " to an expression");
+ }
+
+ return node;
+}
+
+function toBlock(node, parent) {
+ if (t.isBlockStatement(node)) {
+ return node;
+ }
+
+ if (t.isEmptyStatement(node)) {
+ node = [];
+ }
+
+ if (!Array.isArray(node)) {
+ if (!t.isStatement(node)) {
+ if (t.isFunction(parent)) {
+ node = t.returnStatement(node);
+ } else {
+ node = t.expressionStatement(node);
+ }
+ }
+
+ node = [node];
+ }
+
+ return t.blockStatement(node);
+}
+
+function valueToNode(value) {
+ if (value === undefined) {
+ return t.identifier("undefined");
+ }
+
+ if (value === true || value === false) {
+ return t.booleanLiteral(value);
+ }
+
+ if (value === null) {
+ return t.nullLiteral();
+ }
+
+ if (typeof value === "string") {
+ return t.stringLiteral(value);
+ }
+
+ if (typeof value === "number") {
+ return t.numericLiteral(value);
+ }
+
+ if ((0, _isRegExp2.default)(value)) {
+ var pattern = value.source;
+ var flags = value.toString().match(/\/([a-z]+|)$/)[1];
+ return t.regExpLiteral(pattern, flags);
+ }
+
+ if (Array.isArray(value)) {
+ return t.arrayExpression(value.map(t.valueToNode));
+ }
+
+ if ((0, _isPlainObject2.default)(value)) {
+ var props = [];
+ for (var key in value) {
+ var nodeKey = void 0;
+ if (t.isValidIdentifier(key)) {
+ nodeKey = t.identifier(key);
+ } else {
+ nodeKey = t.stringLiteral(key);
+ }
+ props.push(t.objectProperty(nodeKey, t.valueToNode(value[key])));
+ }
+ return t.objectExpression(props);
+ }
+
+ throw new Error("don't know how to turn this value into a node");
+}
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/core.js b/node_modules/babel-types/lib/definitions/core.js
new file mode 100644
index 00000000..3b03262f
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/core.js
@@ -0,0 +1,701 @@
+"use strict";
+
+var _index = require("../index");
+
+var t = _interopRequireWildcard(_index);
+
+var _constants = require("../constants");
+
+var _index2 = require("./index");
+
+var _index3 = _interopRequireDefault(_index2);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+(0, _index3.default)("ArrayExpression", {
+ fields: {
+ elements: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeOrValueType)("null", "Expression", "SpreadElement"))),
+ default: []
+ }
+ },
+ visitor: ["elements"],
+ aliases: ["Expression"]
+});
+
+(0, _index3.default)("AssignmentExpression", {
+ fields: {
+ operator: {
+ validate: (0, _index2.assertValueType)("string")
+ },
+ left: {
+ validate: (0, _index2.assertNodeType)("LVal")
+ },
+ right: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ },
+ builder: ["operator", "left", "right"],
+ visitor: ["left", "right"],
+ aliases: ["Expression"]
+});
+
+(0, _index3.default)("BinaryExpression", {
+ builder: ["operator", "left", "right"],
+ fields: {
+ operator: {
+ validate: _index2.assertOneOf.apply(undefined, _constants.BINARY_OPERATORS)
+ },
+ left: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ right: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ },
+ visitor: ["left", "right"],
+ aliases: ["Binary", "Expression"]
+});
+
+(0, _index3.default)("Directive", {
+ visitor: ["value"],
+ fields: {
+ value: {
+ validate: (0, _index2.assertNodeType)("DirectiveLiteral")
+ }
+ }
+});
+
+(0, _index3.default)("DirectiveLiteral", {
+ builder: ["value"],
+ fields: {
+ value: {
+ validate: (0, _index2.assertValueType)("string")
+ }
+ }
+});
+
+(0, _index3.default)("BlockStatement", {
+ builder: ["body", "directives"],
+ visitor: ["directives", "body"],
+ fields: {
+ directives: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Directive"))),
+ default: []
+ },
+ body: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Statement")))
+ }
+ },
+ aliases: ["Scopable", "BlockParent", "Block", "Statement"]
+});
+
+(0, _index3.default)("BreakStatement", {
+ visitor: ["label"],
+ fields: {
+ label: {
+ validate: (0, _index2.assertNodeType)("Identifier"),
+ optional: true
+ }
+ },
+ aliases: ["Statement", "Terminatorless", "CompletionStatement"]
+});
+
+(0, _index3.default)("CallExpression", {
+ visitor: ["callee", "arguments"],
+ fields: {
+ callee: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ arguments: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Expression", "SpreadElement")))
+ }
+ },
+ aliases: ["Expression"]
+});
+
+(0, _index3.default)("CatchClause", {
+ visitor: ["param", "body"],
+ fields: {
+ param: {
+ validate: (0, _index2.assertNodeType)("Identifier")
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement")
+ }
+ },
+ aliases: ["Scopable"]
+});
+
+(0, _index3.default)("ConditionalExpression", {
+ visitor: ["test", "consequent", "alternate"],
+ fields: {
+ test: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ consequent: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ alternate: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ },
+ aliases: ["Expression", "Conditional"]
+});
+
+(0, _index3.default)("ContinueStatement", {
+ visitor: ["label"],
+ fields: {
+ label: {
+ validate: (0, _index2.assertNodeType)("Identifier"),
+ optional: true
+ }
+ },
+ aliases: ["Statement", "Terminatorless", "CompletionStatement"]
+});
+
+(0, _index3.default)("DebuggerStatement", {
+ aliases: ["Statement"]
+});
+
+(0, _index3.default)("DoWhileStatement", {
+ visitor: ["test", "body"],
+ fields: {
+ test: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("Statement")
+ }
+ },
+ aliases: ["Statement", "BlockParent", "Loop", "While", "Scopable"]
+});
+
+(0, _index3.default)("EmptyStatement", {
+ aliases: ["Statement"]
+});
+
+(0, _index3.default)("ExpressionStatement", {
+ visitor: ["expression"],
+ fields: {
+ expression: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ },
+ aliases: ["Statement", "ExpressionWrapper"]
+});
+
+(0, _index3.default)("File", {
+ builder: ["program", "comments", "tokens"],
+ visitor: ["program"],
+ fields: {
+ program: {
+ validate: (0, _index2.assertNodeType)("Program")
+ }
+ }
+});
+
+(0, _index3.default)("ForInStatement", {
+ visitor: ["left", "right", "body"],
+ aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"],
+ fields: {
+ left: {
+ validate: (0, _index2.assertNodeType)("VariableDeclaration", "LVal")
+ },
+ right: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("Statement")
+ }
+ }
+});
+
+(0, _index3.default)("ForStatement", {
+ visitor: ["init", "test", "update", "body"],
+ aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop"],
+ fields: {
+ init: {
+ validate: (0, _index2.assertNodeType)("VariableDeclaration", "Expression"),
+ optional: true
+ },
+ test: {
+ validate: (0, _index2.assertNodeType)("Expression"),
+ optional: true
+ },
+ update: {
+ validate: (0, _index2.assertNodeType)("Expression"),
+ optional: true
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("Statement")
+ }
+ }
+});
+
+(0, _index3.default)("FunctionDeclaration", {
+ builder: ["id", "params", "body", "generator", "async"],
+ visitor: ["id", "params", "body", "returnType", "typeParameters"],
+ fields: {
+ id: {
+ validate: (0, _index2.assertNodeType)("Identifier")
+ },
+ params: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("LVal")))
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement")
+ },
+ generator: {
+ default: false,
+ validate: (0, _index2.assertValueType)("boolean")
+ },
+ async: {
+ default: false,
+ validate: (0, _index2.assertValueType)("boolean")
+ }
+ },
+ aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Statement", "Pureish", "Declaration"]
+});
+
+(0, _index3.default)("FunctionExpression", {
+ inherits: "FunctionDeclaration",
+ aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Expression", "Pureish"],
+ fields: {
+ id: {
+ validate: (0, _index2.assertNodeType)("Identifier"),
+ optional: true
+ },
+ params: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("LVal")))
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement")
+ },
+ generator: {
+ default: false,
+ validate: (0, _index2.assertValueType)("boolean")
+ },
+ async: {
+ default: false,
+ validate: (0, _index2.assertValueType)("boolean")
+ }
+ }
+});
+
+(0, _index3.default)("Identifier", {
+ builder: ["name"],
+ visitor: ["typeAnnotation"],
+ aliases: ["Expression", "LVal"],
+ fields: {
+ name: {
+ validate: function validate(node, key, val) {
+ if (!t.isValidIdentifier(val)) {}
+ }
+ },
+ decorators: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index3.default)("IfStatement", {
+ visitor: ["test", "consequent", "alternate"],
+ aliases: ["Statement", "Conditional"],
+ fields: {
+ test: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ consequent: {
+ validate: (0, _index2.assertNodeType)("Statement")
+ },
+ alternate: {
+ optional: true,
+ validate: (0, _index2.assertNodeType)("Statement")
+ }
+ }
+});
+
+(0, _index3.default)("LabeledStatement", {
+ visitor: ["label", "body"],
+ aliases: ["Statement"],
+ fields: {
+ label: {
+ validate: (0, _index2.assertNodeType)("Identifier")
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("Statement")
+ }
+ }
+});
+
+(0, _index3.default)("StringLiteral", {
+ builder: ["value"],
+ fields: {
+ value: {
+ validate: (0, _index2.assertValueType)("string")
+ }
+ },
+ aliases: ["Expression", "Pureish", "Literal", "Immutable"]
+});
+
+(0, _index3.default)("NumericLiteral", {
+ builder: ["value"],
+ deprecatedAlias: "NumberLiteral",
+ fields: {
+ value: {
+ validate: (0, _index2.assertValueType)("number")
+ }
+ },
+ aliases: ["Expression", "Pureish", "Literal", "Immutable"]
+});
+
+(0, _index3.default)("NullLiteral", {
+ aliases: ["Expression", "Pureish", "Literal", "Immutable"]
+});
+
+(0, _index3.default)("BooleanLiteral", {
+ builder: ["value"],
+ fields: {
+ value: {
+ validate: (0, _index2.assertValueType)("boolean")
+ }
+ },
+ aliases: ["Expression", "Pureish", "Literal", "Immutable"]
+});
+
+(0, _index3.default)("RegExpLiteral", {
+ builder: ["pattern", "flags"],
+ deprecatedAlias: "RegexLiteral",
+ aliases: ["Expression", "Literal"],
+ fields: {
+ pattern: {
+ validate: (0, _index2.assertValueType)("string")
+ },
+ flags: {
+ validate: (0, _index2.assertValueType)("string"),
+ default: ""
+ }
+ }
+});
+
+(0, _index3.default)("LogicalExpression", {
+ builder: ["operator", "left", "right"],
+ visitor: ["left", "right"],
+ aliases: ["Binary", "Expression"],
+ fields: {
+ operator: {
+ validate: _index2.assertOneOf.apply(undefined, _constants.LOGICAL_OPERATORS)
+ },
+ left: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ right: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index3.default)("MemberExpression", {
+ builder: ["object", "property", "computed"],
+ visitor: ["object", "property"],
+ aliases: ["Expression", "LVal"],
+ fields: {
+ object: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ property: {
+ validate: function validate(node, key, val) {
+ var expectedType = node.computed ? "Expression" : "Identifier";
+ (0, _index2.assertNodeType)(expectedType)(node, key, val);
+ }
+ },
+ computed: {
+ default: false
+ }
+ }
+});
+
+(0, _index3.default)("NewExpression", {
+ visitor: ["callee", "arguments"],
+ aliases: ["Expression"],
+ fields: {
+ callee: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ arguments: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Expression", "SpreadElement")))
+ }
+ }
+});
+
+(0, _index3.default)("Program", {
+ visitor: ["directives", "body"],
+ builder: ["body", "directives"],
+ fields: {
+ directives: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Directive"))),
+ default: []
+ },
+ body: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Statement")))
+ }
+ },
+ aliases: ["Scopable", "BlockParent", "Block", "FunctionParent"]
+});
+
+(0, _index3.default)("ObjectExpression", {
+ visitor: ["properties"],
+ aliases: ["Expression"],
+ fields: {
+ properties: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("ObjectMethod", "ObjectProperty", "SpreadProperty")))
+ }
+ }
+});
+
+(0, _index3.default)("ObjectMethod", {
+ builder: ["kind", "key", "params", "body", "computed"],
+ fields: {
+ kind: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("string"), (0, _index2.assertOneOf)("method", "get", "set")),
+ default: "method"
+ },
+ computed: {
+ validate: (0, _index2.assertValueType)("boolean"),
+ default: false
+ },
+ key: {
+ validate: function validate(node, key, val) {
+ var expectedTypes = node.computed ? ["Expression"] : ["Identifier", "StringLiteral", "NumericLiteral"];
+ _index2.assertNodeType.apply(undefined, expectedTypes)(node, key, val);
+ }
+ },
+ decorators: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Decorator")))
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement")
+ },
+ generator: {
+ default: false,
+ validate: (0, _index2.assertValueType)("boolean")
+ },
+ async: {
+ default: false,
+ validate: (0, _index2.assertValueType)("boolean")
+ }
+ },
+ visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"],
+ aliases: ["UserWhitespacable", "Function", "Scopable", "BlockParent", "FunctionParent", "Method", "ObjectMember"]
+});
+
+(0, _index3.default)("ObjectProperty", {
+ builder: ["key", "value", "computed", "shorthand", "decorators"],
+ fields: {
+ computed: {
+ validate: (0, _index2.assertValueType)("boolean"),
+ default: false
+ },
+ key: {
+ validate: function validate(node, key, val) {
+ var expectedTypes = node.computed ? ["Expression"] : ["Identifier", "StringLiteral", "NumericLiteral"];
+ _index2.assertNodeType.apply(undefined, expectedTypes)(node, key, val);
+ }
+ },
+ value: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ shorthand: {
+ validate: (0, _index2.assertValueType)("boolean"),
+ default: false
+ },
+ decorators: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Decorator"))),
+ optional: true
+ }
+ },
+ visitor: ["key", "value", "decorators"],
+ aliases: ["UserWhitespacable", "Property", "ObjectMember"]
+});
+
+(0, _index3.default)("RestElement", {
+ visitor: ["argument", "typeAnnotation"],
+ aliases: ["LVal"],
+ fields: {
+ argument: {
+ validate: (0, _index2.assertNodeType)("LVal")
+ },
+ decorators: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index3.default)("ReturnStatement", {
+ visitor: ["argument"],
+ aliases: ["Statement", "Terminatorless", "CompletionStatement"],
+ fields: {
+ argument: {
+ validate: (0, _index2.assertNodeType)("Expression"),
+ optional: true
+ }
+ }
+});
+
+(0, _index3.default)("SequenceExpression", {
+ visitor: ["expressions"],
+ fields: {
+ expressions: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Expression")))
+ }
+ },
+ aliases: ["Expression"]
+});
+
+(0, _index3.default)("SwitchCase", {
+ visitor: ["test", "consequent"],
+ fields: {
+ test: {
+ validate: (0, _index2.assertNodeType)("Expression"),
+ optional: true
+ },
+ consequent: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("Statement")))
+ }
+ }
+});
+
+(0, _index3.default)("SwitchStatement", {
+ visitor: ["discriminant", "cases"],
+ aliases: ["Statement", "BlockParent", "Scopable"],
+ fields: {
+ discriminant: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ cases: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("SwitchCase")))
+ }
+ }
+});
+
+(0, _index3.default)("ThisExpression", {
+ aliases: ["Expression"]
+});
+
+(0, _index3.default)("ThrowStatement", {
+ visitor: ["argument"],
+ aliases: ["Statement", "Terminatorless", "CompletionStatement"],
+ fields: {
+ argument: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index3.default)("TryStatement", {
+ visitor: ["block", "handler", "finalizer"],
+ aliases: ["Statement"],
+ fields: {
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement")
+ },
+ handler: {
+ optional: true,
+ handler: (0, _index2.assertNodeType)("BlockStatement")
+ },
+ finalizer: {
+ optional: true,
+ validate: (0, _index2.assertNodeType)("BlockStatement")
+ }
+ }
+});
+
+(0, _index3.default)("UnaryExpression", {
+ builder: ["operator", "argument", "prefix"],
+ fields: {
+ prefix: {
+ default: true
+ },
+ argument: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ operator: {
+ validate: _index2.assertOneOf.apply(undefined, _constants.UNARY_OPERATORS)
+ }
+ },
+ visitor: ["argument"],
+ aliases: ["UnaryLike", "Expression"]
+});
+
+(0, _index3.default)("UpdateExpression", {
+ builder: ["operator", "argument", "prefix"],
+ fields: {
+ prefix: {
+ default: false
+ },
+ argument: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ operator: {
+ validate: _index2.assertOneOf.apply(undefined, _constants.UPDATE_OPERATORS)
+ }
+ },
+ visitor: ["argument"],
+ aliases: ["Expression"]
+});
+
+(0, _index3.default)("VariableDeclaration", {
+ builder: ["kind", "declarations"],
+ visitor: ["declarations"],
+ aliases: ["Statement", "Declaration"],
+ fields: {
+ kind: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("string"), (0, _index2.assertOneOf)("var", "let", "const"))
+ },
+ declarations: {
+ validate: (0, _index2.chain)((0, _index2.assertValueType)("array"), (0, _index2.assertEach)((0, _index2.assertNodeType)("VariableDeclarator")))
+ }
+ }
+});
+
+(0, _index3.default)("VariableDeclarator", {
+ visitor: ["id", "init"],
+ fields: {
+ id: {
+ validate: (0, _index2.assertNodeType)("LVal")
+ },
+ init: {
+ optional: true,
+ validate: (0, _index2.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index3.default)("WhileStatement", {
+ visitor: ["test", "body"],
+ aliases: ["Statement", "BlockParent", "Loop", "While", "Scopable"],
+ fields: {
+ test: {
+ validate: (0, _index2.assertNodeType)("Expression")
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement", "Statement")
+ }
+ }
+});
+
+(0, _index3.default)("WithStatement", {
+ visitor: ["object", "body"],
+ aliases: ["Statement"],
+ fields: {
+ object: {
+ object: (0, _index2.assertNodeType)("Expression")
+ },
+ body: {
+ validate: (0, _index2.assertNodeType)("BlockStatement", "Statement")
+ }
+ }
+});
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/es2015.js b/node_modules/babel-types/lib/definitions/es2015.js
new file mode 100644
index 00000000..a823aa22
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/es2015.js
@@ -0,0 +1,354 @@
+"use strict";
+
+var _index = require("./index");
+
+var _index2 = _interopRequireDefault(_index);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+(0, _index2.default)("AssignmentPattern", {
+ visitor: ["left", "right"],
+ aliases: ["Pattern", "LVal"],
+ fields: {
+ left: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ },
+ right: {
+ validate: (0, _index.assertNodeType)("Expression")
+ },
+ decorators: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index2.default)("ArrayPattern", {
+ visitor: ["elements", "typeAnnotation"],
+ aliases: ["Pattern", "LVal"],
+ fields: {
+ elements: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Expression")))
+ },
+ decorators: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index2.default)("ArrowFunctionExpression", {
+ builder: ["params", "body", "async"],
+ visitor: ["params", "body", "returnType", "typeParameters"],
+ aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Expression", "Pureish"],
+ fields: {
+ params: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("LVal")))
+ },
+ body: {
+ validate: (0, _index.assertNodeType)("BlockStatement", "Expression")
+ },
+ async: {
+ validate: (0, _index.assertValueType)("boolean"),
+ default: false
+ }
+ }
+});
+
+(0, _index2.default)("ClassBody", {
+ visitor: ["body"],
+ fields: {
+ body: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("ClassMethod", "ClassProperty")))
+ }
+ }
+});
+
+(0, _index2.default)("ClassDeclaration", {
+ builder: ["id", "superClass", "body", "decorators"],
+ visitor: ["id", "body", "superClass", "mixins", "typeParameters", "superTypeParameters", "implements", "decorators"],
+ aliases: ["Scopable", "Class", "Statement", "Declaration", "Pureish"],
+ fields: {
+ id: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ },
+ body: {
+ validate: (0, _index.assertNodeType)("ClassBody")
+ },
+ superClass: {
+ optional: true,
+ validate: (0, _index.assertNodeType)("Expression")
+ },
+ decorators: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index2.default)("ClassExpression", {
+ inherits: "ClassDeclaration",
+ aliases: ["Scopable", "Class", "Expression", "Pureish"],
+ fields: {
+ id: {
+ optional: true,
+ validate: (0, _index.assertNodeType)("Identifier")
+ },
+ body: {
+ validate: (0, _index.assertNodeType)("ClassBody")
+ },
+ superClass: {
+ optional: true,
+ validate: (0, _index.assertNodeType)("Expression")
+ },
+ decorators: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index2.default)("ExportAllDeclaration", {
+ visitor: ["source"],
+ aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"],
+ fields: {
+ source: {
+ validate: (0, _index.assertNodeType)("StringLiteral")
+ }
+ }
+});
+
+(0, _index2.default)("ExportDefaultDeclaration", {
+ visitor: ["declaration"],
+ aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"],
+ fields: {
+ declaration: {
+ validate: (0, _index.assertNodeType)("FunctionDeclaration", "ClassDeclaration", "Expression")
+ }
+ }
+});
+
+(0, _index2.default)("ExportNamedDeclaration", {
+ visitor: ["declaration", "specifiers", "source"],
+ aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"],
+ fields: {
+ declaration: {
+ validate: (0, _index.assertNodeType)("Declaration"),
+ optional: true
+ },
+ specifiers: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("ExportSpecifier")))
+ },
+ source: {
+ validate: (0, _index.assertNodeType)("StringLiteral"),
+ optional: true
+ }
+ }
+});
+
+(0, _index2.default)("ExportSpecifier", {
+ visitor: ["local", "exported"],
+ aliases: ["ModuleSpecifier"],
+ fields: {
+ local: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ },
+ exported: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ }
+ }
+});
+
+(0, _index2.default)("ForOfStatement", {
+ visitor: ["left", "right", "body"],
+ aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"],
+ fields: {
+ left: {
+ validate: (0, _index.assertNodeType)("VariableDeclaration", "LVal")
+ },
+ right: {
+ validate: (0, _index.assertNodeType)("Expression")
+ },
+ body: {
+ validate: (0, _index.assertNodeType)("Statement")
+ }
+ }
+});
+
+(0, _index2.default)("ImportDeclaration", {
+ visitor: ["specifiers", "source"],
+ aliases: ["Statement", "Declaration", "ModuleDeclaration"],
+ fields: {
+ specifiers: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("ImportSpecifier", "ImportDefaultSpecifier", "ImportNamespaceSpecifier")))
+ },
+ source: {
+ validate: (0, _index.assertNodeType)("StringLiteral")
+ }
+ }
+});
+
+(0, _index2.default)("ImportDefaultSpecifier", {
+ visitor: ["local"],
+ aliases: ["ModuleSpecifier"],
+ fields: {
+ local: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ }
+ }
+});
+
+(0, _index2.default)("ImportNamespaceSpecifier", {
+ visitor: ["local"],
+ aliases: ["ModuleSpecifier"],
+ fields: {
+ local: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ }
+ }
+});
+
+(0, _index2.default)("ImportSpecifier", {
+ visitor: ["local", "imported"],
+ aliases: ["ModuleSpecifier"],
+ fields: {
+ local: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ },
+ imported: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ },
+ importKind: {
+ validate: (0, _index.assertOneOf)(null, "type", "typeof")
+ }
+ }
+});
+
+(0, _index2.default)("MetaProperty", {
+ visitor: ["meta", "property"],
+ aliases: ["Expression"],
+ fields: {
+ meta: {
+ validate: (0, _index.assertValueType)("string")
+ },
+ property: {
+ validate: (0, _index.assertValueType)("string")
+ }
+ }
+});
+
+(0, _index2.default)("ClassMethod", {
+ aliases: ["Function", "Scopable", "BlockParent", "FunctionParent", "Method"],
+ builder: ["kind", "key", "params", "body", "computed", "static"],
+ visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"],
+ fields: {
+ kind: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("string"), (0, _index.assertOneOf)("get", "set", "method", "constructor")),
+ default: "method"
+ },
+ computed: {
+ default: false,
+ validate: (0, _index.assertValueType)("boolean")
+ },
+ static: {
+ default: false,
+ validate: (0, _index.assertValueType)("boolean")
+ },
+ key: {
+ validate: function validate(node, key, val) {
+ var expectedTypes = node.computed ? ["Expression"] : ["Identifier", "StringLiteral", "NumericLiteral"];
+ _index.assertNodeType.apply(undefined, expectedTypes)(node, key, val);
+ }
+ },
+ params: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("LVal")))
+ },
+ body: {
+ validate: (0, _index.assertNodeType)("BlockStatement")
+ },
+ generator: {
+ default: false,
+ validate: (0, _index.assertValueType)("boolean")
+ },
+ async: {
+ default: false,
+ validate: (0, _index.assertValueType)("boolean")
+ }
+ }
+});
+
+(0, _index2.default)("ObjectPattern", {
+ visitor: ["properties", "typeAnnotation"],
+ aliases: ["Pattern", "LVal"],
+ fields: {
+ properties: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("RestProperty", "Property")))
+ },
+ decorators: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Decorator")))
+ }
+ }
+});
+
+(0, _index2.default)("SpreadElement", {
+ visitor: ["argument"],
+ aliases: ["UnaryLike"],
+ fields: {
+ argument: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index2.default)("Super", {
+ aliases: ["Expression"]
+});
+
+(0, _index2.default)("TaggedTemplateExpression", {
+ visitor: ["tag", "quasi"],
+ aliases: ["Expression"],
+ fields: {
+ tag: {
+ validate: (0, _index.assertNodeType)("Expression")
+ },
+ quasi: {
+ validate: (0, _index.assertNodeType)("TemplateLiteral")
+ }
+ }
+});
+
+(0, _index2.default)("TemplateElement", {
+ builder: ["value", "tail"],
+ fields: {
+ value: {},
+ tail: {
+ validate: (0, _index.assertValueType)("boolean"),
+ default: false
+ }
+ }
+});
+
+(0, _index2.default)("TemplateLiteral", {
+ visitor: ["quasis", "expressions"],
+ aliases: ["Expression", "Literal"],
+ fields: {
+ quasis: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("TemplateElement")))
+ },
+ expressions: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("Expression")))
+ }
+ }
+});
+
+(0, _index2.default)("YieldExpression", {
+ builder: ["argument", "delegate"],
+ visitor: ["argument"],
+ aliases: ["Expression", "Terminatorless"],
+ fields: {
+ delegate: {
+ validate: (0, _index.assertValueType)("boolean"),
+ default: false
+ },
+ argument: {
+ optional: true,
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/experimental.js b/node_modules/babel-types/lib/definitions/experimental.js
new file mode 100644
index 00000000..d65d6096
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/experimental.js
@@ -0,0 +1,103 @@
+"use strict";
+
+var _index = require("./index");
+
+var _index2 = _interopRequireDefault(_index);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+(0, _index2.default)("AwaitExpression", {
+ builder: ["argument"],
+ visitor: ["argument"],
+ aliases: ["Expression", "Terminatorless"],
+ fields: {
+ argument: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index2.default)("ForAwaitStatement", {
+ visitor: ["left", "right", "body"],
+ aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"],
+ fields: {
+ left: {
+ validate: (0, _index.assertNodeType)("VariableDeclaration", "LVal")
+ },
+ right: {
+ validate: (0, _index.assertNodeType)("Expression")
+ },
+ body: {
+ validate: (0, _index.assertNodeType)("Statement")
+ }
+ }
+});
+
+(0, _index2.default)("BindExpression", {
+ visitor: ["object", "callee"],
+ aliases: ["Expression"],
+ fields: {}
+});
+
+(0, _index2.default)("Import", {
+ aliases: ["Expression"]
+});
+
+(0, _index2.default)("Decorator", {
+ visitor: ["expression"],
+ fields: {
+ expression: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index2.default)("DoExpression", {
+ visitor: ["body"],
+ aliases: ["Expression"],
+ fields: {
+ body: {
+ validate: (0, _index.assertNodeType)("BlockStatement")
+ }
+ }
+});
+
+(0, _index2.default)("ExportDefaultSpecifier", {
+ visitor: ["exported"],
+ aliases: ["ModuleSpecifier"],
+ fields: {
+ exported: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ }
+ }
+});
+
+(0, _index2.default)("ExportNamespaceSpecifier", {
+ visitor: ["exported"],
+ aliases: ["ModuleSpecifier"],
+ fields: {
+ exported: {
+ validate: (0, _index.assertNodeType)("Identifier")
+ }
+ }
+});
+
+(0, _index2.default)("RestProperty", {
+ visitor: ["argument"],
+ aliases: ["UnaryLike"],
+ fields: {
+ argument: {
+ validate: (0, _index.assertNodeType)("LVal")
+ }
+ }
+});
+
+(0, _index2.default)("SpreadProperty", {
+ visitor: ["argument"],
+ aliases: ["UnaryLike"],
+ fields: {
+ argument: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/flow.js b/node_modules/babel-types/lib/definitions/flow.js
new file mode 100644
index 00000000..dca21ec1
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/flow.js
@@ -0,0 +1,261 @@
+"use strict";
+
+var _index = require("./index");
+
+var _index2 = _interopRequireDefault(_index);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+(0, _index2.default)("AnyTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
+
+(0, _index2.default)("ArrayTypeAnnotation", {
+ visitor: ["elementType"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("BooleanTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
+
+(0, _index2.default)("BooleanLiteralTypeAnnotation", {
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("NullLiteralTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
+
+(0, _index2.default)("ClassImplements", {
+ visitor: ["id", "typeParameters"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("ClassProperty", {
+ visitor: ["key", "value", "typeAnnotation", "decorators"],
+ builder: ["key", "value", "typeAnnotation", "decorators", "computed"],
+ aliases: ["Property"],
+ fields: {
+ computed: {
+ validate: (0, _index.assertValueType)("boolean"),
+ default: false
+ }
+ }
+});
+
+(0, _index2.default)("DeclareClass", {
+ visitor: ["id", "typeParameters", "extends", "body"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("DeclareFunction", {
+ visitor: ["id"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("DeclareInterface", {
+ visitor: ["id", "typeParameters", "extends", "body"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("DeclareModule", {
+ visitor: ["id", "body"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("DeclareModuleExports", {
+ visitor: ["typeAnnotation"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("DeclareTypeAlias", {
+ visitor: ["id", "typeParameters", "right"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("DeclareVariable", {
+ visitor: ["id"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("ExistentialTypeParam", {
+ aliases: ["Flow"]
+});
+
+(0, _index2.default)("FunctionTypeAnnotation", {
+ visitor: ["typeParameters", "params", "rest", "returnType"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("FunctionTypeParam", {
+ visitor: ["name", "typeAnnotation"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("GenericTypeAnnotation", {
+ visitor: ["id", "typeParameters"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("InterfaceExtends", {
+ visitor: ["id", "typeParameters"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("InterfaceDeclaration", {
+ visitor: ["id", "typeParameters", "extends", "body"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("IntersectionTypeAnnotation", {
+ visitor: ["types"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("MixedTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"]
+});
+
+(0, _index2.default)("EmptyTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"]
+});
+
+(0, _index2.default)("NullableTypeAnnotation", {
+ visitor: ["typeAnnotation"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("NumericLiteralTypeAnnotation", {
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("NumberTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
+
+(0, _index2.default)("StringLiteralTypeAnnotation", {
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("StringTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
+
+(0, _index2.default)("ThisTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
+
+(0, _index2.default)("TupleTypeAnnotation", {
+ visitor: ["types"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeofTypeAnnotation", {
+ visitor: ["argument"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeAlias", {
+ visitor: ["id", "typeParameters", "right"],
+ aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeAnnotation", {
+ visitor: ["typeAnnotation"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeCastExpression", {
+ visitor: ["expression", "typeAnnotation"],
+ aliases: ["Flow", "ExpressionWrapper", "Expression"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeParameter", {
+ visitor: ["bound"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeParameterDeclaration", {
+ visitor: ["params"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("TypeParameterInstantiation", {
+ visitor: ["params"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("ObjectTypeAnnotation", {
+ visitor: ["properties", "indexers", "callProperties"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("ObjectTypeCallProperty", {
+ visitor: ["value"],
+ aliases: ["Flow", "UserWhitespacable"],
+ fields: {}
+});
+
+(0, _index2.default)("ObjectTypeIndexer", {
+ visitor: ["id", "key", "value"],
+ aliases: ["Flow", "UserWhitespacable"],
+ fields: {}
+});
+
+(0, _index2.default)("ObjectTypeProperty", {
+ visitor: ["key", "value"],
+ aliases: ["Flow", "UserWhitespacable"],
+ fields: {}
+});
+
+(0, _index2.default)("QualifiedTypeIdentifier", {
+ visitor: ["id", "qualification"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("UnionTypeAnnotation", {
+ visitor: ["types"],
+ aliases: ["Flow"],
+ fields: {}
+});
+
+(0, _index2.default)("VoidTypeAnnotation", {
+ aliases: ["Flow", "FlowBaseAnnotation"],
+ fields: {}
+});
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/index.js b/node_modules/babel-types/lib/definitions/index.js
new file mode 100644
index 00000000..d5121144
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/index.js
@@ -0,0 +1,249 @@
+"use strict";
+
+exports.__esModule = true;
+exports.DEPRECATED_KEYS = exports.BUILDER_KEYS = exports.NODE_FIELDS = exports.ALIAS_KEYS = exports.VISITOR_KEYS = undefined;
+
+var _getIterator2 = require("babel-runtime/core-js/get-iterator");
+
+var _getIterator3 = _interopRequireDefault(_getIterator2);
+
+var _stringify = require("babel-runtime/core-js/json/stringify");
+
+var _stringify2 = _interopRequireDefault(_stringify);
+
+var _typeof2 = require("babel-runtime/helpers/typeof");
+
+var _typeof3 = _interopRequireDefault(_typeof2);
+
+exports.assertEach = assertEach;
+exports.assertOneOf = assertOneOf;
+exports.assertNodeType = assertNodeType;
+exports.assertNodeOrValueType = assertNodeOrValueType;
+exports.assertValueType = assertValueType;
+exports.chain = chain;
+exports.default = defineType;
+
+var _index = require("../index");
+
+var t = _interopRequireWildcard(_index);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+var VISITOR_KEYS = exports.VISITOR_KEYS = {};
+var ALIAS_KEYS = exports.ALIAS_KEYS = {};
+var NODE_FIELDS = exports.NODE_FIELDS = {};
+var BUILDER_KEYS = exports.BUILDER_KEYS = {};
+var DEPRECATED_KEYS = exports.DEPRECATED_KEYS = {};
+
+function getType(val) {
+ if (Array.isArray(val)) {
+ return "array";
+ } else if (val === null) {
+ return "null";
+ } else if (val === undefined) {
+ return "undefined";
+ } else {
+ return typeof val === "undefined" ? "undefined" : (0, _typeof3.default)(val);
+ }
+}
+
+function assertEach(callback) {
+ function validator(node, key, val) {
+ if (!Array.isArray(val)) return;
+
+ for (var i = 0; i < val.length; i++) {
+ callback(node, key + "[" + i + "]", val[i]);
+ }
+ }
+ validator.each = callback;
+ return validator;
+}
+
+function assertOneOf() {
+ for (var _len = arguments.length, vals = Array(_len), _key = 0; _key < _len; _key++) {
+ vals[_key] = arguments[_key];
+ }
+
+ function validate(node, key, val) {
+ if (vals.indexOf(val) < 0) {
+ throw new TypeError("Property " + key + " expected value to be one of " + (0, _stringify2.default)(vals) + " but got " + (0, _stringify2.default)(val));
+ }
+ }
+
+ validate.oneOf = vals;
+
+ return validate;
+}
+
+function assertNodeType() {
+ for (var _len2 = arguments.length, types = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
+ types[_key2] = arguments[_key2];
+ }
+
+ function validate(node, key, val) {
+ var valid = false;
+
+ for (var _iterator = types, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : (0, _getIterator3.default)(_iterator);;) {
+ var _ref;
+
+ if (_isArray) {
+ if (_i >= _iterator.length) break;
+ _ref = _iterator[_i++];
+ } else {
+ _i = _iterator.next();
+ if (_i.done) break;
+ _ref = _i.value;
+ }
+
+ var type = _ref;
+
+ if (t.is(type, val)) {
+ valid = true;
+ break;
+ }
+ }
+
+ if (!valid) {
+ throw new TypeError("Property " + key + " of " + node.type + " expected node to be of a type " + (0, _stringify2.default)(types) + " " + ("but instead got " + (0, _stringify2.default)(val && val.type)));
+ }
+ }
+
+ validate.oneOfNodeTypes = types;
+
+ return validate;
+}
+
+function assertNodeOrValueType() {
+ for (var _len3 = arguments.length, types = Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
+ types[_key3] = arguments[_key3];
+ }
+
+ function validate(node, key, val) {
+ var valid = false;
+
+ for (var _iterator2 = types, _isArray2 = Array.isArray(_iterator2), _i2 = 0, _iterator2 = _isArray2 ? _iterator2 : (0, _getIterator3.default)(_iterator2);;) {
+ var _ref2;
+
+ if (_isArray2) {
+ if (_i2 >= _iterator2.length) break;
+ _ref2 = _iterator2[_i2++];
+ } else {
+ _i2 = _iterator2.next();
+ if (_i2.done) break;
+ _ref2 = _i2.value;
+ }
+
+ var type = _ref2;
+
+ if (getType(val) === type || t.is(type, val)) {
+ valid = true;
+ break;
+ }
+ }
+
+ if (!valid) {
+ throw new TypeError("Property " + key + " of " + node.type + " expected node to be of a type " + (0, _stringify2.default)(types) + " " + ("but instead got " + (0, _stringify2.default)(val && val.type)));
+ }
+ }
+
+ validate.oneOfNodeOrValueTypes = types;
+
+ return validate;
+}
+
+function assertValueType(type) {
+ function validate(node, key, val) {
+ var valid = getType(val) === type;
+
+ if (!valid) {
+ throw new TypeError("Property " + key + " expected type of " + type + " but got " + getType(val));
+ }
+ }
+
+ validate.type = type;
+
+ return validate;
+}
+
+function chain() {
+ for (var _len4 = arguments.length, fns = Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
+ fns[_key4] = arguments[_key4];
+ }
+
+ function validate() {
+ for (var _iterator3 = fns, _isArray3 = Array.isArray(_iterator3), _i3 = 0, _iterator3 = _isArray3 ? _iterator3 : (0, _getIterator3.default)(_iterator3);;) {
+ var _ref3;
+
+ if (_isArray3) {
+ if (_i3 >= _iterator3.length) break;
+ _ref3 = _iterator3[_i3++];
+ } else {
+ _i3 = _iterator3.next();
+ if (_i3.done) break;
+ _ref3 = _i3.value;
+ }
+
+ var fn = _ref3;
+
+ fn.apply(undefined, arguments);
+ }
+ }
+ validate.chainOf = fns;
+ return validate;
+}
+
+function defineType(type) {
+ var opts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
+
+ var inherits = opts.inherits && store[opts.inherits] || {};
+
+ opts.fields = opts.fields || inherits.fields || {};
+ opts.visitor = opts.visitor || inherits.visitor || [];
+ opts.aliases = opts.aliases || inherits.aliases || [];
+ opts.builder = opts.builder || inherits.builder || opts.visitor || [];
+
+ if (opts.deprecatedAlias) {
+ DEPRECATED_KEYS[opts.deprecatedAlias] = type;
+ }
+
+ for (var _iterator4 = opts.visitor.concat(opts.builder), _isArray4 = Array.isArray(_iterator4), _i4 = 0, _iterator4 = _isArray4 ? _iterator4 : (0, _getIterator3.default)(_iterator4);;) {
+ var _ref4;
+
+ if (_isArray4) {
+ if (_i4 >= _iterator4.length) break;
+ _ref4 = _iterator4[_i4++];
+ } else {
+ _i4 = _iterator4.next();
+ if (_i4.done) break;
+ _ref4 = _i4.value;
+ }
+
+ var _key5 = _ref4;
+
+ opts.fields[_key5] = opts.fields[_key5] || {};
+ }
+
+ for (var key in opts.fields) {
+ var field = opts.fields[key];
+
+ if (opts.builder.indexOf(key) === -1) {
+ field.optional = true;
+ }
+ if (field.default === undefined) {
+ field.default = null;
+ } else if (!field.validate) {
+ field.validate = assertValueType(getType(field.default));
+ }
+ }
+
+ VISITOR_KEYS[type] = opts.visitor;
+ BUILDER_KEYS[type] = opts.builder;
+ NODE_FIELDS[type] = opts.fields;
+ ALIAS_KEYS[type] = opts.aliases;
+
+ store[type] = opts;
+}
+
+var store = {};
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/init.js b/node_modules/babel-types/lib/definitions/init.js
new file mode 100644
index 00000000..a3334fed
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/init.js
@@ -0,0 +1,15 @@
+"use strict";
+
+require("./index");
+
+require("./core");
+
+require("./es2015");
+
+require("./flow");
+
+require("./jsx");
+
+require("./misc");
+
+require("./experimental");
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/jsx.js b/node_modules/babel-types/lib/definitions/jsx.js
new file mode 100644
index 00000000..1c0c0665
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/jsx.js
@@ -0,0 +1,147 @@
+"use strict";
+
+var _index = require("./index");
+
+var _index2 = _interopRequireDefault(_index);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+(0, _index2.default)("JSXAttribute", {
+ visitor: ["name", "value"],
+ aliases: ["JSX", "Immutable"],
+ fields: {
+ name: {
+ validate: (0, _index.assertNodeType)("JSXIdentifier", "JSXNamespacedName")
+ },
+ value: {
+ optional: true,
+ validate: (0, _index.assertNodeType)("JSXElement", "StringLiteral", "JSXExpressionContainer")
+ }
+ }
+});
+
+(0, _index2.default)("JSXClosingElement", {
+ visitor: ["name"],
+ aliases: ["JSX", "Immutable"],
+ fields: {
+ name: {
+ validate: (0, _index.assertNodeType)("JSXIdentifier", "JSXMemberExpression")
+ }
+ }
+});
+
+(0, _index2.default)("JSXElement", {
+ builder: ["openingElement", "closingElement", "children", "selfClosing"],
+ visitor: ["openingElement", "children", "closingElement"],
+ aliases: ["JSX", "Immutable", "Expression"],
+ fields: {
+ openingElement: {
+ validate: (0, _index.assertNodeType)("JSXOpeningElement")
+ },
+ closingElement: {
+ optional: true,
+ validate: (0, _index.assertNodeType)("JSXClosingElement")
+ },
+ children: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("JSXText", "JSXExpressionContainer", "JSXSpreadChild", "JSXElement")))
+ }
+ }
+});
+
+(0, _index2.default)("JSXEmptyExpression", {
+ aliases: ["JSX", "Expression"]
+});
+
+(0, _index2.default)("JSXExpressionContainer", {
+ visitor: ["expression"],
+ aliases: ["JSX", "Immutable"],
+ fields: {
+ expression: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index2.default)("JSXSpreadChild", {
+ visitor: ["expression"],
+ aliases: ["JSX", "Immutable"],
+ fields: {
+ expression: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index2.default)("JSXIdentifier", {
+ builder: ["name"],
+ aliases: ["JSX", "Expression"],
+ fields: {
+ name: {
+ validate: (0, _index.assertValueType)("string")
+ }
+ }
+});
+
+(0, _index2.default)("JSXMemberExpression", {
+ visitor: ["object", "property"],
+ aliases: ["JSX", "Expression"],
+ fields: {
+ object: {
+ validate: (0, _index.assertNodeType)("JSXMemberExpression", "JSXIdentifier")
+ },
+ property: {
+ validate: (0, _index.assertNodeType)("JSXIdentifier")
+ }
+ }
+});
+
+(0, _index2.default)("JSXNamespacedName", {
+ visitor: ["namespace", "name"],
+ aliases: ["JSX"],
+ fields: {
+ namespace: {
+ validate: (0, _index.assertNodeType)("JSXIdentifier")
+ },
+ name: {
+ validate: (0, _index.assertNodeType)("JSXIdentifier")
+ }
+ }
+});
+
+(0, _index2.default)("JSXOpeningElement", {
+ builder: ["name", "attributes", "selfClosing"],
+ visitor: ["name", "attributes"],
+ aliases: ["JSX", "Immutable"],
+ fields: {
+ name: {
+ validate: (0, _index.assertNodeType)("JSXIdentifier", "JSXMemberExpression")
+ },
+ selfClosing: {
+ default: false,
+ validate: (0, _index.assertValueType)("boolean")
+ },
+ attributes: {
+ validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("JSXAttribute", "JSXSpreadAttribute")))
+ }
+ }
+});
+
+(0, _index2.default)("JSXSpreadAttribute", {
+ visitor: ["argument"],
+ aliases: ["JSX"],
+ fields: {
+ argument: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
+
+(0, _index2.default)("JSXText", {
+ aliases: ["JSX", "Immutable"],
+ builder: ["value"],
+ fields: {
+ value: {
+ validate: (0, _index.assertValueType)("string")
+ }
+ }
+});
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/definitions/misc.js b/node_modules/babel-types/lib/definitions/misc.js
new file mode 100644
index 00000000..f982b9a8
--- /dev/null
+++ b/node_modules/babel-types/lib/definitions/misc.js
@@ -0,0 +1,21 @@
+"use strict";
+
+var _index = require("./index");
+
+var _index2 = _interopRequireDefault(_index);
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+(0, _index2.default)("Noop", {
+ visitor: []
+});
+
+(0, _index2.default)("ParenthesizedExpression", {
+ visitor: ["expression"],
+ aliases: ["Expression", "ExpressionWrapper"],
+ fields: {
+ expression: {
+ validate: (0, _index.assertNodeType)("Expression")
+ }
+ }
+});
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/flow.js b/node_modules/babel-types/lib/flow.js
new file mode 100644
index 00000000..28579157
--- /dev/null
+++ b/node_modules/babel-types/lib/flow.js
@@ -0,0 +1,108 @@
+"use strict";
+
+exports.__esModule = true;
+exports.createUnionTypeAnnotation = createUnionTypeAnnotation;
+exports.removeTypeDuplicates = removeTypeDuplicates;
+exports.createTypeAnnotationBasedOnTypeof = createTypeAnnotationBasedOnTypeof;
+
+var _index = require("./index");
+
+var t = _interopRequireWildcard(_index);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function createUnionTypeAnnotation(types) {
+ var flattened = removeTypeDuplicates(types);
+
+ if (flattened.length === 1) {
+ return flattened[0];
+ } else {
+ return t.unionTypeAnnotation(flattened);
+ }
+}
+
+function removeTypeDuplicates(nodes) {
+ var generics = {};
+ var bases = {};
+
+ var typeGroups = [];
+
+ var types = [];
+
+ for (var i = 0; i < nodes.length; i++) {
+ var node = nodes[i];
+ if (!node) continue;
+
+ if (types.indexOf(node) >= 0) {
+ continue;
+ }
+
+ if (t.isAnyTypeAnnotation(node)) {
+ return [node];
+ }
+
+ if (t.isFlowBaseAnnotation(node)) {
+ bases[node.type] = node;
+ continue;
+ }
+
+ if (t.isUnionTypeAnnotation(node)) {
+ if (typeGroups.indexOf(node.types) < 0) {
+ nodes = nodes.concat(node.types);
+ typeGroups.push(node.types);
+ }
+ continue;
+ }
+
+ if (t.isGenericTypeAnnotation(node)) {
+ var name = node.id.name;
+
+ if (generics[name]) {
+ var existing = generics[name];
+ if (existing.typeParameters) {
+ if (node.typeParameters) {
+ existing.typeParameters.params = removeTypeDuplicates(existing.typeParameters.params.concat(node.typeParameters.params));
+ }
+ } else {
+ existing = node.typeParameters;
+ }
+ } else {
+ generics[name] = node;
+ }
+
+ continue;
+ }
+
+ types.push(node);
+ }
+
+ for (var type in bases) {
+ types.push(bases[type]);
+ }
+
+ for (var _name in generics) {
+ types.push(generics[_name]);
+ }
+
+ return types;
+}
+
+function createTypeAnnotationBasedOnTypeof(type) {
+ if (type === "string") {
+ return t.stringTypeAnnotation();
+ } else if (type === "number") {
+ return t.numberTypeAnnotation();
+ } else if (type === "undefined") {
+ return t.voidTypeAnnotation();
+ } else if (type === "boolean") {
+ return t.booleanTypeAnnotation();
+ } else if (type === "function") {
+ return t.genericTypeAnnotation(t.identifier("Function"));
+ } else if (type === "object") {
+ return t.genericTypeAnnotation(t.identifier("Object"));
+ } else if (type === "symbol") {
+ return t.genericTypeAnnotation(t.identifier("Symbol"));
+ } else {
+ throw new Error("Invalid typeof value");
+ }
+}
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/index.js b/node_modules/babel-types/lib/index.js
new file mode 100644
index 00000000..3653bb74
--- /dev/null
+++ b/node_modules/babel-types/lib/index.js
@@ -0,0 +1,839 @@
+"use strict";
+
+exports.__esModule = true;
+exports.createTypeAnnotationBasedOnTypeof = exports.removeTypeDuplicates = exports.createUnionTypeAnnotation = exports.valueToNode = exports.toBlock = exports.toExpression = exports.toStatement = exports.toBindingIdentifierName = exports.toIdentifier = exports.toKeyAlias = exports.toSequenceExpression = exports.toComputedKey = exports.isNodesEquivalent = exports.isImmutable = exports.isScope = exports.isSpecifierDefault = exports.isVar = exports.isBlockScoped = exports.isLet = exports.isValidIdentifier = exports.isReferenced = exports.isBinding = exports.getOuterBindingIdentifiers = exports.getBindingIdentifiers = exports.TYPES = exports.react = exports.DEPRECATED_KEYS = exports.BUILDER_KEYS = exports.NODE_FIELDS = exports.ALIAS_KEYS = exports.VISITOR_KEYS = exports.NOT_LOCAL_BINDING = exports.BLOCK_SCOPED_SYMBOL = exports.INHERIT_KEYS = exports.UNARY_OPERATORS = exports.STRING_UNARY_OPERATORS = exports.NUMBER_UNARY_OPERATORS = exports.BOOLEAN_UNARY_OPERATORS = exports.BINARY_OPERATORS = exports.NUMBER_BINARY_OPERATORS = exports.BOOLEAN_BINARY_OPERATORS = exports.COMPARISON_BINARY_OPERATORS = exports.EQUALITY_BINARY_OPERATORS = exports.BOOLEAN_NUMBER_BINARY_OPERATORS = exports.UPDATE_OPERATORS = exports.LOGICAL_OPERATORS = exports.COMMENT_KEYS = exports.FOR_INIT_KEYS = exports.FLATTENABLE_KEYS = exports.STATEMENT_OR_BLOCK_KEYS = undefined;
+
+var _getOwnPropertySymbols = require("babel-runtime/core-js/object/get-own-property-symbols");
+
+var _getOwnPropertySymbols2 = _interopRequireDefault(_getOwnPropertySymbols);
+
+var _getIterator2 = require("babel-runtime/core-js/get-iterator");
+
+var _getIterator3 = _interopRequireDefault(_getIterator2);
+
+var _keys = require("babel-runtime/core-js/object/keys");
+
+var _keys2 = _interopRequireDefault(_keys);
+
+var _stringify = require("babel-runtime/core-js/json/stringify");
+
+var _stringify2 = _interopRequireDefault(_stringify);
+
+var _constants = require("./constants");
+
+Object.defineProperty(exports, "STATEMENT_OR_BLOCK_KEYS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.STATEMENT_OR_BLOCK_KEYS;
+ }
+});
+Object.defineProperty(exports, "FLATTENABLE_KEYS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.FLATTENABLE_KEYS;
+ }
+});
+Object.defineProperty(exports, "FOR_INIT_KEYS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.FOR_INIT_KEYS;
+ }
+});
+Object.defineProperty(exports, "COMMENT_KEYS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.COMMENT_KEYS;
+ }
+});
+Object.defineProperty(exports, "LOGICAL_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.LOGICAL_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "UPDATE_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.UPDATE_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "BOOLEAN_NUMBER_BINARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.BOOLEAN_NUMBER_BINARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "EQUALITY_BINARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.EQUALITY_BINARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "COMPARISON_BINARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.COMPARISON_BINARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "BOOLEAN_BINARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.BOOLEAN_BINARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "NUMBER_BINARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.NUMBER_BINARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "BINARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.BINARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "BOOLEAN_UNARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.BOOLEAN_UNARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "NUMBER_UNARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.NUMBER_UNARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "STRING_UNARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.STRING_UNARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "UNARY_OPERATORS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.UNARY_OPERATORS;
+ }
+});
+Object.defineProperty(exports, "INHERIT_KEYS", {
+ enumerable: true,
+ get: function get() {
+ return _constants.INHERIT_KEYS;
+ }
+});
+Object.defineProperty(exports, "BLOCK_SCOPED_SYMBOL", {
+ enumerable: true,
+ get: function get() {
+ return _constants.BLOCK_SCOPED_SYMBOL;
+ }
+});
+Object.defineProperty(exports, "NOT_LOCAL_BINDING", {
+ enumerable: true,
+ get: function get() {
+ return _constants.NOT_LOCAL_BINDING;
+ }
+});
+exports.is = is;
+exports.isType = isType;
+exports.validate = validate;
+exports.shallowEqual = shallowEqual;
+exports.appendToMemberExpression = appendToMemberExpression;
+exports.prependToMemberExpression = prependToMemberExpression;
+exports.ensureBlock = ensureBlock;
+exports.clone = clone;
+exports.cloneWithoutLoc = cloneWithoutLoc;
+exports.cloneDeep = cloneDeep;
+exports.buildMatchMemberExpression = buildMatchMemberExpression;
+exports.removeComments = removeComments;
+exports.inheritsComments = inheritsComments;
+exports.inheritTrailingComments = inheritTrailingComments;
+exports.inheritLeadingComments = inheritLeadingComments;
+exports.inheritInnerComments = inheritInnerComments;
+exports.inherits = inherits;
+exports.assertNode = assertNode;
+exports.isNode = isNode;
+exports.traverseFast = traverseFast;
+exports.removeProperties = removeProperties;
+exports.removePropertiesDeep = removePropertiesDeep;
+
+var _retrievers = require("./retrievers");
+
+Object.defineProperty(exports, "getBindingIdentifiers", {
+ enumerable: true,
+ get: function get() {
+ return _retrievers.getBindingIdentifiers;
+ }
+});
+Object.defineProperty(exports, "getOuterBindingIdentifiers", {
+ enumerable: true,
+ get: function get() {
+ return _retrievers.getOuterBindingIdentifiers;
+ }
+});
+
+var _validators = require("./validators");
+
+Object.defineProperty(exports, "isBinding", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isBinding;
+ }
+});
+Object.defineProperty(exports, "isReferenced", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isReferenced;
+ }
+});
+Object.defineProperty(exports, "isValidIdentifier", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isValidIdentifier;
+ }
+});
+Object.defineProperty(exports, "isLet", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isLet;
+ }
+});
+Object.defineProperty(exports, "isBlockScoped", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isBlockScoped;
+ }
+});
+Object.defineProperty(exports, "isVar", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isVar;
+ }
+});
+Object.defineProperty(exports, "isSpecifierDefault", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isSpecifierDefault;
+ }
+});
+Object.defineProperty(exports, "isScope", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isScope;
+ }
+});
+Object.defineProperty(exports, "isImmutable", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isImmutable;
+ }
+});
+Object.defineProperty(exports, "isNodesEquivalent", {
+ enumerable: true,
+ get: function get() {
+ return _validators.isNodesEquivalent;
+ }
+});
+
+var _converters = require("./converters");
+
+Object.defineProperty(exports, "toComputedKey", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toComputedKey;
+ }
+});
+Object.defineProperty(exports, "toSequenceExpression", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toSequenceExpression;
+ }
+});
+Object.defineProperty(exports, "toKeyAlias", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toKeyAlias;
+ }
+});
+Object.defineProperty(exports, "toIdentifier", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toIdentifier;
+ }
+});
+Object.defineProperty(exports, "toBindingIdentifierName", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toBindingIdentifierName;
+ }
+});
+Object.defineProperty(exports, "toStatement", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toStatement;
+ }
+});
+Object.defineProperty(exports, "toExpression", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toExpression;
+ }
+});
+Object.defineProperty(exports, "toBlock", {
+ enumerable: true,
+ get: function get() {
+ return _converters.toBlock;
+ }
+});
+Object.defineProperty(exports, "valueToNode", {
+ enumerable: true,
+ get: function get() {
+ return _converters.valueToNode;
+ }
+});
+
+var _flow = require("./flow");
+
+Object.defineProperty(exports, "createUnionTypeAnnotation", {
+ enumerable: true,
+ get: function get() {
+ return _flow.createUnionTypeAnnotation;
+ }
+});
+Object.defineProperty(exports, "removeTypeDuplicates", {
+ enumerable: true,
+ get: function get() {
+ return _flow.removeTypeDuplicates;
+ }
+});
+Object.defineProperty(exports, "createTypeAnnotationBasedOnTypeof", {
+ enumerable: true,
+ get: function get() {
+ return _flow.createTypeAnnotationBasedOnTypeof;
+ }
+});
+
+var _toFastProperties = require("to-fast-properties");
+
+var _toFastProperties2 = _interopRequireDefault(_toFastProperties);
+
+var _compact = require("lodash/compact");
+
+var _compact2 = _interopRequireDefault(_compact);
+
+var _clone = require("lodash/clone");
+
+var _clone2 = _interopRequireDefault(_clone);
+
+var _uniq = require("lodash/uniq");
+
+var _uniq2 = _interopRequireDefault(_uniq);
+
+require("./definitions/init");
+
+var _definitions = require("./definitions");
+
+var _react2 = require("./react");
+
+var _react = _interopRequireWildcard(_react2);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+var t = exports;
+
+function registerType(type) {
+ var is = t["is" + type];
+ if (!is) {
+ is = t["is" + type] = function (node, opts) {
+ return t.is(type, node, opts);
+ };
+ }
+
+ t["assert" + type] = function (node, opts) {
+ opts = opts || {};
+ if (!is(node, opts)) {
+ throw new Error("Expected type " + (0, _stringify2.default)(type) + " with option " + (0, _stringify2.default)(opts));
+ }
+ };
+}
+
+exports.VISITOR_KEYS = _definitions.VISITOR_KEYS;
+exports.ALIAS_KEYS = _definitions.ALIAS_KEYS;
+exports.NODE_FIELDS = _definitions.NODE_FIELDS;
+exports.BUILDER_KEYS = _definitions.BUILDER_KEYS;
+exports.DEPRECATED_KEYS = _definitions.DEPRECATED_KEYS;
+exports.react = _react;
+
+
+for (var type in t.VISITOR_KEYS) {
+ registerType(type);
+}
+
+t.FLIPPED_ALIAS_KEYS = {};
+
+(0, _keys2.default)(t.ALIAS_KEYS).forEach(function (type) {
+ t.ALIAS_KEYS[type].forEach(function (alias) {
+ var types = t.FLIPPED_ALIAS_KEYS[alias] = t.FLIPPED_ALIAS_KEYS[alias] || [];
+ types.push(type);
+ });
+});
+
+(0, _keys2.default)(t.FLIPPED_ALIAS_KEYS).forEach(function (type) {
+ t[type.toUpperCase() + "_TYPES"] = t.FLIPPED_ALIAS_KEYS[type];
+ registerType(type);
+});
+
+var TYPES = exports.TYPES = (0, _keys2.default)(t.VISITOR_KEYS).concat((0, _keys2.default)(t.FLIPPED_ALIAS_KEYS)).concat((0, _keys2.default)(t.DEPRECATED_KEYS));
+
+function is(type, node, opts) {
+ if (!node) return false;
+
+ var matches = isType(node.type, type);
+ if (!matches) return false;
+
+ if (typeof opts === "undefined") {
+ return true;
+ } else {
+ return t.shallowEqual(node, opts);
+ }
+}
+
+function isType(nodeType, targetType) {
+ if (nodeType === targetType) return true;
+
+ if (t.ALIAS_KEYS[targetType]) return false;
+
+ var aliases = t.FLIPPED_ALIAS_KEYS[targetType];
+ if (aliases) {
+ if (aliases[0] === nodeType) return true;
+
+ for (var _iterator = aliases, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : (0, _getIterator3.default)(_iterator);;) {
+ var _ref;
+
+ if (_isArray) {
+ if (_i >= _iterator.length) break;
+ _ref = _iterator[_i++];
+ } else {
+ _i = _iterator.next();
+ if (_i.done) break;
+ _ref = _i.value;
+ }
+
+ var alias = _ref;
+
+ if (nodeType === alias) return true;
+ }
+ }
+
+ return false;
+}
+
+(0, _keys2.default)(t.BUILDER_KEYS).forEach(function (type) {
+ var keys = t.BUILDER_KEYS[type];
+
+ function builder() {
+ if (arguments.length > keys.length) {
+ throw new Error("t." + type + ": Too many arguments passed. Received " + arguments.length + " but can receive " + ("no more than " + keys.length));
+ }
+
+ var node = {};
+ node.type = type;
+
+ var i = 0;
+
+ for (var _iterator2 = keys, _isArray2 = Array.isArray(_iterator2), _i2 = 0, _iterator2 = _isArray2 ? _iterator2 : (0, _getIterator3.default)(_iterator2);;) {
+ var _ref2;
+
+ if (_isArray2) {
+ if (_i2 >= _iterator2.length) break;
+ _ref2 = _iterator2[_i2++];
+ } else {
+ _i2 = _iterator2.next();
+ if (_i2.done) break;
+ _ref2 = _i2.value;
+ }
+
+ var _key = _ref2;
+
+ var field = t.NODE_FIELDS[type][_key];
+
+ var arg = arguments[i++];
+ if (arg === undefined) arg = (0, _clone2.default)(field.default);
+
+ node[_key] = arg;
+ }
+
+ for (var key in node) {
+ validate(node, key, node[key]);
+ }
+
+ return node;
+ }
+
+ t[type] = builder;
+ t[type[0].toLowerCase() + type.slice(1)] = builder;
+});
+
+var _loop = function _loop(_type) {
+ var newType = t.DEPRECATED_KEYS[_type];
+
+ function proxy(fn) {
+ return function () {
+ console.trace("The node type " + _type + " has been renamed to " + newType);
+ return fn.apply(this, arguments);
+ };
+ }
+
+ t[_type] = t[_type[0].toLowerCase() + _type.slice(1)] = proxy(t[newType]);
+ t["is" + _type] = proxy(t["is" + newType]);
+ t["assert" + _type] = proxy(t["assert" + newType]);
+};
+
+for (var _type in t.DEPRECATED_KEYS) {
+ _loop(_type);
+}
+
+function validate(node, key, val) {
+ if (!node) return;
+
+ var fields = t.NODE_FIELDS[node.type];
+ if (!fields) return;
+
+ var field = fields[key];
+ if (!field || !field.validate) return;
+ if (field.optional && val == null) return;
+
+ field.validate(node, key, val);
+}
+
+function shallowEqual(actual, expected) {
+ var keys = (0, _keys2.default)(expected);
+
+ for (var _iterator3 = keys, _isArray3 = Array.isArray(_iterator3), _i3 = 0, _iterator3 = _isArray3 ? _iterator3 : (0, _getIterator3.default)(_iterator3);;) {
+ var _ref3;
+
+ if (_isArray3) {
+ if (_i3 >= _iterator3.length) break;
+ _ref3 = _iterator3[_i3++];
+ } else {
+ _i3 = _iterator3.next();
+ if (_i3.done) break;
+ _ref3 = _i3.value;
+ }
+
+ var key = _ref3;
+
+ if (actual[key] !== expected[key]) {
+ return false;
+ }
+ }
+
+ return true;
+}
+
+function appendToMemberExpression(member, append, computed) {
+ member.object = t.memberExpression(member.object, member.property, member.computed);
+ member.property = append;
+ member.computed = !!computed;
+ return member;
+}
+
+function prependToMemberExpression(member, prepend) {
+ member.object = t.memberExpression(prepend, member.object);
+ return member;
+}
+
+function ensureBlock(node) {
+ var key = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "body";
+
+ return node[key] = t.toBlock(node[key], node);
+}
+
+function clone(node) {
+ if (!node) return node;
+ var newNode = {};
+ for (var key in node) {
+ if (key[0] === "_") continue;
+ newNode[key] = node[key];
+ }
+ return newNode;
+}
+
+function cloneWithoutLoc(node) {
+ var newNode = clone(node);
+ delete newNode.loc;
+ return newNode;
+}
+
+function cloneDeep(node) {
+ if (!node) return node;
+ var newNode = {};
+
+ for (var key in node) {
+ if (key[0] === "_") continue;
+
+ var val = node[key];
+
+ if (val) {
+ if (val.type) {
+ val = t.cloneDeep(val);
+ } else if (Array.isArray(val)) {
+ val = val.map(t.cloneDeep);
+ }
+ }
+
+ newNode[key] = val;
+ }
+
+ return newNode;
+}
+
+function buildMatchMemberExpression(match, allowPartial) {
+ var parts = match.split(".");
+
+ return function (member) {
+ if (!t.isMemberExpression(member)) return false;
+
+ var search = [member];
+ var i = 0;
+
+ while (search.length) {
+ var node = search.shift();
+
+ if (allowPartial && i === parts.length) {
+ return true;
+ }
+
+ if (t.isIdentifier(node)) {
+ if (parts[i] !== node.name) return false;
+ } else if (t.isStringLiteral(node)) {
+ if (parts[i] !== node.value) return false;
+ } else if (t.isMemberExpression(node)) {
+ if (node.computed && !t.isStringLiteral(node.property)) {
+ return false;
+ } else {
+ search.push(node.object);
+ search.push(node.property);
+ continue;
+ }
+ } else {
+ return false;
+ }
+
+ if (++i > parts.length) {
+ return false;
+ }
+ }
+
+ return true;
+ };
+}
+
+function removeComments(node) {
+ for (var _iterator4 = t.COMMENT_KEYS, _isArray4 = Array.isArray(_iterator4), _i4 = 0, _iterator4 = _isArray4 ? _iterator4 : (0, _getIterator3.default)(_iterator4);;) {
+ var _ref4;
+
+ if (_isArray4) {
+ if (_i4 >= _iterator4.length) break;
+ _ref4 = _iterator4[_i4++];
+ } else {
+ _i4 = _iterator4.next();
+ if (_i4.done) break;
+ _ref4 = _i4.value;
+ }
+
+ var key = _ref4;
+
+ delete node[key];
+ }
+ return node;
+}
+
+function inheritsComments(child, parent) {
+ inheritTrailingComments(child, parent);
+ inheritLeadingComments(child, parent);
+ inheritInnerComments(child, parent);
+ return child;
+}
+
+function inheritTrailingComments(child, parent) {
+ _inheritComments("trailingComments", child, parent);
+}
+
+function inheritLeadingComments(child, parent) {
+ _inheritComments("leadingComments", child, parent);
+}
+
+function inheritInnerComments(child, parent) {
+ _inheritComments("innerComments", child, parent);
+}
+
+function _inheritComments(key, child, parent) {
+ if (child && parent) {
+ child[key] = (0, _uniq2.default)((0, _compact2.default)([].concat(child[key], parent[key])));
+ }
+}
+
+function inherits(child, parent) {
+ if (!child || !parent) return child;
+
+ for (var _iterator5 = t.INHERIT_KEYS.optional, _isArray5 = Array.isArray(_iterator5), _i5 = 0, _iterator5 = _isArray5 ? _iterator5 : (0, _getIterator3.default)(_iterator5);;) {
+ var _ref5;
+
+ if (_isArray5) {
+ if (_i5 >= _iterator5.length) break;
+ _ref5 = _iterator5[_i5++];
+ } else {
+ _i5 = _iterator5.next();
+ if (_i5.done) break;
+ _ref5 = _i5.value;
+ }
+
+ var _key2 = _ref5;
+
+ if (child[_key2] == null) {
+ child[_key2] = parent[_key2];
+ }
+ }
+
+ for (var key in parent) {
+ if (key[0] === "_") child[key] = parent[key];
+ }
+
+ for (var _iterator6 = t.INHERIT_KEYS.force, _isArray6 = Array.isArray(_iterator6), _i6 = 0, _iterator6 = _isArray6 ? _iterator6 : (0, _getIterator3.default)(_iterator6);;) {
+ var _ref6;
+
+ if (_isArray6) {
+ if (_i6 >= _iterator6.length) break;
+ _ref6 = _iterator6[_i6++];
+ } else {
+ _i6 = _iterator6.next();
+ if (_i6.done) break;
+ _ref6 = _i6.value;
+ }
+
+ var _key3 = _ref6;
+
+ child[_key3] = parent[_key3];
+ }
+
+ t.inheritsComments(child, parent);
+
+ return child;
+}
+
+function assertNode(node) {
+ if (!isNode(node)) {
+ throw new TypeError("Not a valid node " + (node && node.type));
+ }
+}
+
+function isNode(node) {
+ return !!(node && _definitions.VISITOR_KEYS[node.type]);
+}
+
+(0, _toFastProperties2.default)(t);
+(0, _toFastProperties2.default)(t.VISITOR_KEYS);
+
+function traverseFast(node, enter, opts) {
+ if (!node) return;
+
+ var keys = t.VISITOR_KEYS[node.type];
+ if (!keys) return;
+
+ opts = opts || {};
+ enter(node, opts);
+
+ for (var _iterator7 = keys, _isArray7 = Array.isArray(_iterator7), _i7 = 0, _iterator7 = _isArray7 ? _iterator7 : (0, _getIterator3.default)(_iterator7);;) {
+ var _ref7;
+
+ if (_isArray7) {
+ if (_i7 >= _iterator7.length) break;
+ _ref7 = _iterator7[_i7++];
+ } else {
+ _i7 = _iterator7.next();
+ if (_i7.done) break;
+ _ref7 = _i7.value;
+ }
+
+ var key = _ref7;
+
+ var subNode = node[key];
+
+ if (Array.isArray(subNode)) {
+ for (var _iterator8 = subNode, _isArray8 = Array.isArray(_iterator8), _i8 = 0, _iterator8 = _isArray8 ? _iterator8 : (0, _getIterator3.default)(_iterator8);;) {
+ var _ref8;
+
+ if (_isArray8) {
+ if (_i8 >= _iterator8.length) break;
+ _ref8 = _iterator8[_i8++];
+ } else {
+ _i8 = _iterator8.next();
+ if (_i8.done) break;
+ _ref8 = _i8.value;
+ }
+
+ var _node = _ref8;
+
+ traverseFast(_node, enter, opts);
+ }
+ } else {
+ traverseFast(subNode, enter, opts);
+ }
+ }
+}
+
+var CLEAR_KEYS = ["tokens", "start", "end", "loc", "raw", "rawValue"];
+
+var CLEAR_KEYS_PLUS_COMMENTS = t.COMMENT_KEYS.concat(["comments"]).concat(CLEAR_KEYS);
+
+function removeProperties(node, opts) {
+ opts = opts || {};
+ var map = opts.preserveComments ? CLEAR_KEYS : CLEAR_KEYS_PLUS_COMMENTS;
+ for (var _iterator9 = map, _isArray9 = Array.isArray(_iterator9), _i9 = 0, _iterator9 = _isArray9 ? _iterator9 : (0, _getIterator3.default)(_iterator9);;) {
+ var _ref9;
+
+ if (_isArray9) {
+ if (_i9 >= _iterator9.length) break;
+ _ref9 = _iterator9[_i9++];
+ } else {
+ _i9 = _iterator9.next();
+ if (_i9.done) break;
+ _ref9 = _i9.value;
+ }
+
+ var _key4 = _ref9;
+
+ if (node[_key4] != null) node[_key4] = undefined;
+ }
+
+ for (var key in node) {
+ if (key[0] === "_" && node[key] != null) node[key] = undefined;
+ }
+
+ var syms = (0, _getOwnPropertySymbols2.default)(node);
+ for (var _iterator10 = syms, _isArray10 = Array.isArray(_iterator10), _i10 = 0, _iterator10 = _isArray10 ? _iterator10 : (0, _getIterator3.default)(_iterator10);;) {
+ var _ref10;
+
+ if (_isArray10) {
+ if (_i10 >= _iterator10.length) break;
+ _ref10 = _iterator10[_i10++];
+ } else {
+ _i10 = _iterator10.next();
+ if (_i10.done) break;
+ _ref10 = _i10.value;
+ }
+
+ var sym = _ref10;
+
+ node[sym] = null;
+ }
+}
+
+function removePropertiesDeep(tree, opts) {
+ traverseFast(tree, removeProperties, opts);
+ return tree;
+}
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/react.js b/node_modules/babel-types/lib/react.js
new file mode 100644
index 00000000..923ee123
--- /dev/null
+++ b/node_modules/babel-types/lib/react.js
@@ -0,0 +1,80 @@
+"use strict";
+
+exports.__esModule = true;
+exports.isReactComponent = undefined;
+exports.isCompatTag = isCompatTag;
+exports.buildChildren = buildChildren;
+
+var _index = require("./index");
+
+var t = _interopRequireWildcard(_index);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+var isReactComponent = exports.isReactComponent = t.buildMatchMemberExpression("React.Component");
+
+function isCompatTag(tagName) {
+ return !!tagName && /^[a-z]|\-/.test(tagName);
+}
+
+function cleanJSXElementLiteralChild(child, args) {
+ var lines = child.value.split(/\r\n|\n|\r/);
+
+ var lastNonEmptyLine = 0;
+
+ for (var i = 0; i < lines.length; i++) {
+ if (lines[i].match(/[^ \t]/)) {
+ lastNonEmptyLine = i;
+ }
+ }
+
+ var str = "";
+
+ for (var _i = 0; _i < lines.length; _i++) {
+ var line = lines[_i];
+
+ var isFirstLine = _i === 0;
+ var isLastLine = _i === lines.length - 1;
+ var isLastNonEmptyLine = _i === lastNonEmptyLine;
+
+ var trimmedLine = line.replace(/\t/g, " ");
+
+ if (!isFirstLine) {
+ trimmedLine = trimmedLine.replace(/^[ ]+/, "");
+ }
+
+ if (!isLastLine) {
+ trimmedLine = trimmedLine.replace(/[ ]+$/, "");
+ }
+
+ if (trimmedLine) {
+ if (!isLastNonEmptyLine) {
+ trimmedLine += " ";
+ }
+
+ str += trimmedLine;
+ }
+ }
+
+ if (str) args.push(t.stringLiteral(str));
+}
+
+function buildChildren(node) {
+ var elems = [];
+
+ for (var i = 0; i < node.children.length; i++) {
+ var child = node.children[i];
+
+ if (t.isJSXText(child)) {
+ cleanJSXElementLiteralChild(child, elems);
+ continue;
+ }
+
+ if (t.isJSXExpressionContainer(child)) child = child.expression;
+ if (t.isJSXEmptyExpression(child)) continue;
+
+ elems.push(child);
+ }
+
+ return elems;
+}
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/retrievers.js b/node_modules/babel-types/lib/retrievers.js
new file mode 100644
index 00000000..e5782e08
--- /dev/null
+++ b/node_modules/babel-types/lib/retrievers.js
@@ -0,0 +1,115 @@
+"use strict";
+
+exports.__esModule = true;
+
+var _create = require("babel-runtime/core-js/object/create");
+
+var _create2 = _interopRequireDefault(_create);
+
+exports.getBindingIdentifiers = getBindingIdentifiers;
+exports.getOuterBindingIdentifiers = getOuterBindingIdentifiers;
+
+var _index = require("./index");
+
+var t = _interopRequireWildcard(_index);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+function getBindingIdentifiers(node, duplicates, outerOnly) {
+ var search = [].concat(node);
+ var ids = (0, _create2.default)(null);
+
+ while (search.length) {
+ var id = search.shift();
+ if (!id) continue;
+
+ var keys = t.getBindingIdentifiers.keys[id.type];
+
+ if (t.isIdentifier(id)) {
+ if (duplicates) {
+ var _ids = ids[id.name] = ids[id.name] || [];
+ _ids.push(id);
+ } else {
+ ids[id.name] = id;
+ }
+ continue;
+ }
+
+ if (t.isExportDeclaration(id)) {
+ if (t.isDeclaration(id.declaration)) {
+ search.push(id.declaration);
+ }
+ continue;
+ }
+
+ if (outerOnly) {
+ if (t.isFunctionDeclaration(id)) {
+ search.push(id.id);
+ continue;
+ }
+
+ if (t.isFunctionExpression(id)) {
+ continue;
+ }
+ }
+
+ if (keys) {
+ for (var i = 0; i < keys.length; i++) {
+ var key = keys[i];
+ if (id[key]) {
+ search = search.concat(id[key]);
+ }
+ }
+ }
+ }
+
+ return ids;
+}
+
+getBindingIdentifiers.keys = {
+ DeclareClass: ["id"],
+ DeclareFunction: ["id"],
+ DeclareModule: ["id"],
+ DeclareVariable: ["id"],
+ InterfaceDeclaration: ["id"],
+ TypeAlias: ["id"],
+
+ CatchClause: ["param"],
+ LabeledStatement: ["label"],
+ UnaryExpression: ["argument"],
+ AssignmentExpression: ["left"],
+
+ ImportSpecifier: ["local"],
+ ImportNamespaceSpecifier: ["local"],
+ ImportDefaultSpecifier: ["local"],
+ ImportDeclaration: ["specifiers"],
+
+ ExportSpecifier: ["exported"],
+ ExportNamespaceSpecifier: ["exported"],
+ ExportDefaultSpecifier: ["exported"],
+
+ FunctionDeclaration: ["id", "params"],
+ FunctionExpression: ["id", "params"],
+
+ ClassDeclaration: ["id"],
+ ClassExpression: ["id"],
+
+ RestElement: ["argument"],
+ UpdateExpression: ["argument"],
+
+ RestProperty: ["argument"],
+ ObjectProperty: ["value"],
+
+ AssignmentPattern: ["left"],
+ ArrayPattern: ["elements"],
+ ObjectPattern: ["properties"],
+
+ VariableDeclaration: ["declarations"],
+ VariableDeclarator: ["id"]
+};
+
+function getOuterBindingIdentifiers(node, duplicates) {
+ return getBindingIdentifiers(node, duplicates, true);
+}
\ No newline at end of file
diff --git a/node_modules/babel-types/lib/validators.js b/node_modules/babel-types/lib/validators.js
new file mode 100644
index 00000000..23578a1d
--- /dev/null
+++ b/node_modules/babel-types/lib/validators.js
@@ -0,0 +1,263 @@
+"use strict";
+
+exports.__esModule = true;
+
+var _keys = require("babel-runtime/core-js/object/keys");
+
+var _keys2 = _interopRequireDefault(_keys);
+
+var _typeof2 = require("babel-runtime/helpers/typeof");
+
+var _typeof3 = _interopRequireDefault(_typeof2);
+
+var _getIterator2 = require("babel-runtime/core-js/get-iterator");
+
+var _getIterator3 = _interopRequireDefault(_getIterator2);
+
+exports.isBinding = isBinding;
+exports.isReferenced = isReferenced;
+exports.isValidIdentifier = isValidIdentifier;
+exports.isLet = isLet;
+exports.isBlockScoped = isBlockScoped;
+exports.isVar = isVar;
+exports.isSpecifierDefault = isSpecifierDefault;
+exports.isScope = isScope;
+exports.isImmutable = isImmutable;
+exports.isNodesEquivalent = isNodesEquivalent;
+
+var _retrievers = require("./retrievers");
+
+var _esutils = require("esutils");
+
+var _esutils2 = _interopRequireDefault(_esutils);
+
+var _index = require("./index");
+
+var t = _interopRequireWildcard(_index);
+
+var _constants = require("./constants");
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+function isBinding(node, parent) {
+ var keys = _retrievers.getBindingIdentifiers.keys[parent.type];
+ if (keys) {
+ for (var i = 0; i < keys.length; i++) {
+ var key = keys[i];
+ var val = parent[key];
+ if (Array.isArray(val)) {
+ if (val.indexOf(node) >= 0) return true;
+ } else {
+ if (val === node) return true;
+ }
+ }
+ }
+
+ return false;
+}
+
+function isReferenced(node, parent) {
+ switch (parent.type) {
+ case "BindExpression":
+ return parent.object === node || parent.callee === node;
+
+ case "MemberExpression":
+ case "JSXMemberExpression":
+ if (parent.property === node && parent.computed) {
+ return true;
+ } else if (parent.object === node) {
+ return true;
+ } else {
+ return false;
+ }
+
+ case "MetaProperty":
+ return false;
+
+ case "ObjectProperty":
+ if (parent.key === node) {
+ return parent.computed;
+ }
+
+ case "VariableDeclarator":
+ return parent.id !== node;
+
+ case "ArrowFunctionExpression":
+ case "FunctionDeclaration":
+ case "FunctionExpression":
+ for (var _iterator = parent.params, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : (0, _getIterator3.default)(_iterator);;) {
+ var _ref;
+
+ if (_isArray) {
+ if (_i >= _iterator.length) break;
+ _ref = _iterator[_i++];
+ } else {
+ _i = _iterator.next();
+ if (_i.done) break;
+ _ref = _i.value;
+ }
+
+ var param = _ref;
+
+ if (param === node) return false;
+ }
+
+ return parent.id !== node;
+
+ case "ExportSpecifier":
+ if (parent.source) {
+ return false;
+ } else {
+ return parent.local === node;
+ }
+
+ case "ExportNamespaceSpecifier":
+ case "ExportDefaultSpecifier":
+ return false;
+
+ case "JSXAttribute":
+ return parent.name !== node;
+
+ case "ClassProperty":
+ if (parent.key === node) {
+ return parent.computed;
+ } else {
+ return parent.value === node;
+ }
+
+ case "ImportDefaultSpecifier":
+ case "ImportNamespaceSpecifier":
+ case "ImportSpecifier":
+ return false;
+
+ case "ClassDeclaration":
+ case "ClassExpression":
+ return parent.id !== node;
+
+ case "ClassMethod":
+ case "ObjectMethod":
+ return parent.key === node && parent.computed;
+
+ case "LabeledStatement":
+ return false;
+
+ case "CatchClause":
+ return parent.param !== node;
+
+ case "RestElement":
+ return false;
+
+ case "AssignmentExpression":
+ return parent.right === node;
+
+ case "AssignmentPattern":
+ return parent.right === node;
+
+ case "ObjectPattern":
+ case "ArrayPattern":
+ return false;
+ }
+
+ return true;
+}
+
+function isValidIdentifier(name) {
+ if (typeof name !== "string" || _esutils2.default.keyword.isReservedWordES6(name, true)) {
+ return false;
+ } else {
+ return _esutils2.default.keyword.isIdentifierNameES6(name);
+ }
+}
+
+function isLet(node) {
+ return t.isVariableDeclaration(node) && (node.kind !== "var" || node[_constants.BLOCK_SCOPED_SYMBOL]);
+}
+
+function isBlockScoped(node) {
+ return t.isFunctionDeclaration(node) || t.isClassDeclaration(node) || t.isLet(node);
+}
+
+function isVar(node) {
+ return t.isVariableDeclaration(node, { kind: "var" }) && !node[_constants.BLOCK_SCOPED_SYMBOL];
+}
+
+function isSpecifierDefault(specifier) {
+ return t.isImportDefaultSpecifier(specifier) || t.isIdentifier(specifier.imported || specifier.exported, { name: "default" });
+}
+
+function isScope(node, parent) {
+ if (t.isBlockStatement(node) && t.isFunction(parent, { body: node })) {
+ return false;
+ }
+
+ return t.isScopable(node);
+}
+
+function isImmutable(node) {
+ if (t.isType(node.type, "Immutable")) return true;
+
+ if (t.isIdentifier(node)) {
+ if (node.name === "undefined") {
+ return true;
+ } else {
+ return false;
+ }
+ }
+
+ return false;
+}
+
+function isNodesEquivalent(a, b) {
+ if ((typeof a === "undefined" ? "undefined" : (0, _typeof3.default)(a)) !== "object" || (typeof a === "undefined" ? "undefined" : (0, _typeof3.default)(a)) !== "object" || a == null || b == null) {
+ return a === b;
+ }
+
+ if (a.type !== b.type) {
+ return false;
+ }
+
+ var fields = (0, _keys2.default)(t.NODE_FIELDS[a.type] || a.type);
+
+ for (var _iterator2 = fields, _isArray2 = Array.isArray(_iterator2), _i2 = 0, _iterator2 = _isArray2 ? _iterator2 : (0, _getIterator3.default)(_iterator2);;) {
+ var _ref2;
+
+ if (_isArray2) {
+ if (_i2 >= _iterator2.length) break;
+ _ref2 = _iterator2[_i2++];
+ } else {
+ _i2 = _iterator2.next();
+ if (_i2.done) break;
+ _ref2 = _i2.value;
+ }
+
+ var field = _ref2;
+
+ if ((0, _typeof3.default)(a[field]) !== (0, _typeof3.default)(b[field])) {
+ return false;
+ }
+
+ if (Array.isArray(a[field])) {
+ if (!Array.isArray(b[field])) {
+ return false;
+ }
+ if (a[field].length !== b[field].length) {
+ return false;
+ }
+
+ for (var i = 0; i < a[field].length; i++) {
+ if (!isNodesEquivalent(a[field][i], b[field][i])) {
+ return false;
+ }
+ }
+ continue;
+ }
+
+ if (!isNodesEquivalent(a[field], b[field])) {
+ return false;
+ }
+ }
+
+ return true;
+}
\ No newline at end of file
diff --git a/node_modules/babel-types/package.json b/node_modules/babel-types/package.json
new file mode 100644
index 00000000..52f6f461
--- /dev/null
+++ b/node_modules/babel-types/package.json
@@ -0,0 +1,126 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "babel-types@^6.22.0",
+ "scope": null,
+ "escapedName": "babel-types",
+ "name": "babel-types",
+ "rawSpec": "^6.22.0",
+ "spec": ">=6.22.0 <7.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/babel-core"
+ ]
+ ],
+ "_from": "babel-types@>=6.22.0 <7.0.0",
+ "_id": "babel-types@6.22.0",
+ "_inCache": true,
+ "_location": "/babel-types",
+ "_nodeVersion": "6.9.0",
+ "_npmOperationalInternal": {
+ "host": "packages-18-east.internal.npmjs.com",
+ "tmp": "tmp/babel-types-6.22.0.tgz_1484872469348_0.9042536793276668"
+ },
+ "_npmUser": {
+ "name": "hzoo",
+ "email": "hi@henryzoo.com"
+ },
+ "_npmVersion": "3.10.10",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "babel-types@^6.22.0",
+ "scope": null,
+ "escapedName": "babel-types",
+ "name": "babel-types",
+ "rawSpec": "^6.22.0",
+ "spec": ">=6.22.0 <7.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/babel-core",
+ "/babel-generator",
+ "/babel-helper-call-delegate",
+ "/babel-helper-define-map",
+ "/babel-helper-function-name",
+ "/babel-helper-get-function-arity",
+ "/babel-helper-hoist-variables",
+ "/babel-helper-optimise-call-expression",
+ "/babel-helper-regex",
+ "/babel-helper-replace-supers",
+ "/babel-plugin-transform-es2015-block-scoping",
+ "/babel-plugin-transform-es2015-classes",
+ "/babel-plugin-transform-es2015-duplicate-keys",
+ "/babel-plugin-transform-es2015-function-name",
+ "/babel-plugin-transform-es2015-modules-commonjs",
+ "/babel-plugin-transform-es2015-parameters",
+ "/babel-plugin-transform-es2015-shorthand-properties",
+ "/babel-plugin-transform-es2015-sticky-regex",
+ "/babel-plugin-transform-strict-mode",
+ "/babel-template",
+ "/babel-traverse",
+ "/regenerator-transform"
+ ],
+ "_resolved": "https://registry.npmjs.org/babel-types/-/babel-types-6.22.0.tgz",
+ "_shasum": "2a447e8d0ea25d2512409e4175479fd78cc8b1db",
+ "_shrinkwrap": null,
+ "_spec": "babel-types@^6.22.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/babel-core",
+ "author": {
+ "name": "Sebastian McKenzie",
+ "email": "sebmck@gmail.com"
+ },
+ "dependencies": {
+ "babel-runtime": "^6.22.0",
+ "esutils": "^2.0.2",
+ "lodash": "^4.2.0",
+ "to-fast-properties": "^1.0.1"
+ },
+ "description": "Babel Types is a Lodash-esque utility library for AST nodes",
+ "devDependencies": {
+ "babylon": "^6.8.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "2a447e8d0ea25d2512409e4175479fd78cc8b1db",
+ "tarball": "https://registry.npmjs.org/babel-types/-/babel-types-6.22.0.tgz"
+ },
+ "homepage": "https://babeljs.io/",
+ "license": "MIT",
+ "main": "lib/index.js",
+ "maintainers": [
+ {
+ "name": "amasad",
+ "email": "amjad.masad@gmail.com"
+ },
+ {
+ "name": "hzoo",
+ "email": "hi@henryzoo.com"
+ },
+ {
+ "name": "jmm",
+ "email": "npm-public@jessemccarthy.net"
+ },
+ {
+ "name": "loganfsmyth",
+ "email": "loganfsmyth@gmail.com"
+ },
+ {
+ "name": "sebmck",
+ "email": "sebmck@gmail.com"
+ },
+ {
+ "name": "thejameskyle",
+ "email": "me@thejameskyle.com"
+ }
+ ],
+ "name": "babel-types",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/babel/babel/tree/master/packages/babel-types"
+ },
+ "scripts": {},
+ "version": "6.22.0"
+}
diff --git a/node_modules/babylon/CHANGELOG.md b/node_modules/babylon/CHANGELOG.md
new file mode 100644
index 00000000..d78294a4
--- /dev/null
+++ b/node_modules/babylon/CHANGELOG.md
@@ -0,0 +1,785 @@
+# Changelog
+
+> **Tags:**
+> - :boom: [Breaking Change]
+> - :eyeglasses: [Spec Compliancy]
+> - :rocket: [New Feature]
+> - :bug: [Bug Fix]
+> - :memo: [Documentation]
+> - :house: [Internal]
+> - :nail_care: [Polish]
+
+> Semver Policy: https://github.com/babel/babylon#semver
+
+_Note: Gaps between patch versions are faulty, broken or test releases._
+
+See the [Babel Changelog](https://github.com/babel/babel/blob/master/CHANGELOG.md) for the pre-6.8.0 version Changelog.
+
+## 6.15.0 (2017-01-10)
+
+### :eyeglasses: Spec Compliancy
+
+Add support for Flow shorthand import type ([#267](https://github.com/babel/babylon/pull/267)) (Jeff Morrison)
+
+This change implements flows new shorthand import syntax
+and where previously you had to write this code:
+
+```js
+import {someValue} from "blah";
+import type {someType} from "blah";
+import typeof {someOtherValue} from "blah";
+```
+
+you can now write it like this:
+
+```js
+import {
+ someValue,
+ type someType,
+ typeof someOtherValue,
+} from "blah";
+```
+
+For more information look at [this](https://github.com/facebook/flow/pull/2890) pull request.
+
+flow: allow leading pipes in all positions ([#256](https://github.com/babel/babylon/pull/256)) (Vladimir Kurchatkin)
+
+This change now allows a leading pipe everywhere types can be used:
+```js
+var f = (x): | 1 | 2 => 1;
+```
+
+Throw error when exporting non-declaration ([#241](https://github.com/babel/babylon/pull/241)) (Kai Cataldo)
+
+Previously babylon parsed the following exports, although they are not valid:
+```js
+export typeof foo;
+export new Foo();
+export function() {};
+export for (;;);
+export while(foo);
+```
+
+### :bug: Bug Fix
+
+Don't set inType flag when parsing property names ([#266](https://github.com/babel/babylon/pull/266)) (Vladimir Kurchatkin)
+
+This fixes parsing of this case:
+
+```js
+const map = {
+ [age <= 17] : 'Too young'
+};
+```
+
+Fix source location for JSXEmptyExpression nodes (fixes #248) ([#249](https://github.com/babel/babylon/pull/249)) (James Long)
+
+The following case produced an invalid AST
+```js
+{/* foo */}
+```
+
+Use fromCodePoint to convert high value unicode entities ([#243](https://github.com/babel/babylon/pull/243)) (Ryan Duffy)
+
+When high value unicode entities (e.g. 💩) were used in the input source code they are now correctly encoded in the resulting AST.
+
+Rename folder to avoid Windows-illegal characters ([#281](https://github.com/babel/babylon/pull/281)) (Ryan Plant)
+
+Allow this.state.clone() when parsing decorators ([#262](https://github.com/babel/babylon/pull/262)) (Alex Rattray)
+
+### :house: Internal
+
+User external-helpers ([#254](https://github.com/babel/babylon/pull/254)) (Daniel Tschinder)
+
+Add watch script for dev ([#234](https://github.com/babel/babylon/pull/234)) (Kai Cataldo)
+
+Freeze current plugins list for "*" option, and remove from README.md ([#245](https://github.com/babel/babylon/pull/245)) (Andrew Levine)
+
+Prepare tests for multiple fixture runners. ([#240](https://github.com/babel/babylon/pull/240)) (Daniel Tschinder)
+
+Add some test coverage for decorators stage-0 plugin ([#250](https://github.com/babel/babylon/pull/250)) (Andrew Levine)
+
+Refactor tokenizer types file ([#263](https://github.com/babel/babylon/pull/263)) (Sven SAULEAU)
+
+Update eslint-config-babel to the latest version 🚀 ([#273](https://github.com/babel/babylon/pull/273)) (greenkeeper[bot])
+
+chore(package): update rollup to version 0.41.0 ([#272](https://github.com/babel/babylon/pull/272)) (greenkeeper[bot])
+
+chore(package): update flow-bin to version 0.37.0 ([#255](https://github.com/babel/babylon/pull/255)) (greenkeeper[bot])
+
+## 6.14.1 (2016-11-17)
+
+### :bug: Bug Fix
+
+Allow `"plugins": ["*"]` ([#229](https://github.com/babel/babylon/pull/229)) (Daniel Tschinder)
+
+```js
+{
+ "plugins": ["*"]
+}
+```
+
+Will include all parser plugins instead of specifying each one individually. Useful for tools like babel-eslint, jscodeshift, and ast-explorer.
+
+## 6.14.0 (2016-11-16)
+
+### :eyeglasses: Spec Compliancy
+
+Throw error for reserved words `enum` and `await` ([#195](https://github.com/babel/babylon/pull/195)) (Kai Cataldo)
+
+[11.6.2.2 Future Reserved Words](http://www.ecma-international.org/ecma-262/6.0/#sec-future-reserved-words)
+
+Babylon will throw for more reserved words such as `enum` or `await` (in strict mode).
+
+```
+class enum {} // throws
+class await {} // throws in strict mode (module)
+```
+
+Optional names for function types and object type indexers ([#197](https://github.com/babel/babylon/pull/197)) (Gabe Levi)
+
+So where you used to have to write
+
+```js
+type A = (x: string, y: boolean) => number;
+type B = (z: string) => number;
+type C = { [key: string]: number };
+```
+
+you can now write (with flow 0.34.0)
+
+```js
+type A = (string, boolean) => number;
+type B = string => number;
+type C = { [string]: number };
+```
+
+Parse flow nested array type annotations like `number[][]` ([#219](https://github.com/babel/babylon/pull/219)) (Bernhard Häussner)
+
+Supports these form now of specifying array types:
+
+```js
+var a: number[][][][];
+var b: string[][];
+```
+
+### :bug: Bug Fix
+
+Correctly eat semicolon at the end of `DelcareModuleExports` ([#223](https://github.com/babel/babylon/pull/223)) (Daniel Tschinder)
+
+```
+declare module "foo" { declare module.exports: number }
+declare module "foo" { declare module.exports: number; } // also allowed now
+```
+
+### :house: Internal
+
+ * Count Babel tests towards Babylon code coverage ([#182](https://github.com/babel/babylon/pull/182)) (Moti Zilberman)
+ * Fix strange line endings ([#214](https://github.com/babel/babylon/pull/214)) (Thomas Grainger)
+ * Add node 7 (Daniel Tschinder)
+ * chore(package): update flow-bin to version 0.34.0 ([#204](https://github.com/babel/babylon/pull/204)) (Greenkeeper)
+
+## v6.13.1 (2016-10-26)
+
+### :nail_care: Polish
+
+- Use rollup for bundling to speed up startup time ([#190](https://github.com/babel/babylon/pull/190)) ([@drewml](https://github.com/DrewML))
+
+```js
+const babylon = require('babylon');
+const ast = babylon.parse('var foo = "lol";');
+```
+
+With that test case, there was a ~95ms savings by removing the need for node to build/traverse the dependency graph.
+
+**Without bundling**
+
+
+**With bundling**
+
+
+- add clean command [skip ci] ([#201](https://github.com/babel/babylon/pull/201)) (Henry Zhu)
+- add ForAwaitStatement (async generator already added) [skip ci] ([#196](https://github.com/babel/babylon/pull/196)) (Henry Zhu)
+
+## v6.13.0 (2016-10-21)
+
+### :eyeglasses: Spec Compliancy
+
+Property variance type annotations for Flow plugin ([#161](https://github.com/babel/babylon/pull/161)) (Sam Goldman)
+
+> See https://flowtype.org/docs/variance.html for more information
+
+```js
+type T = { +p: T };
+interface T { -p: T };
+declare class T { +[k:K]: V };
+class T { -[k:K]: V };
+class C2 { +p: T = e };
+```
+
+Raise error on duplicate definition of __proto__ ([#183](https://github.com/babel/babylon/pull/183)) (Moti Zilberman)
+
+```js
+({ __proto__: 1, __proto__: 2 }) // Throws an error now
+```
+
+### :bug: Bug Fix
+
+Flow: Allow class properties to be named `static` ([#184](https://github.com/babel/babylon/pull/184)) (Moti Zilberman)
+
+```js
+declare class A {
+ static: T;
+}
+```
+
+Allow "async" as identifier for object literal property shorthand ([#187](https://github.com/babel/babylon/pull/187)) (Andrew Levine)
+
+```js
+var foo = { async, bar };
+```
+
+### :nail_care: Polish
+
+Fix flowtype and add inType to state ([#189](https://github.com/babel/babylon/pull/189)) (Daniel Tschinder)
+
+> This improves the performance slightly (because of hidden classes)
+
+### :house: Internal
+
+Fix .gitattributes line ending setting ([#191](https://github.com/babel/babylon/pull/191)) (Moti Zilberman)
+
+Increase test coverage ([#175](https://github.com/babel/babylon/pull/175) (Moti Zilberman)
+
+Readd missin .eslinignore for IDEs (Daniel Tschinder)
+
+Error on missing expected.json fixture in CI ([#188](https://github.com/babel/babylon/pull/188)) (Moti Zilberman)
+
+Add .gitattributes and .editorconfig for LF line endings ([#179](https://github.com/babel/babylon/pull/179)) (Moti Zilberman)
+
+Fixes two tests that are failing after the merge of #172 ([#177](https://github.com/babel/babylon/pull/177)) (Moti Zilberman)
+
+## v6.12.0 (2016-10-14)
+
+### :eyeglasses: Spec Compliancy
+
+Implement import() syntax ([#163](https://github.com/babel/babylon/pull/163)) (Jordan Gensler)
+
+#### Dynamic Import
+
+- Proposal Repo: https://github.com/domenic/proposal-dynamic-import
+- Championed by [@domenic](https://github.com/domenic)
+- stage-2
+- [sept-28 tc39 notes](https://github.com/rwaldron/tc39-notes/blob/master/es7/2016-09/sept-28.md#113a-import)
+
+> This repository contains a proposal for adding a "function-like" import() module loading syntactic form to JavaScript
+
+```js
+import(`./section-modules/${link.dataset.entryModule}.js`)
+.then(module => {
+ module.loadPageInto(main);
+})
+```
+
+Add EmptyTypeAnnotation ([#171](https://github.com/babel/babylon/pull/171)) (Sam Goldman)
+
+#### EmptyTypeAnnotation
+
+Just wasn't covered before.
+
+```js
+type T = empty;
+```
+
+### :bug: Bug Fix
+
+Fix crash when exporting with destructuring and sparse array ([#170](https://github.com/babel/babylon/pull/170)) (Jeroen Engels)
+
+```js
+// was failing due to sparse array
+export const { foo: [ ,, qux7 ] } = bar;
+```
+
+Allow keyword in Flow object declaration property names with type parameters ([#146](https://github.com/babel/babylon/pull/146)) (Dan Harper)
+
+```js
+declare class X {
+ foobar(): void;
+ static foobar(): void;
+}
+```
+
+Allow keyword in object/class property names with Flow type parameters ([#145](https://github.com/babel/babylon/pull/145)) (Dan Harper)
+
+```js
+class Foo {
+ delete(item: T): T {
+ return item;
+ }
+}
+```
+
+Allow typeAnnotations for yield expressions ([#174](https://github.com/babel/babylon/pull/174))) (Daniel Tschinder)
+
+```js
+function *foo() {
+ const x = (yield 5: any);
+}
+```
+
+### :nail_care: Polish
+
+Annotate more errors with expected token ([#172](https://github.com/babel/babylon/pull/172))) (Moti Zilberman)
+
+```js
+// Unexpected token, expected ; (1:6)
+{ set 1 }
+```
+
+### :house: Internal
+
+Remove kcheck ([#173](https://github.com/babel/babylon/pull/173))) (Daniel Tschinder)
+
+Also run flow, linting, babel tests on seperate instances (add back node 0.10)
+
+## v6.11.6 (2016-10-12)
+
+### :bug: Bug Fix/Regression
+
+Fix crash when exporting with destructuring and sparse array ([#170](https://github.com/babel/babylon/pull/170)) (Jeroen Engels)
+
+```js
+// was failing with `Cannot read property 'type' of null` because of null identifiers
+export const { foo: [ ,, qux7 ] } = bar;
+```
+
+## v6.11.5 (2016-10-12)
+
+### :eyeglasses: Spec Compliancy
+
+Fix: Check for duplicate named exports in exported destructuring assignments ([#144](https://github.com/babel/babylon/pull/144)) (Kai Cataldo)
+
+```js
+// `foo` has already been exported. Exported identifiers must be unique. (2:20)
+export function foo() {};
+export const { a: [{foo}] } = bar;
+```
+
+Fix: Check for duplicate named exports in exported rest elements/properties ([#164](https://github.com/babel/babylon/pull/164)) (Kai Cataldo)
+
+```js
+// `foo` has already been exported. Exported identifiers must be unique. (2:22)
+export const foo = 1;
+export const [bar, ...foo] = baz;
+```
+
+### :bug: Bug Fix
+
+Fix: Allow identifier `async` for default param in arrow expression ([#165](https://github.com/babel/babylon/pull/165)) (Kai Cataldo)
+
+```js
+// this is ok now
+const test = ({async = true}) => {};
+```
+
+### :nail_care: Polish
+
+Babylon will now print out the token it's expecting if there's a `SyntaxError` ([#150](https://github.com/babel/babylon/pull/150)) (Daniel Tschinder)
+
+```bash
+# So in the case of a missing ending curly (`}`)
+Module build failed: SyntaxError: Unexpected token, expected } (30:0)
+ 28 | }
+ 29 |
+> 30 |
+ | ^
+```
+
+## v6.11.4 (2016-10-03)
+
+Temporary rollback for erroring on trailing comma with spread (#154) (Henry Zhu)
+
+## v6.11.3 (2016-10-01)
+
+### :eyeglasses: Spec Compliancy
+
+Add static errors for object rest (#149) ([@danez](https://github.com/danez))
+
+> https://github.com/sebmarkbage/ecmascript-rest-spread
+
+Object rest copies the *rest* of properties from the right hand side `obj` starting from the left to right.
+
+```js
+let { x, y, ...z } = { x: 1, y: 2, z: 3 };
+// x = 1
+// y = 2
+// z = { z: 3 }
+```
+
+#### New Syntax Errors:
+
+**SyntaxError**: The rest element has to be the last element when destructuring (1:10)
+```bash
+> 1 | let { ...x, y, z } = { x: 1, y: 2, z: 3};
+ | ^
+# Previous behavior:
+# x = { x: 1, y: 2, z: 3 }
+# y = 2
+# z = 3
+```
+
+Before, this was just a more verbose way of shallow copying `obj` since it doesn't actually do what you think.
+
+**SyntaxError**: Cannot have multiple rest elements when destructuring (1:13)
+
+```bash
+> 1 | let { x, ...y, ...z } = { x: 1, y: 2, z: 3};
+ | ^
+# Previous behavior:
+# x = 1
+# y = { y: 2, z: 3 }
+# z = { y: 2, z: 3 }
+```
+
+Before y and z would just be the same value anyway so there is no reason to need to have both.
+
+**SyntaxError**: A trailing comma is not permitted after the rest element (1:16)
+
+```js
+let { x, y, ...z, } = obj;
+```
+
+The rationale for this is that the use case for trailing comma is that you can add something at the end without affecting the line above. Since a RestProperty always has to be the last property it doesn't make sense.
+
+---
+
+get / set are valid property names in default assignment (#142) ([@jezell](https://github.com/jezell))
+
+```js
+// valid
+function something({ set = null, get = null }) {}
+```
+
+## v6.11.2 (2016-09-23)
+
+### Bug Fix
+
+- [#139](https://github.com/babel/babylon/issues/139) Don't do the duplicate check if not an identifier (#140) @hzoo
+
+```js
+// regression with duplicate export check
+SyntaxError: ./typography.js: `undefined` has already been exported. Exported identifiers must be unique. (22:13)
+ 20 |
+ 21 | export const { rhythm } = typography;
+> 22 | export const { TypographyStyle } = typography
+```
+
+Bail out for now, and make a change to account for destructuring in the next release.
+
+## 6.11.1 (2016-09-22)
+
+### Bug Fix
+- [#137](https://github.com/babel/babylon/pull/137) - Fix a regression with duplicate exports - it was erroring on all keys in `Object.prototype`. @danez
+
+```javascript
+export toString from './toString';
+```
+
+```bash
+`toString` has already been exported. Exported identifiers must be unique. (1:7)
+> 1 | export toString from './toString';
+ | ^
+ 2 |
+```
+
+## 6.11.0 (2016-09-22)
+
+### Spec Compliancy (will break CI)
+
+- Disallow duplicate named exports ([#107](https://github.com/babel/babylon/pull/107)) @kaicataldo
+
+```js
+// Only one default export allowed per module. (2:9)
+export default function() {};
+export { foo as default };
+
+// Only one default export allowed per module. (2:0)
+export default {};
+export default function() {};
+
+// `Foo` has already been exported. Exported identifiers must be unique. (2:0)
+export { Foo };
+export class Foo {};
+```
+
+### New Feature (Syntax)
+
+- Add support for computed class property names ([#121](https://github.com/babel/babylon/pull/121)) @motiz88
+
+```js
+// AST
+interface ClassProperty <: Node {
+ type: "ClassProperty";
+ key: Identifier;
+ value: Expression;
+ computed: boolean; // added
+}
+```
+
+```js
+// with "plugins": ["classProperties"]
+class Foo {
+ [x]
+ ['y']
+}
+
+class Bar {
+ [p]
+ [m] () {}
+}
+ ```
+
+### Bug Fix
+
+- Fix `static` property falling through in the declare class Flow AST ([#135](https://github.com/babel/babylon/pull/135)) @danharper
+
+```js
+declare class X {
+ a: number;
+ static b: number; // static
+ c: number; // this was being marked as static in the AST as well
+}
+```
+
+### Polish
+
+- Rephrase "assigning/binding to rvalue" errors to include context ([#119](https://github.com/babel/babylon/pull/119)) @motiz88
+
+```js
+// Used to error with:
+// SyntaxError: Assigning to rvalue (1:0)
+
+// Now:
+// Invalid left-hand side in assignment expression (1:0)
+3 = 4
+
+// Invalid left-hand side in for-in statement (1:5)
+for (+i in {});
+```
+
+### Internal
+
+- Fix call to `this.parseMaybeAssign` with correct arguments ([#133](https://github.com/babel/babylon/pull/133)) @danez
+- Add semver note to changelog ([#131](https://github.com/babel/babylon/pull/131)) @hzoo
+
+## 6.10.0 (2016-09-19)
+
+> We plan to include some spec compliancy bugs in patch versions. An example was the multiple default exports issue.
+
+### Spec Compliancy
+
+* Implement ES2016 check for simple parameter list in strict mode ([#106](https://github.com/babel/babylon/pull/106)) (Timothy Gu)
+
+> It is a Syntax Error if ContainsUseStrict of FunctionBody is true and IsSimpleParameterList of FormalParameters is false. https://tc39.github.io/ecma262/2016/#sec-function-definitions-static-semantics-early-errors
+
+More Context: [tc39-notes](https://github.com/rwaldron/tc39-notes/blob/master/es7/2015-07/july-29.md#611-the-scope-of-use-strict-with-respect-to-destructuring-in-parameter-lists)
+
+For example:
+
+```js
+// this errors because it uses destructuring and default parameters
+// in a function with a "use strict" directive
+function a([ option1, option2 ] = []) {
+ "use strict";
+}
+ ```
+
+The solution would be to use a top level "use strict" or to remove the destructuring or default parameters when using a function + "use strict" or to.
+
+### New Feature
+
+* Exact object type annotations for Flow plugin ([#104](https://github.com/babel/babylon/pull/104)) (Basil Hosmer)
+
+Added to flow in https://github.com/facebook/flow/commit/c710c40aa2a115435098d6c0dfeaadb023cd39b8
+
+Looks like:
+
+```js
+var a : {| x: number, y: string |} = { x: 0, y: 'foo' };
+```
+
+### Bug Fixes
+
+* Include `typeParameter` location in `ArrowFunctionExpression` ([#126](https://github.com/babel/babylon/pull/126)) (Daniel Tschinder)
+* Error on invalid flow type annotation with default assignment ([#122](https://github.com/babel/babylon/pull/122)) (Dan Harper)
+* Fix Flow return types on arrow functions ([#124](https://github.com/babel/babylon/pull/124)) (Dan Harper)
+
+### Misc
+
+* Add tests for export extensions ([#127](https://github.com/babel/babylon/pull/127)) (Daniel Tschinder)
+* Fix Contributing guidelines [skip ci] (Daniel Tschinder)
+
+## 6.9.2 (2016-09-09)
+
+The only change is to remove the `babel-runtime` dependency by compiling with Babel's ES2015 loose mode. So using babylon standalone should be smaller.
+
+## 6.9.1 (2016-08-23)
+
+This release contains mainly small bugfixes but also updates babylons default mode to es2017. The features for `exponentiationOperator`, `asyncFunctions` and `trailingFunctionCommas` which previously needed to be activated via plugin are now enabled by default and the plugins are now no-ops.
+
+### Bug Fixes
+
+- Fix issues with default object params in async functions ([#96](https://github.com/babel/babylon/pull/96)) @danez
+- Fix issues with flow-types and async function ([#95](https://github.com/babel/babylon/pull/95)) @danez
+- Fix arrow functions with destructuring, types & default value ([#94](https://github.com/babel/babylon/pull/94)) @danharper
+- Fix declare class with qualified type identifier ([#97](https://github.com/babel/babylon/pull/97)) @danez
+- Remove exponentiationOperator, asyncFunctions, trailingFunctionCommas plugins and enable them by default ([#98](https://github.com/babel/babylon/pull/98)) @danez
+
+## 6.9.0 (2016-08-16)
+
+### New syntax support
+
+- Add JSX spread children ([#42](https://github.com/babel/babylon/pull/42)) @calebmer
+
+(Be aware that React is not going to support this syntax)
+
+```js
+
+ {...todos.map(todo => )}
+
+```
+
+- Add support for declare module.exports ([#72](https://github.com/babel/babylon/pull/72)) @danez
+
+```js
+declare module "foo" {
+ declare module.exports: {}
+}
+```
+
+### New Features
+
+- If supplied, attach filename property to comment node loc. ([#80](https://github.com/babel/babylon/pull/80)) @divmain
+- Add identifier name to node loc field ([#90](https://github.com/babel/babylon/pull/90)) @kittens
+
+### Bug Fixes
+
+- Fix exponential operator to behave according to spec ([#75](https://github.com/babel/babylon/pull/75)) @danez
+- Fix lookahead to not add comments to arrays which are not cloned ([#76](https://github.com/babel/babylon/pull/76)) @danez
+- Fix accidental fall-through in Flow type parsing. ([#82](https://github.com/babel/babylon/pull/82)) @xiemaisi
+- Only allow declares inside declare module ([#73](https://github.com/babel/babylon/pull/73)) @danez
+- Small fix for parsing type parameter declarations ([#83](https://github.com/babel/babylon/pull/83)) @gabelevi
+- Fix arrow param locations with flow types ([#57](https://github.com/babel/babylon/pull/57)) @danez
+- Fixes SyntaxError position with flow optional type ([#65](https://github.com/babel/babylon/pull/65)) @danez
+
+### Internal
+
+- Add codecoverage to tests @danez
+- Fix tests to not save expected output if we expect the test to fail @danez
+- Make a shallow clone of babel for testing @danez
+- chore(package): update cross-env to version 2.0.0 ([#77](https://github.com/babel/babylon/pull/77)) @greenkeeperio-bot
+- chore(package): update ava to version 0.16.0 ([#86](https://github.com/babel/babylon/pull/86)) @greenkeeperio-bot
+- chore(package): update babel-plugin-istanbul to version 2.0.0 ([#89](https://github.com/babel/babylon/pull/89)) @greenkeeperio-bot
+- chore(package): update nyc to version 8.0.0 ([#88](https://github.com/babel/babylon/pull/88)) @greenkeeperio-bot
+
+## 6.8.4 (2016-07-06)
+
+### Bug Fixes
+
+- Fix the location of params, when flow and default value used ([#68](https://github.com/babel/babylon/pull/68)) @danez
+
+## 6.8.3 (2016-07-02)
+
+### Bug Fixes
+
+- Fix performance regression introduced in 6.8.2 with conditionals ([#63](https://github.com/babel/babylon/pull/63)) @danez
+
+## 6.8.2 (2016-06-24)
+
+### Bug Fixes
+
+- Fix parse error with yielding jsx elements in generators `function* it() { yield ; }` ([#31](https://github.com/babel/babylon/pull/31)) @eldereal
+- When cloning nodes do not clone its comments ([#24](https://github.com/babel/babylon/pull/24)) @danez
+- Fix parse errors when using arrow functions with an spread element and return type `(...props): void => {}` ([#10](https://github.com/babel/babylon/pull/10)) @danez
+- Fix leading comments added from previous node ([#23](https://github.com/babel/babylon/pull/23)) @danez
+- Fix parse errors with flow's optional arguments `(arg?) => {}` ([#19](https://github.com/babel/babylon/pull/19)) @danez
+- Support negative numeric type literals @kittens
+- Remove line terminator restriction after await keyword @kittens
+- Remove grouped type arrow restriction as it seems flow no longer has it @kittens
+- Fix parse error with generic methods that have the name `get` or `set` `class foo { get() {} }` ([#55](https://github.com/babel/babylon/pull/55)) @vkurchatkin
+- Fix parse error with arrow functions that have flow type parameter declarations `(x: T): T => x;` ([#54](https://github.com/babel/babylon/pull/54)) @gabelevi
+
+### Documentation
+
+- Document AST differences from ESTree ([#41](https://github.com/babel/babylon/pull/41)) @nene
+- Move ast spec from babel/babel ([#46](https://github.com/babel/babylon/pull/46)) @hzoo
+
+### Internal
+
+- Enable skipped tests ([#16](https://github.com/babel/babylon/pull/16)) @danez
+- Add script to test latest version of babylon with babel ([#21](https://github.com/babel/babylon/pull/21)) @danez
+- Upgrade test runner ava @kittens
+- Add missing generate-identifier-regex script @kittens
+- Rename parser context types @kittens
+- Add node v6 to travis testing @hzoo
+- Update to Unicode v9 ([#45](https://github.com/babel/babylon/pull/45)) @mathiasbynens
+
+## 6.8.1 (2016-06-06)
+
+### New Feature
+
+- Parse type parameter declarations with defaults like `type Foo = T`
+
+### Bug Fixes
+- Type parameter declarations need 1 or more type parameters.
+- The existential type `*` is not a valid type parameter.
+- The existential type `*` is a primary type
+
+### Spec Compliancy
+- The param list for type parameter declarations now consists of `TypeParameter` nodes
+- New `TypeParameter` AST Node (replaces using the `Identifier` node before)
+
+```
+interface TypeParameter <: Node {
+ bound: TypeAnnotation;
+ default: TypeAnnotation;
+ name: string;
+ variance: "plus" | "minus";
+}
+```
+
+## 6.8.0 (2016-05-02)
+
+#### New Feature
+
+##### Parse Method Parameter Decorators ([#12](https://github.com/babel/babylon/pull/12))
+
+> [Method Parameter Decorators](https://goo.gl/8MmCMG) is now a TC39 [stage 0 proposal](https://github.com/tc39/ecma262/blob/master/stage0.md).
+
+Examples:
+
+```js
+class Foo {
+ constructor(@foo() x, @bar({ a: 123 }) @baz() y) {}
+}
+
+export default function func(@foo() x, @bar({ a: 123 }) @baz() y) {}
+
+var obj = {
+ method(@foo() x, @bar({ a: 123 }) @baz() y) {}
+};
+```
+
+##### Parse for-await statements (w/ `asyncGenerators` plugin) ([#17](https://github.com/babel/babylon/pull/17))
+
+There is also a new node type, `ForAwaitStatement`.
+
+> [Async generators and for-await](https://github.com/tc39/proposal-async-iteration) are now a [stage 2 proposal](https://github.com/tc39/ecma262#current-proposals).
+
+Example:
+
+```js
+async function f() {
+ for await (let x of y);
+}
+```
diff --git a/node_modules/babylon/LICENSE b/node_modules/babylon/LICENSE
new file mode 100644
index 00000000..d4c7fc58
--- /dev/null
+++ b/node_modules/babylon/LICENSE
@@ -0,0 +1,19 @@
+Copyright (C) 2012-2014 by various contributors (see AUTHORS)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/babylon/README.md b/node_modules/babylon/README.md
new file mode 100644
index 00000000..68c136a8
--- /dev/null
+++ b/node_modules/babylon/README.md
@@ -0,0 +1,120 @@
+
+
+
+
+
+ Babylon is a JavaScript parser used in Babel .
+
+
+
+
+
+
+
+ - The latest ECMAScript version enabled by default (ES2017).
+ - Comment attachment.
+ - Support for JSX and Flow.
+ - Support for experimental language proposals (accepting PRs for anything at least [stage-0](https://github.com/tc39/proposals/blob/master/stage-0-proposals.md)).
+
+## Credits
+
+Heavily based on [acorn](https://github.com/marijnh/acorn) and [acorn-jsx](https://github.com/RReverser/acorn-jsx),
+thanks to the awesome work of [@RReverser](https://github.com/RReverser) and [@marijnh](https://github.com/marijnh).
+
+Significant diversions are expected to occur in the future such as streaming, EBNF definitions, sweet.js integration, interspatial parsing and more.
+
+## API
+
+### `babylon.parse(code, [options])`
+
+### Options
+
+- **allowImportExportEverywhere**: By default, `import` and `export`
+ declarations can only appear at a program's top level. Setting this
+ option to `true` allows them anywhere where a statement is allowed.
+
+- **allowReturnOutsideFunction**: By default, a return statement at
+ the top level raises an error. Set this to `true` to accept such
+ code.
+
+- **allowSuperOutsideMethod** TODO
+
+- **sourceType**: Indicate the mode the code should be parsed in. Can be
+ either `"script"` or `"module"`.
+
+- **sourceFilename**: Correlate output AST nodes with their source filename. Useful when generating code and source maps from the ASTs of multiple input files.
+
+- **plugins**: Array containing the plugins that you want to enable.
+
+### Output
+
+Babylon generates AST according to [Babel AST format][].
+It is based on [ESTree spec][] with the following deviations:
+
+- [Literal][] token is replaced with [StringLiteral][], [NumericLiteral][], [BooleanLiteral][], [NullLiteral][], [RegExpLiteral][]
+- [Property][] token is replaced with [ObjectProperty][] and [ObjectMethod][]
+- [MethodDefinition][] is replaced with [ClassMethod][]
+- [Program][] and [BlockStatement][] contain additional `directives` field with [Directive][] and [DirectiveLiteral][]
+- [ClassMethod][], [ObjectProperty][], and [ObjectMethod][] value property's properties in [FunctionExpression][] is coerced/brought into the main method node.
+
+AST for JSX code is based on [Facebook JSX AST][] with the addition of one node type:
+
+- `JSXText`
+
+[Babel AST format]: https://github.com/babel/babylon/blob/master/ast/spec.md
+[ESTree spec]: https://github.com/estree/estree
+
+[Literal]: https://github.com/estree/estree/blob/master/es5.md#literal
+[Property]: https://github.com/estree/estree/blob/master/es5.md#property
+[MethodDefinition]: https://github.com/estree/estree/blob/master/es2015.md#methoddefinition
+
+[StringLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#stringliteral
+[NumericLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#numericliteral
+[BooleanLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#booleanliteral
+[NullLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#nullliteral
+[RegExpLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#regexpliteral
+[ObjectProperty]: https://github.com/babel/babylon/blob/master/ast/spec.md#objectproperty
+[ObjectMethod]: https://github.com/babel/babylon/blob/master/ast/spec.md#objectmethod
+[ClassMethod]: https://github.com/babel/babylon/blob/master/ast/spec.md#classmethod
+[Program]: https://github.com/babel/babylon/blob/master/ast/spec.md#programs
+[BlockStatement]: https://github.com/babel/babylon/blob/master/ast/spec.md#blockstatement
+[Directive]: https://github.com/babel/babylon/blob/master/ast/spec.md#directive
+[DirectiveLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#directiveliteral
+[FunctionExpression]: https://github.com/babel/babylon/blob/master/ast/spec.md#functionexpression
+
+[Facebook JSX AST]: https://github.com/facebook/jsx/blob/master/AST.md
+
+### Semver
+
+Babylon follows semver in most situations. The only thing to note is that some spec-compliancy bug fixes may be released under patch versions.
+
+For example: We push a fix to early error on something like [#107](https://github.com/babel/babylon/pull/107) - multiple default exports per file. That would be considered a bug fix even though it would cause a build to fail.
+
+### Example
+
+```javascript
+require("babylon").parse("code", {
+ // parse in strict mode and allow module declarations
+ sourceType: "module",
+
+ plugins: [
+ // enable jsx and flow syntax
+ "jsx",
+ "flow"
+ ]
+});
+```
+
+### Plugins
+
+ - `jsx`
+ - `flow`
+ - `doExpressions`
+ - `objectRestSpread`
+ - `decorators` (Based on an outdated version of the Decorators proposal. Will be removed in a future version of `Babylon`)
+ - `classProperties`
+ - `exportExtensions`
+ - `asyncGenerators`
+ - `functionBind`
+ - `functionSent`
+ - `dynamicImport`
diff --git a/node_modules/babylon/bin/babylon.js b/node_modules/babylon/bin/babylon.js
new file mode 100755
index 00000000..449ddfed
--- /dev/null
+++ b/node_modules/babylon/bin/babylon.js
@@ -0,0 +1,16 @@
+#!/usr/bin/env node
+/* eslint no-var: 0 */
+
+var babylon = require("..");
+var fs = require("fs");
+
+var filename = process.argv[2];
+if (!filename) {
+ console.error("no filename specified");
+ process.exit(0);
+}
+
+var file = fs.readFileSync(filename, "utf8");
+var ast = babylon.parse(file);
+
+console.log(JSON.stringify(ast, null, " "));
diff --git a/node_modules/babylon/bin/generate-identifier-regex.js b/node_modules/babylon/bin/generate-identifier-regex.js
new file mode 100644
index 00000000..76cc7f30
--- /dev/null
+++ b/node_modules/babylon/bin/generate-identifier-regex.js
@@ -0,0 +1,62 @@
+"use strict";
+
+// Which Unicode version should be used?
+const version = "9.0.0";
+
+const start = require("unicode-" + version + "/Binary_Property/ID_Start/code-points.js")
+ .filter(function(ch) { return ch > 0x7f; });
+let last = -1;
+const cont = [0x200c, 0x200d].concat(
+ require("unicode-" + version + "/Binary_Property/ID_Continue/code-points.js")
+ .filter(function(ch) {
+ return ch > 0x7f && search(start, ch, last + 1) == -1;
+ })
+ );
+
+function search(arr, ch, starting) {
+ for (let i = starting; arr[i] <= ch && i < arr.length; last = i++)
+ if (arr[i] === ch)
+ return i;
+ return -1;
+}
+
+function pad(str, width) {
+ while (str.length < width) str = "0" + str;
+ return str;
+}
+
+function esc(code) {
+ const hex = code.toString(16);
+ if (hex.length <= 2) return "\\x" + pad(hex, 2);
+ else return "\\u" + pad(hex, 4);
+}
+
+function generate(chars) {
+ const astral = [];
+ let re = "";
+ for (let i = 0, at = 0x10000; i < chars.length; i++) {
+ const from = chars[i];
+ let to = from;
+ while (i < chars.length - 1 && chars[i + 1] == to + 1) {
+ i++;
+ to++;
+ }
+ if (to <= 0xffff) {
+ if (from == to) re += esc(from);
+ else if (from + 1 == to) re += esc(from) + esc(to);
+ else re += esc(from) + "-" + esc(to);
+ } else {
+ astral.push(from - at, to - from);
+ at = to;
+ }
+ }
+ return {nonASCII: re, astral: astral};
+}
+
+const startData = generate(start);
+const contData = generate(cont);
+
+console.log("let nonASCIIidentifierStartChars = \"" + startData.nonASCII + "\";");
+console.log("let nonASCIIidentifierChars = \"" + contData.nonASCII + "\";");
+console.log("const astralIdentifierStartCodes = " + JSON.stringify(startData.astral) + ";");
+console.log("const astralIdentifierCodes = " + JSON.stringify(contData.astral) + ";");
diff --git a/node_modules/babylon/lib/index.js b/node_modules/babylon/lib/index.js
new file mode 100644
index 00000000..4b4b2411
--- /dev/null
+++ b/node_modules/babylon/lib/index.js
@@ -0,0 +1,6661 @@
+'use strict';
+
+Object.defineProperty(exports, '__esModule', { value: true });
+
+/* eslint max-len: 0 */
+
+// This is a trick taken from Esprima. It turns out that, on
+// non-Chrome browsers, to check whether a string is in a set, a
+// predicate containing a big ugly `switch` statement is faster than
+// a regular expression, and on Chrome the two are about on par.
+// This function uses `eval` (non-lexical) to produce such a
+// predicate from a space-separated string of words.
+//
+// It starts by sorting the words by length.
+
+function makePredicate(words) {
+ words = words.split(" ");
+ return function (str) {
+ return words.indexOf(str) >= 0;
+ };
+}
+
+// Reserved word lists for various dialects of the language
+
+var reservedWords = {
+ 6: makePredicate("enum await"),
+ strict: makePredicate("implements interface let package private protected public static yield"),
+ strictBind: makePredicate("eval arguments")
+};
+
+// And the keywords
+
+var isKeyword = makePredicate("break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this let const class extends export import yield super");
+
+// ## Character categories
+
+// Big ugly regular expressions that match characters in the
+// whitespace, identifier, and identifier-start categories. These
+// are only applied when a character is found to actually have a
+// code point above 128.
+// Generated by `bin/generate-identifier-regex.js`.
+
+var nonASCIIidentifierStartChars = "\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC";
+var nonASCIIidentifierChars = "\u200C\u200D\xB7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D4-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0D01-\u0D03\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF5\u1DFB-\u1DFF\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA900-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F";
+
+var nonASCIIidentifierStart = new RegExp("[" + nonASCIIidentifierStartChars + "]");
+var nonASCIIidentifier = new RegExp("[" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + "]");
+
+nonASCIIidentifierStartChars = nonASCIIidentifierChars = null;
+
+// These are a run-length and offset encoded representation of the
+// >0xffff code points that are a valid part of identifiers. The
+// offset starts at 0x10000, and each pair of numbers represents an
+// offset to the next range, and then a size of the range. They were
+// generated by `bin/generate-identifier-regex.js`.
+var astralIdentifierStartCodes = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 17, 26, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 157, 310, 10, 21, 11, 7, 153, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 71, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 26, 45, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 785, 52, 76, 44, 33, 24, 27, 35, 42, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 85, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 159, 52, 19, 3, 54, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 86, 25, 391, 63, 32, 0, 449, 56, 264, 8, 2, 36, 18, 0, 50, 29, 881, 921, 103, 110, 18, 195, 2749, 1070, 4050, 582, 8634, 568, 8, 30, 114, 29, 19, 47, 17, 3, 32, 20, 6, 18, 881, 68, 12, 0, 67, 12, 65, 0, 32, 6124, 20, 754, 9486, 1, 3071, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 4149, 196, 60, 67, 1213, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42710, 42, 4148, 12, 221, 3, 5761, 10591, 541];
+var astralIdentifierCodes = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 1306, 2, 54, 14, 32, 9, 16, 3, 46, 10, 54, 9, 7, 2, 37, 13, 2, 9, 52, 0, 13, 2, 49, 13, 10, 2, 4, 9, 83, 11, 7, 0, 161, 11, 6, 9, 7, 3, 57, 0, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 193, 17, 10, 9, 87, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 84, 14, 5, 9, 423, 9, 838, 7, 2, 7, 17, 9, 57, 21, 2, 13, 19882, 9, 135, 4, 60, 6, 26, 9, 1016, 45, 17, 3, 19723, 1, 5319, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 2214, 6, 110, 6, 6, 9, 792487, 239];
+
+// This has a complexity linear to the value of the code. The
+// assumption is that looking up astral identifier characters is
+// rare.
+function isInAstralSet(code, set) {
+ var pos = 0x10000;
+ for (var i = 0; i < set.length; i += 2) {
+ pos += set[i];
+ if (pos > code) return false;
+
+ pos += set[i + 1];
+ if (pos >= code) return true;
+ }
+}
+
+// Test whether a given character code starts an identifier.
+
+function isIdentifierStart(code) {
+ if (code < 65) return code === 36;
+ if (code < 91) return true;
+ if (code < 97) return code === 95;
+ if (code < 123) return true;
+ if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code));
+ return isInAstralSet(code, astralIdentifierStartCodes);
+}
+
+// Test whether a given character is part of an identifier.
+
+function isIdentifierChar(code) {
+ if (code < 48) return code === 36;
+ if (code < 58) return true;
+ if (code < 65) return false;
+ if (code < 91) return true;
+ if (code < 97) return code === 95;
+ if (code < 123) return true;
+ if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code));
+ return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes);
+}
+
+// A second optional argument can be given to further configure
+var defaultOptions = {
+ // Source type ("script" or "module") for different semantics
+ sourceType: "script",
+ // Source filename.
+ sourceFilename: undefined,
+ // When enabled, a return at the top level is not considered an
+ // error.
+ allowReturnOutsideFunction: false,
+ // When enabled, import/export statements are not constrained to
+ // appearing at the top of the program.
+ allowImportExportEverywhere: false,
+ // TODO
+ allowSuperOutsideMethod: false,
+ // An array of plugins to enable
+ plugins: [],
+ // TODO
+ strictMode: null
+};
+
+// Interpret and default an options object
+
+function getOptions(opts) {
+ var options = {};
+ for (var key in defaultOptions) {
+ options[key] = opts && key in opts ? opts[key] : defaultOptions[key];
+ }
+ return options;
+}
+
+var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
+ return typeof obj;
+} : function (obj) {
+ return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
+};
+
+
+
+
+
+
+
+
+
+
+
+var classCallCheck = function (instance, Constructor) {
+ if (!(instance instanceof Constructor)) {
+ throw new TypeError("Cannot call a class as a function");
+ }
+};
+
+
+
+
+
+
+
+
+
+
+
+var inherits = function (subClass, superClass) {
+ if (typeof superClass !== "function" && superClass !== null) {
+ throw new TypeError("Super expression must either be null or a function, not " + typeof superClass);
+ }
+
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
+ constructor: {
+ value: subClass,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+ if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;
+};
+
+
+
+
+
+
+
+
+
+
+
+var possibleConstructorReturn = function (self, call) {
+ if (!self) {
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
+ }
+
+ return call && (typeof call === "object" || typeof call === "function") ? call : self;
+};
+
+// ## Token types
+
+// The assignment of fine-grained, information-carrying type objects
+// allows the tokenizer to store the information it has about a
+// token in a way that is very cheap for the parser to look up.
+
+// All token type variables start with an underscore, to make them
+// easy to recognize.
+
+// The `beforeExpr` property is used to disambiguate between regular
+// expressions and divisions. It is set on all token types that can
+// be followed by an expression (thus, a slash after them would be a
+// regular expression).
+//
+// `isLoop` marks a keyword as starting a loop, which is important
+// to know when parsing a label, in order to allow or disallow
+// continue jumps to that label.
+
+var beforeExpr = true;
+var startsExpr = true;
+var isLoop = true;
+var isAssign = true;
+var prefix = true;
+var postfix = true;
+
+var TokenType = function TokenType(label) {
+ var conf = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
+ classCallCheck(this, TokenType);
+
+ this.label = label;
+ this.keyword = conf.keyword;
+ this.beforeExpr = !!conf.beforeExpr;
+ this.startsExpr = !!conf.startsExpr;
+ this.rightAssociative = !!conf.rightAssociative;
+ this.isLoop = !!conf.isLoop;
+ this.isAssign = !!conf.isAssign;
+ this.prefix = !!conf.prefix;
+ this.postfix = !!conf.postfix;
+ this.binop = conf.binop || null;
+ this.updateContext = null;
+};
+
+var KeywordTokenType = function (_TokenType) {
+ inherits(KeywordTokenType, _TokenType);
+
+ function KeywordTokenType(name) {
+ var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
+ classCallCheck(this, KeywordTokenType);
+
+ options.keyword = name;
+
+ return possibleConstructorReturn(this, _TokenType.call(this, name, options));
+ }
+
+ return KeywordTokenType;
+}(TokenType);
+
+var BinopTokenType = function (_TokenType2) {
+ inherits(BinopTokenType, _TokenType2);
+
+ function BinopTokenType(name, prec) {
+ classCallCheck(this, BinopTokenType);
+ return possibleConstructorReturn(this, _TokenType2.call(this, name, { beforeExpr: beforeExpr, binop: prec }));
+ }
+
+ return BinopTokenType;
+}(TokenType);
+
+var types = {
+ num: new TokenType("num", { startsExpr: startsExpr }),
+ regexp: new TokenType("regexp", { startsExpr: startsExpr }),
+ string: new TokenType("string", { startsExpr: startsExpr }),
+ name: new TokenType("name", { startsExpr: startsExpr }),
+ eof: new TokenType("eof"),
+
+ // Punctuation token types.
+ bracketL: new TokenType("[", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ bracketR: new TokenType("]"),
+ braceL: new TokenType("{", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ braceBarL: new TokenType("{|", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ braceR: new TokenType("}"),
+ braceBarR: new TokenType("|}"),
+ parenL: new TokenType("(", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ parenR: new TokenType(")"),
+ comma: new TokenType(",", { beforeExpr: beforeExpr }),
+ semi: new TokenType(";", { beforeExpr: beforeExpr }),
+ colon: new TokenType(":", { beforeExpr: beforeExpr }),
+ doubleColon: new TokenType("::", { beforeExpr: beforeExpr }),
+ dot: new TokenType("."),
+ question: new TokenType("?", { beforeExpr: beforeExpr }),
+ arrow: new TokenType("=>", { beforeExpr: beforeExpr }),
+ template: new TokenType("template"),
+ ellipsis: new TokenType("...", { beforeExpr: beforeExpr }),
+ backQuote: new TokenType("`", { startsExpr: startsExpr }),
+ dollarBraceL: new TokenType("${", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ at: new TokenType("@"),
+
+ // Operators. These carry several kinds of properties to help the
+ // parser use them properly (the presence of these properties is
+ // what categorizes them as operators).
+ //
+ // `binop`, when present, specifies that this operator is a binary
+ // operator, and will refer to its precedence.
+ //
+ // `prefix` and `postfix` mark the operator as a prefix or postfix
+ // unary operator.
+ //
+ // `isAssign` marks all of `=`, `+=`, `-=` etcetera, which act as
+ // binary operators with a very low precedence, that should result
+ // in AssignmentExpression nodes.
+
+ eq: new TokenType("=", { beforeExpr: beforeExpr, isAssign: isAssign }),
+ assign: new TokenType("_=", { beforeExpr: beforeExpr, isAssign: isAssign }),
+ incDec: new TokenType("++/--", { prefix: prefix, postfix: postfix, startsExpr: startsExpr }),
+ prefix: new TokenType("prefix", { beforeExpr: beforeExpr, prefix: prefix, startsExpr: startsExpr }),
+ logicalOR: new BinopTokenType("||", 1),
+ logicalAND: new BinopTokenType("&&", 2),
+ bitwiseOR: new BinopTokenType("|", 3),
+ bitwiseXOR: new BinopTokenType("^", 4),
+ bitwiseAND: new BinopTokenType("&", 5),
+ equality: new BinopTokenType("==/!=", 6),
+ relational: new BinopTokenType(">", 7),
+ bitShift: new BinopTokenType("<>>", 8),
+ plusMin: new TokenType("+/-", { beforeExpr: beforeExpr, binop: 9, prefix: prefix, startsExpr: startsExpr }),
+ modulo: new BinopTokenType("%", 10),
+ star: new BinopTokenType("*", 10),
+ slash: new BinopTokenType("/", 10),
+ exponent: new TokenType("**", { beforeExpr: beforeExpr, binop: 11, rightAssociative: true })
+};
+
+var keywords = {
+ "break": new KeywordTokenType("break"),
+ "case": new KeywordTokenType("case", { beforeExpr: beforeExpr }),
+ "catch": new KeywordTokenType("catch"),
+ "continue": new KeywordTokenType("continue"),
+ "debugger": new KeywordTokenType("debugger"),
+ "default": new KeywordTokenType("default", { beforeExpr: beforeExpr }),
+ "do": new KeywordTokenType("do", { isLoop: isLoop, beforeExpr: beforeExpr }),
+ "else": new KeywordTokenType("else", { beforeExpr: beforeExpr }),
+ "finally": new KeywordTokenType("finally"),
+ "for": new KeywordTokenType("for", { isLoop: isLoop }),
+ "function": new KeywordTokenType("function", { startsExpr: startsExpr }),
+ "if": new KeywordTokenType("if"),
+ "return": new KeywordTokenType("return", { beforeExpr: beforeExpr }),
+ "switch": new KeywordTokenType("switch"),
+ "throw": new KeywordTokenType("throw", { beforeExpr: beforeExpr }),
+ "try": new KeywordTokenType("try"),
+ "var": new KeywordTokenType("var"),
+ "let": new KeywordTokenType("let"),
+ "const": new KeywordTokenType("const"),
+ "while": new KeywordTokenType("while", { isLoop: isLoop }),
+ "with": new KeywordTokenType("with"),
+ "new": new KeywordTokenType("new", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ "this": new KeywordTokenType("this", { startsExpr: startsExpr }),
+ "super": new KeywordTokenType("super", { startsExpr: startsExpr }),
+ "class": new KeywordTokenType("class"),
+ "extends": new KeywordTokenType("extends", { beforeExpr: beforeExpr }),
+ "export": new KeywordTokenType("export"),
+ "import": new KeywordTokenType("import"),
+ "yield": new KeywordTokenType("yield", { beforeExpr: beforeExpr, startsExpr: startsExpr }),
+ "null": new KeywordTokenType("null", { startsExpr: startsExpr }),
+ "true": new KeywordTokenType("true", { startsExpr: startsExpr }),
+ "false": new KeywordTokenType("false", { startsExpr: startsExpr }),
+ "in": new KeywordTokenType("in", { beforeExpr: beforeExpr, binop: 7 }),
+ "instanceof": new KeywordTokenType("instanceof", { beforeExpr: beforeExpr, binop: 7 }),
+ "typeof": new KeywordTokenType("typeof", { beforeExpr: beforeExpr, prefix: prefix, startsExpr: startsExpr }),
+ "void": new KeywordTokenType("void", { beforeExpr: beforeExpr, prefix: prefix, startsExpr: startsExpr }),
+ "delete": new KeywordTokenType("delete", { beforeExpr: beforeExpr, prefix: prefix, startsExpr: startsExpr })
+};
+
+// Map keyword names to token types.
+Object.keys(keywords).forEach(function (name) {
+ types["_" + name] = keywords[name];
+});
+
+// Matches a whole line break (where CRLF is considered a single
+// line break). Used to count lines.
+
+var lineBreak = /\r\n?|\n|\u2028|\u2029/;
+var lineBreakG = new RegExp(lineBreak.source, "g");
+
+function isNewLine(code) {
+ return code === 10 || code === 13 || code === 0x2028 || code === 0x2029;
+}
+
+var nonASCIIwhitespace = /[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/;
+
+// The algorithm used to determine whether a regexp can appear at a
+// given point in the program is loosely based on sweet.js' approach.
+// See https://github.com/mozilla/sweet.js/wiki/design
+
+var TokContext = function TokContext(token, isExpr, preserveSpace, override) {
+ classCallCheck(this, TokContext);
+
+ this.token = token;
+ this.isExpr = !!isExpr;
+ this.preserveSpace = !!preserveSpace;
+ this.override = override;
+};
+
+var types$1 = {
+ braceStatement: new TokContext("{", false),
+ braceExpression: new TokContext("{", true),
+ templateQuasi: new TokContext("${", true),
+ parenStatement: new TokContext("(", false),
+ parenExpression: new TokContext("(", true),
+ template: new TokContext("`", true, true, function (p) {
+ return p.readTmplToken();
+ }),
+ functionExpression: new TokContext("function", true)
+};
+
+// Token-specific context update code
+
+types.parenR.updateContext = types.braceR.updateContext = function () {
+ if (this.state.context.length === 1) {
+ this.state.exprAllowed = true;
+ return;
+ }
+
+ var out = this.state.context.pop();
+ if (out === types$1.braceStatement && this.curContext() === types$1.functionExpression) {
+ this.state.context.pop();
+ this.state.exprAllowed = false;
+ } else if (out === types$1.templateQuasi) {
+ this.state.exprAllowed = true;
+ } else {
+ this.state.exprAllowed = !out.isExpr;
+ }
+};
+
+types.name.updateContext = function (prevType) {
+ this.state.exprAllowed = false;
+
+ if (prevType === types._let || prevType === types._const || prevType === types._var) {
+ if (lineBreak.test(this.input.slice(this.state.end))) {
+ this.state.exprAllowed = true;
+ }
+ }
+};
+
+types.braceL.updateContext = function (prevType) {
+ this.state.context.push(this.braceIsBlock(prevType) ? types$1.braceStatement : types$1.braceExpression);
+ this.state.exprAllowed = true;
+};
+
+types.dollarBraceL.updateContext = function () {
+ this.state.context.push(types$1.templateQuasi);
+ this.state.exprAllowed = true;
+};
+
+types.parenL.updateContext = function (prevType) {
+ var statementParens = prevType === types._if || prevType === types._for || prevType === types._with || prevType === types._while;
+ this.state.context.push(statementParens ? types$1.parenStatement : types$1.parenExpression);
+ this.state.exprAllowed = true;
+};
+
+types.incDec.updateContext = function () {
+ // tokExprAllowed stays unchanged
+};
+
+types._function.updateContext = function () {
+ if (this.curContext() !== types$1.braceStatement) {
+ this.state.context.push(types$1.functionExpression);
+ }
+
+ this.state.exprAllowed = false;
+};
+
+types.backQuote.updateContext = function () {
+ if (this.curContext() === types$1.template) {
+ this.state.context.pop();
+ } else {
+ this.state.context.push(types$1.template);
+ }
+ this.state.exprAllowed = false;
+};
+
+// These are used when `options.locations` is on, for the
+// `startLoc` and `endLoc` properties.
+
+var Position = function Position(line, col) {
+ classCallCheck(this, Position);
+
+ this.line = line;
+ this.column = col;
+};
+
+var SourceLocation = function SourceLocation(start, end) {
+ classCallCheck(this, SourceLocation);
+
+ this.start = start;
+ this.end = end;
+};
+
+// The `getLineInfo` function is mostly useful when the
+// `locations` option is off (for performance reasons) and you
+// want to find the line/column position for a given character
+// offset. `input` should be the code string that the offset refers
+// into.
+
+function getLineInfo(input, offset) {
+ for (var line = 1, cur = 0;;) {
+ lineBreakG.lastIndex = cur;
+ var match = lineBreakG.exec(input);
+ if (match && match.index < offset) {
+ ++line;
+ cur = match.index + match[0].length;
+ } else {
+ return new Position(line, offset - cur);
+ }
+ }
+}
+
+var State = function () {
+ function State() {
+ classCallCheck(this, State);
+ }
+
+ State.prototype.init = function init(options, input) {
+ this.strict = options.strictMode === false ? false : options.sourceType === "module";
+
+ this.input = input;
+
+ this.potentialArrowAt = -1;
+
+ this.inMethod = this.inFunction = this.inGenerator = this.inAsync = this.inPropertyName = this.inType = this.noAnonFunctionType = false;
+
+ this.labels = [];
+
+ this.decorators = [];
+
+ this.tokens = [];
+
+ this.comments = [];
+
+ this.trailingComments = [];
+ this.leadingComments = [];
+ this.commentStack = [];
+
+ this.pos = this.lineStart = 0;
+ this.curLine = 1;
+
+ this.type = types.eof;
+ this.value = null;
+ this.start = this.end = this.pos;
+ this.startLoc = this.endLoc = this.curPosition();
+
+ this.lastTokEndLoc = this.lastTokStartLoc = null;
+ this.lastTokStart = this.lastTokEnd = this.pos;
+
+ this.context = [types$1.braceStatement];
+ this.exprAllowed = true;
+
+ this.containsEsc = this.containsOctal = false;
+ this.octalPosition = null;
+
+ this.exportedIdentifiers = [];
+
+ return this;
+ };
+
+ // TODO
+
+
+ // TODO
+
+
+ // Used to signify the start of a potential arrow function
+
+
+ // Flags to track whether we are in a function, a generator.
+
+
+ // Labels in scope.
+
+
+ // Leading decorators.
+
+
+ // Token store.
+
+
+ // Comment store.
+
+
+ // Comment attachment store
+
+
+ // The current position of the tokenizer in the input.
+
+
+ // Properties of the current token:
+ // Its type
+
+
+ // For tokens that include more information than their type, the value
+
+
+ // Its start and end offset
+
+
+ // And, if locations are used, the {line, column} object
+ // corresponding to those offsets
+
+
+ // Position information for the previous token
+
+
+ // The context stack is used to superficially track syntactic
+ // context to predict whether a regular expression is allowed in a
+ // given position.
+
+
+ // Used to signal to callers of `readWord1` whether the word
+ // contained any escape sequences. This is needed because words with
+ // escape sequences must not be interpreted as keywords.
+
+
+ // TODO
+
+
+ // Names of exports store. `default` is stored as a name for both
+ // `export default foo;` and `export { foo as default };`.
+
+
+ State.prototype.curPosition = function curPosition() {
+ return new Position(this.curLine, this.pos - this.lineStart);
+ };
+
+ State.prototype.clone = function clone(skipArrays) {
+ var state = new State();
+ for (var key in this) {
+ var val = this[key];
+
+ if ((!skipArrays || key === "context") && Array.isArray(val)) {
+ val = val.slice();
+ }
+
+ state[key] = val;
+ }
+ return state;
+ };
+
+ return State;
+}();
+
+/* eslint indent: 0 */
+
+// Object type used to represent tokens. Note that normally, tokens
+// simply exist as properties on the parser object. This is only
+// used for the onToken callback and the external tokenizer.
+
+var Token = function Token(state) {
+ classCallCheck(this, Token);
+
+ this.type = state.type;
+ this.value = state.value;
+ this.start = state.start;
+ this.end = state.end;
+ this.loc = new SourceLocation(state.startLoc, state.endLoc);
+};
+
+// ## Tokenizer
+
+function codePointToString(code) {
+ // UTF-16 Decoding
+ if (code <= 0xFFFF) {
+ return String.fromCharCode(code);
+ } else {
+ return String.fromCharCode((code - 0x10000 >> 10) + 0xD800, (code - 0x10000 & 1023) + 0xDC00);
+ }
+}
+
+var Tokenizer = function () {
+ function Tokenizer(options, input) {
+ classCallCheck(this, Tokenizer);
+
+ this.state = new State();
+ this.state.init(options, input);
+ }
+
+ // Move to the next token
+
+ Tokenizer.prototype.next = function next() {
+ if (!this.isLookahead) {
+ this.state.tokens.push(new Token(this.state));
+ }
+
+ this.state.lastTokEnd = this.state.end;
+ this.state.lastTokStart = this.state.start;
+ this.state.lastTokEndLoc = this.state.endLoc;
+ this.state.lastTokStartLoc = this.state.startLoc;
+ this.nextToken();
+ };
+
+ // TODO
+
+ Tokenizer.prototype.eat = function eat(type) {
+ if (this.match(type)) {
+ this.next();
+ return true;
+ } else {
+ return false;
+ }
+ };
+
+ // TODO
+
+ Tokenizer.prototype.match = function match(type) {
+ return this.state.type === type;
+ };
+
+ // TODO
+
+ Tokenizer.prototype.isKeyword = function isKeyword$$1(word) {
+ return isKeyword(word);
+ };
+
+ // TODO
+
+ Tokenizer.prototype.lookahead = function lookahead() {
+ var old = this.state;
+ this.state = old.clone(true);
+
+ this.isLookahead = true;
+ this.next();
+ this.isLookahead = false;
+
+ var curr = this.state.clone(true);
+ this.state = old;
+ return curr;
+ };
+
+ // Toggle strict mode. Re-reads the next number or string to please
+ // pedantic tests (`"use strict"; 010;` should fail).
+
+ Tokenizer.prototype.setStrict = function setStrict(strict) {
+ this.state.strict = strict;
+ if (!this.match(types.num) && !this.match(types.string)) return;
+ this.state.pos = this.state.start;
+ while (this.state.pos < this.state.lineStart) {
+ this.state.lineStart = this.input.lastIndexOf("\n", this.state.lineStart - 2) + 1;
+ --this.state.curLine;
+ }
+ this.nextToken();
+ };
+
+ Tokenizer.prototype.curContext = function curContext() {
+ return this.state.context[this.state.context.length - 1];
+ };
+
+ // Read a single token, updating the parser object's token-related
+ // properties.
+
+ Tokenizer.prototype.nextToken = function nextToken() {
+ var curContext = this.curContext();
+ if (!curContext || !curContext.preserveSpace) this.skipSpace();
+
+ this.state.containsOctal = false;
+ this.state.octalPosition = null;
+ this.state.start = this.state.pos;
+ this.state.startLoc = this.state.curPosition();
+ if (this.state.pos >= this.input.length) return this.finishToken(types.eof);
+
+ if (curContext.override) {
+ return curContext.override(this);
+ } else {
+ return this.readToken(this.fullCharCodeAtPos());
+ }
+ };
+
+ Tokenizer.prototype.readToken = function readToken(code) {
+ // Identifier or keyword. '\uXXXX' sequences are allowed in
+ // identifiers, so '\' also dispatches to that.
+ if (isIdentifierStart(code) || code === 92 /* '\' */) {
+ return this.readWord();
+ } else {
+ return this.getTokenFromCode(code);
+ }
+ };
+
+ Tokenizer.prototype.fullCharCodeAtPos = function fullCharCodeAtPos() {
+ var code = this.input.charCodeAt(this.state.pos);
+ if (code <= 0xd7ff || code >= 0xe000) return code;
+
+ var next = this.input.charCodeAt(this.state.pos + 1);
+ return (code << 10) + next - 0x35fdc00;
+ };
+
+ Tokenizer.prototype.pushComment = function pushComment(block, text, start, end, startLoc, endLoc) {
+ var comment = {
+ type: block ? "CommentBlock" : "CommentLine",
+ value: text,
+ start: start,
+ end: end,
+ loc: new SourceLocation(startLoc, endLoc)
+ };
+
+ if (!this.isLookahead) {
+ this.state.tokens.push(comment);
+ this.state.comments.push(comment);
+ this.addComment(comment);
+ }
+ };
+
+ Tokenizer.prototype.skipBlockComment = function skipBlockComment() {
+ var startLoc = this.state.curPosition();
+ var start = this.state.pos;
+ var end = this.input.indexOf("*/", this.state.pos += 2);
+ if (end === -1) this.raise(this.state.pos - 2, "Unterminated comment");
+
+ this.state.pos = end + 2;
+ lineBreakG.lastIndex = start;
+ var match = void 0;
+ while ((match = lineBreakG.exec(this.input)) && match.index < this.state.pos) {
+ ++this.state.curLine;
+ this.state.lineStart = match.index + match[0].length;
+ }
+
+ this.pushComment(true, this.input.slice(start + 2, end), start, this.state.pos, startLoc, this.state.curPosition());
+ };
+
+ Tokenizer.prototype.skipLineComment = function skipLineComment(startSkip) {
+ var start = this.state.pos;
+ var startLoc = this.state.curPosition();
+ var ch = this.input.charCodeAt(this.state.pos += startSkip);
+ while (this.state.pos < this.input.length && ch !== 10 && ch !== 13 && ch !== 8232 && ch !== 8233) {
+ ++this.state.pos;
+ ch = this.input.charCodeAt(this.state.pos);
+ }
+
+ this.pushComment(false, this.input.slice(start + startSkip, this.state.pos), start, this.state.pos, startLoc, this.state.curPosition());
+ };
+
+ // Called at the start of the parse and after every token. Skips
+ // whitespace and comments, and.
+
+ Tokenizer.prototype.skipSpace = function skipSpace() {
+ loop: while (this.state.pos < this.input.length) {
+ var ch = this.input.charCodeAt(this.state.pos);
+ switch (ch) {
+ case 32:case 160:
+ // ' '
+ ++this.state.pos;
+ break;
+
+ case 13:
+ if (this.input.charCodeAt(this.state.pos + 1) === 10) {
+ ++this.state.pos;
+ }
+
+ case 10:case 8232:case 8233:
+ ++this.state.pos;
+ ++this.state.curLine;
+ this.state.lineStart = this.state.pos;
+ break;
+
+ case 47:
+ // '/'
+ switch (this.input.charCodeAt(this.state.pos + 1)) {
+ case 42:
+ // '*'
+ this.skipBlockComment();
+ break;
+
+ case 47:
+ this.skipLineComment(2);
+ break;
+
+ default:
+ break loop;
+ }
+ break;
+
+ default:
+ if (ch > 8 && ch < 14 || ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch))) {
+ ++this.state.pos;
+ } else {
+ break loop;
+ }
+ }
+ }
+ };
+
+ // Called at the end of every token. Sets `end`, `val`, and
+ // maintains `context` and `exprAllowed`, and skips the space after
+ // the token, so that the next one's `start` will point at the
+ // right position.
+
+ Tokenizer.prototype.finishToken = function finishToken(type, val) {
+ this.state.end = this.state.pos;
+ this.state.endLoc = this.state.curPosition();
+ var prevType = this.state.type;
+ this.state.type = type;
+ this.state.value = val;
+
+ this.updateContext(prevType);
+ };
+
+ // ### Token reading
+
+ // This is the function that is called to fetch the next token. It
+ // is somewhat obscure, because it works in character codes rather
+ // than characters, and because operator parsing has been inlined
+ // into it.
+ //
+ // All in the name of speed.
+ //
+
+
+ Tokenizer.prototype.readToken_dot = function readToken_dot() {
+ var next = this.input.charCodeAt(this.state.pos + 1);
+ if (next >= 48 && next <= 57) {
+ return this.readNumber(true);
+ }
+
+ var next2 = this.input.charCodeAt(this.state.pos + 2);
+ if (next === 46 && next2 === 46) {
+ // 46 = dot '.'
+ this.state.pos += 3;
+ return this.finishToken(types.ellipsis);
+ } else {
+ ++this.state.pos;
+ return this.finishToken(types.dot);
+ }
+ };
+
+ Tokenizer.prototype.readToken_slash = function readToken_slash() {
+ // '/'
+ if (this.state.exprAllowed) {
+ ++this.state.pos;
+ return this.readRegexp();
+ }
+
+ var next = this.input.charCodeAt(this.state.pos + 1);
+ if (next === 61) {
+ return this.finishOp(types.assign, 2);
+ } else {
+ return this.finishOp(types.slash, 1);
+ }
+ };
+
+ Tokenizer.prototype.readToken_mult_modulo = function readToken_mult_modulo(code) {
+ // '%*'
+ var type = code === 42 ? types.star : types.modulo;
+ var width = 1;
+ var next = this.input.charCodeAt(this.state.pos + 1);
+
+ if (next === 42) {
+ // '*'
+ width++;
+ next = this.input.charCodeAt(this.state.pos + 2);
+ type = types.exponent;
+ }
+
+ if (next === 61) {
+ width++;
+ type = types.assign;
+ }
+
+ return this.finishOp(type, width);
+ };
+
+ Tokenizer.prototype.readToken_pipe_amp = function readToken_pipe_amp(code) {
+ // '|&'
+ var next = this.input.charCodeAt(this.state.pos + 1);
+ if (next === code) return this.finishOp(code === 124 ? types.logicalOR : types.logicalAND, 2);
+ if (next === 61) return this.finishOp(types.assign, 2);
+ if (code === 124 && next === 125 && this.hasPlugin("flow")) return this.finishOp(types.braceBarR, 2);
+ return this.finishOp(code === 124 ? types.bitwiseOR : types.bitwiseAND, 1);
+ };
+
+ Tokenizer.prototype.readToken_caret = function readToken_caret() {
+ // '^'
+ var next = this.input.charCodeAt(this.state.pos + 1);
+ if (next === 61) {
+ return this.finishOp(types.assign, 2);
+ } else {
+ return this.finishOp(types.bitwiseXOR, 1);
+ }
+ };
+
+ Tokenizer.prototype.readToken_plus_min = function readToken_plus_min(code) {
+ // '+-'
+ var next = this.input.charCodeAt(this.state.pos + 1);
+
+ if (next === code) {
+ if (next === 45 && this.input.charCodeAt(this.state.pos + 2) === 62 && lineBreak.test(this.input.slice(this.state.lastTokEnd, this.state.pos))) {
+ // A `-->` line comment
+ this.skipLineComment(3);
+ this.skipSpace();
+ return this.nextToken();
+ }
+ return this.finishOp(types.incDec, 2);
+ }
+
+ if (next === 61) {
+ return this.finishOp(types.assign, 2);
+ } else {
+ return this.finishOp(types.plusMin, 1);
+ }
+ };
+
+ Tokenizer.prototype.readToken_lt_gt = function readToken_lt_gt(code) {
+ // '<>'
+ var next = this.input.charCodeAt(this.state.pos + 1);
+ var size = 1;
+
+ if (next === code) {
+ size = code === 62 && this.input.charCodeAt(this.state.pos + 2) === 62 ? 3 : 2;
+ if (this.input.charCodeAt(this.state.pos + size) === 61) return this.finishOp(types.assign, size + 1);
+ return this.finishOp(types.bitShift, size);
+ }
+
+ if (next === 33 && code === 60 && this.input.charCodeAt(this.state.pos + 2) === 45 && this.input.charCodeAt(this.state.pos + 3) === 45) {
+ if (this.inModule) this.unexpected();
+ // `
+
+License
+
+Unless stated otherwise all works are:
+
+
+
+and licensed under:
+
+
+
+MIT License
+
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+
+
diff --git a/node_modules/domain-browser/README.md b/node_modules/domain-browser/README.md
new file mode 100644
index 00000000..43502eff
--- /dev/null
+++ b/node_modules/domain-browser/README.md
@@ -0,0 +1,111 @@
+
+
+domain-browser
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Node's domain module for the web browser. This is merely an evented try...catch with the same API as node, nothing more.
+
+
+
+
+
+
+Install
+
+NPM
+Install: npm install --save domain-browser
+Use: require('domain-browser')
+
+Browserify
+Install: npm install --save domain-browser
+Use: require('domain-browser')
+CDN URL: //wzrd.in/bundle/domain-browser@1.1.7
+
+Ender
+Install: ender add domain-browser
+Use: require('domain-browser')
+
+
+
+
+
+
+History
+
+Discover the release history by heading on over to the HISTORY.md file.
+
+
+
+
+
+
+Backers
+
+Maintainers
+
+These amazing people are maintaining this project:
+
+
+
+Sponsors
+
+No sponsors yet! Will you be the first?
+
+
+
+
+
+
+
+
+Contributors
+
+These amazing people have contributed code to this project:
+
+
+
+Discover how you can contribute by heading on over to the CONTRIBUTING.md file.
+
+
+
+
+
+
+License
+
+Unless stated otherwise all works are:
+
+
+
+and licensed under:
+
+
+
+
diff --git a/node_modules/domain-browser/index.js b/node_modules/domain-browser/index.js
new file mode 100644
index 00000000..f6cd7f7d
--- /dev/null
+++ b/node_modules/domain-browser/index.js
@@ -0,0 +1,69 @@
+// This file should be ES5 compatible
+/* eslint prefer-spread:0, no-var:0, prefer-reflect:0, no-magic-numbers:0 */
+'use strict'
+module.exports = (function () {
+ // Import Events
+ var events = require('events')
+
+ // Export Domain
+ var domain = {}
+ domain.createDomain = domain.create = function () {
+ var d = new events.EventEmitter()
+
+ function emitError (e) {
+ d.emit('error', e)
+ }
+
+ d.add = function (emitter) {
+ emitter.on('error', emitError)
+ }
+ d.remove = function (emitter) {
+ emitter.removeListener('error', emitError)
+ }
+ d.bind = function (fn) {
+ return function () {
+ var args = Array.prototype.slice.call(arguments)
+ try {
+ fn.apply(null, args)
+ }
+ catch (err) {
+ emitError(err)
+ }
+ }
+ }
+ d.intercept = function (fn) {
+ return function (err) {
+ if ( err ) {
+ emitError(err)
+ }
+ else {
+ var args = Array.prototype.slice.call(arguments, 1)
+ try {
+ fn.apply(null, args)
+ }
+ catch (err) {
+ emitError(err)
+ }
+ }
+ }
+ }
+ d.run = function (fn) {
+ try {
+ fn()
+ }
+ catch (err) {
+ emitError(err)
+ }
+ return this
+ }
+ d.dispose = function () {
+ this.removeAllListeners()
+ return this
+ }
+ d.enter = d.exit = function () {
+ return this
+ }
+ return d
+ }
+ return domain
+}).call(this)
diff --git a/node_modules/domain-browser/package.json b/node_modules/domain-browser/package.json
new file mode 100644
index 00000000..e772cba4
--- /dev/null
+++ b/node_modules/domain-browser/package.json
@@ -0,0 +1,181 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "domain-browser@^1.1.1",
+ "scope": null,
+ "escapedName": "domain-browser",
+ "name": "domain-browser",
+ "rawSpec": "^1.1.1",
+ "spec": ">=1.1.1 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/node-libs-browser"
+ ]
+ ],
+ "_from": "domain-browser@>=1.1.1 <2.0.0",
+ "_id": "domain-browser@1.1.7",
+ "_inCache": true,
+ "_location": "/domain-browser",
+ "_nodeVersion": "5.2.0",
+ "_npmUser": {
+ "name": "balupton",
+ "email": "b@lupton.cc"
+ },
+ "_npmVersion": "3.5.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "domain-browser@^1.1.1",
+ "scope": null,
+ "escapedName": "domain-browser",
+ "name": "domain-browser",
+ "rawSpec": "^1.1.1",
+ "spec": ">=1.1.1 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/node-libs-browser"
+ ],
+ "_resolved": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.1.7.tgz",
+ "_shasum": "867aa4b093faa05f1de08c06f4d7b21fdf8698bc",
+ "_shrinkwrap": null,
+ "_spec": "domain-browser@^1.1.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/node-libs-browser",
+ "author": {
+ "name": "2013+ Bevry Pty Ltd",
+ "email": "us@bevry.me",
+ "url": "http://bevry.me"
+ },
+ "badges": {
+ "list": [
+ "travisci",
+ "npmversion",
+ "npmdownloads",
+ "daviddm",
+ "daviddmdev",
+ "---",
+ "slackin",
+ "patreon",
+ "gratipay",
+ "flattr",
+ "paypal",
+ "bitcoin",
+ "wishlist"
+ ],
+ "config": {
+ "patreonUsername": "bevry",
+ "gratipayUsername": "bevry",
+ "flattrCode": "344188/balupton-on-Flattr",
+ "paypalButtonID": "QB8GQPZAH84N6",
+ "bitcoinURL": "https://bevry.me/bitcoin",
+ "wishlistURL": "https://bevry.me/wishlist",
+ "slackinURL": "https://slack.bevry.me"
+ }
+ },
+ "browsers": true,
+ "bugs": {
+ "url": "https://github.com/bevry/domain-browser/issues"
+ },
+ "contributors": [
+ {
+ "name": "Benjamin Lupton",
+ "email": "b@lupton.cc",
+ "url": "http://balupton.com"
+ },
+ {
+ "name": "Evan Solomon",
+ "url": "http://evansolomon.me"
+ },
+ {
+ "name": "James Halliday",
+ "email": "substack@gmail.com",
+ "url": "http://substack.net/"
+ },
+ {
+ "name": "Guy Bedford",
+ "email": "guybedford@gmail.com",
+ "url": "twitter.com/guybedford"
+ },
+ {
+ "name": "Bogdan Chadkin",
+ "email": "trysound@yandex.ru",
+ "url": "https://github.com/TrySound"
+ }
+ ],
+ "dependencies": {},
+ "description": "Node's domain module for the web browser. This is merely an evented try...catch with the same API as node, nothing more.",
+ "devDependencies": {
+ "assert-helpers": "^4.1.0",
+ "eslint": "^1.10.3",
+ "joe": "^1.6.0",
+ "joe-reporter-console": "^1.2.1",
+ "projectz": "^1.0.8"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "867aa4b093faa05f1de08c06f4d7b21fdf8698bc",
+ "tarball": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.1.7.tgz"
+ },
+ "engines": {
+ "node": ">=0.4",
+ "npm": ">=1.2"
+ },
+ "gitHead": "9b7f0590a10569078b1b3b5c33f201f0a59d9822",
+ "homepage": "https://github.com/bevry/domain-browser",
+ "jspm": {
+ "map": {
+ "./index.js": {
+ "node": "@node/domain"
+ }
+ }
+ },
+ "keywords": [
+ "domain",
+ "trycatch",
+ "try",
+ "catch",
+ "node-compat",
+ "ender.js",
+ "component",
+ "component.io",
+ "umd",
+ "amd",
+ "require.js",
+ "browser"
+ ],
+ "license": "MIT",
+ "main": "./index.js",
+ "maintainers": [
+ {
+ "name": "balupton",
+ "email": "b@lupton.cc"
+ },
+ {
+ "name": "substack",
+ "email": "mail@substack.net"
+ },
+ {
+ "name": "evansolomon",
+ "email": "evan@evanalyze.com"
+ }
+ ],
+ "name": "domain-browser",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+ssh://git@github.com/bevry/domain-browser.git"
+ },
+ "scripts": {
+ "clean": "node --harmony nakefile.js clean",
+ "compile": "node --harmony nakefile.js compile",
+ "meta": "node --harmony nakefile.js meta",
+ "prepare": "node --harmony nakefile.js prepare",
+ "release": "node --harmony nakefile.js release",
+ "setup": "node --harmony nakefile.js setup",
+ "test": "node --harmony ./test.js",
+ "verify": "node --harmony nakefile.js verify",
+ "watch": "node --harmony nakefile.js watch"
+ },
+ "version": "1.1.7"
+}
diff --git a/node_modules/domain-browser/test.js b/node_modules/domain-browser/test.js
new file mode 100644
index 00000000..70efcfcf
--- /dev/null
+++ b/node_modules/domain-browser/test.js
@@ -0,0 +1,100 @@
+/* eslint handle-callback-err:0, no-magic-numbers:0, no-unused-vars:0 */
+'use strict'
+
+// Import
+const events = require('events')
+const equal = require('assert-helpers').equal
+const joe = require('joe')
+const domain = require('./')
+
+// =====================================
+// Tests
+
+joe.describe('domain-browser', function (describe, it) {
+ it('should work on throws', function (done) {
+ const d = domain.create()
+ d.on('error', function (err) {
+ equal(err && err.message, 'a thrown error', 'error message')
+ done()
+ })
+ d.run(function () {
+ throw new Error('a thrown error')
+ })
+ })
+
+ it('should be able to add emitters', function (done) {
+ const d = domain.create()
+ const emitter = new events.EventEmitter()
+
+ d.add(emitter)
+ d.on('error', function (err) {
+ equal(err && err.message, 'an emitted error', 'error message')
+ done()
+ })
+
+ emitter.emit('error', new Error('an emitted error'))
+ })
+
+ it('should be able to remove emitters', function (done) {
+ const emitter = new events.EventEmitter()
+ const d = domain.create()
+ let domainGotError = false
+
+ d.add(emitter)
+ d.on('error', function (err) {
+ domainGotError = true
+ })
+
+ emitter.on('error', function (err) {
+ equal(err && err.message, 'This error should not go to the domain', 'error message')
+
+ // Make sure nothing race condition-y is happening
+ setTimeout(function () {
+ equal(domainGotError, false, 'no domain error')
+ done()
+ }, 0)
+ })
+
+ d.remove(emitter)
+ emitter.emit('error', new Error('This error should not go to the domain'))
+ })
+
+ it('bind should work', function (done) {
+ const d = domain.create()
+ d.on('error', function (err) {
+ equal(err && err.message, 'a thrown error', 'error message')
+ done()
+ })
+ d.bind(function (err, a, b) {
+ equal(err && err.message, 'a passed error', 'error message')
+ equal(a, 2, 'value of a')
+ equal(b, 3, 'value of b')
+ throw new Error('a thrown error')
+ })(new Error('a passed error'), 2, 3)
+ })
+
+ it('intercept should work', function (done) {
+ const d = domain.create()
+ let count = 0
+ d.on('error', function (err) {
+ if ( count === 0 ) {
+ equal(err && err.message, 'a thrown error', 'error message')
+ }
+ else if ( count === 1 ) {
+ equal(err && err.message, 'a passed error', 'error message')
+ done()
+ }
+ count++
+ })
+
+ d.intercept(function (a, b) {
+ equal(a, 2, 'value of a')
+ equal(b, 3, 'value of b')
+ throw new Error('a thrown error')
+ })(null, 2, 3)
+
+ d.intercept(function (a, b) {
+ throw new Error('should never reach here')
+ })(new Error('a passed error'), 2, 3)
+ })
+})
diff --git a/node_modules/duplexify/.npmignore b/node_modules/duplexify/.npmignore
new file mode 100644
index 00000000..3c3629e6
--- /dev/null
+++ b/node_modules/duplexify/.npmignore
@@ -0,0 +1 @@
+node_modules
diff --git a/node_modules/duplexify/.travis.yml b/node_modules/duplexify/.travis.yml
new file mode 100644
index 00000000..ecd4193f
--- /dev/null
+++ b/node_modules/duplexify/.travis.yml
@@ -0,0 +1,6 @@
+language: node_js
+node_js:
+ - "0.10"
+ - "0.12"
+ - "4"
+ - "6"
diff --git a/node_modules/duplexify/LICENSE b/node_modules/duplexify/LICENSE
new file mode 100644
index 00000000..757562ec
--- /dev/null
+++ b/node_modules/duplexify/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014 Mathias Buus
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
\ No newline at end of file
diff --git a/node_modules/duplexify/README.md b/node_modules/duplexify/README.md
new file mode 100644
index 00000000..27669f6b
--- /dev/null
+++ b/node_modules/duplexify/README.md
@@ -0,0 +1,97 @@
+# duplexify
+
+Turn a writeable and readable stream into a single streams2 duplex stream.
+
+Similar to [duplexer2](https://github.com/deoxxa/duplexer2) except it supports both streams2 and streams1 as input
+and it allows you to set the readable and writable part asynchronously using `setReadable(stream)` and `setWritable(stream)`
+
+```
+npm install duplexify
+```
+
+[](http://travis-ci.org/mafintosh/duplexify)
+
+## Usage
+
+Use `duplexify(writable, readable, streamOptions)` (or `duplexify.obj(writable, readable)` to create an object stream)
+
+``` js
+var duplexify = require('duplexify')
+
+// turn writableStream and readableStream into a single duplex stream
+var dup = duplexify(writableStream, readableStream)
+
+dup.write('hello world') // will write to writableStream
+dup.on('data', function(data) {
+ // will read from readableStream
+})
+```
+
+You can also set the readable and writable parts asynchronously
+
+``` js
+var dup = duplexify()
+
+dup.write('hello world') // write will buffer until the writable
+ // part has been set
+
+// wait a bit ...
+dup.setReadable(readableStream)
+
+// maybe wait some more?
+dup.setWritable(writableStream)
+```
+
+If you call `setReadable` or `setWritable` multiple times it will unregister the previous readable/writable stream.
+To disable the readable or writable part call `setReadable` or `setWritable` with `null`.
+
+If the readable or writable streams emits an error or close it will destroy both streams and bubble up the event.
+You can also explictly destroy the streams by calling `dup.destroy()`. The `destroy` method optionally takes an
+error object as argument, in which case the error is emitted as part of the `error` event.
+
+``` js
+dup.on('error', function(err) {
+ console.log('readable or writable emitted an error - close will follow')
+})
+
+dup.on('close', function() {
+ console.log('the duplex stream is destroyed')
+})
+
+dup.destroy() // calls destroy on the readable and writable part (if present)
+```
+
+## HTTP request example
+
+Turn a node core http request into a duplex stream is as easy as
+
+``` js
+var duplexify = require('duplexify')
+var http = require('http')
+
+var request = function(opts) {
+ var req = http.request(opts)
+ var dup = duplexify(req)
+ req.on('response', function(res) {
+ dup.setReadable(res)
+ })
+ return dup
+}
+
+var req = request({
+ method: 'GET',
+ host: 'www.google.com',
+ port: 80
+})
+
+req.end()
+req.pipe(process.stdout)
+```
+
+## License
+
+MIT
+
+## Related
+
+`duplexify` is part of the [mississippi stream utility collection](https://github.com/maxogden/mississippi) which includes more useful stream modules similar to this one.
diff --git a/node_modules/duplexify/example.js b/node_modules/duplexify/example.js
new file mode 100644
index 00000000..5585c197
--- /dev/null
+++ b/node_modules/duplexify/example.js
@@ -0,0 +1,21 @@
+var duplexify = require('duplexify')
+var http = require('http')
+
+var request = function(opts) {
+ var req = http.request(opts)
+ var dup = duplexify()
+ dup.setWritable(req)
+ req.on('response', function(res) {
+ dup.setReadable(res)
+ })
+ return dup
+}
+
+var req = request({
+ method: 'GET',
+ host: 'www.google.com',
+ port: 80
+})
+
+req.end()
+req.pipe(process.stdout)
diff --git a/node_modules/duplexify/index.js b/node_modules/duplexify/index.js
new file mode 100644
index 00000000..a04f124f
--- /dev/null
+++ b/node_modules/duplexify/index.js
@@ -0,0 +1,228 @@
+var stream = require('readable-stream')
+var eos = require('end-of-stream')
+var inherits = require('inherits')
+var shift = require('stream-shift')
+
+var SIGNAL_FLUSH = new Buffer([0])
+
+var onuncork = function(self, fn) {
+ if (self._corked) self.once('uncork', fn)
+ else fn()
+}
+
+var destroyer = function(self, end) {
+ return function(err) {
+ if (err) self.destroy(err.message === 'premature close' ? null : err)
+ else if (end && !self._ended) self.end()
+ }
+}
+
+var end = function(ws, fn) {
+ if (!ws) return fn()
+ if (ws._writableState && ws._writableState.finished) return fn()
+ if (ws._writableState) return ws.end(fn)
+ ws.end()
+ fn()
+}
+
+var toStreams2 = function(rs) {
+ return new (stream.Readable)({objectMode:true, highWaterMark:16}).wrap(rs)
+}
+
+var Duplexify = function(writable, readable, opts) {
+ if (!(this instanceof Duplexify)) return new Duplexify(writable, readable, opts)
+ stream.Duplex.call(this, opts)
+
+ this._writable = null
+ this._readable = null
+ this._readable2 = null
+
+ this._forwardDestroy = !opts || opts.destroy !== false
+ this._forwardEnd = !opts || opts.end !== false
+ this._corked = 1 // start corked
+ this._ondrain = null
+ this._drained = false
+ this._forwarding = false
+ this._unwrite = null
+ this._unread = null
+ this._ended = false
+
+ this.destroyed = false
+
+ if (writable) this.setWritable(writable)
+ if (readable) this.setReadable(readable)
+}
+
+inherits(Duplexify, stream.Duplex)
+
+Duplexify.obj = function(writable, readable, opts) {
+ if (!opts) opts = {}
+ opts.objectMode = true
+ opts.highWaterMark = 16
+ return new Duplexify(writable, readable, opts)
+}
+
+Duplexify.prototype.cork = function() {
+ if (++this._corked === 1) this.emit('cork')
+}
+
+Duplexify.prototype.uncork = function() {
+ if (this._corked && --this._corked === 0) this.emit('uncork')
+}
+
+Duplexify.prototype.setWritable = function(writable) {
+ if (this._unwrite) this._unwrite()
+
+ if (this.destroyed) {
+ if (writable && writable.destroy) writable.destroy()
+ return
+ }
+
+ if (writable === null || writable === false) {
+ this.end()
+ return
+ }
+
+ var self = this
+ var unend = eos(writable, {writable:true, readable:false}, destroyer(this, this._forwardEnd))
+
+ var ondrain = function() {
+ var ondrain = self._ondrain
+ self._ondrain = null
+ if (ondrain) ondrain()
+ }
+
+ var clear = function() {
+ self._writable.removeListener('drain', ondrain)
+ unend()
+ }
+
+ if (this._unwrite) process.nextTick(ondrain) // force a drain on stream reset to avoid livelocks
+
+ this._writable = writable
+ this._writable.on('drain', ondrain)
+ this._unwrite = clear
+
+ this.uncork() // always uncork setWritable
+}
+
+Duplexify.prototype.setReadable = function(readable) {
+ if (this._unread) this._unread()
+
+ if (this.destroyed) {
+ if (readable && readable.destroy) readable.destroy()
+ return
+ }
+
+ if (readable === null || readable === false) {
+ this.push(null)
+ this.resume()
+ return
+ }
+
+ var self = this
+ var unend = eos(readable, {writable:false, readable:true}, destroyer(this))
+
+ var onreadable = function() {
+ self._forward()
+ }
+
+ var onend = function() {
+ self.push(null)
+ }
+
+ var clear = function() {
+ self._readable2.removeListener('readable', onreadable)
+ self._readable2.removeListener('end', onend)
+ unend()
+ }
+
+ this._drained = true
+ this._readable = readable
+ this._readable2 = readable._readableState ? readable : toStreams2(readable)
+ this._readable2.on('readable', onreadable)
+ this._readable2.on('end', onend)
+ this._unread = clear
+
+ this._forward()
+}
+
+Duplexify.prototype._read = function() {
+ this._drained = true
+ this._forward()
+}
+
+Duplexify.prototype._forward = function() {
+ if (this._forwarding || !this._readable2 || !this._drained) return
+ this._forwarding = true
+
+ var data
+
+ while (this._drained && (data = shift(this._readable2)) !== null) {
+ if (this.destroyed) continue
+ this._drained = this.push(data)
+ }
+
+ this._forwarding = false
+}
+
+Duplexify.prototype.destroy = function(err) {
+ if (this.destroyed) return
+ this.destroyed = true
+
+ var self = this
+ process.nextTick(function() {
+ self._destroy(err)
+ })
+}
+
+Duplexify.prototype._destroy = function(err) {
+ if (err) {
+ var ondrain = this._ondrain
+ this._ondrain = null
+ if (ondrain) ondrain(err)
+ else this.emit('error', err)
+ }
+
+ if (this._forwardDestroy) {
+ if (this._readable && this._readable.destroy) this._readable.destroy()
+ if (this._writable && this._writable.destroy) this._writable.destroy()
+ }
+
+ this.emit('close')
+}
+
+Duplexify.prototype._write = function(data, enc, cb) {
+ if (this.destroyed) return cb()
+ if (this._corked) return onuncork(this, this._write.bind(this, data, enc, cb))
+ if (data === SIGNAL_FLUSH) return this._finish(cb)
+ if (!this._writable) return cb()
+
+ if (this._writable.write(data) === false) this._ondrain = cb
+ else cb()
+}
+
+
+Duplexify.prototype._finish = function(cb) {
+ var self = this
+ this.emit('preend')
+ onuncork(this, function() {
+ end(self._forwardEnd && self._writable, function() {
+ // haxx to not emit prefinish twice
+ if (self._writableState.prefinished === false) self._writableState.prefinished = true
+ self.emit('prefinish')
+ onuncork(self, cb)
+ })
+ })
+}
+
+Duplexify.prototype.end = function(data, enc, cb) {
+ if (typeof data === 'function') return this.end(null, null, data)
+ if (typeof enc === 'function') return this.end(data, null, enc)
+ this._ended = true
+ if (data) this.write(data)
+ if (!this._writableState.ending) this.write(SIGNAL_FLUSH)
+ return stream.Writable.prototype.end.call(this, cb)
+}
+
+module.exports = Duplexify
diff --git a/node_modules/duplexify/package.json b/node_modules/duplexify/package.json
new file mode 100644
index 00000000..1708c73a
--- /dev/null
+++ b/node_modules/duplexify/package.json
@@ -0,0 +1,102 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "duplexify@^3.2.0",
+ "scope": null,
+ "escapedName": "duplexify",
+ "name": "duplexify",
+ "rawSpec": "^3.2.0",
+ "spec": ">=3.2.0 <4.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/gasket"
+ ]
+ ],
+ "_from": "duplexify@>=3.2.0 <4.0.0",
+ "_id": "duplexify@3.5.0",
+ "_inCache": true,
+ "_location": "/duplexify",
+ "_nodeVersion": "4.6.1",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/duplexify-3.5.0.tgz_1477317448157_0.2257942291907966"
+ },
+ "_npmUser": {
+ "name": "mafintosh",
+ "email": "mathiasbuus@gmail.com"
+ },
+ "_npmVersion": "2.15.9",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "duplexify@^3.2.0",
+ "scope": null,
+ "escapedName": "duplexify",
+ "name": "duplexify",
+ "rawSpec": "^3.2.0",
+ "spec": ">=3.2.0 <4.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/gasket",
+ "/pumpify"
+ ],
+ "_resolved": "https://registry.npmjs.org/duplexify/-/duplexify-3.5.0.tgz",
+ "_shasum": "1aa773002e1578457e9d9d4a50b0ccaaebcbd604",
+ "_shrinkwrap": null,
+ "_spec": "duplexify@^3.2.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/gasket",
+ "author": {
+ "name": "Mathias Buus"
+ },
+ "bugs": {
+ "url": "https://github.com/mafintosh/duplexify/issues"
+ },
+ "dependencies": {
+ "end-of-stream": "1.0.0",
+ "inherits": "^2.0.1",
+ "readable-stream": "^2.0.0",
+ "stream-shift": "^1.0.0"
+ },
+ "description": "Turn a writable and readable stream into a streams2 duplex stream with support for async initialization and streams1/streams2 input",
+ "devDependencies": {
+ "concat-stream": "^1.4.6",
+ "tape": "^2.13.3",
+ "through2": "^0.5.1"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "1aa773002e1578457e9d9d4a50b0ccaaebcbd604",
+ "tarball": "https://registry.npmjs.org/duplexify/-/duplexify-3.5.0.tgz"
+ },
+ "gitHead": "97f525d36ce275e52435611d70b3a77a7234eaa1",
+ "homepage": "https://github.com/mafintosh/duplexify",
+ "keywords": [
+ "duplex",
+ "streams2",
+ "streams",
+ "stream",
+ "writable",
+ "readable",
+ "async"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "mafintosh",
+ "email": "mathiasbuus@gmail.com"
+ }
+ ],
+ "name": "duplexify",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/mafintosh/duplexify.git"
+ },
+ "scripts": {
+ "test": "tape test.js"
+ },
+ "version": "3.5.0"
+}
diff --git a/node_modules/duplexify/test.js b/node_modules/duplexify/test.js
new file mode 100644
index 00000000..f4856d39
--- /dev/null
+++ b/node_modules/duplexify/test.js
@@ -0,0 +1,292 @@
+var tape = require('tape')
+var through = require('through2')
+var concat = require('concat-stream')
+var net = require('net')
+var duplexify = require('./')
+
+tape('passthrough', function(t) {
+ t.plan(2)
+
+ var pt = through()
+ var dup = duplexify(pt, pt)
+
+ dup.end('hello world')
+ dup.on('finish', function() {
+ t.ok(true, 'should finish')
+ })
+ dup.pipe(concat(function(data) {
+ t.same(data.toString(), 'hello world', 'same in as out')
+ }))
+})
+
+tape('passthrough + double end', function(t) {
+ t.plan(2)
+
+ var pt = through()
+ var dup = duplexify(pt, pt)
+
+ dup.end('hello world')
+ dup.end()
+
+ dup.on('finish', function() {
+ t.ok(true, 'should finish')
+ })
+ dup.pipe(concat(function(data) {
+ t.same(data.toString(), 'hello world', 'same in as out')
+ }))
+})
+
+tape('async passthrough + end', function(t) {
+ t.plan(2)
+
+ var pt = through.obj({highWaterMark:1}, function(data, enc, cb) {
+ setTimeout(function() {
+ cb(null, data)
+ }, 100)
+ })
+
+ var dup = duplexify(pt, pt)
+
+ dup.write('hello ')
+ dup.write('world')
+ dup.end()
+
+ dup.on('finish', function() {
+ t.ok(true, 'should finish')
+ })
+ dup.pipe(concat(function(data) {
+ t.same(data.toString(), 'hello world', 'same in as out')
+ }))
+})
+
+tape('duplex', function(t) {
+ var readExpected = ['read-a', 'read-b', 'read-c']
+ var writeExpected = ['write-a', 'write-b', 'write-c']
+
+ t.plan(readExpected.length+writeExpected.length+2)
+
+ var readable = through.obj()
+ var writable = through.obj(function(data, enc, cb) {
+ t.same(data, writeExpected.shift(), 'onwrite should match')
+ cb()
+ })
+
+ var dup = duplexify.obj(writable, readable)
+
+ readExpected.slice().forEach(function(data) {
+ readable.write(data)
+ })
+ readable.end()
+
+ writeExpected.slice().forEach(function(data) {
+ dup.write(data)
+ })
+ dup.end()
+
+ dup.on('data', function(data) {
+ t.same(data, readExpected.shift(), 'ondata should match')
+ })
+ dup.on('end', function() {
+ t.ok(true, 'should end')
+ })
+ dup.on('finish', function() {
+ t.ok(true, 'should finish')
+ })
+})
+
+tape('async', function(t) {
+ var dup = duplexify()
+ var pt = through()
+
+ dup.pipe(concat(function(data) {
+ t.same(data.toString(), 'i was async', 'same in as out')
+ t.end()
+ }))
+
+ dup.write('i')
+ dup.write(' was ')
+ dup.end('async')
+
+ setTimeout(function() {
+ dup.setWritable(pt)
+ setTimeout(function() {
+ dup.setReadable(pt)
+ }, 50)
+ }, 50)
+})
+
+tape('destroy', function(t) {
+ t.plan(2)
+
+ var write = through()
+ var read = through()
+ var dup = duplexify(write, read)
+
+ write.destroy = function() {
+ t.ok(true, 'write destroyed')
+ }
+
+ dup.on('close', function() {
+ t.ok(true, 'close emitted')
+ })
+
+ dup.destroy()
+ dup.destroy() // should only work once
+})
+
+tape('destroy both', function(t) {
+ t.plan(3)
+
+ var write = through()
+ var read = through()
+ var dup = duplexify(write, read)
+
+ write.destroy = function() {
+ t.ok(true, 'write destroyed')
+ }
+
+ read.destroy = function() {
+ t.ok(true, 'read destroyed')
+ }
+
+ dup.on('close', function() {
+ t.ok(true, 'close emitted')
+ })
+
+ dup.destroy()
+ dup.destroy() // should only work once
+})
+
+tape('bubble read errors', function(t) {
+ t.plan(2)
+
+ var write = through()
+ var read = through()
+ var dup = duplexify(write, read)
+
+ dup.on('error', function(err) {
+ t.same(err.message, 'read-error', 'received read error')
+ })
+ dup.on('close', function() {
+ t.ok(true, 'close emitted')
+ })
+
+ read.emit('error', new Error('read-error'))
+ write.emit('error', new Error('write-error')) // only emit first error
+})
+
+tape('bubble write errors', function(t) {
+ t.plan(2)
+
+ var write = through()
+ var read = through()
+ var dup = duplexify(write, read)
+
+ dup.on('error', function(err) {
+ t.same(err.message, 'write-error', 'received write error')
+ })
+ dup.on('close', function() {
+ t.ok(true, 'close emitted')
+ })
+
+ write.emit('error', new Error('write-error'))
+ read.emit('error', new Error('read-error')) // only emit first error
+})
+
+tape('reset writable / readable', function(t) {
+ t.plan(3)
+
+ var toUpperCase = function(data, enc, cb) {
+ cb(null, data.toString().toUpperCase())
+ }
+
+ var passthrough = through()
+ var upper = through(toUpperCase)
+ var dup = duplexify(passthrough, passthrough)
+
+ dup.once('data', function(data) {
+ t.same(data.toString(), 'hello')
+ dup.setWritable(upper)
+ dup.setReadable(upper)
+ dup.once('data', function(data) {
+ t.same(data.toString(), 'HELLO')
+ dup.once('data', function(data) {
+ t.same(data.toString(), 'HI')
+ t.end()
+ })
+ })
+ dup.write('hello')
+ dup.write('hi')
+ })
+ dup.write('hello')
+})
+
+tape('cork', function(t) {
+ var passthrough = through()
+ var dup = duplexify(passthrough, passthrough)
+ var ok = false
+
+ dup.on('prefinish', function() {
+ dup.cork()
+ setTimeout(function() {
+ ok = true
+ dup.uncork()
+ }, 100)
+ })
+ dup.on('finish', function() {
+ t.ok(ok)
+ t.end()
+ })
+ dup.end()
+})
+
+tape('prefinish not twice', function(t) {
+ var passthrough = through()
+ var dup = duplexify(passthrough, passthrough)
+ var prefinished = false
+
+ dup.on('prefinish', function() {
+ t.ok(!prefinished, 'only prefinish once')
+ prefinished = true
+ })
+
+ dup.on('finish', function() {
+ t.end()
+ })
+
+ dup.end()
+})
+
+tape('close', function(t) {
+ var passthrough = through()
+ var dup = duplexify(passthrough, passthrough)
+ var ok = false
+
+ passthrough.emit('close')
+ dup.on('close', function() {
+ t.ok(true, 'should forward close')
+ t.end()
+ })
+})
+
+tape('works with node native streams (net)', function(t) {
+ t.plan(1)
+
+ var server = net.createServer(function(socket) {
+ var dup = duplexify(socket, socket)
+
+ dup.once('data', function(chunk) {
+ t.same(chunk, Buffer('hello world'))
+ server.close()
+ socket.end()
+ t.end()
+ })
+ })
+
+ server.listen(0, function () {
+ var socket = net.connect(server.address().port)
+ var dup = duplexify(socket, socket)
+
+ dup.write(Buffer('hello world'))
+ })
+})
diff --git a/node_modules/ee-first/LICENSE b/node_modules/ee-first/LICENSE
new file mode 100644
index 00000000..a7ae8ee9
--- /dev/null
+++ b/node_modules/ee-first/LICENSE
@@ -0,0 +1,22 @@
+
+The MIT License (MIT)
+
+Copyright (c) 2014 Jonathan Ong me@jongleberry.com
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/ee-first/README.md b/node_modules/ee-first/README.md
new file mode 100644
index 00000000..cbd2478b
--- /dev/null
+++ b/node_modules/ee-first/README.md
@@ -0,0 +1,80 @@
+# EE First
+
+[![NPM version][npm-image]][npm-url]
+[![Build status][travis-image]][travis-url]
+[![Test coverage][coveralls-image]][coveralls-url]
+[![License][license-image]][license-url]
+[![Downloads][downloads-image]][downloads-url]
+[![Gittip][gittip-image]][gittip-url]
+
+Get the first event in a set of event emitters and event pairs,
+then clean up after itself.
+
+## Install
+
+```sh
+$ npm install ee-first
+```
+
+## API
+
+```js
+var first = require('ee-first')
+```
+
+### first(arr, listener)
+
+Invoke `listener` on the first event from the list specified in `arr`. `arr` is
+an array of arrays, with each array in the format `[ee, ...event]`. `listener`
+will be called only once, the first time any of the given events are emitted. If
+`error` is one of the listened events, then if that fires first, the `listener`
+will be given the `err` argument.
+
+The `listener` is invoked as `listener(err, ee, event, args)`, where `err` is the
+first argument emitted from an `error` event, if applicable; `ee` is the event
+emitter that fired; `event` is the string event name that fired; and `args` is an
+array of the arguments that were emitted on the event.
+
+```js
+var ee1 = new EventEmitter()
+var ee2 = new EventEmitter()
+
+first([
+ [ee1, 'close', 'end', 'error'],
+ [ee2, 'error']
+], function (err, ee, event, args) {
+ // listener invoked
+})
+```
+
+#### .cancel()
+
+The group of listeners can be cancelled before being invoked and have all the event
+listeners removed from the underlying event emitters.
+
+```js
+var thunk = first([
+ [ee1, 'close', 'end', 'error'],
+ [ee2, 'error']
+], function (err, ee, event, args) {
+ // listener invoked
+})
+
+// cancel and clean up
+thunk.cancel()
+```
+
+[npm-image]: https://img.shields.io/npm/v/ee-first.svg?style=flat-square
+[npm-url]: https://npmjs.org/package/ee-first
+[github-tag]: http://img.shields.io/github/tag/jonathanong/ee-first.svg?style=flat-square
+[github-url]: https://github.com/jonathanong/ee-first/tags
+[travis-image]: https://img.shields.io/travis/jonathanong/ee-first.svg?style=flat-square
+[travis-url]: https://travis-ci.org/jonathanong/ee-first
+[coveralls-image]: https://img.shields.io/coveralls/jonathanong/ee-first.svg?style=flat-square
+[coveralls-url]: https://coveralls.io/r/jonathanong/ee-first?branch=master
+[license-image]: http://img.shields.io/npm/l/ee-first.svg?style=flat-square
+[license-url]: LICENSE.md
+[downloads-image]: http://img.shields.io/npm/dm/ee-first.svg?style=flat-square
+[downloads-url]: https://npmjs.org/package/ee-first
+[gittip-image]: https://img.shields.io/gittip/jonathanong.svg?style=flat-square
+[gittip-url]: https://www.gittip.com/jonathanong/
diff --git a/node_modules/ee-first/index.js b/node_modules/ee-first/index.js
new file mode 100644
index 00000000..501287cd
--- /dev/null
+++ b/node_modules/ee-first/index.js
@@ -0,0 +1,95 @@
+/*!
+ * ee-first
+ * Copyright(c) 2014 Jonathan Ong
+ * MIT Licensed
+ */
+
+'use strict'
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = first
+
+/**
+ * Get the first event in a set of event emitters and event pairs.
+ *
+ * @param {array} stuff
+ * @param {function} done
+ * @public
+ */
+
+function first(stuff, done) {
+ if (!Array.isArray(stuff))
+ throw new TypeError('arg must be an array of [ee, events...] arrays')
+
+ var cleanups = []
+
+ for (var i = 0; i < stuff.length; i++) {
+ var arr = stuff[i]
+
+ if (!Array.isArray(arr) || arr.length < 2)
+ throw new TypeError('each array member must be [ee, events...]')
+
+ var ee = arr[0]
+
+ for (var j = 1; j < arr.length; j++) {
+ var event = arr[j]
+ var fn = listener(event, callback)
+
+ // listen to the event
+ ee.on(event, fn)
+ // push this listener to the list of cleanups
+ cleanups.push({
+ ee: ee,
+ event: event,
+ fn: fn,
+ })
+ }
+ }
+
+ function callback() {
+ cleanup()
+ done.apply(null, arguments)
+ }
+
+ function cleanup() {
+ var x
+ for (var i = 0; i < cleanups.length; i++) {
+ x = cleanups[i]
+ x.ee.removeListener(x.event, x.fn)
+ }
+ }
+
+ function thunk(fn) {
+ done = fn
+ }
+
+ thunk.cancel = cleanup
+
+ return thunk
+}
+
+/**
+ * Create the event listener.
+ * @private
+ */
+
+function listener(event, done) {
+ return function onevent(arg1) {
+ var args = new Array(arguments.length)
+ var ee = this
+ var err = event === 'error'
+ ? arg1
+ : null
+
+ // copy args to prevent arguments escaping scope
+ for (var i = 0; i < args.length; i++) {
+ args[i] = arguments[i]
+ }
+
+ done(err, ee, event, args)
+ }
+}
diff --git a/node_modules/ee-first/package.json b/node_modules/ee-first/package.json
new file mode 100644
index 00000000..82f813e3
--- /dev/null
+++ b/node_modules/ee-first/package.json
@@ -0,0 +1,98 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "ee-first@1.1.1",
+ "scope": null,
+ "escapedName": "ee-first",
+ "name": "ee-first",
+ "rawSpec": "1.1.1",
+ "spec": "1.1.1",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/on-finished"
+ ]
+ ],
+ "_from": "ee-first@1.1.1",
+ "_id": "ee-first@1.1.1",
+ "_inCache": true,
+ "_location": "/ee-first",
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "ee-first@1.1.1",
+ "scope": null,
+ "escapedName": "ee-first",
+ "name": "ee-first",
+ "rawSpec": "1.1.1",
+ "spec": "1.1.1",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/on-finished"
+ ],
+ "_resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz",
+ "_shasum": "590c61156b0ae2f4f0255732a158b266bc56b21d",
+ "_shrinkwrap": null,
+ "_spec": "ee-first@1.1.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/on-finished",
+ "author": {
+ "name": "Jonathan Ong",
+ "email": "me@jongleberry.com",
+ "url": "http://jongleberry.com"
+ },
+ "bugs": {
+ "url": "https://github.com/jonathanong/ee-first/issues"
+ },
+ "contributors": [
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "return the first event in a set of ee/event pairs",
+ "devDependencies": {
+ "istanbul": "0.3.9",
+ "mocha": "2.2.5"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "590c61156b0ae2f4f0255732a158b266bc56b21d",
+ "tarball": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz"
+ },
+ "files": [
+ "index.js",
+ "LICENSE"
+ ],
+ "gitHead": "512e0ce4cc3643f603708f965a97b61b1a9c0441",
+ "homepage": "https://github.com/jonathanong/ee-first",
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "jongleberry",
+ "email": "jonathanrichardong@gmail.com"
+ },
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "ee-first",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonathanong/ee-first.git"
+ },
+ "scripts": {
+ "test": "mocha --reporter spec --bail --check-leaks test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
+ },
+ "version": "1.1.1"
+}
diff --git a/node_modules/emojis-list/CHANGELOG.md b/node_modules/emojis-list/CHANGELOG.md
new file mode 100644
index 00000000..d81a55cb
--- /dev/null
+++ b/node_modules/emojis-list/CHANGELOG.md
@@ -0,0 +1,70 @@
+
+# 2.1.0 (2016-10-03)
+
+* Fetch new emoji ([7dbe84d](https://github.com/kikobeats/emojis-list/commit/7dbe84d))
+
+
+
+
+## 2.0.1 (2016-05-12)
+
+* Fix typo ([3808909](https://github.com/kikobeats/emojis-list/commit/3808909))
+
+
+
+
+# 2.0.0 (2016-05-12)
+
+* Add update script ([f846dd6](https://github.com/kikobeats/emojis-list/commit/f846dd6))
+* Block dependencies in last version ([1d9e0a5](https://github.com/kikobeats/emojis-list/commit/1d9e0a5))
+* Extract main file name ([9ffe7bb](https://github.com/kikobeats/emojis-list/commit/9ffe7bb))
+* Remove unnecessary files ([4c34729](https://github.com/kikobeats/emojis-list/commit/4c34729))
+* Update docs, special webpack setup is not necessary ([c4aefe9](https://github.com/kikobeats/emojis-list/commit/c4aefe9))
+* Update example ([1e2ae03](https://github.com/kikobeats/emojis-list/commit/1e2ae03))
+* Update how to generate emojis array ([b56bad9](https://github.com/kikobeats/emojis-list/commit/b56bad9))
+* Update main file based in the new interface ([996fccb](https://github.com/kikobeats/emojis-list/commit/996fccb))
+
+
+
+
+## 1.0.3 (2016-05-12)
+
+* Add standard as linter ([5e939d6](https://github.com/kikobeats/emojis-list/commit/5e939d6))
+* Change interface ([16bc0c0](https://github.com/kikobeats/emojis-list/commit/16bc0c0))
+* Generate emoji file ([fbcf8e9](https://github.com/kikobeats/emojis-list/commit/fbcf8e9))
+* Remove unnecessary special doc ([2b12bec](https://github.com/kikobeats/emojis-list/commit/2b12bec))
+* chore(package): update browserify to version 13.0.1 ([e2c98bf](https://github.com/kikobeats/emojis-list/commit/e2c98bf))
+* chore(package): update gulp-header to version 1.8.1 ([28de793](https://github.com/kikobeats/emojis-list/commit/28de793))
+
+
+
+
+## 1.0.2 (2016-05-05)
+
+* fixed #2 ([9a6abe7](https://github.com/kikobeats/emojis-list/commit/9a6abe7)), closes [#2](https://github.com/kikobeats/emojis-list/issues/2)
+* Fomar using standard ([5202f9f](https://github.com/kikobeats/emojis-list/commit/5202f9f))
+* Update badge ([53fad9b](https://github.com/kikobeats/emojis-list/commit/53fad9b))
+
+
+
+
+## 1.0.1 (2016-04-13)
+
+* lock versions ([4a5d82e](https://github.com/kikobeats/emojis-list/commit/4a5d82e))
+* setup devDependencies ([d1de0fc](https://github.com/kikobeats/emojis-list/commit/d1de0fc))
+* update bumped ([9941038](https://github.com/kikobeats/emojis-list/commit/9941038))
+* Update package.json ([6c14b74](https://github.com/kikobeats/emojis-list/commit/6c14b74))
+* Update README.md ([1d9beeb](https://github.com/kikobeats/emojis-list/commit/1d9beeb))
+* Update README.md ([73f215e](https://github.com/kikobeats/emojis-list/commit/73f215e))
+* Update tests ([a94f7dc](https://github.com/kikobeats/emojis-list/commit/a94f7dc))
+
+
+
+
+# 1.0.0 (2015-05-12)
+
+* first commit ([a65b79d](https://github.com/kikobeats/emojis-list/commit/a65b79d))
+* updated ([9f0564c](https://github.com/kikobeats/emojis-list/commit/9f0564c))
+
+
+
diff --git a/node_modules/emojis-list/LICENSE.md b/node_modules/emojis-list/LICENSE.md
new file mode 100755
index 00000000..c0928aeb
--- /dev/null
+++ b/node_modules/emojis-list/LICENSE.md
@@ -0,0 +1,9 @@
+The MIT License (MIT)
+
+Copyright © 2015 Kiko Beats
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/emojis-list/README.md b/node_modules/emojis-list/README.md
new file mode 100755
index 00000000..1de02f9f
--- /dev/null
+++ b/node_modules/emojis-list/README.md
@@ -0,0 +1,48 @@
+# emojis-list
+
+[](https://david-dm.org/Kikobeats/emojis-list)
+[](https://david-dm.org/Kikobeats/emojis-list#info=devDependencies)
+[](https://www.npmjs.org/package/emojis-list)
+[](https://paypal.me/kikobeats)
+
+> Complete list of standard Unicode Hex Character Code that represent emojis.
+
+**NOTE**: The lists is related with the Unicode Hex Character Code. The representation of the emoji depend of the system. Will be possible that the system don't have all the representations.
+
+## Install
+
+```bash
+npm install emojis-list --save
+```
+
+If you want to use in the browser (powered by [Browserify](http://browserify.org/)):
+
+```bash
+bower install emojis-list --save
+```
+
+and later link in your HTML:
+
+```html
+
+```
+
+## Usage
+
+```
+var emojis = require('emojis-list');
+console.log(emojis[0]);
+// => 🀄
+```
+
+## Related
+
+* [emojis-unicode](https://github.com/Kikobeats/emojis-unicode) – Complete list of standard Unicode codes that represent emojis.
+* [emojis-keywords](https://github.com/Kikobeats/emojis-keywords) – Complete list of am emoji shortcuts.
+* [is-emoji-keyword](https://github.com/Kikobeats/is-emoji-keyword) – Check if a word is a emoji shortcut.
+* [is-standard-emoji](https://github.com/kikobeats/is-standard-emoji) – Simply way to check if a emoji is a standard emoji.
+* [trim-emoji](https://github.com/Kikobeats/trim-emoji) – Deletes ':' from the begin and the end of an emoji shortcut.
+
+## License
+
+MIT © [Kiko Beats](http://www.kikobeats.com)
diff --git a/node_modules/emojis-list/index.js b/node_modules/emojis-list/index.js
new file mode 100644
index 00000000..d59beaba
--- /dev/null
+++ b/node_modules/emojis-list/index.js
@@ -0,0 +1,2479 @@
+module.exports = [
+ "🀄",
+ "🃏",
+ "🅰",
+ "🅱",
+ "🅾",
+ "🅿",
+ "🆎",
+ "🆑",
+ "🆒",
+ "🆓",
+ "🆔",
+ "🆕",
+ "🆖",
+ "🆗",
+ "🆘",
+ "🆙",
+ "🆚",
+ "🇦🇨",
+ "🇦🇩",
+ "🇦🇪",
+ "🇦🇫",
+ "🇦🇬",
+ "🇦🇮",
+ "🇦🇱",
+ "🇦🇲",
+ "🇦🇴",
+ "🇦🇶",
+ "🇦🇷",
+ "🇦🇸",
+ "🇦🇹",
+ "🇦🇺",
+ "🇦🇼",
+ "🇦🇽",
+ "🇦🇿",
+ "🇦",
+ "🇧🇦",
+ "🇧🇧",
+ "🇧🇩",
+ "🇧🇪",
+ "🇧🇫",
+ "🇧🇬",
+ "🇧🇭",
+ "🇧🇮",
+ "🇧🇯",
+ "🇧🇱",
+ "🇧🇲",
+ "🇧🇳",
+ "🇧🇴",
+ "🇧🇶",
+ "🇧🇷",
+ "🇧🇸",
+ "🇧🇹",
+ "🇧🇻",
+ "🇧🇼",
+ "🇧🇾",
+ "🇧🇿",
+ "🇧",
+ "🇨🇦",
+ "🇨🇨",
+ "🇨🇩",
+ "🇨🇫",
+ "🇨🇬",
+ "🇨🇭",
+ "🇨🇮",
+ "🇨🇰",
+ "🇨🇱",
+ "🇨🇲",
+ "🇨🇳",
+ "🇨🇴",
+ "🇨🇵",
+ "🇨🇷",
+ "🇨🇺",
+ "🇨🇻",
+ "🇨🇼",
+ "🇨🇽",
+ "🇨🇾",
+ "🇨🇿",
+ "🇨",
+ "🇩🇪",
+ "🇩🇬",
+ "🇩🇯",
+ "🇩🇰",
+ "🇩🇲",
+ "🇩🇴",
+ "🇩🇿",
+ "🇩",
+ "🇪🇦",
+ "🇪🇨",
+ "🇪🇪",
+ "🇪🇬",
+ "🇪🇭",
+ "🇪🇷",
+ "🇪🇸",
+ "🇪🇹",
+ "🇪🇺",
+ "🇪",
+ "🇫🇮",
+ "🇫🇯",
+ "🇫🇰",
+ "🇫🇲",
+ "🇫🇴",
+ "🇫🇷",
+ "🇫",
+ "🇬🇦",
+ "🇬🇧",
+ "🇬🇩",
+ "🇬🇪",
+ "🇬🇫",
+ "🇬🇬",
+ "🇬🇭",
+ "🇬🇮",
+ "🇬🇱",
+ "🇬🇲",
+ "🇬🇳",
+ "🇬🇵",
+ "🇬🇶",
+ "🇬🇷",
+ "🇬🇸",
+ "🇬🇹",
+ "🇬🇺",
+ "🇬🇼",
+ "🇬🇾",
+ "🇬",
+ "🇭🇰",
+ "🇭🇲",
+ "🇭🇳",
+ "🇭🇷",
+ "🇭🇹",
+ "🇭🇺",
+ "🇭",
+ "🇮🇨",
+ "🇮🇩",
+ "🇮🇪",
+ "🇮🇱",
+ "🇮🇲",
+ "🇮🇳",
+ "🇮🇴",
+ "🇮🇶",
+ "🇮🇷",
+ "🇮🇸",
+ "🇮🇹",
+ "🇮",
+ "🇯🇪",
+ "🇯🇲",
+ "🇯🇴",
+ "🇯🇵",
+ "🇯",
+ "🇰🇪",
+ "🇰🇬",
+ "🇰🇭",
+ "🇰🇮",
+ "🇰🇲",
+ "🇰🇳",
+ "🇰🇵",
+ "🇰🇷",
+ "🇰🇼",
+ "🇰🇾",
+ "🇰🇿",
+ "🇰",
+ "🇱🇦",
+ "🇱🇧",
+ "🇱🇨",
+ "🇱🇮",
+ "🇱🇰",
+ "🇱🇷",
+ "🇱🇸",
+ "🇱🇹",
+ "🇱🇺",
+ "🇱🇻",
+ "🇱🇾",
+ "🇱",
+ "🇲🇦",
+ "🇲🇨",
+ "🇲🇩",
+ "🇲🇪",
+ "🇲🇫",
+ "🇲🇬",
+ "🇲🇭",
+ "🇲🇰",
+ "🇲🇱",
+ "🇲🇲",
+ "🇲🇳",
+ "🇲🇴",
+ "🇲🇵",
+ "🇲🇶",
+ "🇲🇷",
+ "🇲🇸",
+ "🇲🇹",
+ "🇲🇺",
+ "🇲🇻",
+ "🇲🇼",
+ "🇲🇽",
+ "🇲🇾",
+ "🇲🇿",
+ "🇲",
+ "🇳🇦",
+ "🇳🇨",
+ "🇳🇪",
+ "🇳🇫",
+ "🇳🇬",
+ "🇳🇮",
+ "🇳🇱",
+ "🇳🇴",
+ "🇳🇵",
+ "🇳🇷",
+ "🇳🇺",
+ "🇳🇿",
+ "🇳",
+ "🇴🇲",
+ "🇴",
+ "🇵🇦",
+ "🇵🇪",
+ "🇵🇫",
+ "🇵🇬",
+ "🇵🇭",
+ "🇵🇰",
+ "🇵🇱",
+ "🇵🇲",
+ "🇵🇳",
+ "🇵🇷",
+ "🇵🇸",
+ "🇵🇹",
+ "🇵🇼",
+ "🇵🇾",
+ "🇵",
+ "🇶🇦",
+ "🇶",
+ "🇷🇪",
+ "🇷🇴",
+ "🇷🇸",
+ "🇷🇺",
+ "🇷🇼",
+ "🇷",
+ "🇸🇦",
+ "🇸🇧",
+ "🇸🇨",
+ "🇸🇩",
+ "🇸🇪",
+ "🇸🇬",
+ "🇸🇭",
+ "🇸🇮",
+ "🇸🇯",
+ "🇸🇰",
+ "🇸🇱",
+ "🇸🇲",
+ "🇸🇳",
+ "🇸🇴",
+ "🇸🇷",
+ "🇸🇸",
+ "🇸🇹",
+ "🇸🇻",
+ "🇸🇽",
+ "🇸🇾",
+ "🇸🇿",
+ "🇸",
+ "🇹🇦",
+ "🇹🇨",
+ "🇹🇩",
+ "🇹🇫",
+ "🇹🇬",
+ "🇹🇭",
+ "🇹🇯",
+ "🇹🇰",
+ "🇹🇱",
+ "🇹🇲",
+ "🇹🇳",
+ "🇹🇴",
+ "🇹🇷",
+ "🇹🇹",
+ "🇹🇻",
+ "🇹🇼",
+ "🇹🇿",
+ "🇹",
+ "🇺🇦",
+ "🇺🇬",
+ "🇺🇲",
+ "🇺🇳",
+ "🇺🇸",
+ "🇺🇾",
+ "🇺🇿",
+ "🇺",
+ "🇻🇦",
+ "🇻🇨",
+ "🇻🇪",
+ "🇻🇬",
+ "🇻🇮",
+ "🇻🇳",
+ "🇻🇺",
+ "🇻",
+ "🇼🇫",
+ "🇼🇸",
+ "🇼",
+ "🇽🇰",
+ "🇽",
+ "🇾🇪",
+ "🇾🇹",
+ "🇾",
+ "🇿🇦",
+ "🇿🇲",
+ "🇿🇼",
+ "🇿",
+ "🈁",
+ "🈂",
+ "🈚",
+ "🈯",
+ "🈲",
+ "🈳",
+ "🈴",
+ "🈵",
+ "🈶",
+ "🈷",
+ "🈸",
+ "🈹",
+ "🈺",
+ "🉐",
+ "🉑",
+ "🌀",
+ "🌁",
+ "🌂",
+ "🌃",
+ "🌄",
+ "🌅",
+ "🌆",
+ "🌇",
+ "🌈",
+ "🌉",
+ "🌊",
+ "🌋",
+ "🌌",
+ "🌍",
+ "🌎",
+ "🌏",
+ "🌐",
+ "🌑",
+ "🌒",
+ "🌓",
+ "🌔",
+ "🌕",
+ "🌖",
+ "🌗",
+ "🌘",
+ "🌙",
+ "🌚",
+ "🌛",
+ "🌜",
+ "🌝",
+ "🌞",
+ "🌟",
+ "🌠",
+ "🌡",
+ "🌤",
+ "🌥",
+ "🌦",
+ "🌧",
+ "🌨",
+ "🌩",
+ "🌪",
+ "🌫",
+ "🌬",
+ "🌭",
+ "🌮",
+ "🌯",
+ "🌰",
+ "🌱",
+ "🌲",
+ "🌳",
+ "🌴",
+ "🌵",
+ "🌶",
+ "🌷",
+ "🌸",
+ "🌹",
+ "🌺",
+ "🌻",
+ "🌼",
+ "🌽",
+ "🌾",
+ "🌿",
+ "🍀",
+ "🍁",
+ "🍂",
+ "🍃",
+ "🍄",
+ "🍅",
+ "🍆",
+ "🍇",
+ "🍈",
+ "🍉",
+ "🍊",
+ "🍋",
+ "🍌",
+ "🍍",
+ "🍎",
+ "🍏",
+ "🍐",
+ "🍑",
+ "🍒",
+ "🍓",
+ "🍔",
+ "🍕",
+ "🍖",
+ "🍗",
+ "🍘",
+ "🍙",
+ "🍚",
+ "🍛",
+ "🍜",
+ "🍝",
+ "🍞",
+ "🍟",
+ "🍠",
+ "🍡",
+ "🍢",
+ "🍣",
+ "🍤",
+ "🍥",
+ "🍦",
+ "🍧",
+ "🍨",
+ "🍩",
+ "🍪",
+ "🍫",
+ "🍬",
+ "🍭",
+ "🍮",
+ "🍯",
+ "🍰",
+ "🍱",
+ "🍲",
+ "🍳",
+ "🍴",
+ "🍵",
+ "🍶",
+ "🍷",
+ "🍸",
+ "🍹",
+ "🍺",
+ "🍻",
+ "🍼",
+ "🍽",
+ "🍾",
+ "🍿",
+ "🎀",
+ "🎁",
+ "🎂",
+ "🎃",
+ "🎄",
+ "🎅🏻",
+ "🎅🏼",
+ "🎅🏽",
+ "🎅🏾",
+ "🎅🏿",
+ "🎅",
+ "🎆",
+ "🎇",
+ "🎈",
+ "🎉",
+ "🎊",
+ "🎋",
+ "🎌",
+ "🎍",
+ "🎎",
+ "🎏",
+ "🎐",
+ "🎑",
+ "🎒",
+ "🎓",
+ "🎖",
+ "🎗",
+ "🎙",
+ "🎚",
+ "🎛",
+ "🎞",
+ "🎟",
+ "🎠",
+ "🎡",
+ "🎢",
+ "🎣",
+ "🎤",
+ "🎥",
+ "🎦",
+ "🎧",
+ "🎨",
+ "🎩",
+ "🎪",
+ "🎫",
+ "🎬",
+ "🎭",
+ "🎮",
+ "🎯",
+ "🎰",
+ "🎱",
+ "🎲",
+ "🎳",
+ "🎴",
+ "🎵",
+ "🎶",
+ "🎷",
+ "🎸",
+ "🎹",
+ "🎺",
+ "🎻",
+ "🎼",
+ "🎽",
+ "🎾",
+ "🎿",
+ "🏀",
+ "🏁",
+ "🏂🏻",
+ "🏂🏼",
+ "🏂🏽",
+ "🏂🏾",
+ "🏂🏿",
+ "🏂",
+ "🏃🏻♀️",
+ "🏃🏻♂️",
+ "🏃🏻",
+ "🏃🏼♀️",
+ "🏃🏼♂️",
+ "🏃🏼",
+ "🏃🏽♀️",
+ "🏃🏽♂️",
+ "🏃🏽",
+ "🏃🏾♀️",
+ "🏃🏾♂️",
+ "🏃🏾",
+ "🏃🏿♀️",
+ "🏃🏿♂️",
+ "🏃🏿",
+ "🏃♀️",
+ "🏃♂️",
+ "🏃",
+ "🏄🏻♀️",
+ "🏄🏻♂️",
+ "🏄🏻",
+ "🏄🏼♀️",
+ "🏄🏼♂️",
+ "🏄🏼",
+ "🏄🏽♀️",
+ "🏄🏽♂️",
+ "🏄🏽",
+ "🏄🏾♀️",
+ "🏄🏾♂️",
+ "🏄🏾",
+ "🏄🏿♀️",
+ "🏄🏿♂️",
+ "🏄🏿",
+ "🏄♀️",
+ "🏄♂️",
+ "🏄",
+ "🏅",
+ "🏆",
+ "🏇🏻",
+ "🏇🏼",
+ "🏇🏽",
+ "🏇🏾",
+ "🏇🏿",
+ "🏇",
+ "🏈",
+ "🏉",
+ "🏊🏻♀️",
+ "🏊🏻♂️",
+ "🏊🏻",
+ "🏊🏼♀️",
+ "🏊🏼♂️",
+ "🏊🏼",
+ "🏊🏽♀️",
+ "🏊🏽♂️",
+ "🏊🏽",
+ "🏊🏾♀️",
+ "🏊🏾♂️",
+ "🏊🏾",
+ "🏊🏿♀️",
+ "🏊🏿♂️",
+ "🏊🏿",
+ "🏊♀️",
+ "🏊♂️",
+ "🏊",
+ "🏋🏻♀️",
+ "🏋🏻♂️",
+ "🏋🏻",
+ "🏋🏼♀️",
+ "🏋🏼♂️",
+ "🏋🏼",
+ "🏋🏽♀️",
+ "🏋🏽♂️",
+ "🏋🏽",
+ "🏋🏾♀️",
+ "🏋🏾♂️",
+ "🏋🏾",
+ "🏋🏿♀️",
+ "🏋🏿♂️",
+ "🏋🏿",
+ "🏋️♀️",
+ "🏋️♂️",
+ "🏋",
+ "🏌🏻♀️",
+ "🏌🏻♂️",
+ "🏌🏻",
+ "🏌🏼♀️",
+ "🏌🏼♂️",
+ "🏌🏼",
+ "🏌🏽♀️",
+ "🏌🏽♂️",
+ "🏌🏽",
+ "🏌🏾♀️",
+ "🏌🏾♂️",
+ "🏌🏾",
+ "🏌🏿♀️",
+ "🏌🏿♂️",
+ "🏌🏿",
+ "🏌️♀️",
+ "🏌️♂️",
+ "🏌",
+ "🏍",
+ "🏎",
+ "🏏",
+ "🏐",
+ "🏑",
+ "🏒",
+ "🏓",
+ "🏔",
+ "🏕",
+ "🏖",
+ "🏗",
+ "🏘",
+ "🏙",
+ "🏚",
+ "🏛",
+ "🏜",
+ "🏝",
+ "🏞",
+ "🏟",
+ "🏠",
+ "🏡",
+ "🏢",
+ "🏣",
+ "🏤",
+ "🏥",
+ "🏦",
+ "🏧",
+ "🏨",
+ "🏩",
+ "🏪",
+ "🏫",
+ "🏬",
+ "🏭",
+ "🏮",
+ "🏯",
+ "🏰",
+ "🏳️🌈",
+ "🏳",
+ "🏴☠️",
+ "🏴",
+ "🏵",
+ "🏷",
+ "🏸",
+ "🏹",
+ "🏺",
+ "🏻",
+ "🏼",
+ "🏽",
+ "🏾",
+ "🏿",
+ "🐀",
+ "🐁",
+ "🐂",
+ "🐃",
+ "🐄",
+ "🐅",
+ "🐆",
+ "🐇",
+ "🐈",
+ "🐉",
+ "🐊",
+ "🐋",
+ "🐌",
+ "🐍",
+ "🐎",
+ "🐏",
+ "🐐",
+ "🐑",
+ "🐒",
+ "🐓",
+ "🐔",
+ "🐕",
+ "🐖",
+ "🐗",
+ "🐘",
+ "🐙",
+ "🐚",
+ "🐛",
+ "🐜",
+ "🐝",
+ "🐞",
+ "🐟",
+ "🐠",
+ "🐡",
+ "🐢",
+ "🐣",
+ "🐤",
+ "🐥",
+ "🐦",
+ "🐧",
+ "🐨",
+ "🐩",
+ "🐪",
+ "🐫",
+ "🐬",
+ "🐭",
+ "🐮",
+ "🐯",
+ "🐰",
+ "🐱",
+ "🐲",
+ "🐳",
+ "🐴",
+ "🐵",
+ "🐶",
+ "🐷",
+ "🐸",
+ "🐹",
+ "🐺",
+ "🐻",
+ "🐼",
+ "🐽",
+ "🐾",
+ "🐿",
+ "👀",
+ "👁🗨",
+ "👁",
+ "👂🏻",
+ "👂🏼",
+ "👂🏽",
+ "👂🏾",
+ "👂🏿",
+ "👂",
+ "👃🏻",
+ "👃🏼",
+ "👃🏽",
+ "👃🏾",
+ "👃🏿",
+ "👃",
+ "👄",
+ "👅",
+ "👆🏻",
+ "👆🏼",
+ "👆🏽",
+ "👆🏾",
+ "👆🏿",
+ "👆",
+ "👇🏻",
+ "👇🏼",
+ "👇🏽",
+ "👇🏾",
+ "👇🏿",
+ "👇",
+ "👈🏻",
+ "👈🏼",
+ "👈🏽",
+ "👈🏾",
+ "👈🏿",
+ "👈",
+ "👉🏻",
+ "👉🏼",
+ "👉🏽",
+ "👉🏾",
+ "👉🏿",
+ "👉",
+ "👊🏻",
+ "👊🏼",
+ "👊🏽",
+ "👊🏾",
+ "👊🏿",
+ "👊",
+ "👋🏻",
+ "👋🏼",
+ "👋🏽",
+ "👋🏾",
+ "👋🏿",
+ "👋",
+ "👌🏻",
+ "👌🏼",
+ "👌🏽",
+ "👌🏾",
+ "👌🏿",
+ "👌",
+ "👍🏻",
+ "👍🏼",
+ "👍🏽",
+ "👍🏾",
+ "👍🏿",
+ "👍",
+ "👎🏻",
+ "👎🏼",
+ "👎🏽",
+ "👎🏾",
+ "👎🏿",
+ "👎",
+ "👏🏻",
+ "👏🏼",
+ "👏🏽",
+ "👏🏾",
+ "👏🏿",
+ "👏",
+ "👐🏻",
+ "👐🏼",
+ "👐🏽",
+ "👐🏾",
+ "👐🏿",
+ "👐",
+ "👑",
+ "👒",
+ "👓",
+ "👔",
+ "👕",
+ "👖",
+ "👗",
+ "👘",
+ "👙",
+ "👚",
+ "👛",
+ "👜",
+ "👝",
+ "👞",
+ "👟",
+ "👠",
+ "👡",
+ "👢",
+ "👣",
+ "👤",
+ "👥",
+ "👦🏻",
+ "👦🏼",
+ "👦🏽",
+ "👦🏾",
+ "👦🏿",
+ "👦",
+ "👧🏻",
+ "👧🏼",
+ "👧🏽",
+ "👧🏾",
+ "👧🏿",
+ "👧",
+ "👨🏻🌾",
+ "👨🏻🍳",
+ "👨🏻🎓",
+ "👨🏻🎤",
+ "👨🏻🎨",
+ "👨🏻🏫",
+ "👨🏻🏭",
+ "👨🏻💻",
+ "👨🏻💼",
+ "👨🏻🔧",
+ "👨🏻🔬",
+ "👨🏻🚀",
+ "👨🏻🚒",
+ "👨🏻⚕️",
+ "👨🏻⚖️",
+ "👨🏻✈️",
+ "👨🏻",
+ "👨🏼🌾",
+ "👨🏼🍳",
+ "👨🏼🎓",
+ "👨🏼🎤",
+ "👨🏼🎨",
+ "👨🏼🏫",
+ "👨🏼🏭",
+ "👨🏼💻",
+ "👨🏼💼",
+ "👨🏼🔧",
+ "👨🏼🔬",
+ "👨🏼🚀",
+ "👨🏼🚒",
+ "👨🏼⚕️",
+ "👨🏼⚖️",
+ "👨🏼✈️",
+ "👨🏼",
+ "👨🏽🌾",
+ "👨🏽🍳",
+ "👨🏽🎓",
+ "👨🏽🎤",
+ "👨🏽🎨",
+ "👨🏽🏫",
+ "👨🏽🏭",
+ "👨🏽💻",
+ "👨🏽💼",
+ "👨🏽🔧",
+ "👨🏽🔬",
+ "👨🏽🚀",
+ "👨🏽🚒",
+ "👨🏽⚕️",
+ "👨🏽⚖️",
+ "👨🏽✈️",
+ "👨🏽",
+ "👨🏾🌾",
+ "👨🏾🍳",
+ "👨🏾🎓",
+ "👨🏾🎤",
+ "👨🏾🎨",
+ "👨🏾🏫",
+ "👨🏾🏭",
+ "👨🏾💻",
+ "👨🏾💼",
+ "👨🏾🔧",
+ "👨🏾🔬",
+ "👨🏾🚀",
+ "👨🏾🚒",
+ "👨🏾⚕️",
+ "👨🏾⚖️",
+ "👨🏾✈️",
+ "👨🏾",
+ "👨🏿🌾",
+ "👨🏿🍳",
+ "👨🏿🎓",
+ "👨🏿🎤",
+ "👨🏿🎨",
+ "👨🏿🏫",
+ "👨🏿🏭",
+ "👨🏿💻",
+ "👨🏿💼",
+ "👨🏿🔧",
+ "👨🏿🔬",
+ "👨🏿🚀",
+ "👨🏿🚒",
+ "👨🏿⚕️",
+ "👨🏿⚖️",
+ "👨🏿✈️",
+ "👨🏿",
+ "👨🌾",
+ "👨🍳",
+ "👨🎓",
+ "👨🎤",
+ "👨🎨",
+ "👨🏫",
+ "👨🏭",
+ "👨👦👦",
+ "👨👦",
+ "👨👧👦",
+ "👨👧👧",
+ "👨👧",
+ "👨👨👦👦",
+ "👨👨👦",
+ "👨👨👧👦",
+ "👨👨👧👧",
+ "👨👨👧",
+ "👨👩👦👦",
+ "👨👩👦",
+ "👨👩👧👦",
+ "👨👩👧👧",
+ "👨👩👧",
+ "👨💻",
+ "👨💼",
+ "👨🔧",
+ "👨🔬",
+ "👨🚀",
+ "👨🚒",
+ "👨⚕️",
+ "👨⚖️",
+ "👨✈️",
+ "👨❤️👨",
+ "👨❤️💋👨",
+ "👨",
+ "👩🏻🌾",
+ "👩🏻🍳",
+ "👩🏻🎓",
+ "👩🏻🎤",
+ "👩🏻🎨",
+ "👩🏻🏫",
+ "👩🏻🏭",
+ "👩🏻💻",
+ "👩🏻💼",
+ "👩🏻🔧",
+ "👩🏻🔬",
+ "👩🏻🚀",
+ "👩🏻🚒",
+ "👩🏻⚕️",
+ "👩🏻⚖️",
+ "👩🏻✈️",
+ "👩🏻",
+ "👩🏼🌾",
+ "👩🏼🍳",
+ "👩🏼🎓",
+ "👩🏼🎤",
+ "👩🏼🎨",
+ "👩🏼🏫",
+ "👩🏼🏭",
+ "👩🏼💻",
+ "👩🏼💼",
+ "👩🏼🔧",
+ "👩🏼🔬",
+ "👩🏼🚀",
+ "👩🏼🚒",
+ "👩🏼⚕️",
+ "👩🏼⚖️",
+ "👩🏼✈️",
+ "👩🏼",
+ "👩🏽🌾",
+ "👩🏽🍳",
+ "👩🏽🎓",
+ "👩🏽🎤",
+ "👩🏽🎨",
+ "👩🏽🏫",
+ "👩🏽🏭",
+ "👩🏽💻",
+ "👩🏽💼",
+ "👩🏽🔧",
+ "👩🏽🔬",
+ "👩🏽🚀",
+ "👩🏽🚒",
+ "👩🏽⚕️",
+ "👩🏽⚖️",
+ "👩🏽✈️",
+ "👩🏽",
+ "👩🏾🌾",
+ "👩🏾🍳",
+ "👩🏾🎓",
+ "👩🏾🎤",
+ "👩🏾🎨",
+ "👩🏾🏫",
+ "👩🏾🏭",
+ "👩🏾💻",
+ "👩🏾💼",
+ "👩🏾🔧",
+ "👩🏾🔬",
+ "👩🏾🚀",
+ "👩🏾🚒",
+ "👩🏾⚕️",
+ "👩🏾⚖️",
+ "👩🏾✈️",
+ "👩🏾",
+ "👩🏿🌾",
+ "👩🏿🍳",
+ "👩🏿🎓",
+ "👩🏿🎤",
+ "👩🏿🎨",
+ "👩🏿🏫",
+ "👩🏿🏭",
+ "👩🏿💻",
+ "👩🏿💼",
+ "👩🏿🔧",
+ "👩🏿🔬",
+ "👩🏿🚀",
+ "👩🏿🚒",
+ "👩🏿⚕️",
+ "👩🏿⚖️",
+ "👩🏿✈️",
+ "👩🏿",
+ "👩🌾",
+ "👩🍳",
+ "👩🎓",
+ "👩🎤",
+ "👩🎨",
+ "👩🏫",
+ "👩🏭",
+ "👩👦👦",
+ "👩👦",
+ "👩👧👦",
+ "👩👧👧",
+ "👩👧",
+ "👩👩👦👦",
+ "👩👩👦",
+ "👩👩👧👦",
+ "👩👩👧👧",
+ "👩👩👧",
+ "👩💻",
+ "👩💼",
+ "👩🔧",
+ "👩🔬",
+ "👩🚀",
+ "👩🚒",
+ "👩⚕️",
+ "👩⚖️",
+ "👩✈️",
+ "👩❤️👨",
+ "👩❤️👩",
+ "👩❤️💋👨",
+ "👩❤️💋👩",
+ "👩",
+ "👪🏻",
+ "👪🏼",
+ "👪🏽",
+ "👪🏾",
+ "👪🏿",
+ "👪",
+ "👫🏻",
+ "👫🏼",
+ "👫🏽",
+ "👫🏾",
+ "👫🏿",
+ "👫",
+ "👬🏻",
+ "👬🏼",
+ "👬🏽",
+ "👬🏾",
+ "👬🏿",
+ "👬",
+ "👭🏻",
+ "👭🏼",
+ "👭🏽",
+ "👭🏾",
+ "👭🏿",
+ "👭",
+ "👮🏻♀️",
+ "👮🏻♂️",
+ "👮🏻",
+ "👮🏼♀️",
+ "👮🏼♂️",
+ "👮🏼",
+ "👮🏽♀️",
+ "👮🏽♂️",
+ "👮🏽",
+ "👮🏾♀️",
+ "👮🏾♂️",
+ "👮🏾",
+ "👮🏿♀️",
+ "👮🏿♂️",
+ "👮🏿",
+ "👮♀️",
+ "👮♂️",
+ "👮",
+ "👯🏻♀️",
+ "👯🏻♂️",
+ "👯🏻",
+ "👯🏼♀️",
+ "👯🏼♂️",
+ "👯🏼",
+ "👯🏽♀️",
+ "👯🏽♂️",
+ "👯🏽",
+ "👯🏾♀️",
+ "👯🏾♂️",
+ "👯🏾",
+ "👯🏿♀️",
+ "👯🏿♂️",
+ "👯🏿",
+ "👯♀️",
+ "👯♂️",
+ "👯",
+ "👰🏻",
+ "👰🏼",
+ "👰🏽",
+ "👰🏾",
+ "👰🏿",
+ "👰",
+ "👱🏻♀️",
+ "👱🏻♂️",
+ "👱🏻",
+ "👱🏼♀️",
+ "👱🏼♂️",
+ "👱🏼",
+ "👱🏽♀️",
+ "👱🏽♂️",
+ "👱🏽",
+ "👱🏾♀️",
+ "👱🏾♂️",
+ "👱🏾",
+ "👱🏿♀️",
+ "👱🏿♂️",
+ "👱🏿",
+ "👱♀️",
+ "👱♂️",
+ "👱",
+ "👲🏻",
+ "👲🏼",
+ "👲🏽",
+ "👲🏾",
+ "👲🏿",
+ "👲",
+ "👳🏻♀️",
+ "👳🏻♂️",
+ "👳🏻",
+ "👳🏼♀️",
+ "👳🏼♂️",
+ "👳🏼",
+ "👳🏽♀️",
+ "👳🏽♂️",
+ "👳🏽",
+ "👳🏾♀️",
+ "👳🏾♂️",
+ "👳🏾",
+ "👳🏿♀️",
+ "👳🏿♂️",
+ "👳🏿",
+ "👳♀️",
+ "👳♂️",
+ "👳",
+ "👴🏻",
+ "👴🏼",
+ "👴🏽",
+ "👴🏾",
+ "👴🏿",
+ "👴",
+ "👵🏻",
+ "👵🏼",
+ "👵🏽",
+ "👵🏾",
+ "👵🏿",
+ "👵",
+ "👶🏻",
+ "👶🏼",
+ "👶🏽",
+ "👶🏾",
+ "👶🏿",
+ "👶",
+ "👷🏻♀️",
+ "👷🏻♂️",
+ "👷🏻",
+ "👷🏼♀️",
+ "👷🏼♂️",
+ "👷🏼",
+ "👷🏽♀️",
+ "👷🏽♂️",
+ "👷🏽",
+ "👷🏾♀️",
+ "👷🏾♂️",
+ "👷🏾",
+ "👷🏿♀️",
+ "👷🏿♂️",
+ "👷🏿",
+ "👷♀️",
+ "👷♂️",
+ "👷",
+ "👸🏻",
+ "👸🏼",
+ "👸🏽",
+ "👸🏾",
+ "👸🏿",
+ "👸",
+ "👹",
+ "👺",
+ "👻",
+ "👼🏻",
+ "👼🏼",
+ "👼🏽",
+ "👼🏾",
+ "👼🏿",
+ "👼",
+ "👽",
+ "👾",
+ "👿",
+ "💀",
+ "💁🏻♀️",
+ "💁🏻♂️",
+ "💁🏻",
+ "💁🏼♀️",
+ "💁🏼♂️",
+ "💁🏼",
+ "💁🏽♀️",
+ "💁🏽♂️",
+ "💁🏽",
+ "💁🏾♀️",
+ "💁🏾♂️",
+ "💁🏾",
+ "💁🏿♀️",
+ "💁🏿♂️",
+ "💁🏿",
+ "💁♀️",
+ "💁♂️",
+ "💁",
+ "💂🏻♀️",
+ "💂🏻♂️",
+ "💂🏻",
+ "💂🏼♀️",
+ "💂🏼♂️",
+ "💂🏼",
+ "💂🏽♀️",
+ "💂🏽♂️",
+ "💂🏽",
+ "💂🏾♀️",
+ "💂🏾♂️",
+ "💂🏾",
+ "💂🏿♀️",
+ "💂🏿♂️",
+ "💂🏿",
+ "💂♀️",
+ "💂♂️",
+ "💂",
+ "💃🏻",
+ "💃🏼",
+ "💃🏽",
+ "💃🏾",
+ "💃🏿",
+ "💃",
+ "💄",
+ "💅🏻",
+ "💅🏼",
+ "💅🏽",
+ "💅🏾",
+ "💅🏿",
+ "💅",
+ "💆🏻♀️",
+ "💆🏻♂️",
+ "💆🏻",
+ "💆🏼♀️",
+ "💆🏼♂️",
+ "💆🏼",
+ "💆🏽♀️",
+ "💆🏽♂️",
+ "💆🏽",
+ "💆🏾♀️",
+ "💆🏾♂️",
+ "💆🏾",
+ "💆🏿♀️",
+ "💆🏿♂️",
+ "💆🏿",
+ "💆♀️",
+ "💆♂️",
+ "💆",
+ "💇🏻♀️",
+ "💇🏻♂️",
+ "💇🏻",
+ "💇🏼♀️",
+ "💇🏼♂️",
+ "💇🏼",
+ "💇🏽♀️",
+ "💇🏽♂️",
+ "💇🏽",
+ "💇🏾♀️",
+ "💇🏾♂️",
+ "💇🏾",
+ "💇🏿♀️",
+ "💇🏿♂️",
+ "💇🏿",
+ "💇♀️",
+ "💇♂️",
+ "💇",
+ "💈",
+ "💉",
+ "💊",
+ "💋",
+ "💌",
+ "💍",
+ "💎",
+ "💏",
+ "💐",
+ "💑",
+ "💒",
+ "💓",
+ "💔",
+ "💕",
+ "💖",
+ "💗",
+ "💘",
+ "💙",
+ "💚",
+ "💛",
+ "💜",
+ "💝",
+ "💞",
+ "💟",
+ "💠",
+ "💡",
+ "💢",
+ "💣",
+ "💤",
+ "💥",
+ "💦",
+ "💧",
+ "💨",
+ "💩",
+ "💪🏻",
+ "💪🏼",
+ "💪🏽",
+ "💪🏾",
+ "💪🏿",
+ "💪",
+ "💫",
+ "💬",
+ "💭",
+ "💮",
+ "💯",
+ "💰",
+ "💱",
+ "💲",
+ "💳",
+ "💴",
+ "💵",
+ "💶",
+ "💷",
+ "💸",
+ "💹",
+ "💺",
+ "💻",
+ "💼",
+ "💽",
+ "💾",
+ "💿",
+ "📀",
+ "📁",
+ "📂",
+ "📃",
+ "📄",
+ "📅",
+ "📆",
+ "📇",
+ "📈",
+ "📉",
+ "📊",
+ "📋",
+ "📌",
+ "📍",
+ "📎",
+ "📏",
+ "📐",
+ "📑",
+ "📒",
+ "📓",
+ "📔",
+ "📕",
+ "📖",
+ "📗",
+ "📘",
+ "📙",
+ "📚",
+ "📛",
+ "📜",
+ "📝",
+ "📞",
+ "📟",
+ "📠",
+ "📡",
+ "📢",
+ "📣",
+ "📤",
+ "📥",
+ "📦",
+ "📧",
+ "📨",
+ "📩",
+ "📪",
+ "📫",
+ "📬",
+ "📭",
+ "📮",
+ "📯",
+ "📰",
+ "📱",
+ "📲",
+ "📳",
+ "📴",
+ "📵",
+ "📶",
+ "📷",
+ "📸",
+ "📹",
+ "📺",
+ "📻",
+ "📼",
+ "📽",
+ "📿",
+ "🔀",
+ "🔁",
+ "🔂",
+ "🔃",
+ "🔄",
+ "🔅",
+ "🔆",
+ "🔇",
+ "🔈",
+ "🔉",
+ "🔊",
+ "🔋",
+ "🔌",
+ "🔍",
+ "🔎",
+ "🔏",
+ "🔐",
+ "🔑",
+ "🔒",
+ "🔓",
+ "🔔",
+ "🔕",
+ "🔖",
+ "🔗",
+ "🔘",
+ "🔙",
+ "🔚",
+ "🔛",
+ "🔜",
+ "🔝",
+ "🔞",
+ "🔟",
+ "🔠",
+ "🔡",
+ "🔢",
+ "🔣",
+ "🔤",
+ "🔥",
+ "🔦",
+ "🔧",
+ "🔨",
+ "🔩",
+ "🔪",
+ "🔫",
+ "🔬",
+ "🔭",
+ "🔮",
+ "🔯",
+ "🔰",
+ "🔱",
+ "🔲",
+ "🔳",
+ "🔴",
+ "🔵",
+ "🔶",
+ "🔷",
+ "🔸",
+ "🔹",
+ "🔺",
+ "🔻",
+ "🔼",
+ "🔽",
+ "🕉",
+ "🕊",
+ "🕋",
+ "🕌",
+ "🕍",
+ "🕎",
+ "🕐",
+ "🕑",
+ "🕒",
+ "🕓",
+ "🕔",
+ "🕕",
+ "🕖",
+ "🕗",
+ "🕘",
+ "🕙",
+ "🕚",
+ "🕛",
+ "🕜",
+ "🕝",
+ "🕞",
+ "🕟",
+ "🕠",
+ "🕡",
+ "🕢",
+ "🕣",
+ "🕤",
+ "🕥",
+ "🕦",
+ "🕧",
+ "🕯",
+ "🕰",
+ "🕳",
+ "🕴🏻",
+ "🕴🏼",
+ "🕴🏽",
+ "🕴🏾",
+ "🕴🏿",
+ "🕴",
+ "🕵🏻♀️",
+ "🕵🏻♂️",
+ "🕵🏻",
+ "🕵🏼♀️",
+ "🕵🏼♂️",
+ "🕵🏼",
+ "🕵🏽♀️",
+ "🕵🏽♂️",
+ "🕵🏽",
+ "🕵🏾♀️",
+ "🕵🏾♂️",
+ "🕵🏾",
+ "🕵🏿♀️",
+ "🕵🏿♂️",
+ "🕵🏿",
+ "🕵️♀️",
+ "🕵️♂️",
+ "🕵",
+ "🕶",
+ "🕷",
+ "🕸",
+ "🕹",
+ "🕺🏻",
+ "🕺🏼",
+ "🕺🏽",
+ "🕺🏾",
+ "🕺🏿",
+ "🕺",
+ "🖇",
+ "🖊",
+ "🖋",
+ "🖌",
+ "🖍",
+ "🖐🏻",
+ "🖐🏼",
+ "🖐🏽",
+ "🖐🏾",
+ "🖐🏿",
+ "🖐",
+ "🖕🏻",
+ "🖕🏼",
+ "🖕🏽",
+ "🖕🏾",
+ "🖕🏿",
+ "🖕",
+ "🖖🏻",
+ "🖖🏼",
+ "🖖🏽",
+ "🖖🏾",
+ "🖖🏿",
+ "🖖",
+ "🖤",
+ "🖥",
+ "🖨",
+ "🖱",
+ "🖲",
+ "🖼",
+ "🗂",
+ "🗃",
+ "🗄",
+ "🗑",
+ "🗒",
+ "🗓",
+ "🗜",
+ "🗝",
+ "🗞",
+ "🗡",
+ "🗣",
+ "🗨",
+ "🗯",
+ "🗳",
+ "🗺",
+ "🗻",
+ "🗼",
+ "🗽",
+ "🗾",
+ "🗿",
+ "😀",
+ "😁",
+ "😂",
+ "😃",
+ "😄",
+ "😅",
+ "😆",
+ "😇",
+ "😈",
+ "😉",
+ "😊",
+ "😋",
+ "😌",
+ "😍",
+ "😎",
+ "😏",
+ "😐",
+ "😑",
+ "😒",
+ "😓",
+ "😔",
+ "😕",
+ "😖",
+ "😗",
+ "😘",
+ "😙",
+ "😚",
+ "😛",
+ "😜",
+ "😝",
+ "😞",
+ "😟",
+ "😠",
+ "😡",
+ "😢",
+ "😣",
+ "😤",
+ "😥",
+ "😦",
+ "😧",
+ "😨",
+ "😩",
+ "😪",
+ "😫",
+ "😬",
+ "😭",
+ "😮",
+ "😯",
+ "😰",
+ "😱",
+ "😲",
+ "😳",
+ "😴",
+ "😵",
+ "😶",
+ "😷",
+ "😸",
+ "😹",
+ "😺",
+ "😻",
+ "😼",
+ "😽",
+ "😾",
+ "😿",
+ "🙀",
+ "🙁",
+ "🙂",
+ "🙃",
+ "🙄",
+ "🙅🏻♀️",
+ "🙅🏻♂️",
+ "🙅🏻",
+ "🙅🏼♀️",
+ "🙅🏼♂️",
+ "🙅🏼",
+ "🙅🏽♀️",
+ "🙅🏽♂️",
+ "🙅🏽",
+ "🙅🏾♀️",
+ "🙅🏾♂️",
+ "🙅🏾",
+ "🙅🏿♀️",
+ "🙅🏿♂️",
+ "🙅🏿",
+ "🙅♀️",
+ "🙅♂️",
+ "🙅",
+ "🙆🏻♀️",
+ "🙆🏻♂️",
+ "🙆🏻",
+ "🙆🏼♀️",
+ "🙆🏼♂️",
+ "🙆🏼",
+ "🙆🏽♀️",
+ "🙆🏽♂️",
+ "🙆🏽",
+ "🙆🏾♀️",
+ "🙆🏾♂️",
+ "🙆🏾",
+ "🙆🏿♀️",
+ "🙆🏿♂️",
+ "🙆🏿",
+ "🙆♀️",
+ "🙆♂️",
+ "🙆",
+ "🙇🏻♀️",
+ "🙇🏻♂️",
+ "🙇🏻",
+ "🙇🏼♀️",
+ "🙇🏼♂️",
+ "🙇🏼",
+ "🙇🏽♀️",
+ "🙇🏽♂️",
+ "🙇🏽",
+ "🙇🏾♀️",
+ "🙇🏾♂️",
+ "🙇🏾",
+ "🙇🏿♀️",
+ "🙇🏿♂️",
+ "🙇🏿",
+ "🙇♀️",
+ "🙇♂️",
+ "🙇",
+ "🙈",
+ "🙉",
+ "🙊",
+ "🙋🏻♀️",
+ "🙋🏻♂️",
+ "🙋🏻",
+ "🙋🏼♀️",
+ "🙋🏼♂️",
+ "🙋🏼",
+ "🙋🏽♀️",
+ "🙋🏽♂️",
+ "🙋🏽",
+ "🙋🏾♀️",
+ "🙋🏾♂️",
+ "🙋🏾",
+ "🙋🏿♀️",
+ "🙋🏿♂️",
+ "🙋🏿",
+ "🙋♀️",
+ "🙋♂️",
+ "🙋",
+ "🙌🏻",
+ "🙌🏼",
+ "🙌🏽",
+ "🙌🏾",
+ "🙌🏿",
+ "🙌",
+ "🙍🏻♀️",
+ "🙍🏻♂️",
+ "🙍🏻",
+ "🙍🏼♀️",
+ "🙍🏼♂️",
+ "🙍🏼",
+ "🙍🏽♀️",
+ "🙍🏽♂️",
+ "🙍🏽",
+ "🙍🏾♀️",
+ "🙍🏾♂️",
+ "🙍🏾",
+ "🙍🏿♀️",
+ "🙍🏿♂️",
+ "🙍🏿",
+ "🙍♀️",
+ "🙍♂️",
+ "🙍",
+ "🙎🏻♀️",
+ "🙎🏻♂️",
+ "🙎🏻",
+ "🙎🏼♀️",
+ "🙎🏼♂️",
+ "🙎🏼",
+ "🙎🏽♀️",
+ "🙎🏽♂️",
+ "🙎🏽",
+ "🙎🏾♀️",
+ "🙎🏾♂️",
+ "🙎🏾",
+ "🙎🏿♀️",
+ "🙎🏿♂️",
+ "🙎🏿",
+ "🙎♀️",
+ "🙎♂️",
+ "🙎",
+ "🙏🏻",
+ "🙏🏼",
+ "🙏🏽",
+ "🙏🏾",
+ "🙏🏿",
+ "🙏",
+ "🚀",
+ "🚁",
+ "🚂",
+ "🚃",
+ "🚄",
+ "🚅",
+ "🚆",
+ "🚇",
+ "🚈",
+ "🚉",
+ "🚊",
+ "🚋",
+ "🚌",
+ "🚍",
+ "🚎",
+ "🚏",
+ "🚐",
+ "🚑",
+ "🚒",
+ "🚓",
+ "🚔",
+ "🚕",
+ "🚖",
+ "🚗",
+ "🚘",
+ "🚙",
+ "🚚",
+ "🚛",
+ "🚜",
+ "🚝",
+ "🚞",
+ "🚟",
+ "🚠",
+ "🚡",
+ "🚢",
+ "🚣🏻♀️",
+ "🚣🏻♂️",
+ "🚣🏻",
+ "🚣🏼♀️",
+ "🚣🏼♂️",
+ "🚣🏼",
+ "🚣🏽♀️",
+ "🚣🏽♂️",
+ "🚣🏽",
+ "🚣🏾♀️",
+ "🚣🏾♂️",
+ "🚣🏾",
+ "🚣🏿♀️",
+ "🚣🏿♂️",
+ "🚣🏿",
+ "🚣♀️",
+ "🚣♂️",
+ "🚣",
+ "🚤",
+ "🚥",
+ "🚦",
+ "🚧",
+ "🚨",
+ "🚩",
+ "🚪",
+ "🚫",
+ "🚬",
+ "🚭",
+ "🚮",
+ "🚯",
+ "🚰",
+ "🚱",
+ "🚲",
+ "🚳",
+ "🚴🏻♀️",
+ "🚴🏻♂️",
+ "🚴🏻",
+ "🚴🏼♀️",
+ "🚴🏼♂️",
+ "🚴🏼",
+ "🚴🏽♀️",
+ "🚴🏽♂️",
+ "🚴🏽",
+ "🚴🏾♀️",
+ "🚴🏾♂️",
+ "🚴🏾",
+ "🚴🏿♀️",
+ "🚴🏿♂️",
+ "🚴🏿",
+ "🚴♀️",
+ "🚴♂️",
+ "🚴",
+ "🚵🏻♀️",
+ "🚵🏻♂️",
+ "🚵🏻",
+ "🚵🏼♀️",
+ "🚵🏼♂️",
+ "🚵🏼",
+ "🚵🏽♀️",
+ "🚵🏽♂️",
+ "🚵🏽",
+ "🚵🏾♀️",
+ "🚵🏾♂️",
+ "🚵🏾",
+ "🚵🏿♀️",
+ "🚵🏿♂️",
+ "🚵🏿",
+ "🚵♀️",
+ "🚵♂️",
+ "🚵",
+ "🚶🏻♀️",
+ "🚶🏻♂️",
+ "🚶🏻",
+ "🚶🏼♀️",
+ "🚶🏼♂️",
+ "🚶🏼",
+ "🚶🏽♀️",
+ "🚶🏽♂️",
+ "🚶🏽",
+ "🚶🏾♀️",
+ "🚶🏾♂️",
+ "🚶🏾",
+ "🚶🏿♀️",
+ "🚶🏿♂️",
+ "🚶🏿",
+ "🚶♀️",
+ "🚶♂️",
+ "🚶",
+ "🚷",
+ "🚸",
+ "🚹",
+ "🚺",
+ "🚻",
+ "🚼",
+ "🚽",
+ "🚾",
+ "🚿",
+ "🛀🏻",
+ "🛀🏼",
+ "🛀🏽",
+ "🛀🏾",
+ "🛀🏿",
+ "🛀",
+ "🛁",
+ "🛂",
+ "🛃",
+ "🛄",
+ "🛅",
+ "🛋",
+ "🛌🏻",
+ "🛌🏼",
+ "🛌🏽",
+ "🛌🏾",
+ "🛌🏿",
+ "🛌",
+ "🛍",
+ "🛎",
+ "🛏",
+ "🛐",
+ "🛑",
+ "🛒",
+ "🛠",
+ "🛡",
+ "🛢",
+ "🛣",
+ "🛤",
+ "🛥",
+ "🛩",
+ "🛫",
+ "🛬",
+ "🛰",
+ "🛳",
+ "🛴",
+ "🛵",
+ "🛶",
+ "🤐",
+ "🤑",
+ "🤒",
+ "🤓",
+ "🤔",
+ "🤕",
+ "🤖",
+ "🤗",
+ "🤘🏻",
+ "🤘🏼",
+ "🤘🏽",
+ "🤘🏾",
+ "🤘🏿",
+ "🤘",
+ "🤙🏻",
+ "🤙🏼",
+ "🤙🏽",
+ "🤙🏾",
+ "🤙🏿",
+ "🤙",
+ "🤚🏻",
+ "🤚🏼",
+ "🤚🏽",
+ "🤚🏾",
+ "🤚🏿",
+ "🤚",
+ "🤛🏻",
+ "🤛🏼",
+ "🤛🏽",
+ "🤛🏾",
+ "🤛🏿",
+ "🤛",
+ "🤜🏻",
+ "🤜🏼",
+ "🤜🏽",
+ "🤜🏾",
+ "🤜🏿",
+ "🤜",
+ "🤝🏻",
+ "🤝🏼",
+ "🤝🏽",
+ "🤝🏾",
+ "🤝🏿",
+ "🤝",
+ "🤞🏻",
+ "🤞🏼",
+ "🤞🏽",
+ "🤞🏾",
+ "🤞🏿",
+ "🤞",
+ "🤠",
+ "🤡",
+ "🤢",
+ "🤣",
+ "🤤",
+ "🤥",
+ "🤦🏻♀️",
+ "🤦🏻♂️",
+ "🤦🏻",
+ "🤦🏼♀️",
+ "🤦🏼♂️",
+ "🤦🏼",
+ "🤦🏽♀️",
+ "🤦🏽♂️",
+ "🤦🏽",
+ "🤦🏾♀️",
+ "🤦🏾♂️",
+ "🤦🏾",
+ "🤦🏿♀️",
+ "🤦🏿♂️",
+ "🤦🏿",
+ "🤦♀️",
+ "🤦♂️",
+ "🤦",
+ "🤧",
+ "🤰🏻",
+ "🤰🏼",
+ "🤰🏽",
+ "🤰🏾",
+ "🤰🏿",
+ "🤰",
+ "🤳🏻",
+ "🤳🏼",
+ "🤳🏽",
+ "🤳🏾",
+ "🤳🏿",
+ "🤳",
+ "🤴🏻",
+ "🤴🏼",
+ "🤴🏽",
+ "🤴🏾",
+ "🤴🏿",
+ "🤴",
+ "🤵🏻",
+ "🤵🏼",
+ "🤵🏽",
+ "🤵🏾",
+ "🤵🏿",
+ "🤵",
+ "🤶🏻",
+ "🤶🏼",
+ "🤶🏽",
+ "🤶🏾",
+ "🤶🏿",
+ "🤶",
+ "🤷🏻♀️",
+ "🤷🏻♂️",
+ "🤷🏻",
+ "🤷🏼♀️",
+ "🤷🏼♂️",
+ "🤷🏼",
+ "🤷🏽♀️",
+ "🤷🏽♂️",
+ "🤷🏽",
+ "🤷🏾♀️",
+ "🤷🏾♂️",
+ "🤷🏾",
+ "🤷🏿♀️",
+ "🤷🏿♂️",
+ "🤷🏿",
+ "🤷♀️",
+ "🤷♂️",
+ "🤷",
+ "🤸🏻♀️",
+ "🤸🏻♂️",
+ "🤸🏻",
+ "🤸🏼♀️",
+ "🤸🏼♂️",
+ "🤸🏼",
+ "🤸🏽♀️",
+ "🤸🏽♂️",
+ "🤸🏽",
+ "🤸🏾♀️",
+ "🤸🏾♂️",
+ "🤸🏾",
+ "🤸🏿♀️",
+ "🤸🏿♂️",
+ "🤸🏿",
+ "🤸♀️",
+ "🤸♂️",
+ "🤸",
+ "🤹🏻♀️",
+ "🤹🏻♂️",
+ "🤹🏻",
+ "🤹🏼♀️",
+ "🤹🏼♂️",
+ "🤹🏼",
+ "🤹🏽♀️",
+ "🤹🏽♂️",
+ "🤹🏽",
+ "🤹🏾♀️",
+ "🤹🏾♂️",
+ "🤹🏾",
+ "🤹🏿♀️",
+ "🤹🏿♂️",
+ "🤹🏿",
+ "🤹♀️",
+ "🤹♂️",
+ "🤹",
+ "🤺",
+ "🤼🏻♀️",
+ "🤼🏻♂️",
+ "🤼🏻",
+ "🤼🏼♀️",
+ "🤼🏼♂️",
+ "🤼🏼",
+ "🤼🏽♀️",
+ "🤼🏽♂️",
+ "🤼🏽",
+ "🤼🏾♀️",
+ "🤼🏾♂️",
+ "🤼🏾",
+ "🤼🏿♀️",
+ "🤼🏿♂️",
+ "🤼🏿",
+ "🤼♀️",
+ "🤼♂️",
+ "🤼",
+ "🤽🏻♀️",
+ "🤽🏻♂️",
+ "🤽🏻",
+ "🤽🏼♀️",
+ "🤽🏼♂️",
+ "🤽🏼",
+ "🤽🏽♀️",
+ "🤽🏽♂️",
+ "🤽🏽",
+ "🤽🏾♀️",
+ "🤽🏾♂️",
+ "🤽🏾",
+ "🤽🏿♀️",
+ "🤽🏿♂️",
+ "🤽🏿",
+ "🤽♀️",
+ "🤽♂️",
+ "🤽",
+ "🤾🏻♀️",
+ "🤾🏻♂️",
+ "🤾🏻",
+ "🤾🏼♀️",
+ "🤾🏼♂️",
+ "🤾🏼",
+ "🤾🏽♀️",
+ "🤾🏽♂️",
+ "🤾🏽",
+ "🤾🏾♀️",
+ "🤾🏾♂️",
+ "🤾🏾",
+ "🤾🏿♀️",
+ "🤾🏿♂️",
+ "🤾🏿",
+ "🤾♀️",
+ "🤾♂️",
+ "🤾",
+ "🥀",
+ "🥁",
+ "🥂",
+ "🥃",
+ "🥄",
+ "🥅",
+ "🥇",
+ "🥈",
+ "🥉",
+ "🥊",
+ "🥋",
+ "🥐",
+ "🥑",
+ "🥒",
+ "🥓",
+ "🥔",
+ "🥕",
+ "🥖",
+ "🥗",
+ "🥘",
+ "🥙",
+ "🥚",
+ "🥛",
+ "🥜",
+ "🥝",
+ "🥞",
+ "🦀",
+ "🦁",
+ "🦂",
+ "🦃",
+ "🦄",
+ "🦅",
+ "🦆",
+ "🦇",
+ "🦈",
+ "🦉",
+ "🦊",
+ "🦋",
+ "🦌",
+ "🦍",
+ "🦎",
+ "🦏",
+ "🦐",
+ "🦑",
+ "🧀",
+ "‼",
+ "⁉",
+ "™",
+ "ℹ",
+ "↔",
+ "↕",
+ "↖",
+ "↗",
+ "↘",
+ "↙",
+ "↩",
+ "↪",
+ "#⃣",
+ "⌚",
+ "⌛",
+ "⌨",
+ "⏏",
+ "⏩",
+ "⏪",
+ "⏫",
+ "⏬",
+ "⏭",
+ "⏮",
+ "⏯",
+ "⏰",
+ "⏱",
+ "⏲",
+ "⏳",
+ "⏸",
+ "⏹",
+ "⏺",
+ "Ⓜ",
+ "▪",
+ "▫",
+ "▶",
+ "◀",
+ "◻",
+ "◼",
+ "◽",
+ "◾",
+ "☀",
+ "☁",
+ "☂",
+ "☃",
+ "☄",
+ "☎",
+ "☑",
+ "☔",
+ "☕",
+ "☘",
+ "☝🏻",
+ "☝🏼",
+ "☝🏽",
+ "☝🏾",
+ "☝🏿",
+ "☝",
+ "☠",
+ "☢",
+ "☣",
+ "☦",
+ "☪",
+ "☮",
+ "☯",
+ "☸",
+ "☹",
+ "☺",
+ "♀",
+ "♂",
+ "♈",
+ "♉",
+ "♊",
+ "♋",
+ "♌",
+ "♍",
+ "♎",
+ "♏",
+ "♐",
+ "♑",
+ "♒",
+ "♓",
+ "♠",
+ "♣",
+ "♥",
+ "♦",
+ "♨",
+ "♻",
+ "♿",
+ "⚒",
+ "⚓",
+ "⚔",
+ "⚕",
+ "⚖",
+ "⚗",
+ "⚙",
+ "⚛",
+ "⚜",
+ "⚠",
+ "⚡",
+ "⚪",
+ "⚫",
+ "⚰",
+ "⚱",
+ "⚽",
+ "⚾",
+ "⛄",
+ "⛅",
+ "⛈",
+ "⛎",
+ "⛏",
+ "⛑",
+ "⛓",
+ "⛔",
+ "⛩",
+ "⛪",
+ "⛰",
+ "⛱",
+ "⛲",
+ "⛳",
+ "⛴",
+ "⛵",
+ "⛷🏻",
+ "⛷🏼",
+ "⛷🏽",
+ "⛷🏾",
+ "⛷🏿",
+ "⛷",
+ "⛸",
+ "⛹🏻♀️",
+ "⛹🏻♂️",
+ "⛹🏻",
+ "⛹🏼♀️",
+ "⛹🏼♂️",
+ "⛹🏼",
+ "⛹🏽♀️",
+ "⛹🏽♂️",
+ "⛹🏽",
+ "⛹🏾♀️",
+ "⛹🏾♂️",
+ "⛹🏾",
+ "⛹🏿♀️",
+ "⛹🏿♂️",
+ "⛹🏿",
+ "⛹️♀️",
+ "⛹️♂️",
+ "⛹",
+ "⛺",
+ "⛽",
+ "✂",
+ "✅",
+ "✈",
+ "✉",
+ "✊🏻",
+ "✊🏼",
+ "✊🏽",
+ "✊🏾",
+ "✊🏿",
+ "✊",
+ "✋🏻",
+ "✋🏼",
+ "✋🏽",
+ "✋🏾",
+ "✋🏿",
+ "✋",
+ "✌🏻",
+ "✌🏼",
+ "✌🏽",
+ "✌🏾",
+ "✌🏿",
+ "✌",
+ "✍🏻",
+ "✍🏼",
+ "✍🏽",
+ "✍🏾",
+ "✍🏿",
+ "✍",
+ "✏",
+ "✒",
+ "✔",
+ "✖",
+ "✝",
+ "✡",
+ "✨",
+ "✳",
+ "✴",
+ "❄",
+ "❇",
+ "❌",
+ "❎",
+ "❓",
+ "❔",
+ "❕",
+ "❗",
+ "❣",
+ "❤",
+ "➕",
+ "➖",
+ "➗",
+ "➡",
+ "➰",
+ "➿",
+ "⤴",
+ "⤵",
+ "*⃣",
+ "⬅",
+ "⬆",
+ "⬇",
+ "⬛",
+ "⬜",
+ "⭐",
+ "⭕",
+ "0⃣",
+ "〰",
+ "〽",
+ "1⃣",
+ "2⃣",
+ "㊗",
+ "㊙",
+ "3⃣",
+ "4⃣",
+ "5⃣",
+ "6⃣",
+ "7⃣",
+ "8⃣",
+ "9⃣",
+ "©",
+ "®",
+ ""
+]
\ No newline at end of file
diff --git a/node_modules/emojis-list/package.json b/node_modules/emojis-list/package.json
new file mode 100644
index 00000000..d40b5cfc
--- /dev/null
+++ b/node_modules/emojis-list/package.json
@@ -0,0 +1,112 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "emojis-list@^2.0.0",
+ "scope": null,
+ "escapedName": "emojis-list",
+ "name": "emojis-list",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/loader-utils"
+ ]
+ ],
+ "_from": "emojis-list@>=2.0.0 <3.0.0",
+ "_id": "emojis-list@2.1.0",
+ "_inCache": true,
+ "_location": "/emojis-list",
+ "_nodeVersion": "6.7.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/emojis-list-2.1.0.tgz_1475503274409_0.1915575808379799"
+ },
+ "_npmUser": {
+ "name": "kikobeats",
+ "email": "josefrancisco.verdu@gmail.com"
+ },
+ "_npmVersion": "3.10.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "emojis-list@^2.0.0",
+ "scope": null,
+ "escapedName": "emojis-list",
+ "name": "emojis-list",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/loader-utils"
+ ],
+ "_resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-2.1.0.tgz",
+ "_shasum": "4daa4d9db00f9819880c79fa457ae5b09a1fd389",
+ "_shrinkwrap": null,
+ "_spec": "emojis-list@^2.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/loader-utils",
+ "author": {
+ "name": "Kiko Beats",
+ "email": "josefrancisco.verdu@gmail.com",
+ "url": "https://github.com/Kikobeats"
+ },
+ "bugs": {
+ "url": "https://github.com/Kikobeats/emojis-list/issues"
+ },
+ "dependencies": {},
+ "description": "Complete list of standard emojis.",
+ "devDependencies": {
+ "acho": "latest",
+ "browserify": "latest",
+ "cheerio": "latest",
+ "got": ">=5 <6",
+ "gulp": "latest",
+ "gulp-header": "latest",
+ "gulp-uglify": "latest",
+ "gulp-util": "latest",
+ "standard": "latest",
+ "vinyl-buffer": "latest",
+ "vinyl-source-stream": "latest"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "4daa4d9db00f9819880c79fa457ae5b09a1fd389",
+ "tarball": "https://registry.npmjs.org/emojis-list/-/emojis-list-2.1.0.tgz"
+ },
+ "engines": {
+ "node": ">= 0.10"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "be6942ce8973057a6ac3aab5b84a9a9585e89417",
+ "homepage": "https://github.com/Kikobeats/emojis-list",
+ "keywords": [
+ "archive",
+ "complete",
+ "emoji",
+ "list",
+ "standard"
+ ],
+ "license": "MIT",
+ "main": "./index.js",
+ "maintainers": [
+ {
+ "name": "kikobeats",
+ "email": "josefrancisco.verdu@gmail.com"
+ }
+ ],
+ "name": "emojis-list",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/kikobeats/emojis-list.git"
+ },
+ "scripts": {
+ "pretest": "standard update.js",
+ "test": "echo 'YOLO'",
+ "update": "node update"
+ },
+ "version": "2.1.0"
+}
diff --git a/node_modules/encodeurl/HISTORY.md b/node_modules/encodeurl/HISTORY.md
new file mode 100644
index 00000000..06d34a5a
--- /dev/null
+++ b/node_modules/encodeurl/HISTORY.md
@@ -0,0 +1,9 @@
+1.0.1 / 2016-06-09
+==================
+
+ * Fix encoding unpaired surrogates at start/end of string
+
+1.0.0 / 2016-06-08
+==================
+
+ * Initial release
diff --git a/node_modules/encodeurl/LICENSE b/node_modules/encodeurl/LICENSE
new file mode 100644
index 00000000..8812229b
--- /dev/null
+++ b/node_modules/encodeurl/LICENSE
@@ -0,0 +1,22 @@
+(The MIT License)
+
+Copyright (c) 2016 Douglas Christopher Wilson
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/encodeurl/README.md b/node_modules/encodeurl/README.md
new file mode 100644
index 00000000..b086133c
--- /dev/null
+++ b/node_modules/encodeurl/README.md
@@ -0,0 +1,124 @@
+# encodeurl
+
+[![NPM Version][npm-image]][npm-url]
+[![NPM Downloads][downloads-image]][downloads-url]
+[![Node.js Version][node-version-image]][node-version-url]
+[![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
+
+Encode a URL to a percent-encoded form, excluding already-encoded sequences
+
+## Installation
+
+```sh
+$ npm install encodeurl
+```
+
+## API
+
+```js
+var encodeUrl = require('encodeurl')
+```
+
+### encodeUrl(url)
+
+Encode a URL to a percent-encoded form, excluding already-encoded sequences.
+
+This function will take an already-encoded URL and encode all the non-URL
+code points (as UTF-8 byte sequences). This function will not encode the
+"%" character unless it is not part of a valid sequence (`%20` will be
+left as-is, but `%foo` will be encoded as `%25foo`).
+
+This encode is meant to be "safe" and does not throw errors. It will try as
+hard as it can to properly encode the given URL, including replacing any raw,
+unpaired surrogate pairs with the Unicode replacement character prior to
+encoding.
+
+This function is _similar_ to the intrinsic function `encodeURI`, except it
+will not encode the `%` character if that is part of a valid sequence, will
+not encode `[` and `]` (for IPv6 hostnames) and will replace raw, unpaired
+surrogate pairs with the Unicode replacement character (instead of throwing).
+
+## Examples
+
+### Encode a URL containing user-controled data
+
+```js
+var encodeUrl = require('encodeurl')
+var escapeHtml = require('escape-html')
+
+http.createServer(function onRequest (req, res) {
+ // get encoded form of inbound url
+ var url = encodeUrl(req.url)
+
+ // create html message
+ var body = 'Location ' + escapeHtml(url) + ' not found
'
+
+ // send a 404
+ res.statusCode = 404
+ res.setHeader('Content-Type', 'text/html; charset=UTF-8')
+ res.setHeader('Content-Length', String(Buffer.byteLength(body, 'utf-8')))
+ res.end(body, 'utf-8')
+})
+```
+
+### Encode a URL for use in a header field
+
+```js
+var encodeUrl = require('encodeurl')
+var escapeHtml = require('escape-html')
+var url = require('url')
+
+http.createServer(function onRequest (req, res) {
+ // parse inbound url
+ var href = url.parse(req)
+
+ // set new host for redirect
+ href.host = 'localhost'
+ href.protocol = 'https:'
+ href.slashes = true
+
+ // create location header
+ var location = encodeUrl(url.format(href))
+
+ // create html message
+ var body = 'Redirecting to new site: ' + escapeHtml(location) + '
'
+
+ // send a 301
+ res.statusCode = 301
+ res.setHeader('Content-Type', 'text/html; charset=UTF-8')
+ res.setHeader('Content-Length', String(Buffer.byteLength(body, 'utf-8')))
+ res.setHeader('Location', location)
+ res.end(body, 'utf-8')
+})
+```
+
+## Testing
+
+```sh
+$ npm test
+$ npm run lint
+```
+
+## References
+
+- [RFC 3986: Uniform Resource Identifier (URI): Generic Syntax][rfc-3986]
+- [WHATWG URL Living Standard][whatwg-url]
+
+[rfc-3986]: https://tools.ietf.org/html/rfc3986
+[whatwg-url]: https://url.spec.whatwg.org/
+
+## License
+
+[MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/encodeurl.svg
+[npm-url]: https://npmjs.org/package/encodeurl
+[node-version-image]: https://img.shields.io/node/v/encodeurl.svg
+[node-version-url]: https://nodejs.org/en/download
+[travis-image]: https://img.shields.io/travis/pillarjs/encodeurl.svg
+[travis-url]: https://travis-ci.org/pillarjs/encodeurl
+[coveralls-image]: https://img.shields.io/coveralls/pillarjs/encodeurl.svg
+[coveralls-url]: https://coveralls.io/r/pillarjs/encodeurl?branch=master
+[downloads-image]: https://img.shields.io/npm/dm/encodeurl.svg
+[downloads-url]: https://npmjs.org/package/encodeurl
diff --git a/node_modules/encodeurl/index.js b/node_modules/encodeurl/index.js
new file mode 100644
index 00000000..ae77cc94
--- /dev/null
+++ b/node_modules/encodeurl/index.js
@@ -0,0 +1,60 @@
+/*!
+ * encodeurl
+ * Copyright(c) 2016 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict'
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = encodeUrl
+
+/**
+ * RegExp to match non-URL code points, *after* encoding (i.e. not including "%")
+ * and including invalid escape sequences.
+ * @private
+ */
+
+var ENCODE_CHARS_REGEXP = /(?:[^\x21\x25\x26-\x3B\x3D\x3F-\x5B\x5D\x5F\x61-\x7A\x7E]|%(?:[^0-9A-Fa-f]|[0-9A-Fa-f][^0-9A-Fa-f]))+/g
+
+/**
+ * RegExp to match unmatched surrogate pair.
+ * @private
+ */
+
+var UNMATCHED_SURROGATE_PAIR_REGEXP = /(^|[^\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF]([^\uDC00-\uDFFF]|$)/g
+
+/**
+ * String to replace unmatched surrogate pair with.
+ * @private
+ */
+
+var UNMATCHED_SURROGATE_PAIR_REPLACE = '$1\uFFFD$2'
+
+/**
+ * Encode a URL to a percent-encoded form, excluding already-encoded sequences.
+ *
+ * This function will take an already-encoded URL and encode all the non-URL
+ * code points. This function will not encode the "%" character unless it is
+ * not part of a valid sequence (`%20` will be left as-is, but `%foo` will
+ * be encoded as `%25foo`).
+ *
+ * This encode is meant to be "safe" and does not throw errors. It will try as
+ * hard as it can to properly encode the given URL, including replacing any raw,
+ * unpaired surrogate pairs with the Unicode replacement character prior to
+ * encoding.
+ *
+ * @param {string} url
+ * @return {string}
+ * @public
+ */
+
+function encodeUrl (url) {
+ return String(url)
+ .replace(UNMATCHED_SURROGATE_PAIR_REGEXP, UNMATCHED_SURROGATE_PAIR_REPLACE)
+ .replace(ENCODE_CHARS_REGEXP, encodeURI)
+}
diff --git a/node_modules/encodeurl/package.json b/node_modules/encodeurl/package.json
new file mode 100644
index 00000000..50c40f05
--- /dev/null
+++ b/node_modules/encodeurl/package.json
@@ -0,0 +1,111 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "encodeurl@~1.0.1",
+ "scope": null,
+ "escapedName": "encodeurl",
+ "name": "encodeurl",
+ "rawSpec": "~1.0.1",
+ "spec": ">=1.0.1 <1.1.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express"
+ ]
+ ],
+ "_from": "encodeurl@>=1.0.1 <1.1.0",
+ "_id": "encodeurl@1.0.1",
+ "_inCache": true,
+ "_location": "/encodeurl",
+ "_nodeVersion": "4.4.3",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/encodeurl-1.0.1.tgz_1465519736251_0.09314409433864057"
+ },
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "2.15.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "encodeurl@~1.0.1",
+ "scope": null,
+ "escapedName": "encodeurl",
+ "name": "encodeurl",
+ "rawSpec": "~1.0.1",
+ "spec": ">=1.0.1 <1.1.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/express",
+ "/send",
+ "/serve-static"
+ ],
+ "_resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.1.tgz",
+ "_shasum": "79e3d58655346909fe6f0f45a5de68103b294d20",
+ "_shrinkwrap": null,
+ "_spec": "encodeurl@~1.0.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express",
+ "bugs": {
+ "url": "https://github.com/pillarjs/encodeurl/issues"
+ },
+ "contributors": [
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "Encode a URL to a percent-encoded form, excluding already-encoded sequences",
+ "devDependencies": {
+ "eslint": "2.11.1",
+ "eslint-config-standard": "5.3.1",
+ "eslint-plugin-promise": "1.3.2",
+ "eslint-plugin-standard": "1.3.2",
+ "istanbul": "0.4.3",
+ "mocha": "2.5.3"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "79e3d58655346909fe6f0f45a5de68103b294d20",
+ "tarball": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.1.tgz"
+ },
+ "engines": {
+ "node": ">= 0.8"
+ },
+ "files": [
+ "LICENSE",
+ "HISTORY.md",
+ "README.md",
+ "index.js"
+ ],
+ "gitHead": "39ed0c235fed4cea7d012038fd6bb0480561d226",
+ "homepage": "https://github.com/pillarjs/encodeurl#readme",
+ "keywords": [
+ "encode",
+ "encodeurl",
+ "url"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "encodeurl",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/pillarjs/encodeurl.git"
+ },
+ "scripts": {
+ "lint": "eslint **/*.js",
+ "test": "mocha --reporter spec --bail --check-leaks test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
+ },
+ "version": "1.0.1"
+}
diff --git a/node_modules/end-of-stream/.npmignore b/node_modules/end-of-stream/.npmignore
new file mode 100644
index 00000000..3c3629e6
--- /dev/null
+++ b/node_modules/end-of-stream/.npmignore
@@ -0,0 +1 @@
+node_modules
diff --git a/node_modules/end-of-stream/README.md b/node_modules/end-of-stream/README.md
new file mode 100644
index 00000000..df800c1e
--- /dev/null
+++ b/node_modules/end-of-stream/README.md
@@ -0,0 +1,47 @@
+# end-of-stream
+
+A node module that calls a callback when a readable/writable/duplex stream has completed or failed.
+
+ npm install end-of-stream
+
+## Usage
+
+Simply pass a stream and a callback to the `eos`.
+Both legacy streams and streams2 are supported.
+
+``` js
+var eos = require('end-of-stream');
+
+eos(readableStream, function(err) {
+ if (err) return console.log('stream had an error or closed early');
+ console.log('stream has ended');
+});
+
+eos(writableStream, function(err) {
+ if (err) return console.log('stream had an error or closed early');
+ console.log('stream has finished');
+});
+
+eos(duplexStream, function(err) {
+ if (err) return console.log('stream had an error or closed early');
+ console.log('stream has ended and finished');
+});
+
+eos(duplexStream, {readable:false}, function(err) {
+ if (err) return console.log('stream had an error or closed early');
+ console.log('stream has ended but might still be writable');
+});
+
+eos(duplexStream, {writable:false}, function(err) {
+ if (err) return console.log('stream had an error or closed early');
+ console.log('stream has ended but might still be readable');
+});
+
+eos(readableStream, {error:false}, function(err) {
+ // do not treat emit('error', err) as a end-of-stream
+});
+```
+
+## License
+
+MIT
\ No newline at end of file
diff --git a/node_modules/end-of-stream/index.js b/node_modules/end-of-stream/index.js
new file mode 100644
index 00000000..9f61ed5a
--- /dev/null
+++ b/node_modules/end-of-stream/index.js
@@ -0,0 +1,72 @@
+var once = require('once');
+
+var noop = function() {};
+
+var isRequest = function(stream) {
+ return stream.setHeader && typeof stream.abort === 'function';
+};
+
+var eos = function(stream, opts, callback) {
+ if (typeof opts === 'function') return eos(stream, null, opts);
+ if (!opts) opts = {};
+
+ callback = once(callback || noop);
+
+ var ws = stream._writableState;
+ var rs = stream._readableState;
+ var readable = opts.readable || (opts.readable !== false && stream.readable);
+ var writable = opts.writable || (opts.writable !== false && stream.writable);
+
+ var onlegacyfinish = function() {
+ if (!stream.writable) onfinish();
+ };
+
+ var onfinish = function() {
+ writable = false;
+ if (!readable) callback();
+ };
+
+ var onend = function() {
+ readable = false;
+ if (!writable) callback();
+ };
+
+ var onclose = function() {
+ if (readable && !(rs && rs.ended)) return callback(new Error('premature close'));
+ if (writable && !(ws && ws.ended)) return callback(new Error('premature close'));
+ };
+
+ var onrequest = function() {
+ stream.req.on('finish', onfinish);
+ };
+
+ if (isRequest(stream)) {
+ stream.on('complete', onfinish);
+ stream.on('abort', onclose);
+ if (stream.req) onrequest();
+ else stream.on('request', onrequest);
+ } else if (writable && !ws) { // legacy streams
+ stream.on('end', onlegacyfinish);
+ stream.on('close', onlegacyfinish);
+ }
+
+ stream.on('end', onend);
+ stream.on('finish', onfinish);
+ if (opts.error !== false) stream.on('error', callback);
+ stream.on('close', onclose);
+
+ return function() {
+ stream.removeListener('complete', onfinish);
+ stream.removeListener('abort', onclose);
+ stream.removeListener('request', onrequest);
+ if (stream.req) stream.req.removeListener('finish', onfinish);
+ stream.removeListener('end', onlegacyfinish);
+ stream.removeListener('close', onlegacyfinish);
+ stream.removeListener('finish', onfinish);
+ stream.removeListener('end', onend);
+ stream.removeListener('error', callback);
+ stream.removeListener('close', onclose);
+ };
+};
+
+module.exports = eos;
\ No newline at end of file
diff --git a/node_modules/end-of-stream/package.json b/node_modules/end-of-stream/package.json
new file mode 100644
index 00000000..e31b03a4
--- /dev/null
+++ b/node_modules/end-of-stream/package.json
@@ -0,0 +1,89 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "end-of-stream@1.0.0",
+ "scope": null,
+ "escapedName": "end-of-stream",
+ "name": "end-of-stream",
+ "rawSpec": "1.0.0",
+ "spec": "1.0.0",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/duplexify"
+ ]
+ ],
+ "_from": "end-of-stream@1.0.0",
+ "_id": "end-of-stream@1.0.0",
+ "_inCache": true,
+ "_location": "/end-of-stream",
+ "_npmUser": {
+ "name": "mafintosh",
+ "email": "mathiasbuus@gmail.com"
+ },
+ "_npmVersion": "1.4.9",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "end-of-stream@1.0.0",
+ "scope": null,
+ "escapedName": "end-of-stream",
+ "name": "end-of-stream",
+ "rawSpec": "1.0.0",
+ "spec": "1.0.0",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/duplexify"
+ ],
+ "_resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.0.0.tgz",
+ "_shasum": "d4596e702734a93e40e9af864319eabd99ff2f0e",
+ "_shrinkwrap": null,
+ "_spec": "end-of-stream@1.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/duplexify",
+ "author": {
+ "name": "Mathias Buus",
+ "email": "mathiasbuus@gmail.com"
+ },
+ "bugs": {
+ "url": "https://github.com/mafintosh/end-of-stream/issues"
+ },
+ "dependencies": {
+ "once": "~1.3.0"
+ },
+ "description": "Call a callback when a readable/writable/duplex stream has completed or failed.",
+ "devDependencies": {},
+ "directories": {},
+ "dist": {
+ "shasum": "d4596e702734a93e40e9af864319eabd99ff2f0e",
+ "tarball": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.0.0.tgz"
+ },
+ "homepage": "https://github.com/mafintosh/end-of-stream",
+ "keywords": [
+ "stream",
+ "streams",
+ "callback",
+ "finish",
+ "close",
+ "end",
+ "wait"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "mafintosh",
+ "email": "mathiasbuus@gmail.com"
+ }
+ ],
+ "name": "end-of-stream",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/mafintosh/end-of-stream.git"
+ },
+ "scripts": {
+ "test": "node test.js"
+ },
+ "version": "1.0.0"
+}
diff --git a/node_modules/end-of-stream/test.js b/node_modules/end-of-stream/test.js
new file mode 100644
index 00000000..d4d126fe
--- /dev/null
+++ b/node_modules/end-of-stream/test.js
@@ -0,0 +1,62 @@
+var assert = require('assert');
+var eos = require('./index');
+
+var expected = 6;
+var fs = require('fs');
+var net = require('net');
+
+var ws = fs.createWriteStream('/dev/null');
+eos(ws, function(err) {
+ expected--;
+ assert(!!err);
+ if (!expected) process.exit(0);
+});
+ws.close();
+
+var rs = fs.createReadStream('/dev/random');
+eos(rs, function(err) {
+ expected--;
+ assert(!!err);
+ if (!expected) process.exit(0);
+});
+rs.close();
+
+var rs = fs.createReadStream(__filename);
+eos(rs, function(err) {
+ expected--;
+ assert(!err);
+ if (!expected) process.exit(0);
+});
+rs.pipe(fs.createWriteStream('/dev/null'));
+
+var rs = fs.createReadStream(__filename);
+eos(rs, function(err) {
+ throw new Error('no go')
+})();
+rs.pipe(fs.createWriteStream('/dev/null'));
+
+var socket = net.connect(50000);
+eos(socket, function(err) {
+ expected--;
+ assert(!!err);
+ if (!expected) process.exit(0);
+});
+
+var server = net.createServer(function(socket) {
+ eos(socket, function() {
+ expected--;
+ if (!expected) process.exit(0);
+ });
+ socket.destroy();
+}).listen(30000, function() {
+ var socket = net.connect(30000);
+ eos(socket, function() {
+ expected--;
+ if (!expected) process.exit(0);
+ });
+});
+
+setTimeout(function() {
+ assert(expected === 0);
+ process.exit(0);
+}, 1000);
diff --git a/node_modules/enhanced-resolve/README.md b/node_modules/enhanced-resolve/README.md
new file mode 100644
index 00000000..d3f79310
--- /dev/null
+++ b/node_modules/enhanced-resolve/README.md
@@ -0,0 +1,28 @@
+# enhanced-resolve
+
+Offers a async require.resolve function. It's highly configurable.
+
+[documentation](https://github.com/webpack/docs/wiki)
+
+
+## Features
+
+* plugin system
+* provide a custom filesystem
+* sync and async node.js filesystems included
+
+
+## Tests
+
+``` javascript
+npm test
+```
+
+[](http://travis-ci.org/webpack/enhanced-resolve)
+
+
+## License
+
+Copyright (c) 2012-2013 Tobias Koppers
+
+MIT (http://www.opensource.org/licenses/mit-license.php)
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js b/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js
new file mode 100644
index 00000000..132f9653
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js
@@ -0,0 +1,152 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+function Storage(duration) {
+ this.duration = duration;
+ this.running = {};
+ this.data = {};
+ this.levels = [];
+ if(duration > 0) {
+ this.levels.push([], [], [], [], [], [], [], [], []);
+ for(var i = 8000; i < duration; i+=500)
+ this.levels.push([]);
+ }
+ this.count = 0;
+ this.interval = null;
+ this.needTickCheck = false;
+ this.nextTick = null;
+ this.passive = true;
+}
+
+Storage.prototype.ensureTick = function() {
+ if(!this.interval && this.duration > 0 && !this.nextTick)
+ this.interval = setInterval(this.tick.bind(this), Math.floor(this.duration / this.levels.length));
+};
+
+Storage.prototype.finished = function(name) {
+ var args = Array.prototype.slice.call(arguments, 1);
+ var callbacks = this.running[name];
+ delete this.running[name];
+ if(this.duration > 0) {
+ this.count++;
+ this.data[name] = args;
+ this.levels[0].push(name);
+ this.ensureTick();
+ }
+ for(var i = 0; i < callbacks.length; i++) {
+ callbacks[i].apply(null, args);
+ }
+};
+
+Storage.prototype.provide = function(name, provider, callback) {
+ var running = this.running[name];
+ if(running) {
+ running.push(callback);
+ return;
+ }
+ if(this.duration > 0) {
+ this.checkTicks();
+ var data = this.data[name];
+ if(data) {
+ return callback.apply(null, data);
+ }
+ }
+ this.running[name] = running = [callback];
+ provider(name, this.finished.bind(this, name));
+};
+
+Storage.prototype.tick = function() {
+ var decay = this.levels.pop();
+ for(var i = decay.length - 1; i >= 0; i--) {
+ delete this.data[decay[i]];
+ }
+ this.count -= decay.length;
+ decay.length = 0;
+ this.levels.unshift(decay);
+ if(this.count == 0) {
+ clearInterval(this.interval);
+ this.interval = null;
+ this.nextTick = null;
+ return true;
+ } else if(this.nextTick) {
+ this.nextTick += Math.floor(this.duration / this.levels.length);
+ var time = new Date().getTime();
+ if(this.nextTick > time) {
+ this.nextTick = null;
+ this.interval = setInterval(this.tick.bind(this), Math.floor(this.duration / this.levels.length));
+ return true;
+ }
+ } else if(this.passive) {
+ clearInterval(this.interval);
+ this.interval = null;
+ this.nextTick = new Date().getTime() + Math.floor(this.duration / this.levels.length);
+ } else {
+ this.passive = true;
+ }
+};
+
+Storage.prototype.checkTicks = function() {
+ this.passive = false;
+ if(this.nextTick) {
+ while(!this.tick());
+ }
+};
+
+Storage.prototype.purge = function(what) {
+ if(!what) {
+ this.count = 0;
+ clearInterval(this.interval);
+ this.nextTick = null;
+ this.data = {};
+ this.levels.forEach(function(level) {
+ level.length = 0;
+ });
+ } else if(typeof what === "string") {
+ Object.keys(this.data).forEach(function(key) {
+ if(key.indexOf(what) === 0)
+ delete this.data[key];
+ }, this);
+ } else {
+ for(var i = what.length - 1; i >= 0; i--) {
+ this.purge(what[i]);
+ }
+ }
+};
+
+
+function CachedInputFileSystem(fileSystem, duration) {
+ this.fileSystem = fileSystem;
+ this._statStorage = new Storage(duration);
+ this._readdirStorage = new Storage(duration);
+ this._readFileStorage = new Storage(duration);
+ this._readlinkStorage = new Storage(duration);
+}
+module.exports = CachedInputFileSystem;
+
+CachedInputFileSystem.prototype.isSync = function() {
+ return this.fileSystem.isSync();
+};
+
+CachedInputFileSystem.prototype.stat = function(path, callback) {
+ this._statStorage.provide(path, this.fileSystem.stat.bind(this.fileSystem), callback);
+};
+
+CachedInputFileSystem.prototype.readdir = function(path, callback) {
+ this._readdirStorage.provide(path, this.fileSystem.readdir.bind(this.fileSystem), callback);
+};
+
+CachedInputFileSystem.prototype.readFile = function(path, callback) {
+ this._readFileStorage.provide(path, this.fileSystem.readFile.bind(this.fileSystem), callback);
+};
+
+CachedInputFileSystem.prototype.readlink = function(path, callback) {
+ this._readlinkStorage.provide(path, this.fileSystem.readlink.bind(this.fileSystem), callback);
+};
+
+CachedInputFileSystem.prototype.purge = function(what) {
+ this._statStorage.purge(what);
+ this._readdirStorage.purge(what);
+ this._readFileStorage.purge(what);
+ this._readlinkStorage.purge(what);
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/DirectoryDefaultFilePlugin.js b/node_modules/enhanced-resolve/lib/DirectoryDefaultFilePlugin.js
new file mode 100644
index 00000000..f4514ff3
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/DirectoryDefaultFilePlugin.js
@@ -0,0 +1,42 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+
+function DirectoryDefaultFilePlugin(files) {
+ this.files = files;
+}
+module.exports = DirectoryDefaultFilePlugin;
+
+DirectoryDefaultFilePlugin.prototype.apply = function(resolver) {
+ var files = this.files;
+ resolver.plugin("directory", function(request, callback) {
+ var fs = this.fileSystem;
+ var topLevelCallback = callback;
+ var directory = this.join(request.path, request.request);
+ fs.stat(directory, function(err, stat) {
+ if(err || !stat) {
+ if(callback.log) callback.log(directory + " doesn't exist (directory default file)");
+ return callback();
+ }
+ if(!stat.isDirectory()) {
+ if(callback.log) callback.log(directory + " is not a directory (directory default file)");
+ return callback();
+ }
+ this.forEachBail(files, function(file, callback) {
+ this.doResolve("file", {
+ path: directory,
+ query: request.query,
+ request: file
+ }, createInnerCallback(function(err, result) {
+ if(!err && result) return callback(result);
+ return callback();
+ }, topLevelCallback, "directory default file " + file));
+ }.bind(this), function(result) {
+ if(!result) return callback();
+ return callback(null, result);
+ });
+ }.bind(this));
+ });
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/DirectoryDescriptionFileFieldAliasPlugin.js b/node_modules/enhanced-resolve/lib/DirectoryDescriptionFileFieldAliasPlugin.js
new file mode 100644
index 00000000..e9a44f2c
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/DirectoryDescriptionFileFieldAliasPlugin.js
@@ -0,0 +1,126 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+
+function DirectoryDescriptionFileFieldAliasPlugin(filename, field) {
+ this.filename = filename;
+ this.field = field;
+}
+module.exports = DirectoryDescriptionFileFieldAliasPlugin;
+
+function findDescriptionFileField(resolver, directory, filename, field, callback) {
+ (function findDescriptionFile() {
+ var descriptionFilePath = resolver.join(directory, filename);
+ resolver.fileSystem.readFile(descriptionFilePath, function(err, content) {
+ if(err) {
+ directory = cdUp(directory);
+ if(!directory) {
+ return callback();
+ } else {
+ return findDescriptionFile();
+ }
+ }
+ try {
+ content = JSON.parse(content);
+ } catch(e) {
+ if(callback.log)
+ callback.log(descriptionFilePath + " (directory description file): " + e);
+ else
+ e.message = descriptionFilePath + " (directory description file): " + e;
+ return callback(e);
+ }
+ var fieldData;
+ if(Array.isArray(field)) {
+ var current = content;
+ for(var j = 0; j < field.length; j++) {
+ if(current === null || typeof current !== "object") {
+ current = null;
+ break;
+ }
+ current = current[field[j]];
+ }
+ if(typeof current === "object") {
+ fieldData = current;
+ }
+ } else {
+ if(typeof content[field] === "object") {
+ fieldData = content[field];
+ }
+ }
+ if(!fieldData) return callback();
+ callback(null, fieldData, directory);
+ });
+ }());
+}
+
+function cdUp(directory) {
+ if(directory === "/") return null;
+ var i = directory.lastIndexOf("/"),
+ j = directory.lastIndexOf("\\");
+ var p = i < 0 ? j : j < 0 ? i : i < j ? j : i;
+ if(p < 0) return null;
+ return directory.substr(0, p || 1);
+}
+
+DirectoryDescriptionFileFieldAliasPlugin.prototype.apply = function(resolver) {
+ var filename = this.filename;
+ var field = this.field;
+ resolver.plugin("module", function(request, callback) {
+ var directory = request.path;
+ var moduleName = request.request;
+ findDescriptionFileField(this, directory, filename, field, function(err, fieldData, directory) {
+ if(err) return callback(err);
+ if(!fieldData) return callback();
+ var data = fieldData[moduleName];
+ if(data === moduleName) return callback();
+ if(data === false) return callback(null, {
+ path: false,
+ resolved: true
+ });
+ if(!data) return callback();
+ var newRequest = this.parse(data);
+ var obj = {
+ path: directory,
+ request: newRequest.path,
+ query: newRequest.query,
+ directory: newRequest.directory
+ };
+ var newCallback = createInnerCallback(callback, callback, "aliased from directory description file " + this.join(directory, filename) + " with mapping " + JSON.stringify(moduleName));
+ if(newRequest.module) return this.doResolve("module", obj, newCallback);
+ if(newRequest.directory) return this.doResolve("directory", obj, newCallback);
+ return this.doResolve(["file", "directory"], obj, newCallback);
+ }.bind(this));
+ });
+ resolver.plugin("result", function(request, callback) {
+ var directory = cdUp(request.path);
+ var requestPath = request.path;
+ findDescriptionFileField(this, directory, filename, field, function(err, fieldData, directory) {
+ if(err) return callback(err);
+ if(!fieldData) return callback();
+ var relative = requestPath.substr(directory.length+1).replace(/\\/g, "/");
+ if(typeof fieldData[relative] !== "undefined")
+ var data = fieldData[relative];
+ else if(typeof fieldData["./" + relative] !== "undefined")
+ var data = fieldData["./" + relative];
+ if(data === relative || data === "./" + relative) return callback();
+ if(data === false) return callback(null, {
+ path: false,
+ resolved: true
+ });
+ if(!data) return callback();
+ var newRequest = this.parse(data);
+ var obj = {
+ path: directory,
+ request: newRequest.path,
+ query: newRequest.query,
+ directory: newRequest.directory
+ };
+ var newCallback = createInnerCallback(callback, callback, "aliased from directory description file " + this.join(directory, filename) + " with mapping " + JSON.stringify(relative));
+ if(newRequest.module) return this.doResolve("module", obj, newCallback);
+ if(newRequest.directory) return this.doResolve("directory", obj, newCallback);
+ return this.doResolve(["file", "directory"], obj, newCallback);
+ }.bind(this));
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/DirectoryDescriptionFilePlugin.js b/node_modules/enhanced-resolve/lib/DirectoryDescriptionFilePlugin.js
new file mode 100644
index 00000000..2cbc8c68
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/DirectoryDescriptionFilePlugin.js
@@ -0,0 +1,74 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+
+function DirectoryDescriptionFilePlugin(filename, fields) {
+ this.filename = filename;
+ this.fields = fields;
+}
+module.exports = DirectoryDescriptionFilePlugin;
+
+DirectoryDescriptionFilePlugin.prototype.apply = function(resolver) {
+ var filename = this.filename;
+ var fields = this.fields;
+ resolver.plugin("directory", function(request, callback) {
+ var fs = this.fileSystem;
+ var directory = this.join(request.path, request.request);
+ var descriptionFilePath = this.join(directory, filename);
+ fs.readFile(descriptionFilePath, function(err, content) {
+ if(err) {
+ if(callback.log)
+ callback.log(descriptionFilePath + " doesn't exist (directory description file)");
+ return callback();
+ }
+ content = content.toString("utf-8");
+ try {
+ content = JSON.parse(content);
+ } catch(e) {
+ if(callback.log)
+ callback.log(descriptionFilePath + " (directory description file): " + e);
+ else
+ e.message = descriptionFilePath + " (directory description file): " + e;
+ return callback(e);
+ }
+ var mainModules = [];
+ for(var i = 0; i < fields.length; i++) {
+ if(Array.isArray(fields[i])) {
+ var current = content;
+ for(var j = 0; j < fields[i].length; j++) {
+ if(current === null || typeof current !== "object") {
+ current = null;
+ break;
+ }
+ var field = fields[i][j];
+ current = current[field];
+ }
+ if(typeof current === "string") {
+ mainModules.push(current);
+ continue;
+ }
+ } else {
+ var field = fields[i];
+ if(typeof content[field] === "string") {
+ mainModules.push(content[field]);
+ continue;
+ }
+ }
+ }
+ (function next() {
+ if(mainModules.length == 0) return callback();
+ var mainModule = mainModules.shift();
+ return this.doResolve(["file", "directory"], {
+ path: directory,
+ query: request.query,
+ request: mainModule
+ }, createInnerCallback(function(err, result) {
+ if(!err && result) return callback(null, result);
+ return next.call(this);
+ }.bind(this), callback, "use " + mainModule + " from " + filename));
+ }.call(this))
+ }.bind(this));
+ });
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/DirectoryResultPlugin.js b/node_modules/enhanced-resolve/lib/DirectoryResultPlugin.js
new file mode 100644
index 00000000..7ad57306
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/DirectoryResultPlugin.js
@@ -0,0 +1,31 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+function DirectoryResultPlugin(files) {
+ this.files = files;
+}
+module.exports = DirectoryResultPlugin;
+
+DirectoryResultPlugin.prototype.apply = function(resolver) {
+ var files = this.files;
+ resolver.plugin("directory", function(request, callback) {
+ var fs = this.fileSystem;
+ var directory = this.join(request.path, request.request);
+ fs.stat(directory, function(err, stat) {
+ if(!err && stat && stat.isDirectory()) {
+ return this.doResolve("result", {
+ path: directory,
+ query: request.query,
+ directory: true,
+ resolved: true
+ }, callback);
+ }
+ if(callback.log) {
+ if(err) callback.log(directory + " doesn't exist");
+ else callback.log(directory + " is not a directory");
+ }
+ return callback();
+ }.bind(this));
+ });
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/FileAppendPlugin.js b/node_modules/enhanced-resolve/lib/FileAppendPlugin.js
new file mode 100644
index 00000000..1be582a4
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/FileAppendPlugin.js
@@ -0,0 +1,40 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+function FileAppendPlugin(appendings) {
+ this.appendings = appendings;
+}
+module.exports = FileAppendPlugin;
+
+FileAppendPlugin.prototype.apply = function(resolver) {
+ var appendings = this.appendings;
+ resolver.plugin("file", function(request, callback) {
+ var fs = this.fileSystem;
+ var addr = this.join(request.path, request.request);
+ var addrs = appendings.map(function(a) { return addr + a });
+ var log = callback.log;
+ var missing = callback.missing;
+ this.forEachBail(addrs, function(addr, callback) {
+ fs.stat(addr, function(err, stat) {
+ if(!err && stat && stat.isFile())
+ return callback(addr);
+ if(missing && err)
+ missing.push(addr);
+ if(log) {
+ if(err) log(addr + " doesn't exist");
+ else log(addr + " is not a file");
+ }
+ return callback();
+ });
+ }, function(validAddr) {
+ if(!validAddr) return callback();
+ return this.doResolve("result", {
+ path: validAddr,
+ query: request.query,
+ file: true,
+ resolved: true
+ }, callback);
+ }.bind(this));
+ });
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/ModuleAliasPlugin.js b/node_modules/enhanced-resolve/lib/ModuleAliasPlugin.js
new file mode 100644
index 00000000..eaa69267
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ModuleAliasPlugin.js
@@ -0,0 +1,44 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+
+function ModuleAliasPlugin(aliasMap) {
+ this.aliasMap = aliasMap;
+}
+module.exports = ModuleAliasPlugin;
+
+ModuleAliasPlugin.prototype.apply = function(resolver) {
+ var aliasMap = this.aliasMap;
+ resolver.plugin("module", function(request, callback) {
+ var fs = this.fileSystem;
+ var keys = Object.keys(aliasMap);
+ var i = 0;
+ (function next() {
+ for(;i < keys.length; i++) {
+ var aliasName = keys[i];
+ var onlyModule = /\$$/.test(aliasName);
+ if(onlyModule) aliasName = aliasName.substr(0, aliasName.length-1);
+ if((!onlyModule && request.request.indexOf(aliasName + "/") === 0) || request.request === aliasName) {
+ var aliasValue = aliasMap[keys[i]];
+ if(request.request.indexOf(aliasValue + "/") !== 0 && request.request != aliasValue) {
+ var newRequestStr = aliasValue + request.request.substr(aliasName.length);
+ var newRequest = this.parse(newRequestStr);
+ var obj = {
+ path: request.path,
+ request: newRequest.path,
+ query: newRequest.query,
+ directory: newRequest.directory
+ };
+ var newCallback = createInnerCallback(callback, callback, "aliased with mapping " + JSON.stringify(aliasName) + ": " + JSON.stringify(aliasValue) + " to " + newRequestStr);
+ if(newRequest.module) return this.doResolve("module", obj, newCallback);
+ if(newRequest.directory) return this.doResolve("directory", obj, newCallback);
+ return this.doResolve(["file", "directory"], obj, newCallback);
+ }
+ }
+ }
+ return callback();
+ }.call(this));
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/ModuleAsDirectoryPlugin.js b/node_modules/enhanced-resolve/lib/ModuleAsDirectoryPlugin.js
new file mode 100644
index 00000000..e058fcf9
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ModuleAsDirectoryPlugin.js
@@ -0,0 +1,43 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+function ModuleAsDirectoryPlugin(moduleType) {
+ this.moduleType = moduleType;
+}
+module.exports = ModuleAsDirectoryPlugin;
+
+ModuleAsDirectoryPlugin.prototype.apply = function(resolver) {
+ resolver.plugin("module-" + this.moduleType, function(request, callback) {
+ var fs = this.fileSystem;
+ var i = request.request.indexOf("/"),
+ j = request.request.indexOf("\\");
+ var p = i < 0 ? j : j < 0 ? i : i < j ? i : j;
+ var moduleName, remainingRequest;
+ if(p < 0) {
+ moduleName = request.request;
+ remainingRequest = "";
+ } else {
+ moduleName = request.request.substr(0, p);
+ remainingRequest = request.request.substr(p+1);
+ }
+ var modulePath = this.join(request.path, moduleName);
+ fs.stat(modulePath, function(err, stat) {
+ if(err || !stat) {
+ if(callback.missing)
+ callback.missing.push(modulePath);
+ if(callback.log) callback.log(modulePath + " doesn't exist (module as directory)");
+ return callback();
+ }
+ if(stat.isDirectory()) {
+ return this.doResolve(request.directory ? "directory" : ["file", "directory"], {
+ path: modulePath,
+ request: remainingRequest,
+ query: request.query
+ }, callback, true);
+ }
+ if(callback.log) callback.log(modulePath + " is not a directory (module as directory)");
+ return callback();
+ }.bind(this));
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/ModuleAsFilePlugin.js b/node_modules/enhanced-resolve/lib/ModuleAsFilePlugin.js
new file mode 100644
index 00000000..7d6fadba
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ModuleAsFilePlugin.js
@@ -0,0 +1,18 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+function ModuleAsFilePlugin(moduleType) {
+ this.moduleType = moduleType;
+}
+module.exports = ModuleAsFilePlugin;
+
+ModuleAsFilePlugin.prototype.apply = function(resolver) {
+ resolver.plugin("module-" + this.moduleType, function(request, callback) {
+ var fs = this.fileSystem;
+ var i = request.request.indexOf("/"),
+ j = request.request.indexOf("\\");
+ if(i >= 0 || j >= 0 || request.directory) return callback();
+ return this.doResolve("file", request, callback, true);
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/ModuleTemplatesPlugin.js b/node_modules/enhanced-resolve/lib/ModuleTemplatesPlugin.js
new file mode 100644
index 00000000..2962ee27
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ModuleTemplatesPlugin.js
@@ -0,0 +1,45 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+
+function ModuleTemplatesPlugin(moduleType, templates, targetModuleType) {
+ this.moduleType = moduleType;
+ this.targetModuleType = targetModuleType;
+ this.templates = templates;
+}
+module.exports = ModuleTemplatesPlugin;
+
+ModuleTemplatesPlugin.prototype.apply = function(resolver) {
+ var templates = this.templates;
+ var targetModuleType = this.targetModuleType;
+ resolver.plugin("module-" + this.moduleType, function(request, callback) {
+ var fs = this.fileSystem;
+ var topLevelCallback = callback;
+ var i = request.request.indexOf("/"),
+ j = request.request.indexOf("\\");
+ var p = i < 0 ? j : j < 0 ? i : i < j ? i : j;
+ var moduleName, remainingRequest;
+ if(p < 0) {
+ moduleName = request.request;
+ remainingRequest = "";
+ } else {
+ moduleName = request.request.substr(0, p);
+ remainingRequest = request.request.substr(p);
+ }
+ this.forEachBail(templates, function(template, callback) {
+ var moduleFinalName = template.replace(/\*/g, moduleName);
+ this.applyPluginsParallelBailResult("module-" + targetModuleType, {
+ path: request.path,
+ request: moduleFinalName + remainingRequest,
+ query: request.query,
+ directory: request.directory
+ }, createInnerCallback(function(err, result) {
+ if(err) return callback(err);
+ if(!result) return callback();
+ return callback(null, result);
+ }, topLevelCallback, "module variation " + moduleFinalName));
+ }.bind(this), callback);
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/ModulesInDirectoriesPlugin.js b/node_modules/enhanced-resolve/lib/ModulesInDirectoriesPlugin.js
new file mode 100644
index 00000000..3b801c01
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ModulesInDirectoriesPlugin.js
@@ -0,0 +1,58 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+var popPathSeqment = require("./popPathSeqment");
+
+function ModulesInDirectoriesPlugin(moduleType, directories) {
+ this.moduleType = moduleType;
+ this.directories = directories;
+}
+module.exports = ModulesInDirectoriesPlugin;
+
+ModulesInDirectoriesPlugin.prototype.apply = function(resolver) {
+ var moduleType = this.moduleType;
+ var directories = this.directories;
+ resolver.plugin("module", function(request, callback) {
+ var fs = this.fileSystem;
+ var paths = [request.path];
+ var addr = [request.path];
+ var pathSeqment = popPathSeqment(addr);
+ var topLevelCallback = callback;
+ while(pathSeqment) {
+ paths.push(addr[0]);
+ pathSeqment = popPathSeqment(addr);
+ }
+ var addrs = paths.map(function(p) {
+ return directories.map(function(d) {
+ return this.join(p, d);
+ }, this);
+ }, this).reduce(function(array, p) {
+ array.push.apply(array, p);
+ return array;
+ }, []);
+ this.forEachBail(addrs, function(addr, callback) {
+ fs.stat(addr, function(err, stat) {
+ if(!err && stat && stat.isDirectory()) {
+ this.applyPluginsParallelBailResult("module-" + moduleType, {
+ path: addr,
+ request: request.request,
+ query: request.query,
+ directory: request.directory
+ }, createInnerCallback(function(err, result) {
+ if(err) return callback(err);
+ if(!result) return callback();
+ return callback(null, result);
+ }, topLevelCallback, "looking for modules in " + addr));
+ return;
+ }
+ return callback();
+ }.bind(this));
+ }.bind(this), function(err, result) {
+ if(err) return callback(err);
+ if(!result) return callback();
+ return callback(null, result);
+ });
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/ModulesInRootPlugin.js b/node_modules/enhanced-resolve/lib/ModulesInRootPlugin.js
new file mode 100644
index 00000000..2b2ab6ae
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ModulesInRootPlugin.js
@@ -0,0 +1,28 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var createInnerCallback = require("./createInnerCallback");
+
+function ModulesInRootPlugin(moduleType, path) {
+ this.moduleType = moduleType;
+ this.path = path;
+}
+module.exports = ModulesInRootPlugin;
+
+ModulesInRootPlugin.prototype.apply = function(resolver) {
+ var moduleType = this.moduleType;
+ var path = this.path;
+ resolver.plugin("module", function(request, callback) {
+ this.applyPluginsParallelBailResult("module-" + moduleType, {
+ path: path,
+ request: request.request,
+ query: request.query,
+ directory: request.directory
+ }, createInnerCallback(function innerCallback(err, result) {
+ if(err) return callback(err);
+ if(!result) return callback();
+ return callback(null, result);
+ }, callback, "looking for modules in " + path));
+ });
+};
diff --git a/node_modules/enhanced-resolve/lib/NodeJsInputFileSystem.js b/node_modules/enhanced-resolve/lib/NodeJsInputFileSystem.js
new file mode 100644
index 00000000..588095d8
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/NodeJsInputFileSystem.js
@@ -0,0 +1,23 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var fs = require("graceful-fs");
+
+function NodeJsInputFileSystem() {}
+module.exports = NodeJsInputFileSystem;
+
+NodeJsInputFileSystem.prototype.isSync = function() {
+ return false;
+};
+
+NodeJsInputFileSystem.prototype.stat = fs.stat.bind(fs);
+NodeJsInputFileSystem.prototype.readdir = function readdir(path, callback) {
+ fs.readdir(path, function (err, files) {
+ callback(err, files && files.map(function (file) {
+ return file.normalize ? file.normalize("NFC") : file;
+ }));
+ });
+};
+NodeJsInputFileSystem.prototype.readFile = fs.readFile.bind(fs);
+NodeJsInputFileSystem.prototype.readlink = fs.readlink.bind(fs);
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/Resolver.js b/node_modules/enhanced-resolve/lib/Resolver.js
new file mode 100644
index 00000000..62e57d92
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/Resolver.js
@@ -0,0 +1,200 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var Tapable = require("tapable");
+var createInnerCallback = require("./createInnerCallback");
+
+function Resolver(fileSystem) {
+ Tapable.call(this);
+ this.fileSystem = fileSystem;
+}
+module.exports = Resolver;
+
+Resolver.prototype = Object.create(Tapable.prototype);
+
+Resolver.prototype.resolveSync = function resolveSync(context, request) {
+ var err, result, sync = false;
+ this.resolve(context, request, function(e, r) {
+ err = e;
+ result = r;
+ sync = true;
+ });
+ if(!sync) throw new Error("Cannot 'resolveSync' because the fileSystem is not sync. Use 'resolve'!");
+ if(err) throw err;
+ return result;
+};
+
+Resolver.prototype.resolve = function resolve(context, request, callback) {
+ if(typeof request === "string") request = this.parse(request);
+ this.applyPlugins("resolve", context, request);
+ var obj = {
+ path: context,
+ request: request.path,
+ query: request.query,
+ directory: request.directory
+ };
+ function onResolved(err, result) {
+ if(err) return callback(err);
+ return callback(null, result.path === false ? false : result.path + (result.query || ""));
+ }
+ onResolved.log = callback.log;
+ onResolved.missing = callback.missing;
+ if(request.module) return this.doResolve("module", obj, onResolved);
+ if(request.directory) return this.doResolve("directory", obj, onResolved);
+ return this.doResolve(["file", "directory"], obj, onResolved);
+};
+
+Resolver.prototype.doResolve = function doResolve(types, request, callback, noError) {
+ if(!Array.isArray(types)) types = [types];
+ var stackLine = types.join(" or ") + ": (" + request.path + ") " +
+ (request.request || "") + (request.query || "") +
+ (request.directory ? " directory" : "") +
+ (request.module ? " module" : "");
+ var newStack = [stackLine];
+ if(callback.stack) {
+ newStack = callback.stack.concat(newStack);
+ if(callback.stack.indexOf(stackLine) >= 0) {
+ // Prevent recursion
+ var recursionError = new Error("Recursion in resolving\nStack:\n " + newStack.join("\n "));
+ recursionError.recursion = true;
+ if(callback.log) callback.log("abort resolving because of recursion");
+ return callback(recursionError);
+ }
+ }
+ this.applyPlugins("resolve-step", types, request);
+ var localMissing = [];
+ var missing = callback.missing ? {
+ push: function(item) {
+ callback.missing.push(item);
+ localMissing.push(item);
+ }
+ } : localMissing;
+ var log = [];
+ function writeLog(msg) {
+ log.push(msg);
+ }
+ function logAsString() {
+ return log.join("\n");
+ }
+ var currentRequestString = request.request ? request.request + " in " + request.path : request.path;
+ if(types.length == 1 && !noError) {
+ // If only one type, we can pass the error.
+ return this.applyPluginsParallelBailResult(types[0], request, createInnerCallback(function innerCallback(err, result) {
+ if(callback.log) {
+ for(var i = 0; i < log.length; i++)
+ callback.log(log[i]);
+ }
+ if(err) return callback(err);
+ if(result) return callback(null, result);
+ if(types[0] === "result") return callback(null, request);
+ var error = new Error("Cannot resolve " + types[0] + " '" + request.request + "' in " + request.path);
+ error.details = logAsString();
+ error.missing = localMissing;
+ return callback(error);
+ }, {
+ log: writeLog,
+ missing: missing,
+ stack: newStack
+ }, "resolve " + types[0] + " " + currentRequestString));
+ }
+ // For multiple type we list the errors in the details although some of them are not important
+ this.forEachBail(types, function(type, callback) {
+ this.applyPluginsParallelBailResult(type, request, createInnerCallback(function(err, result) {
+ if(!err && result) return callback(result);
+ if (err) {
+ (err.message || "").split("\n").forEach(function(line) {
+ log.push(" " + line);
+ });
+ }
+ callback();
+ }, {
+ log: writeLog,
+ missing: missing,
+ stack: newStack
+ }, "resolve " + type));
+ }.bind(this), function(result) {
+ if(callback.log) {
+ callback.log("resolve '" + types.join("' or '") + "' " + currentRequestString);
+ for(var i = 0; i < log.length; i++)
+ callback.log(" " + log[i]);
+ }
+ if(noError && !result) return callback();
+ if(result) return callback(null, result);
+ var error = new Error("Cannot resolve '" + types.join("' or '") + "' " + currentRequestString);
+ error.details = logAsString();
+ error.missing = localMissing;
+ return callback(error);
+ });
+};
+
+Resolver.prototype.parse = function parse(identifier) {
+ if(identifier === "") return null;
+ var part = {
+ path: null,
+ query: null,
+ module: false,
+ directory: false,
+ file: false
+ };
+ var idxQuery = identifier.indexOf("?");
+ if(idxQuery == 0) {
+ part.query = identifier;
+ } else if(idxQuery > 0) {
+ part.path = identifier.slice(0, idxQuery);
+ part.query = identifier.slice(idxQuery);
+ } else {
+ part.path = identifier;
+ }
+ if(part.path) {
+ part.module = this.isModule(part.path);
+ if(part.directory = this.isDirectory(part.path)) {
+ part.path = part.path.substr(0, part.path.length - 1);
+ }
+ }
+ return part;
+};
+
+var notModuleRegExp = /^\.$|^\.[\\\/]|^\.\.$|^\.\.[\/\\]|^\/|^[A-Z]:[\\\/]/i;
+Resolver.prototype.isModule = function isModule(path) {
+ return !notModuleRegExp.test(path);
+};
+
+var directoryRegExp = /[\/\\]$/i;
+Resolver.prototype.isDirectory = function isDirectory(path) {
+ return directoryRegExp.test(path);
+};
+
+Resolver.prototype.join = require("memory-fs/lib/join");
+
+Resolver.prototype.normalize = require("memory-fs/lib/normalize");
+
+Resolver.prototype.forEachBail = function(array, iterator, callback) {
+ if(array.length == 0) return callback();
+ var currentPos = array.length;
+ var currentError, currentResult;
+ var done = [];
+ for(var i = 0; i < array.length; i++) {
+ var itCb = (function(i) {
+ return function() {
+ if(i >= currentPos) return; // ignore
+ var args = Array.prototype.slice.call(arguments);
+ done.push(i);
+ if(args.length > 0) {
+ currentPos = i + 1;
+ done = done.filter(function(item) {
+ return item <= i;
+ });
+ currentResult = args;
+ }
+ if(done.length == currentPos) {
+ callback.apply(null, currentResult);
+ currentPos = 0;
+ }
+ };
+ }(i));
+ iterator(array[i], itCb);
+ if(currentPos == 0) break;
+ }
+};
+
diff --git a/node_modules/enhanced-resolve/lib/ResultSymlinkPlugin.js b/node_modules/enhanced-resolve/lib/ResultSymlinkPlugin.js
new file mode 100644
index 00000000..9d4fac2a
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/ResultSymlinkPlugin.js
@@ -0,0 +1,49 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var popPathSeqment = require("./popPathSeqment");
+
+function ResultSymlinkPlugin(appendings) {
+}
+module.exports = ResultSymlinkPlugin;
+
+ResultSymlinkPlugin.prototype.apply = function(resolver) {
+ resolver.plugin("result", function pluginMethod(request, callback) {
+ var fs = this.fileSystem;
+ var paths = [request.path];
+ var pathSeqments = [];
+ var addr = [request.path];
+ var pathSeqment = popPathSeqment(addr);
+ while(pathSeqment) {
+ pathSeqments.push(pathSeqment);
+ paths.push(addr[0]);
+ pathSeqment = popPathSeqment(addr);
+ }
+ pathSeqments.push(paths[paths.length-1]);
+ var log = callback.log;
+ var missing = callback.missing;
+ var containsSymlink = false;
+ this.forEachBail(paths.map(function(_, i) { return i; }), function(idx, callback) {
+ fs.readlink(paths[idx], function(err, result) {
+ if(!err && result) {
+ pathSeqments[idx] = result;
+ containsSymlink = true;
+ // Shortcut when absolute symlink found
+ if(/^(\/|[a-zA-z]:($|\\))/.test(result))
+ return callback(null, idx);
+ }
+ callback();
+ });
+ }, function(err, idx) {
+ if(!containsSymlink) return callback();
+ var resultSeqments = typeof idx === "number" ? pathSeqments.slice(0, idx+1) : pathSeqments.slice();
+ var result = resultSeqments.reverse().reduce(function(a, b) {
+ return this.join(a, b);
+ }.bind(this));
+ log("resolved symlink to " + result);
+ request.path = result;
+ pluginMethod.call(this, request, callback);
+ }.bind(this));
+ });
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/SyncNodeJsInputFileSystem.js b/node_modules/enhanced-resolve/lib/SyncNodeJsInputFileSystem.js
new file mode 100644
index 00000000..9fc036a7
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/SyncNodeJsInputFileSystem.js
@@ -0,0 +1,34 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var fs = require("graceful-fs");
+
+function SyncNodeJsInputFileSystem() {}
+module.exports = SyncNodeJsInputFileSystem;
+
+SyncNodeJsInputFileSystem.prototype.isSync = function() {
+ return true;
+};
+
+function asAsync(fn, context) {
+ return function() {
+ var args = Array.prototype.slice.call(arguments);
+ var callback = args.pop();
+ try {
+ callback(null, fn.apply(context, args));
+ } catch(e) {
+ callback(e);
+ }
+ };
+}
+
+SyncNodeJsInputFileSystem.prototype.stat = asAsync(fs.statSync, fs);
+SyncNodeJsInputFileSystem.prototype.readdir = asAsync(function readdirSync(path) {
+ var files = fs.readdirSync(path);
+ return files && files.map(function (file) {
+ return file.normalize ? file.normalize("NFC") : file;
+ });
+}, fs);
+SyncNodeJsInputFileSystem.prototype.readFile = asAsync(fs.readFileSync, fs);
+SyncNodeJsInputFileSystem.prototype.readlink = asAsync(fs.readlinkSync, fs);
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js b/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js
new file mode 100644
index 00000000..8806b1ca
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js
@@ -0,0 +1,32 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+function UnsafeCachePlugin(regExps, cache) {
+ this.regExps = regExps || [/./];
+ if(this.regExps === true) this.regExps = [/./];
+ else if(!Array.isArray(this.regExps)) this.regExps = [this.regExps];
+ this.cache = cache || {};
+}
+module.exports = UnsafeCachePlugin;
+
+UnsafeCachePlugin.prototype.apply = function(resolver) {
+ var oldResolve = resolver.resolve;
+ var regExps = this.regExps;
+ var cache = this.cache;
+ resolver.resolve = function resolve(context, request, callback) {
+ var id = context + "->" + request;
+ if(cache[id]) {
+ // From cache
+ return callback(null, cache[id]);
+ }
+ oldResolve.call(resolver, context, request, function(err, result) {
+ if(err) return callback(err);
+ var doCache = regExps.some(function(regExp) {
+ return regExp.test(result.path);
+ });
+ if(!doCache) return callback(null, result);
+ callback(null, cache[id] = result);
+ });
+ };
+};
diff --git a/node_modules/enhanced-resolve/lib/createInnerCallback.js b/node_modules/enhanced-resolve/lib/createInnerCallback.js
new file mode 100644
index 00000000..66fc772a
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/createInnerCallback.js
@@ -0,0 +1,30 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+module.exports = function createInnerCallback(callback, options, message) {
+ var log = options.log;
+ if(!log) {
+ if(options.stack !== callback.stack) {
+ function callbackWrapper() {
+ return callback.apply(this, arguments);
+ }
+ callbackWrapper.stack = options.stack;
+ callbackWrapper.missing = options.missing;
+ }
+ return callback;
+ }
+ function loggingCallbackWrapper() {
+ log(message);
+ for(var i = 0; i < theLog.length; i++)
+ log(" " + theLog[i]);
+ return callback.apply(this, arguments);
+ }
+ var theLog = [];
+ loggingCallbackWrapper.log = function writeLog(msg) {
+ theLog.push(msg);
+ };
+ loggingCallbackWrapper.stack = options.stack;
+ loggingCallbackWrapper.missing = options.missing;
+ return loggingCallbackWrapper;
+}
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/lib/node.js b/node_modules/enhanced-resolve/lib/node.js
new file mode 100644
index 00000000..22c65905
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/node.js
@@ -0,0 +1,103 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+var Resolver = require("./Resolver");
+var NodeJsInputFileSystem = require("./NodeJsInputFileSystem");
+var SyncNodeJsInputFileSystem = require("./SyncNodeJsInputFileSystem");
+var CachedInputFileSystem = require("./CachedInputFileSystem");
+var ModulesInDirectoriesPlugin = require("./ModulesInDirectoriesPlugin");
+var ModuleTemplatesPlugin = require("./ModuleTemplatesPlugin");
+var ModuleAsFilePlugin = require("./ModuleAsFilePlugin");
+var ModuleAsDirectoryPlugin = require("./ModuleAsDirectoryPlugin");
+var DirectoryDefaultFilePlugin = require("./DirectoryDefaultFilePlugin");
+var DirectoryDescriptionFilePlugin = require("./DirectoryDescriptionFilePlugin");
+var FileAppendPlugin = require("./FileAppendPlugin");
+var ResultSymlinkPlugin = require("./ResultSymlinkPlugin");
+var DirectoryResultPlugin = require("./DirectoryResultPlugin");
+
+var commonPlugins = [
+ new ModulesInDirectoriesPlugin("node", ["node_modules"]),
+ new ModuleAsFilePlugin("node"),
+ new ModuleAsDirectoryPlugin("node"),
+ new DirectoryDescriptionFilePlugin("package.json", ["main"]),
+ new DirectoryDefaultFilePlugin(["index"]),
+ new FileAppendPlugin(["", ".js", ".node"]),
+ new ResultSymlinkPlugin()
+];
+
+var commonContextPlugins = [
+ new ModulesInDirectoriesPlugin("node", ["node_modules"]),
+ new ModuleAsFilePlugin("node"),
+ new ModuleAsDirectoryPlugin("node"),
+ new DirectoryResultPlugin(),
+ new ResultSymlinkPlugin()
+];
+
+var commonLoaderPlugins = [
+ new ModulesInDirectoriesPlugin("loader-module", ["node_loaders", "node_modules"]),
+ new ModuleTemplatesPlugin("loader-module", ["*-loader", "*"], "node"),
+ new ModuleAsFilePlugin("node"),
+ new ModuleAsDirectoryPlugin("node"),
+ new DirectoryDescriptionFilePlugin("package.json", ["loader", "main"]),
+ new DirectoryDefaultFilePlugin(["index"]),
+ new FileAppendPlugin([".loader.js", "", ".js"]),
+ new ResultSymlinkPlugin()
+];
+
+var asyncFileSystem = new CachedInputFileSystem(new NodeJsInputFileSystem(), 4000);
+var syncFileSystem = new CachedInputFileSystem(new SyncNodeJsInputFileSystem(), 4000);
+
+
+var asyncResolver = new Resolver(asyncFileSystem);
+asyncResolver.apply.apply(asyncResolver, commonPlugins);
+module.exports = function resolve(context, request, callback) {
+ asyncResolver.resolve(context, request, callback);
+};
+
+var syncResolver = new Resolver(syncFileSystem);
+syncResolver.apply.apply(syncResolver, commonPlugins);
+module.exports.sync = function resolveSync(context, request) {
+ return syncResolver.resolveSync(context, request);
+};
+
+
+var asyncContextResolver = new Resolver(asyncFileSystem);
+asyncContextResolver.apply.apply(asyncContextResolver, commonContextPlugins);
+module.exports.context = function resolveContext(context, request, callback) {
+ asyncContextResolver.resolve(context, request, callback);
+};
+
+var syncContextResolver = new Resolver(syncFileSystem);
+syncContextResolver.apply.apply(syncContextResolver, commonContextPlugins);
+module.exports.context.sync = function resolveSync(context, request) {
+ return syncContextResolver.resolveSync(context, request);
+};
+
+
+var asyncLoaderResolver = new Resolver(asyncFileSystem);
+asyncLoaderResolver.apply.apply(asyncLoaderResolver, commonLoaderPlugins);
+module.exports.loader = function resolveContext(context, request, callback) {
+ asyncLoaderResolver.resolve(context, request, callback);
+};
+
+var syncLoaderResolver = new Resolver(syncFileSystem);
+syncLoaderResolver.apply.apply(syncLoaderResolver, commonLoaderPlugins);
+module.exports.loader.sync = function resolveSync(context, request) {
+ return syncLoaderResolver.resolveSync(context, request);
+};
+
+// Export Resolver, FileSystems and Plugins
+module.exports.Resolver = Resolver;
+module.exports.NodeJsInputFileSystem = NodeJsInputFileSystem;
+module.exports.SyncNodeJsInputFileSystem = SyncNodeJsInputFileSystem;
+module.exports.CachedInputFileSystem = CachedInputFileSystem;
+module.exports.ModulesInDirectoriesPlugin = ModulesInDirectoriesPlugin;
+module.exports.ModuleAsDirectoryPlugin = ModuleAsDirectoryPlugin;
+module.exports.DirectoryDefaultFilePlugin = DirectoryDefaultFilePlugin;
+module.exports.DirectoryDescriptionFilePlugin = DirectoryDescriptionFilePlugin;
+module.exports.FileAppendPlugin = FileAppendPlugin;
+module.exports.DirectoryResultPlugin = DirectoryResultPlugin;
+module.exports.ResultSymlinkPlugin = ResultSymlinkPlugin;
+module.exports.ModuleAsFilePlugin = ModuleAsFilePlugin;
+module.exports.ModuleTemplatesPlugin = ModuleTemplatesPlugin;
diff --git a/node_modules/enhanced-resolve/lib/popPathSeqment.js b/node_modules/enhanced-resolve/lib/popPathSeqment.js
new file mode 100644
index 00000000..7eea05c2
--- /dev/null
+++ b/node_modules/enhanced-resolve/lib/popPathSeqment.js
@@ -0,0 +1,13 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+module.exports = function popPathSeqment(pathInArray) {
+ var i = pathInArray[0].lastIndexOf("/"),
+ j = pathInArray[0].lastIndexOf("\\");
+ var p = i < 0 ? j : j < 0 ? i : i < j ? j : i;
+ if(p < 0) return null;
+ var s = pathInArray[0].substr(p+1);
+ pathInArray[0] = pathInArray[0].substr(0, p || 1);
+ return s;
+};
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/.gitattributes b/node_modules/enhanced-resolve/node_modules/memory-fs/.gitattributes
new file mode 100644
index 00000000..412eeda7
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/.gitattributes
@@ -0,0 +1,22 @@
+# Auto detect text files and perform LF normalization
+* text=auto
+
+# Custom for Visual Studio
+*.cs diff=csharp
+*.sln merge=union
+*.csproj merge=union
+*.vbproj merge=union
+*.fsproj merge=union
+*.dbproj merge=union
+
+# Standard to msysgit
+*.doc diff=astextplain
+*.DOC diff=astextplain
+*.docx diff=astextplain
+*.DOCX diff=astextplain
+*.dot diff=astextplain
+*.DOT diff=astextplain
+*.pdf diff=astextplain
+*.PDF diff=astextplain
+*.rtf diff=astextplain
+*.RTF diff=astextplain
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/.npmignore b/node_modules/enhanced-resolve/node_modules/memory-fs/.npmignore
new file mode 100644
index 00000000..d2b38602
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/.npmignore
@@ -0,0 +1,65 @@
+# Logs
+logs
+*.log
+
+# Runtime data
+pids
+*.pid
+*.seed
+
+# Directory for instrumented libs generated by jscoverage/JSCover
+lib-cov
+
+# Coverage directory used by tools like istanbul
+coverage
+
+# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
+.grunt
+
+# Compiled binary addons (http://nodejs.org/api/addons.html)
+build/Release
+
+# Dependency directory
+# Deployed apps should consider commenting this line out:
+# see https://npmjs.org/doc/faq.html#Should-I-check-my-node_modules-folder-into-git
+node_modules
+
+# =========================
+# Operating System Files
+# =========================
+
+# OSX
+# =========================
+
+.DS_Store
+.AppleDouble
+.LSOverride
+
+# Icon must ends with two \r.
+Icon
+
+# Thumbnails
+._*
+
+# Files that might appear on external disk
+.Spotlight-V100
+.Trashes
+
+# Windows
+# =========================
+
+# Windows image file caches
+Thumbs.db
+ehthumbs.db
+
+# Folder config file
+Desktop.ini
+
+# Recycle Bin used on file shares
+$RECYCLE.BIN/
+
+# Windows Installer files
+*.cab
+*.msi
+*.msm
+*.msp
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/.travis.yml b/node_modules/enhanced-resolve/node_modules/memory-fs/.travis.yml
new file mode 100644
index 00000000..1416d607
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/.travis.yml
@@ -0,0 +1,4 @@
+language: node_js
+node_js:
+ - "0.10"
+ - "0.11"
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/README.md b/node_modules/enhanced-resolve/node_modules/memory-fs/README.md
new file mode 100644
index 00000000..450ef484
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/README.md
@@ -0,0 +1,29 @@
+# memory-fs
+
+A simple in-memory filesystem. Holds data in a javascript object.
+
+``` javascript
+var MemoryFileSystem = require("memory-fs");
+var fs = new MemoryFileSystem(); // Optionally pass a javascript object
+
+fs.mkdirpSync("/a/test/dir");
+fs.writeFileSync("/a/test/dir/file.txt", "Hello World");
+fs.readFileSync("/a/test/dir/file.txt"); // returns Buffer("Hello World")
+
+// Async variantes too
+fs.unlink("/a/test/dir/file.txt", function(err) {
+ // ...
+});
+
+fs.readdirSync("/a/test"); // returns ["dir"]
+fs.statSync("/a/test/dir").isDirectory(); // returns true
+fs.rmdirSync("/a/test/dir");
+
+fs.mkdirpSync("C:\\use\\windows\\style\\paths");
+```
+
+## License
+
+Copyright (c) 2012-2014 Tobias Koppers
+
+MIT (http://www.opensource.org/licenses/mit-license.php)
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/lib/MemoryFileSystem.js b/node_modules/enhanced-resolve/node_modules/memory-fs/lib/MemoryFileSystem.js
new file mode 100644
index 00000000..118b3d23
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/lib/MemoryFileSystem.js
@@ -0,0 +1,225 @@
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+
+var normalize = require("./normalize");
+
+function MemoryFileSystem(data) {
+ this.data = data || {};
+}
+module.exports = MemoryFileSystem;
+
+function isDir(item) {
+ if(typeof item !== "object") return false;
+ return item[""] === true;
+}
+
+function isFile(item) {
+ if(typeof item !== "object") return false;
+ return !item[""];
+}
+
+function pathToArray(path) {
+ path = normalize(path);
+ var nix = /^\//.test(path);
+ if(!nix) {
+ if(!/^[A-Za-z]:/.test(path)) throw new Error("Invalid path '" + path + "'");
+ path = path.replace(/[\\\/]+/g, "\\"); // multi slashs
+ path = path.split(/[\\\/]/);
+ path[0] = path[0].toUpperCase();
+ } else {
+ path = path.replace(/\/+/g, "/"); // multi slashs
+ path = path.substr(1).split("/");
+ }
+ if(!path[path.length-1]) path.pop();
+ return path;
+}
+
+function trueFn() { return true; }
+function falseFn() { return false; }
+
+MemoryFileSystem.prototype.statSync = function(_path) {
+ var path = pathToArray(_path);
+ var current = this.data;
+ for(var i = 0; i < path.length - 1; i++) {
+ if(!isDir(current[path[i]]))
+ throw new Error("Path doesn't exist '" + _path + "'");
+ current = current[path[i]];
+ }
+ if(_path === "/" || isDir(current[path[i]])) {
+ return {
+ isFile: falseFn,
+ isDirectory: trueFn,
+ isBlockDevice: falseFn,
+ isCharacterDevice: falseFn,
+ isSymbolicLink: falseFn,
+ isFIFO: falseFn,
+ isSocket: falseFn
+ };
+ } else if(isFile(current[path[i]])) {
+ return {
+ isFile: trueFn,
+ isDirectory: falseFn,
+ isBlockDevice: falseFn,
+ isCharacterDevice: falseFn,
+ isSymbolicLink: falseFn,
+ isFIFO: falseFn,
+ isSocket: falseFn
+ };
+ } else
+ throw new Error("Path doesn't exist '" + _path + "'");
+};
+
+MemoryFileSystem.prototype.readFileSync = function(_path, encoding) {
+ var path = pathToArray(_path);
+ var current = this.data;
+ for(var i = 0; i < path.length - 1; i++) {
+ if(!isDir(current[path[i]]))
+ throw new Error("Path doesn't exist '" + _path + "'");
+ current = current[path[i]];
+ }
+ if(!isFile(current[path[i]])) {
+ if(isDir(current[path[i]]))
+ throw new Error("Cannot readFile on directory '" + _path + "'");
+ else
+ throw new Error("Path doesn't exist '" + _path + "'");
+ }
+ current = current[path[i]];
+ return encoding ? current.toString(encoding) : current;
+};
+
+MemoryFileSystem.prototype.readdirSync = function(_path) {
+ if(_path === "/") return Object.keys(this.data).filter(Boolean);
+ var path = pathToArray(_path);
+ var current = this.data;
+ for(var i = 0; i < path.length - 1; i++) {
+ if(!isDir(current[path[i]]))
+ throw new Error("Path doesn't exist '" + _path + "'");
+ current = current[path[i]];
+ }
+ if(!isDir(current[path[i]])) {
+ if(isFile(current[path[i]]))
+ throw new Error("Cannot readdir on file '" + _path + "'");
+ else
+ throw new Error("Path doesn't exist '" + _path + "'");
+ }
+ return Object.keys(current[path[i]]).filter(Boolean);
+};
+
+MemoryFileSystem.prototype.mkdirpSync = function(_path) {
+ var path = pathToArray(_path);
+ if(path.length === 0) return;
+ var current = this.data;
+ for(var i = 0; i < path.length; i++) {
+ if(isFile(current[path[i]]))
+ throw new Error("Path is a file '" + _path + "'");
+ else if(!isDir(current[path[i]]))
+ current[path[i]] = {"":true};
+ current = current[path[i]];
+ }
+ return;
+};
+
+MemoryFileSystem.prototype.mkdirSync = function(_path) {
+ var path = pathToArray(_path);
+ if(path.length === 0) return;
+ var current = this.data;
+ for(var i = 0; i < path.length - 1; i++) {
+ if(!isDir(current[path[i]]))
+ throw new Error("Path doesn't exist '" + _path + "'");
+ current = current[path[i]];
+ }
+ if(isDir(current[path[i]]))
+ throw new new Error("Directory already exist '" + _path + "'");
+ else if(isFile(current[path[i]]))
+ throw new Error("Cannot mkdir on file '" + _path + "'");
+ current[path[i]] = {"":true};
+ return;
+};
+
+MemoryFileSystem.prototype._remove = function(_path, name, testFn) {
+ var path = pathToArray(_path);
+ if(path.length === 0) throw new Error("Path cannot be removed '" + _path + "'");
+ var current = this.data;
+ for(var i = 0; i < path.length - 1; i++) {
+ if(!isDir(current[path[i]]))
+ throw new Error("Path doesn't exist '" + _path + "'");
+ current = current[path[i]];
+ }
+ if(!testFn(current[path[i]]))
+ throw new Error("'" + name + "' doesn't exist '" + _path + "'");
+ delete current[path[i]];
+ return;
+};
+
+MemoryFileSystem.prototype.rmdirSync = function(_path) {
+ return this._remove(_path, "Directory", isDir);
+};
+
+MemoryFileSystem.prototype.unlinkSync = function(_path) {
+ return this._remove(_path, "File", isFile);
+};
+
+MemoryFileSystem.prototype.readlinkSync = function(_path) {
+ throw new Error("Path is not a link '" + _path + "'");
+};
+
+MemoryFileSystem.prototype.writeFileSync = function(_path, content, encoding) {
+ if(!content && !encoding) throw new Error("No content");
+ var path = pathToArray(_path);
+ if(path.length === 0) throw new Error("Path is not a file '" + _path + "'");
+ var current = this.data;
+ for(var i = 0; i < path.length - 1; i++) {
+ if(!isDir(current[path[i]]))
+ throw new Error("Path doesn't exist '" + _path + "'");
+ current = current[path[i]];
+ }
+ if(isDir(current[path[i]]))
+ throw new Error("Cannot writeFile on directory '" + _path + "'");
+ current[path[i]] = encoding || typeof content === "string" ? new Buffer(content, encoding) : content;
+ return;
+};
+
+MemoryFileSystem.prototype.join = require("./join");
+
+MemoryFileSystem.prototype.normalize = normalize;
+
+// async functions
+
+["stat", "readdir", "mkdirp", "mkdir", "rmdir", "unlink", "readlink"].forEach(function(fn) {
+ MemoryFileSystem.prototype[fn] = function(path, callback) {
+ try {
+ var result = this[fn + "Sync"](path);
+ } catch(e) {
+ return callback(e);
+ }
+ return callback(null, result);
+ };
+});
+
+MemoryFileSystem.prototype.readFile = function(path, optArg, callback) {
+ if(!callback) {
+ callback = optArg;
+ optArg = undefined;
+ }
+ try {
+ var result = this.readFileSync(path, optArg);
+ } catch(e) {
+ return callback(e);
+ }
+ return callback(null, result);
+};
+
+MemoryFileSystem.prototype.writeFile = function (path, content, encoding, callback) {
+ if(!callback) {
+ callback = encoding;
+ encoding = undefined;
+ }
+ try {
+ this.writeFileSync(path, content, encoding);
+ } catch(e) {
+ return callback(e);
+ }
+ return callback();
+};
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/lib/join.js b/node_modules/enhanced-resolve/node_modules/memory-fs/lib/join.js
new file mode 100644
index 00000000..255e1755
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/lib/join.js
@@ -0,0 +1,14 @@
+var normalize = require("./normalize");
+
+var absoluteWinRegExp = /^[A-Z]:([\\\/]|$)/i;
+var absoluteNixRegExp = /^\//i;
+
+module.exports = function join(path, request) {
+ if(request == "") return normalize(path);
+ if(absoluteWinRegExp.test(request)) return normalize(request.replace(/\//g, "\\"));
+ if(absoluteNixRegExp.test(request)) return normalize(request);
+ if(path == "/") return normalize(path + request);
+ if(absoluteWinRegExp.test(path)) return normalize(path + "\\" + request.replace(/\//g, "\\"));
+ if(absoluteNixRegExp.test(path)) return normalize(path + "/" + request);
+ return normalize(path + "/" + request);
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/lib/normalize.js b/node_modules/enhanced-resolve/node_modules/memory-fs/lib/normalize.js
new file mode 100644
index 00000000..04726d04
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/lib/normalize.js
@@ -0,0 +1,38 @@
+var doubleSlashWinRegExp = /\\+/g;
+var doubleSlashNixRegExp = /\/+/g;
+var currentDirectoryWinMiddleRegExp = /\\(\.\\)+/;
+var currentDirectoryWinEndRegExp = /\\\.$/;
+var parentDirectoryWinMiddleRegExp = /\\+[^\\]+\\+\.\.\\/;
+var parentDirectoryWinEndRegExp1 = /([A-Z]:\\)\\*[^\\]+\\+\.\.$/i;
+var parentDirectoryWinEndRegExp2 = /\\+[^\\]+\\+\.\.$/;
+var currentDirectoryNixMiddleRegExp = /\/+(\.\/)+/;
+var currentDirectoryNixEndRegExp1 = /^\/+\.$/;
+var currentDirectoryNixEndRegExp2 = /\/+\.$/;
+var parentDirectoryNixMiddleRegExp = /(^|\/[^\/]+)\/+\.\.\/+/;
+var parentDirectoryNixEndRegExp1 = /^\/[^\/]+\/+\.\.$/;
+var parentDirectoryNixEndRegExp2 = /\/+[^\/]+\/+\.\.$/;
+var parentDirectoryNixEndRegExp3 = /^\/+\.\.$/;
+
+// RegExp magic :)
+
+module.exports = function normalize(path) {
+ while(currentDirectoryWinMiddleRegExp.test(path))
+ path = path.replace(currentDirectoryWinMiddleRegExp, "\\");
+ path = path.replace(currentDirectoryWinEndRegExp, "");
+ while(parentDirectoryWinMiddleRegExp.test(path))
+ path = path.replace(parentDirectoryWinMiddleRegExp, "\\");
+ path = path.replace(parentDirectoryWinEndRegExp1, "$1");
+ path = path.replace(parentDirectoryWinEndRegExp2, "");
+
+ while(currentDirectoryNixMiddleRegExp.test(path))
+ path = path.replace(currentDirectoryNixMiddleRegExp, "/");
+ path = path.replace(currentDirectoryNixEndRegExp1, "/");
+ path = path.replace(currentDirectoryNixEndRegExp2, "");
+ while(parentDirectoryNixMiddleRegExp.test(path))
+ path = path.replace(parentDirectoryNixMiddleRegExp, "/");
+ path = path.replace(parentDirectoryNixEndRegExp1, "/");
+ path = path.replace(parentDirectoryNixEndRegExp2, "");
+ path = path.replace(parentDirectoryNixEndRegExp3, "/");
+
+ return path.replace(doubleSlashWinRegExp, "\\").replace(doubleSlashNixRegExp, "/");
+};
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/package.json b/node_modules/enhanced-resolve/node_modules/memory-fs/package.json
new file mode 100644
index 00000000..35e64c96
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/package.json
@@ -0,0 +1,89 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "memory-fs@^0.2.0",
+ "scope": null,
+ "escapedName": "memory-fs",
+ "name": "memory-fs",
+ "rawSpec": "^0.2.0",
+ "spec": ">=0.2.0 <0.3.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/enhanced-resolve"
+ ]
+ ],
+ "_from": "memory-fs@>=0.2.0 <0.3.0",
+ "_id": "memory-fs@0.2.0",
+ "_inCache": true,
+ "_location": "/enhanced-resolve/memory-fs",
+ "_npmUser": {
+ "name": "sokra",
+ "email": "tobias.koppers@googlemail.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "memory-fs@^0.2.0",
+ "scope": null,
+ "escapedName": "memory-fs",
+ "name": "memory-fs",
+ "rawSpec": "^0.2.0",
+ "spec": ">=0.2.0 <0.3.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/enhanced-resolve"
+ ],
+ "_resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.2.0.tgz",
+ "_shasum": "f2bb25368bc121e391c2520de92969caee0a0290",
+ "_shrinkwrap": null,
+ "_spec": "memory-fs@^0.2.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/enhanced-resolve",
+ "author": {
+ "name": "Tobias Koppers @sokra"
+ },
+ "bugs": {
+ "url": "https://github.com/webpack/memory-fs/issues"
+ },
+ "dependencies": {},
+ "description": "A simple in-memory filesystem. Holds data in a javascript object.",
+ "devDependencies": {
+ "istanbul": "^0.2.13",
+ "mocha": "^1.20.1",
+ "should": "^4.0.4"
+ },
+ "directories": {
+ "test": "test"
+ },
+ "dist": {
+ "shasum": "f2bb25368bc121e391c2520de92969caee0a0290",
+ "tarball": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.2.0.tgz"
+ },
+ "gitHead": "b90785340f2adf4eed77c59bdda7742a51d16e5e",
+ "homepage": "https://github.com/webpack/memory-fs",
+ "keywords": [
+ "fs",
+ "memory"
+ ],
+ "license": "MIT",
+ "main": "lib/MemoryFileSystem.js",
+ "maintainers": [
+ {
+ "name": "sokra",
+ "email": "tobias.koppers@googlemail.com"
+ }
+ ],
+ "name": "memory-fs",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/webpack/memory-fs.git"
+ },
+ "scripts": {
+ "cover": "istanbul cover node_modules/mocha/bin/_mocha -- -R spec",
+ "test": "mocha -R spec"
+ },
+ "version": "0.2.0"
+}
diff --git a/node_modules/enhanced-resolve/node_modules/memory-fs/test/MemoryFileSystem.js b/node_modules/enhanced-resolve/node_modules/memory-fs/test/MemoryFileSystem.js
new file mode 100644
index 00000000..49446181
--- /dev/null
+++ b/node_modules/enhanced-resolve/node_modules/memory-fs/test/MemoryFileSystem.js
@@ -0,0 +1,362 @@
+var should = require("should");
+var MemoryFileSystem = require("../lib/MemoryFileSystem");
+
+describe("directory", function() {
+ it("should have a empty root directory as startup", function(done) {
+ var fs = new MemoryFileSystem();
+ fs.readdirSync("/").should.be.eql([]);
+ var stat = fs.statSync("/");
+ stat.isFile().should.be.eql(false);
+ stat.isDirectory().should.be.eql(true);
+ fs.readdir("/", function(err, files) {
+ if(err) throw err;
+ files.should.be.eql([]);
+ done();
+ });
+ });
+ it("should make and remove directories (linux style)", function() {
+ var fs = new MemoryFileSystem();
+ fs.mkdirSync("/test");
+ fs.mkdirSync("/test//sub/");
+ fs.mkdirpSync("/test/sub2");
+ fs.mkdirSync("/root\\dir");
+ fs.mkdirpSync("/");
+ fs.mkdirSync("/");
+ fs.readdirSync("/").should.be.eql(["test", "root\\dir"]);
+ fs.readdirSync("/test/").should.be.eql(["sub", "sub2"]);
+ fs.rmdirSync("/test/sub//");
+ fs.readdirSync("//test").should.be.eql(["sub2"]);
+ fs.rmdirSync("/test/sub2");
+ fs.rmdirSync("/test");
+ (function() {
+ fs.readdirSync("/test");
+ }).should.throw();
+ fs.readdirSync("/").should.be.eql(["root\\dir"]);
+ fs.mkdirpSync("/a/depth/sub/dir");
+ var stat = fs.statSync("/a/depth/sub");
+ stat.isFile().should.be.eql(false);
+ stat.isDirectory().should.be.eql(true);
+ });
+ it("should make and remove directories (windows style)", function() {
+ var fs = new MemoryFileSystem();
+ fs.mkdirSync("C:\\");
+ fs.mkdirSync("C:\\test");
+ fs.mkdirSync("C:\\test\\\\sub/");
+ fs.mkdirpSync("c:\\test/sub2");
+ fs.mkdirSync("C:\\root-dir");
+ fs.readdirSync("C:").should.be.eql(["test", "root-dir"]);
+ fs.readdirSync("C:/test/").should.be.eql(["sub", "sub2"]);
+ fs.rmdirSync("C:/test\\sub\\\\");
+ fs.readdirSync("C:\\\\test").should.be.eql(["sub2"]);
+ fs.rmdirSync("C:\\test\\sub2");
+ fs.rmdirSync("C:\\test");
+ (function() {
+ fs.readdirSync("C:\\test");
+ }).should.throw();
+ fs.readdirSync("C:").should.be.eql(["root-dir"]);
+ fs.mkdirpSync("D:\\a\\depth\\sub\\dir");
+ var stat = fs.statSync("D:\\a\\depth\\sub");
+ stat.isFile().should.be.eql(false);
+ stat.isDirectory().should.be.eql(true);
+ fs.readdirSync("D:\\//a/depth/\\sub").should.be.eql(["dir"]);
+ });
+});
+describe("files", function() {
+ it("should make and remove files", function() {
+ var fs = new MemoryFileSystem();
+ fs.mkdirSync("/test");
+ var buf = new Buffer("Hello World", "utf-8");
+ fs.writeFileSync("/test/hello-world.txt", buf);
+ fs.readFileSync("/test/hello-world.txt").should.be.eql(buf);
+ fs.readFileSync("/test/hello-world.txt", "utf-8").should.be.eql("Hello World");
+ (function() {
+ fs.readFileSync("/test/other-file");
+ }).should.throw();
+ (function() {
+ fs.readFileSync("/test/other-file", "utf-8");
+ }).should.throw();
+ fs.writeFileSync("/a", "Test", "utf-8");
+ fs.readFileSync("/a", "utf-8").should.be.eql("Test");
+ var stat = fs.statSync("/a");
+ stat.isFile().should.be.eql(true);
+ stat.isDirectory().should.be.eql(false);
+ });
+});
+describe("errors", function() {
+ it("should fail on invalid paths", function() {
+ var fs = new MemoryFileSystem();
+ fs.mkdirpSync("/test/a/b/c");
+ fs.mkdirpSync("/test/a/bc");
+ fs.mkdirpSync("/test/abc");
+ (function() {
+ fs.mkdirpSync("xyz");
+ }).should.throw();
+ (function() {
+ fs.readdirSync("/test/abc/a/b/c");
+ }).should.throw();
+ (function() {
+ fs.readdirSync("/abc");
+ }).should.throw();
+ (function() {
+ fs.statSync("/abc");
+ }).should.throw();
+ (function() {
+ fs.mkdirSync("/test/a/d/b/c");
+ }).should.throw();
+ (function() {
+ fs.writeFileSync("/test/a/d/b/c", "Hello");
+ }).should.throw();
+ (function() {
+ fs.readFileSync("/test/a/d/b/c");
+ }).should.throw();
+ (function() {
+ fs.readFileSync("/test/abcd");
+ }).should.throw();
+ (function() {
+ fs.mkdirSync("/test/abcd/dir");
+ }).should.throw();
+ (function() {
+ fs.unlinkSync("/test/abcd");
+ }).should.throw();
+ (function() {
+ fs.unlinkSync("/test/abcd/file");
+ }).should.throw();
+ (function() {
+ fs.statSync("/test/a/d/b/c");
+ }).should.throw();
+ (function() {
+ fs.statSync("/test/abcd");
+ }).should.throw();
+ fs.mkdir("/test/a/d/b/c", function(err) {
+ err.should.be.instanceof(Error);
+ });
+ });
+ it("should fail incorrect arguments", function() {
+ var fs = new MemoryFileSystem();
+ (function() {
+ fs.writeFileSync("/test");
+ }).should.throw();
+ });
+ it("should fail on wrong type", function() {
+ var fs = new MemoryFileSystem();
+ fs.mkdirpSync("/test/dir");
+ fs.mkdirpSync("/test/dir");
+ fs.writeFileSync("/test/file", "Hello");
+ (function() {
+ fs.writeFileSync("/test/dir", "Hello");
+ }).should.throw();
+ (function() {
+ fs.readFileSync("/test/dir");
+ }).should.throw();
+ (function() {
+ fs.writeFileSync("/", "Hello");
+ }).should.throw();
+ (function() {
+ fs.rmdirSync("/");
+ }).should.throw();
+ (function() {
+ fs.unlinkSync("/");
+ }).should.throw();
+ (function() {
+ fs.mkdirSync("/test/dir");
+ }).should.throw();
+ (function() {
+ fs.mkdirSync("/test/file");
+ }).should.throw();
+ (function() {
+ fs.mkdirpSync("/test/file");
+ }).should.throw();
+ (function() {
+ fs.readdirSync("/test/file");
+ }).should.throw();
+ fs.readdirSync("/test/").should.be.eql(["dir", "file"]);
+ });
+ it("should throw on readlink", function() {
+ var fs = new MemoryFileSystem();
+ fs.mkdirpSync("/test/dir");
+ (function() {
+ fs.readlinkSync("/");
+ }).should.throw();
+ (function() {
+ fs.readlinkSync("/link");
+ }).should.throw();
+ (function() {
+ fs.readlinkSync("/test");
+ }).should.throw();
+ (function() {
+ fs.readlinkSync("/test/dir");
+ }).should.throw();
+ (function() {
+ fs.readlinkSync("/test/dir/link");
+ }).should.throw();
+ });
+});
+describe("async", function() {
+ it("should be able to use the async versions", function(done) {
+ var fs = new MemoryFileSystem();
+ fs.mkdirp("/test/dir", function(err) {
+ if(err) throw err;
+ fs.writeFile("/test/dir/a", "Hello", function(err) {
+ if(err) throw err;
+ fs.writeFile("/test/dir/b", "World", "utf-8", function(err) {
+ if(err) throw err;
+ fs.readFile("/test/dir/a", "utf-8", function(err, content) {
+ if(err) throw err;
+ content.should.be.eql("Hello");
+ fs.readFile("/test/dir/b", function(err, content) {
+ if(err) throw err;
+ content.should.be.eql(new Buffer("World"));
+ done();
+ });
+ });
+ });
+ });
+ });
+ });
+ it("should return errors", function(done) {
+ var fs = new MemoryFileSystem();
+ fs.readFile("/fail/file", function(err, content) {
+ err.should.be.instanceof(Error);
+ fs.writeFile("/fail/file", "", function(err) {
+ err.should.be.instanceof(Error);
+ done();
+ });
+ });
+ });
+});
+describe("normalize", function() {
+ it("should normalize paths", function() {
+ var fs = new MemoryFileSystem();
+ fs.normalize("/a/b/c").should.be.eql("/a/b/c");
+ fs.normalize("/a//b/c").should.be.eql("/a/b/c");
+ fs.normalize("/a//b//c").should.be.eql("/a/b/c");
+ fs.normalize("//a//b//c").should.be.eql("/a/b/c");
+ fs.normalize("/a/////b/c").should.be.eql("/a/b/c");
+ fs.normalize("/./a/d///..////b/c").should.be.eql("/a/b/c");
+ fs.normalize("/..").should.be.eql("/");
+ fs.normalize("/.").should.be.eql("/");
+ fs.normalize("/.git").should.be.eql("/.git");
+ fs.normalize("/a/b/c/.git").should.be.eql("/a/b/c/.git");
+ fs.normalize("/a/b/c/..git").should.be.eql("/a/b/c/..git");
+ fs.normalize("/a/b/c/..").should.be.eql("/a/b");
+ fs.normalize("/a/b/c/../..").should.be.eql("/a");
+ fs.normalize("/a/b/c/../../..").should.be.eql("/");
+ fs.normalize("C:\\a\\..").should.be.eql("C:\\");
+ fs.normalize("C:\\a\\b\\..").should.be.eql("C:\\a");
+ fs.normalize("C:\\a\\b\\\c\\..\\..").should.be.eql("C:\\a");
+ fs.normalize("C:\\a\\b\\d\\..\\c\\..\\..").should.be.eql("C:\\a");
+ fs.normalize("C:\\a\\b\\d\\\\.\\\\.\\c\\.\\..").should.be.eql("C:\\a\\b\\d");
+ });
+});
+describe("join", function() {
+ it("should join paths", function() {
+ var fs = new MemoryFileSystem();
+ fs.join("/", "a/b/c").should.be.eql("/a/b/c");
+ fs.join("/a", "b/c").should.be.eql("/a/b/c");
+ fs.join("/a/b", "c").should.be.eql("/a/b/c");
+ fs.join("/a/", "b/c").should.be.eql("/a/b/c");
+ fs.join("/a//", "b/c").should.be.eql("/a/b/c");
+ fs.join("a", "b/c").should.be.eql("a/b/c");
+ fs.join("a/b", "c").should.be.eql("a/b/c");
+ fs.join("C:", "a/b").should.be.eql("C:\\a\\b");
+ fs.join("C:\\", "a/b").should.be.eql("C:\\a\\b");
+ fs.join("C:\\", "a\\b").should.be.eql("C:\\a\\b");
+ });
+ it("should join paths (weird cases)", function() {
+ var fs = new MemoryFileSystem();
+ fs.join("/", "").should.be.eql("/");
+ fs.join("/a/b/", "").should.be.eql("/a/b/");
+ fs.join("/a/b/c", "").should.be.eql("/a/b/c");
+ fs.join("C:", "").should.be.eql("C:");
+ fs.join("C:\\a\\b", "").should.be.eql("C:\\a\\b");
+ });
+ it("should join paths (absolute request)", function() {
+ var fs = new MemoryFileSystem();
+ fs.join("/a/b/c", "/d/e/f").should.be.eql("/d/e/f");
+ fs.join("C:\\a\\b\\c", "/d/e/f").should.be.eql("/d/e/f");
+ fs.join("/a/b/c", "C:\\d\\e\\f").should.be.eql("C:\\d\\e\\f");
+ fs.join("C:\\a\\b\\c", "C:\\d\\e\\f").should.be.eql("C:\\d\\e\\f");
+ });
+});
+describe("os", function() {
+ var fileSystem;
+
+ beforeEach(function() {
+ fileSystem = new MemoryFileSystem({
+ "": true,
+ a: {
+ "": true,
+ index: new Buffer("1"), // /a/index
+ dir: {
+ "": true,
+ index: new Buffer("2") // /a/dir/index
+ }
+ },
+ "C:": {
+ "": true,
+ a: {
+ "": true,
+ index: new Buffer("3"), // C:\files\index
+ dir: {
+ "": true,
+ index: new Buffer("4") // C:\files\a\index
+ }
+ }
+ }
+ });
+ });
+
+ describe("unix", function() {
+ it("should stat stuff", function() {
+ fileSystem.statSync("/a").isDirectory().should.be.eql(true);
+ fileSystem.statSync("/a").isFile().should.be.eql(false);
+ fileSystem.statSync("/a/index").isDirectory().should.be.eql(false);
+ fileSystem.statSync("/a/index").isFile().should.be.eql(true);
+ fileSystem.statSync("/a/dir").isDirectory().should.be.eql(true);
+ fileSystem.statSync("/a/dir").isFile().should.be.eql(false);
+ fileSystem.statSync("/a/dir/index").isDirectory().should.be.eql(false);
+ fileSystem.statSync("/a/dir/index").isFile().should.be.eql(true);
+ });
+ it("should readdir directories", function() {
+ fileSystem.readdirSync("/a").should.be.eql(["index", "dir"]);
+ fileSystem.readdirSync("/a/dir").should.be.eql(["index"]);
+ });
+ it("should readdir directories", function() {
+ fileSystem.readFileSync("/a/index", "utf-8").should.be.eql("1");
+ fileSystem.readFileSync("/a/dir/index", "utf-8").should.be.eql("2");
+ });
+ it("should also accept multi slashs", function() {
+ fileSystem.statSync("/a///dir//index").isFile().should.be.eql(true);
+ });
+ });
+
+ describe("windows", function() {
+ it("should stat stuff", function() {
+ fileSystem.statSync("C:\\a").isDirectory().should.be.eql(true);
+ fileSystem.statSync("C:\\a").isFile().should.be.eql(false);
+ fileSystem.statSync("C:\\a\\index").isDirectory().should.be.eql(false);
+ fileSystem.statSync("C:\\a\\index").isFile().should.be.eql(true);
+ fileSystem.statSync("C:\\a\\dir").isDirectory().should.be.eql(true);
+ fileSystem.statSync("C:\\a\\dir").isFile().should.be.eql(false);
+ fileSystem.statSync("C:\\a\\dir\\index").isDirectory().should.be.eql(false);
+ fileSystem.statSync("C:\\a\\dir\\index").isFile().should.be.eql(true);
+ });
+ it("should readdir directories", function() {
+ fileSystem.readdirSync("C:\\a").should.be.eql(["index", "dir"]);
+ fileSystem.readdirSync("C:\\a\\dir").should.be.eql(["index"]);
+ });
+ it("should readdir directories", function() {
+ fileSystem.readFileSync("C:\\a\\index", "utf-8").should.be.eql("3");
+ fileSystem.readFileSync("C:\\a\\dir\\index", "utf-8").should.be.eql("4");
+ });
+ it("should also accept multi slashs", function() {
+ fileSystem.statSync("C:\\\\a\\\\\\dir\\\\index").isFile().should.be.eql(true);
+ });
+ it("should also accept a normal slash", function() {
+ fileSystem.statSync("C:\\a\\dir/index").isFile().should.be.eql(true);
+ fileSystem.statSync("C:\\a\\dir\\index").isFile().should.be.eql(true);
+ fileSystem.statSync("C:\\a/dir/index").isFile().should.be.eql(true);
+ fileSystem.statSync("C:\\a/dir\\index").isFile().should.be.eql(true);
+ });
+ });
+});
\ No newline at end of file
diff --git a/node_modules/enhanced-resolve/package.json b/node_modules/enhanced-resolve/package.json
new file mode 100644
index 00000000..c9669f78
--- /dev/null
+++ b/node_modules/enhanced-resolve/package.json
@@ -0,0 +1,99 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "enhanced-resolve@~0.9.0",
+ "scope": null,
+ "escapedName": "enhanced-resolve",
+ "name": "enhanced-resolve",
+ "rawSpec": "~0.9.0",
+ "spec": ">=0.9.0 <0.10.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/webpack"
+ ]
+ ],
+ "_from": "enhanced-resolve@>=0.9.0 <0.10.0",
+ "_id": "enhanced-resolve@0.9.1",
+ "_inCache": true,
+ "_location": "/enhanced-resolve",
+ "_nodeVersion": "4.0.0",
+ "_npmUser": {
+ "name": "sokra",
+ "email": "tobias.koppers@googlemail.com"
+ },
+ "_npmVersion": "3.3.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "enhanced-resolve@~0.9.0",
+ "scope": null,
+ "escapedName": "enhanced-resolve",
+ "name": "enhanced-resolve",
+ "rawSpec": "~0.9.0",
+ "spec": ">=0.9.0 <0.10.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/webpack"
+ ],
+ "_resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-0.9.1.tgz",
+ "_shasum": "4d6e689b3725f86090927ccc86cd9f1635b89e2e",
+ "_shrinkwrap": null,
+ "_spec": "enhanced-resolve@~0.9.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/webpack",
+ "author": {
+ "name": "Tobias Koppers @sokra"
+ },
+ "bugs": {
+ "url": "https://github.com/webpack/enhanced-resolve/issues"
+ },
+ "dependencies": {
+ "graceful-fs": "^4.1.2",
+ "memory-fs": "^0.2.0",
+ "tapable": "^0.1.8"
+ },
+ "description": "Offers a async require.resolve function. It's highly configurable.",
+ "devDependencies": {
+ "istanbul": "^0.3.5",
+ "mocha": "^2.1.0",
+ "should": "^4.6.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "4d6e689b3725f86090927ccc86cd9f1635b89e2e",
+ "tarball": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-0.9.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.6"
+ },
+ "files": [
+ "lib"
+ ],
+ "gitHead": "1d14a6debbe4054f84d7d7f870ca0a1cb963f75b",
+ "homepage": "http://github.com/webpack/enhanced-resolve",
+ "licenses": [
+ {
+ "type": "MIT",
+ "url": "http://www.opensource.org/licenses/mit-license.php"
+ }
+ ],
+ "main": "lib/node.js",
+ "maintainers": [
+ {
+ "name": "sokra",
+ "email": "tobias.koppers@googlemail.com"
+ }
+ ],
+ "name": "enhanced-resolve",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/webpack/enhanced-resolve.git"
+ },
+ "scripts": {
+ "cover": "istanbul cover node_modules/mocha/bin/_mocha -- -R spec",
+ "test": "mocha --reporter spec"
+ },
+ "version": "0.9.1"
+}
diff --git a/node_modules/errno/.jshintrc b/node_modules/errno/.jshintrc
new file mode 100644
index 00000000..c8ef3ca4
--- /dev/null
+++ b/node_modules/errno/.jshintrc
@@ -0,0 +1,59 @@
+{
+ "predef": [ ]
+ , "bitwise": false
+ , "camelcase": false
+ , "curly": false
+ , "eqeqeq": false
+ , "forin": false
+ , "immed": false
+ , "latedef": false
+ , "noarg": true
+ , "noempty": true
+ , "nonew": true
+ , "plusplus": false
+ , "quotmark": true
+ , "regexp": false
+ , "undef": true
+ , "unused": true
+ , "strict": false
+ , "trailing": true
+ , "maxlen": 120
+ , "asi": true
+ , "boss": true
+ , "debug": true
+ , "eqnull": true
+ , "esnext": true
+ , "evil": true
+ , "expr": true
+ , "funcscope": false
+ , "globalstrict": false
+ , "iterator": false
+ , "lastsemic": true
+ , "laxbreak": true
+ , "laxcomma": true
+ , "loopfunc": true
+ , "multistr": false
+ , "onecase": false
+ , "proto": false
+ , "regexdash": false
+ , "scripturl": true
+ , "smarttabs": false
+ , "shadow": false
+ , "sub": true
+ , "supernew": false
+ , "validthis": true
+ , "browser": true
+ , "couch": false
+ , "devel": false
+ , "dojo": false
+ , "mootools": false
+ , "node": true
+ , "nonstandard": true
+ , "prototypejs": false
+ , "rhino": false
+ , "worker": true
+ , "wsh": false
+ , "nomen": false
+ , "onevar": false
+ , "passfail": false
+}
\ No newline at end of file
diff --git a/node_modules/errno/.npmignore b/node_modules/errno/.npmignore
new file mode 100644
index 00000000..b512c09d
--- /dev/null
+++ b/node_modules/errno/.npmignore
@@ -0,0 +1 @@
+node_modules
\ No newline at end of file
diff --git a/node_modules/errno/README.md b/node_modules/errno/README.md
new file mode 100644
index 00000000..2c1f8a52
--- /dev/null
+++ b/node_modules/errno/README.md
@@ -0,0 +1,141 @@
+# node-errno
+
+Better [libuv](https://github.com/libuv/libuv)/[Node.js](https://nodejs.org)/[io.js](https://iojs.org) error handling & reporting. Available in npm as *errno*.
+
+* [errno exposed](#errnoexposed)
+* [Custom errors](#customerrors)
+
+
+## errno exposed
+
+Ever find yourself needing more details about Node.js errors? Me too, so *node-errno* contains the errno mappings direct from libuv so you can use them in your code.
+
+**By errno:**
+
+```js
+require('errno').errno[3]
+// → {
+// "errno": 3,
+// "code": "EACCES",
+// "description": "permission denied"
+// }
+```
+
+**By code:**
+
+```js
+require('errno').code.ENOTEMPTY
+// → {
+// "errno": 53,
+// "code": "ENOTEMPTY",
+// "description": "directory not empty"
+// }
+```
+
+**Make your errors more descriptive:**
+
+```js
+var errno = require('errno')
+
+function errmsg(err) {
+ var str = 'Error: '
+ // if it's a libuv error then get the description from errno
+ if (errno.errno[err.errno])
+ str += errno.errno[err.errno].description
+ else
+ str += err.message
+
+ // if it's a `fs` error then it'll have a 'path' property
+ if (err.path)
+ str += ' [' + err.path + ']'
+
+ return str
+}
+
+var fs = require('fs')
+
+fs.readFile('thisisnotarealfile.txt', function (err, data) {
+ if (err)
+ console.log(errmsg(err))
+})
+```
+
+**Use as a command line tool:**
+
+```
+~ $ errno 53
+{
+ "errno": 53,
+ "code": "ENOTEMPTY",
+ "description": "directory not empty"
+}
+~ $ errno EROFS
+{
+ "errno": 56,
+ "code": "EROFS",
+ "description": "read-only file system"
+}
+~ $ errno foo
+No such errno/code: "foo"
+```
+
+Supply no arguments for the full list. Error codes are processed case-insensitive.
+
+You will need to install with `npm install errno -g` if you want the `errno` command to be available without supplying a full path to the node_modules installation.
+
+
+## Custom errors
+
+Use `errno.custom.createError()` to create custom `Error` objects to throw around in your Node.js library. Create error heirachies so `instanceof` becomes a useful tool in tracking errors. Call-stack is correctly captured at the time you create an instance of the error object, plus a `cause` property will make available the original error object if you pass one in to the constructor.
+
+```js
+var create = require('errno').custom.createError
+var MyError = create('MyError') // inherits from Error
+var SpecificError = create('SpecificError', MyError) // inherits from MyError
+var OtherError = create('OtherError', MyError)
+
+// use them!
+if (condition) throw new SpecificError('Eeek! Something bad happened')
+
+if (err) return callback(new OtherError(err))
+```
+
+Also available is a `errno.custom.FilesystemError` with in-built access to errno properties:
+
+```js
+fs.readFile('foo', function (err, data) {
+ if (err) return callback(new errno.custom.FilesystemError(err))
+ // do something else
+})
+```
+
+The resulting error object passed through the callback will have the following properties: `code`, `errno`, `path` and `message` will contain a descriptive human-readable message.
+
+## Contributors
+
+* [bahamas10](https://github.com/bahamas10) (Dave Eddy) - Added CLI
+* [ralphtheninja](https://github.com/ralphtheninja) (Lars-Magnus Skog)
+
+## Copyright & Licence
+
+*Copyright (c) 2012-2015 [Rod Vagg](https://github.com/rvagg) ([@rvagg](https://twitter.com/rvagg))*
+
+Made available under the MIT licence:
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is furnished
+to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
\ No newline at end of file
diff --git a/node_modules/errno/build.js b/node_modules/errno/build.js
new file mode 100755
index 00000000..fce89260
--- /dev/null
+++ b/node_modules/errno/build.js
@@ -0,0 +1,43 @@
+#!/usr/bin/env node
+
+var request = require('request')
+ , fs = require('fs')
+
+ , uvheadloc = 'https://raw.github.com/joyent/libuv/master/include/uv.h'
+ , defreg = /^\s*XX\(\s*([\-\d]+),\s*([A-Z]+),\s*"([^"]*)"\s*\)\s*\\?$/
+
+
+request(uvheadloc, function (err, response) {
+ if (err)
+ throw err
+
+ var data, out
+
+ data = response.body
+ .split('\n')
+ .map(function (line) { return line.match(defreg) })
+ .filter(function (match) { return match })
+ .map(function (match) { return {
+ errno: parseInt(match[1], 10)
+ , code: match[2]
+ , description: match[3]
+ }})
+
+ out = 'var all = module.exports.all = ' + JSON.stringify(data, 0, 1) + '\n\n'
+
+ out += '\nmodule.exports.errno = {\n '
+ + data.map(function (e, i) {
+ return '\'' + e.errno + '\': all[' + i + ']'
+ }).join('\n , ')
+ + '\n}\n\n'
+
+ out += '\nmodule.exports.code = {\n '
+ + data.map(function (e, i) {
+ return '\'' + e.code + '\': all[' + i + ']'
+ }).join('\n , ')
+ + '\n}\n\n'
+
+ out += '\nmodule.exports.custom = require("./custom")(module.exports)\n'
+
+ fs.writeFile('errno.js', out)
+})
\ No newline at end of file
diff --git a/node_modules/errno/cli.js b/node_modules/errno/cli.js
new file mode 100755
index 00000000..f841771b
--- /dev/null
+++ b/node_modules/errno/cli.js
@@ -0,0 +1,20 @@
+#!/usr/bin/env node
+
+var errno = require('./')
+ , arg = process.argv[2]
+ , data, code
+
+if (arg === undefined)
+ return console.log(JSON.stringify(errno.code, null, 2))
+
+if ((code = +arg) == arg)
+ data = errno.errno[code]
+else
+ data = errno.code[arg] || errno.code[arg.toUpperCase()]
+
+if (data)
+ console.log(JSON.stringify(data, null, 2))
+else {
+ console.error('No such errno/code: "' + arg + '"')
+ process.exit(1)
+}
\ No newline at end of file
diff --git a/node_modules/errno/custom.js b/node_modules/errno/custom.js
new file mode 100644
index 00000000..7be16c1e
--- /dev/null
+++ b/node_modules/errno/custom.js
@@ -0,0 +1,55 @@
+var prr = require('prr')
+
+function init (type, message, cause) {
+ prr(this, {
+ type : type
+ , name : type
+ // can be passed just a 'cause'
+ , cause : typeof message != 'string' ? message : cause
+ , message : !!message && typeof message != 'string' ? message.message : message
+
+ }, 'ewr')
+}
+
+// generic prototype, not intended to be actually used - helpful for `instanceof`
+function CustomError (message, cause) {
+ Error.call(this)
+ if (Error.captureStackTrace)
+ Error.captureStackTrace(this, arguments.callee)
+ init.call(this, 'CustomError', message, cause)
+}
+
+CustomError.prototype = new Error()
+
+function createError (errno, type, proto) {
+ var err = function (message, cause) {
+ init.call(this, type, message, cause)
+ //TODO: the specificity here is stupid, errno should be available everywhere
+ if (type == 'FilesystemError') {
+ this.code = this.cause.code
+ this.path = this.cause.path
+ this.errno = this.cause.errno
+ this.message =
+ (errno.errno[this.cause.errno]
+ ? errno.errno[this.cause.errno].description
+ : this.cause.message)
+ + (this.cause.path ? ' [' + this.cause.path + ']' : '')
+ }
+ Error.call(this)
+ if (Error.captureStackTrace)
+ Error.captureStackTrace(this, arguments.callee)
+ }
+ err.prototype = !!proto ? new proto() : new CustomError()
+ return err
+}
+
+module.exports = function (errno) {
+ var ce = function (type, proto) {
+ return createError(errno, type, proto)
+ }
+ return {
+ CustomError : CustomError
+ , FilesystemError : ce('FilesystemError')
+ , createError : ce
+ }
+}
diff --git a/node_modules/errno/errno.js b/node_modules/errno/errno.js
new file mode 100644
index 00000000..efb79d41
--- /dev/null
+++ b/node_modules/errno/errno.js
@@ -0,0 +1,313 @@
+var all = module.exports.all = [
+ {
+ errno: -2,
+ code: 'ENOENT',
+ description: 'no such file or directory'
+ },
+ {
+ errno: -1,
+ code: 'UNKNOWN',
+ description: 'unknown error'
+ },
+ {
+ errno: 0,
+ code: 'OK',
+ description: 'success'
+ },
+ {
+ errno: 1,
+ code: 'EOF',
+ description: 'end of file'
+ },
+ {
+ errno: 2,
+ code: 'EADDRINFO',
+ description: 'getaddrinfo error'
+ },
+ {
+ errno: 3,
+ code: 'EACCES',
+ description: 'permission denied'
+ },
+ {
+ errno: 4,
+ code: 'EAGAIN',
+ description: 'resource temporarily unavailable'
+ },
+ {
+ errno: 5,
+ code: 'EADDRINUSE',
+ description: 'address already in use'
+ },
+ {
+ errno: 6,
+ code: 'EADDRNOTAVAIL',
+ description: 'address not available'
+ },
+ {
+ errno: 7,
+ code: 'EAFNOSUPPORT',
+ description: 'address family not supported'
+ },
+ {
+ errno: 8,
+ code: 'EALREADY',
+ description: 'connection already in progress'
+ },
+ {
+ errno: 9,
+ code: 'EBADF',
+ description: 'bad file descriptor'
+ },
+ {
+ errno: 10,
+ code: 'EBUSY',
+ description: 'resource busy or locked'
+ },
+ {
+ errno: 11,
+ code: 'ECONNABORTED',
+ description: 'software caused connection abort'
+ },
+ {
+ errno: 12,
+ code: 'ECONNREFUSED',
+ description: 'connection refused'
+ },
+ {
+ errno: 13,
+ code: 'ECONNRESET',
+ description: 'connection reset by peer'
+ },
+ {
+ errno: 14,
+ code: 'EDESTADDRREQ',
+ description: 'destination address required'
+ },
+ {
+ errno: 15,
+ code: 'EFAULT',
+ description: 'bad address in system call argument'
+ },
+ {
+ errno: 16,
+ code: 'EHOSTUNREACH',
+ description: 'host is unreachable'
+ },
+ {
+ errno: 17,
+ code: 'EINTR',
+ description: 'interrupted system call'
+ },
+ {
+ errno: 18,
+ code: 'EINVAL',
+ description: 'invalid argument'
+ },
+ {
+ errno: 19,
+ code: 'EISCONN',
+ description: 'socket is already connected'
+ },
+ {
+ errno: 20,
+ code: 'EMFILE',
+ description: 'too many open files'
+ },
+ {
+ errno: 21,
+ code: 'EMSGSIZE',
+ description: 'message too long'
+ },
+ {
+ errno: 22,
+ code: 'ENETDOWN',
+ description: 'network is down'
+ },
+ {
+ errno: 23,
+ code: 'ENETUNREACH',
+ description: 'network is unreachable'
+ },
+ {
+ errno: 24,
+ code: 'ENFILE',
+ description: 'file table overflow'
+ },
+ {
+ errno: 25,
+ code: 'ENOBUFS',
+ description: 'no buffer space available'
+ },
+ {
+ errno: 26,
+ code: 'ENOMEM',
+ description: 'not enough memory'
+ },
+ {
+ errno: 27,
+ code: 'ENOTDIR',
+ description: 'not a directory'
+ },
+ {
+ errno: 28,
+ code: 'EISDIR',
+ description: 'illegal operation on a directory'
+ },
+ {
+ errno: 29,
+ code: 'ENONET',
+ description: 'machine is not on the network'
+ },
+ {
+ errno: 31,
+ code: 'ENOTCONN',
+ description: 'socket is not connected'
+ },
+ {
+ errno: 32,
+ code: 'ENOTSOCK',
+ description: 'socket operation on non-socket'
+ },
+ {
+ errno: 33,
+ code: 'ENOTSUP',
+ description: 'operation not supported on socket'
+ },
+ {
+ errno: 34,
+ code: 'ENOENT',
+ description: 'no such file or directory'
+ },
+ {
+ errno: 35,
+ code: 'ENOSYS',
+ description: 'function not implemented'
+ },
+ {
+ errno: 36,
+ code: 'EPIPE',
+ description: 'broken pipe'
+ },
+ {
+ errno: 37,
+ code: 'EPROTO',
+ description: 'protocol error'
+ },
+ {
+ errno: 38,
+ code: 'EPROTONOSUPPORT',
+ description: 'protocol not supported'
+ },
+ {
+ errno: 39,
+ code: 'EPROTOTYPE',
+ description: 'protocol wrong type for socket'
+ },
+ {
+ errno: 40,
+ code: 'ETIMEDOUT',
+ description: 'connection timed out'
+ },
+ {
+ errno: 41,
+ code: 'ECHARSET',
+ description: 'invalid Unicode character'
+ },
+ {
+ errno: 42,
+ code: 'EAIFAMNOSUPPORT',
+ description: 'address family for hostname not supported'
+ },
+ {
+ errno: 44,
+ code: 'EAISERVICE',
+ description: 'servname not supported for ai_socktype'
+ },
+ {
+ errno: 45,
+ code: 'EAISOCKTYPE',
+ description: 'ai_socktype not supported'
+ },
+ {
+ errno: 46,
+ code: 'ESHUTDOWN',
+ description: 'cannot send after transport endpoint shutdown'
+ },
+ {
+ errno: 47,
+ code: 'EEXIST',
+ description: 'file already exists'
+ },
+ {
+ errno: 48,
+ code: 'ESRCH',
+ description: 'no such process'
+ },
+ {
+ errno: 49,
+ code: 'ENAMETOOLONG',
+ description: 'name too long'
+ },
+ {
+ errno: 50,
+ code: 'EPERM',
+ description: 'operation not permitted'
+ },
+ {
+ errno: 51,
+ code: 'ELOOP',
+ description: 'too many symbolic links encountered'
+ },
+ {
+ errno: 52,
+ code: 'EXDEV',
+ description: 'cross-device link not permitted'
+ },
+ {
+ errno: 53,
+ code: 'ENOTEMPTY',
+ description: 'directory not empty'
+ },
+ {
+ errno: 54,
+ code: 'ENOSPC',
+ description: 'no space left on device'
+ },
+ {
+ errno: 55,
+ code: 'EIO',
+ description: 'i/o error'
+ },
+ {
+ errno: 56,
+ code: 'EROFS',
+ description: 'read-only file system'
+ },
+ {
+ errno: 57,
+ code: 'ENODEV',
+ description: 'no such device'
+ },
+ {
+ errno: 58,
+ code: 'ESPIPE',
+ description: 'invalid seek'
+ },
+ {
+ errno: 59,
+ code: 'ECANCELED',
+ description: 'operation canceled'
+ }
+]
+
+module.exports.errno = {}
+module.exports.code = {}
+
+all.forEach(function (error) {
+ module.exports.errno[error.errno] = error
+ module.exports.code[error.code] = error
+})
+
+module.exports.custom = require('./custom')(module.exports)
+module.exports.create = module.exports.custom.createError
diff --git a/node_modules/errno/package.json b/node_modules/errno/package.json
new file mode 100644
index 00000000..2136db83
--- /dev/null
+++ b/node_modules/errno/package.json
@@ -0,0 +1,92 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "errno@^0.1.3",
+ "scope": null,
+ "escapedName": "errno",
+ "name": "errno",
+ "rawSpec": "^0.1.3",
+ "spec": ">=0.1.3 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/memory-fs"
+ ]
+ ],
+ "_from": "errno@>=0.1.3 <0.2.0",
+ "_id": "errno@0.1.4",
+ "_inCache": true,
+ "_location": "/errno",
+ "_nodeVersion": "3.0.0",
+ "_npmUser": {
+ "name": "rvagg",
+ "email": "rod@vagg.org"
+ },
+ "_npmVersion": "2.13.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "errno@^0.1.3",
+ "scope": null,
+ "escapedName": "errno",
+ "name": "errno",
+ "rawSpec": "^0.1.3",
+ "spec": ">=0.1.3 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/memory-fs",
+ "/webpack-dev-middleware/memory-fs"
+ ],
+ "_resolved": "https://registry.npmjs.org/errno/-/errno-0.1.4.tgz",
+ "_shasum": "b896e23a9e5e8ba33871fc996abd3635fc9a1c7d",
+ "_shrinkwrap": null,
+ "_spec": "errno@^0.1.3",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/memory-fs",
+ "authors": [
+ "Rod Vagg @rvagg (https://github.com/rvagg)"
+ ],
+ "bin": {
+ "errno": "./cli.js"
+ },
+ "bugs": {
+ "url": "https://github.com/rvagg/node-errno/issues"
+ },
+ "dependencies": {
+ "prr": "~0.0.0"
+ },
+ "description": "libuv errno details exposed",
+ "devDependencies": {
+ "tape": "~3.5.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "b896e23a9e5e8ba33871fc996abd3635fc9a1c7d",
+ "tarball": "https://registry.npmjs.org/errno/-/errno-0.1.4.tgz"
+ },
+ "gitHead": "1c2b1fcbf22ef2bafbf6cda378cfed400f5163fd",
+ "homepage": "https://github.com/rvagg/node-errno",
+ "keywords": [
+ "errors",
+ "errno",
+ "libuv"
+ ],
+ "license": "MIT",
+ "main": "errno.js",
+ "maintainers": [
+ {
+ "name": "rvagg",
+ "email": "rod@vagg.org"
+ }
+ ],
+ "name": "errno",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/rvagg/node-errno.git"
+ },
+ "scripts": {
+ "test": "tape test.js"
+ },
+ "version": "0.1.4"
+}
diff --git a/node_modules/errno/test.js b/node_modules/errno/test.js
new file mode 100755
index 00000000..6b76a85a
--- /dev/null
+++ b/node_modules/errno/test.js
@@ -0,0 +1,31 @@
+#!/usr/bin/env node
+
+var test = require('tape')
+ , errno = require('./')
+
+test('sanity checks', function (t) {
+ t.ok(errno.all, 'errno.all not found')
+ t.ok(errno.errno, 'errno.errno not found')
+ t.ok(errno.code, 'errno.code not found')
+
+ t.equal(errno.all.length, 59, 'found ' + errno.all.length + ', expected 59')
+ t.equal(errno.errno['-1'], errno.all[0], 'errno -1 not first element')
+
+ t.equal(errno.code['UNKNOWN'], errno.all[0], 'code UNKNOWN not first element')
+
+ t.equal(errno.errno[1], errno.all[2], 'errno 1 not third element')
+
+ t.equal(errno.code['EOF'], errno.all[2], 'code EOF not third element')
+ t.end()
+})
+
+test('custom errors', function (t) {
+ var Cust = errno.create('FooNotBarError')
+ var cust = new Cust('foo is not bar')
+
+ t.equal(cust.name, 'FooNotBarError', 'correct custom name')
+ t.equal(cust.type, 'FooNotBarError', 'correct custom type')
+ t.equal(cust.message, 'foo is not bar', 'correct custom message')
+ t.notOk(cust.cause, 'no cause')
+ t.end()
+})
diff --git a/node_modules/escape-html/LICENSE b/node_modules/escape-html/LICENSE
new file mode 100644
index 00000000..2e70de97
--- /dev/null
+++ b/node_modules/escape-html/LICENSE
@@ -0,0 +1,24 @@
+(The MIT License)
+
+Copyright (c) 2012-2013 TJ Holowaychuk
+Copyright (c) 2015 Andreas Lubbe
+Copyright (c) 2015 Tiancheng "Timothy" Gu
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/escape-html/Readme.md b/node_modules/escape-html/Readme.md
new file mode 100644
index 00000000..653d9eaa
--- /dev/null
+++ b/node_modules/escape-html/Readme.md
@@ -0,0 +1,43 @@
+
+# escape-html
+
+ Escape string for use in HTML
+
+## Example
+
+```js
+var escape = require('escape-html');
+var html = escape('foo & bar');
+// -> foo & bar
+```
+
+## Benchmark
+
+```
+$ npm run-script bench
+
+> escape-html@1.0.3 bench nodejs-escape-html
+> node benchmark/index.js
+
+
+ http_parser@1.0
+ node@0.10.33
+ v8@3.14.5.9
+ ares@1.9.0-DEV
+ uv@0.10.29
+ zlib@1.2.3
+ modules@11
+ openssl@1.0.1j
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+
+ no special characters x 19,435,271 ops/sec ±0.85% (187 runs sampled)
+ single special character x 6,132,421 ops/sec ±0.67% (194 runs sampled)
+ many special characters x 3,175,826 ops/sec ±0.65% (193 runs sampled)
+```
+
+## License
+
+ MIT
\ No newline at end of file
diff --git a/node_modules/escape-html/index.js b/node_modules/escape-html/index.js
new file mode 100644
index 00000000..bf9e226f
--- /dev/null
+++ b/node_modules/escape-html/index.js
@@ -0,0 +1,78 @@
+/*!
+ * escape-html
+ * Copyright(c) 2012-2013 TJ Holowaychuk
+ * Copyright(c) 2015 Andreas Lubbe
+ * Copyright(c) 2015 Tiancheng "Timothy" Gu
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var matchHtmlRegExp = /["'&<>]/;
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = escapeHtml;
+
+/**
+ * Escape special characters in the given string of html.
+ *
+ * @param {string} string The string to escape for inserting into HTML
+ * @return {string}
+ * @public
+ */
+
+function escapeHtml(string) {
+ var str = '' + string;
+ var match = matchHtmlRegExp.exec(str);
+
+ if (!match) {
+ return str;
+ }
+
+ var escape;
+ var html = '';
+ var index = 0;
+ var lastIndex = 0;
+
+ for (index = match.index; index < str.length; index++) {
+ switch (str.charCodeAt(index)) {
+ case 34: // "
+ escape = '"';
+ break;
+ case 38: // &
+ escape = '&';
+ break;
+ case 39: // '
+ escape = ''';
+ break;
+ case 60: // <
+ escape = '<';
+ break;
+ case 62: // >
+ escape = '>';
+ break;
+ default:
+ continue;
+ }
+
+ if (lastIndex !== index) {
+ html += str.substring(lastIndex, index);
+ }
+
+ lastIndex = index + 1;
+ html += escape;
+ }
+
+ return lastIndex !== index
+ ? html + str.substring(lastIndex, index)
+ : html;
+}
diff --git a/node_modules/escape-html/package.json b/node_modules/escape-html/package.json
new file mode 100644
index 00000000..eb5e0035
--- /dev/null
+++ b/node_modules/escape-html/package.json
@@ -0,0 +1,95 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "escape-html@~1.0.3",
+ "scope": null,
+ "escapedName": "escape-html",
+ "name": "escape-html",
+ "rawSpec": "~1.0.3",
+ "spec": ">=1.0.3 <1.1.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express"
+ ]
+ ],
+ "_from": "escape-html@>=1.0.3 <1.1.0",
+ "_id": "escape-html@1.0.3",
+ "_inCache": true,
+ "_location": "/escape-html",
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "escape-html@~1.0.3",
+ "scope": null,
+ "escapedName": "escape-html",
+ "name": "escape-html",
+ "rawSpec": "~1.0.3",
+ "spec": ">=1.0.3 <1.1.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/express",
+ "/finalhandler",
+ "/send",
+ "/serve-index",
+ "/serve-static"
+ ],
+ "_resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz",
+ "_shasum": "0258eae4d3d0c0974de1c169188ef0051d1d1988",
+ "_shrinkwrap": null,
+ "_spec": "escape-html@~1.0.3",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express",
+ "bugs": {
+ "url": "https://github.com/component/escape-html/issues"
+ },
+ "dependencies": {},
+ "description": "Escape string for use in HTML",
+ "devDependencies": {
+ "beautify-benchmark": "0.2.4",
+ "benchmark": "1.0.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "0258eae4d3d0c0974de1c169188ef0051d1d1988",
+ "tarball": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz"
+ },
+ "files": [
+ "LICENSE",
+ "Readme.md",
+ "index.js"
+ ],
+ "gitHead": "7ac2ea3977fcac3d4c5be8d2a037812820c65f28",
+ "homepage": "https://github.com/component/escape-html",
+ "keywords": [
+ "escape",
+ "html",
+ "utility"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "tjholowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "escape-html",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/component/escape-html.git"
+ },
+ "scripts": {
+ "bench": "node benchmark/index.js"
+ },
+ "version": "1.0.3"
+}
diff --git a/node_modules/escape-string-regexp/index.js b/node_modules/escape-string-regexp/index.js
new file mode 100644
index 00000000..7834bf9b
--- /dev/null
+++ b/node_modules/escape-string-regexp/index.js
@@ -0,0 +1,11 @@
+'use strict';
+
+var matchOperatorsRe = /[|\\{}()[\]^$+*?.]/g;
+
+module.exports = function (str) {
+ if (typeof str !== 'string') {
+ throw new TypeError('Expected a string');
+ }
+
+ return str.replace(matchOperatorsRe, '\\$&');
+};
diff --git a/node_modules/escape-string-regexp/license b/node_modules/escape-string-regexp/license
new file mode 100644
index 00000000..654d0bfe
--- /dev/null
+++ b/node_modules/escape-string-regexp/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/escape-string-regexp/package.json b/node_modules/escape-string-regexp/package.json
new file mode 100644
index 00000000..c48b4a73
--- /dev/null
+++ b/node_modules/escape-string-regexp/package.json
@@ -0,0 +1,109 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "escape-string-regexp@^1.0.2",
+ "scope": null,
+ "escapedName": "escape-string-regexp",
+ "name": "escape-string-regexp",
+ "rawSpec": "^1.0.2",
+ "spec": ">=1.0.2 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/chalk"
+ ]
+ ],
+ "_from": "escape-string-regexp@>=1.0.2 <2.0.0",
+ "_id": "escape-string-regexp@1.0.5",
+ "_inCache": true,
+ "_location": "/escape-string-regexp",
+ "_nodeVersion": "4.2.6",
+ "_npmOperationalInternal": {
+ "host": "packages-9-west.internal.npmjs.com",
+ "tmp": "tmp/escape-string-regexp-1.0.5.tgz_1456059312074_0.7245344955008477"
+ },
+ "_npmUser": {
+ "name": "jbnicolai",
+ "email": "jappelman@xebia.com"
+ },
+ "_npmVersion": "2.14.12",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "escape-string-regexp@^1.0.2",
+ "scope": null,
+ "escapedName": "escape-string-regexp",
+ "name": "escape-string-regexp",
+ "rawSpec": "^1.0.2",
+ "spec": ">=1.0.2 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/chalk"
+ ],
+ "_resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
+ "_shasum": "1b61c0562190a8dff6ae3bb2cf0200ca130b86d4",
+ "_shrinkwrap": null,
+ "_spec": "escape-string-regexp@^1.0.2",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/chalk",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/sindresorhus/escape-string-regexp/issues"
+ },
+ "dependencies": {},
+ "description": "Escape RegExp special characters",
+ "devDependencies": {
+ "ava": "*",
+ "xo": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "1b61c0562190a8dff6ae3bb2cf0200ca130b86d4",
+ "tarball": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz"
+ },
+ "engines": {
+ "node": ">=0.8.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "db124a3e1aae9d692c4899e42a5c6c3e329eaa20",
+ "homepage": "https://github.com/sindresorhus/escape-string-regexp",
+ "keywords": [
+ "escape",
+ "regex",
+ "regexp",
+ "re",
+ "regular",
+ "expression",
+ "string",
+ "str",
+ "special",
+ "characters"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ {
+ "name": "jbnicolai",
+ "email": "jappelman@xebia.com"
+ }
+ ],
+ "name": "escape-string-regexp",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/sindresorhus/escape-string-regexp.git"
+ },
+ "scripts": {
+ "test": "xo && ava"
+ },
+ "version": "1.0.5"
+}
diff --git a/node_modules/escape-string-regexp/readme.md b/node_modules/escape-string-regexp/readme.md
new file mode 100644
index 00000000..87ac82d5
--- /dev/null
+++ b/node_modules/escape-string-regexp/readme.md
@@ -0,0 +1,27 @@
+# escape-string-regexp [](https://travis-ci.org/sindresorhus/escape-string-regexp)
+
+> Escape RegExp special characters
+
+
+## Install
+
+```
+$ npm install --save escape-string-regexp
+```
+
+
+## Usage
+
+```js
+const escapeStringRegexp = require('escape-string-regexp');
+
+const escapedString = escapeStringRegexp('how much $ for a unicorn?');
+//=> 'how much \$ for a unicorn\?'
+
+new RegExp(escapedString);
+```
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)
diff --git a/node_modules/esutils/LICENSE.BSD b/node_modules/esutils/LICENSE.BSD
new file mode 100644
index 00000000..3e580c35
--- /dev/null
+++ b/node_modules/esutils/LICENSE.BSD
@@ -0,0 +1,19 @@
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY
+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/node_modules/esutils/README.md b/node_modules/esutils/README.md
new file mode 100644
index 00000000..610d8bde
--- /dev/null
+++ b/node_modules/esutils/README.md
@@ -0,0 +1,169 @@
+### esutils [](http://travis-ci.org/estools/esutils)
+esutils ([esutils](http://github.com/estools/esutils)) is
+utility box for ECMAScript language tools.
+
+### API
+
+### ast
+
+#### ast.isExpression(node)
+
+Returns true if `node` is an Expression as defined in ECMA262 edition 5.1 section
+[11](https://es5.github.io/#x11).
+
+#### ast.isStatement(node)
+
+Returns true if `node` is a Statement as defined in ECMA262 edition 5.1 section
+[12](https://es5.github.io/#x12).
+
+#### ast.isIterationStatement(node)
+
+Returns true if `node` is an IterationStatement as defined in ECMA262 edition
+5.1 section [12.6](https://es5.github.io/#x12.6).
+
+#### ast.isSourceElement(node)
+
+Returns true if `node` is a SourceElement as defined in ECMA262 edition 5.1
+section [14](https://es5.github.io/#x14).
+
+#### ast.trailingStatement(node)
+
+Returns `Statement?` if `node` has trailing `Statement`.
+```js
+if (cond)
+ consequent;
+```
+When taking this `IfStatement`, returns `consequent;` statement.
+
+#### ast.isProblematicIfStatement(node)
+
+Returns true if `node` is a problematic IfStatement. If `node` is a problematic `IfStatement`, `node` cannot be represented as an one on one JavaScript code.
+```js
+{
+ type: 'IfStatement',
+ consequent: {
+ type: 'WithStatement',
+ body: {
+ type: 'IfStatement',
+ consequent: {type: 'EmptyStatement'}
+ }
+ },
+ alternate: {type: 'EmptyStatement'}
+}
+```
+The above node cannot be represented as a JavaScript code, since the top level `else` alternate belongs to an inner `IfStatement`.
+
+
+### code
+
+#### code.isDecimalDigit(code)
+
+Return true if provided code is decimal digit.
+
+#### code.isHexDigit(code)
+
+Return true if provided code is hexadecimal digit.
+
+#### code.isOctalDigit(code)
+
+Return true if provided code is octal digit.
+
+#### code.isWhiteSpace(code)
+
+Return true if provided code is white space. White space characters are formally defined in ECMA262.
+
+#### code.isLineTerminator(code)
+
+Return true if provided code is line terminator. Line terminator characters are formally defined in ECMA262.
+
+#### code.isIdentifierStart(code)
+
+Return true if provided code can be the first character of ECMA262 Identifier. They are formally defined in ECMA262.
+
+#### code.isIdentifierPart(code)
+
+Return true if provided code can be the trailing character of ECMA262 Identifier. They are formally defined in ECMA262.
+
+### keyword
+
+#### keyword.isKeywordES5(id, strict)
+
+Returns `true` if provided identifier string is a Keyword or Future Reserved Word
+in ECMA262 edition 5.1. They are formally defined in ECMA262 sections
+[7.6.1.1](http://es5.github.io/#x7.6.1.1) and [7.6.1.2](http://es5.github.io/#x7.6.1.2),
+respectively. If the `strict` flag is truthy, this function additionally checks whether
+`id` is a Keyword or Future Reserved Word under strict mode.
+
+#### keyword.isKeywordES6(id, strict)
+
+Returns `true` if provided identifier string is a Keyword or Future Reserved Word
+in ECMA262 edition 6. They are formally defined in ECMA262 sections
+[11.6.2.1](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-keywords) and
+[11.6.2.2](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-future-reserved-words),
+respectively. If the `strict` flag is truthy, this function additionally checks whether
+`id` is a Keyword or Future Reserved Word under strict mode.
+
+#### keyword.isReservedWordES5(id, strict)
+
+Returns `true` if provided identifier string is a Reserved Word in ECMA262 edition 5.1.
+They are formally defined in ECMA262 section [7.6.1](http://es5.github.io/#x7.6.1).
+If the `strict` flag is truthy, this function additionally checks whether `id`
+is a Reserved Word under strict mode.
+
+#### keyword.isReservedWordES6(id, strict)
+
+Returns `true` if provided identifier string is a Reserved Word in ECMA262 edition 6.
+They are formally defined in ECMA262 section [11.6.2](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-reserved-words).
+If the `strict` flag is truthy, this function additionally checks whether `id`
+is a Reserved Word under strict mode.
+
+#### keyword.isRestrictedWord(id)
+
+Returns `true` if provided identifier string is one of `eval` or `arguments`.
+They are restricted in strict mode code throughout ECMA262 edition 5.1 and
+in ECMA262 edition 6 section [12.1.1](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-identifiers-static-semantics-early-errors).
+
+#### keyword.isIdentifierName(id)
+
+Return true if provided identifier string is an IdentifierName as specified in
+ECMA262 edition 5.1 section [7.6](https://es5.github.io/#x7.6).
+
+#### keyword.isIdentifierES5(id, strict)
+
+Return true if provided identifier string is an Identifier as specified in
+ECMA262 edition 5.1 section [7.6](https://es5.github.io/#x7.6). If the `strict`
+flag is truthy, this function additionally checks whether `id` is an Identifier
+under strict mode.
+
+#### keyword.isIdentifierES6(id, strict)
+
+Return true if provided identifier string is an Identifier as specified in
+ECMA262 edition 6 section [12.1](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-identifiers).
+If the `strict` flag is truthy, this function additionally checks whether `id`
+is an Identifier under strict mode.
+
+### License
+
+Copyright (C) 2013 [Yusuke Suzuki](http://github.com/Constellation)
+ (twitter: [@Constellation](http://twitter.com/Constellation)) and other contributors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY
+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/node_modules/esutils/lib/ast.js b/node_modules/esutils/lib/ast.js
new file mode 100644
index 00000000..8faadae1
--- /dev/null
+++ b/node_modules/esutils/lib/ast.js
@@ -0,0 +1,144 @@
+/*
+ Copyright (C) 2013 Yusuke Suzuki
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY
+ DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+(function () {
+ 'use strict';
+
+ function isExpression(node) {
+ if (node == null) { return false; }
+ switch (node.type) {
+ case 'ArrayExpression':
+ case 'AssignmentExpression':
+ case 'BinaryExpression':
+ case 'CallExpression':
+ case 'ConditionalExpression':
+ case 'FunctionExpression':
+ case 'Identifier':
+ case 'Literal':
+ case 'LogicalExpression':
+ case 'MemberExpression':
+ case 'NewExpression':
+ case 'ObjectExpression':
+ case 'SequenceExpression':
+ case 'ThisExpression':
+ case 'UnaryExpression':
+ case 'UpdateExpression':
+ return true;
+ }
+ return false;
+ }
+
+ function isIterationStatement(node) {
+ if (node == null) { return false; }
+ switch (node.type) {
+ case 'DoWhileStatement':
+ case 'ForInStatement':
+ case 'ForStatement':
+ case 'WhileStatement':
+ return true;
+ }
+ return false;
+ }
+
+ function isStatement(node) {
+ if (node == null) { return false; }
+ switch (node.type) {
+ case 'BlockStatement':
+ case 'BreakStatement':
+ case 'ContinueStatement':
+ case 'DebuggerStatement':
+ case 'DoWhileStatement':
+ case 'EmptyStatement':
+ case 'ExpressionStatement':
+ case 'ForInStatement':
+ case 'ForStatement':
+ case 'IfStatement':
+ case 'LabeledStatement':
+ case 'ReturnStatement':
+ case 'SwitchStatement':
+ case 'ThrowStatement':
+ case 'TryStatement':
+ case 'VariableDeclaration':
+ case 'WhileStatement':
+ case 'WithStatement':
+ return true;
+ }
+ return false;
+ }
+
+ function isSourceElement(node) {
+ return isStatement(node) || node != null && node.type === 'FunctionDeclaration';
+ }
+
+ function trailingStatement(node) {
+ switch (node.type) {
+ case 'IfStatement':
+ if (node.alternate != null) {
+ return node.alternate;
+ }
+ return node.consequent;
+
+ case 'LabeledStatement':
+ case 'ForStatement':
+ case 'ForInStatement':
+ case 'WhileStatement':
+ case 'WithStatement':
+ return node.body;
+ }
+ return null;
+ }
+
+ function isProblematicIfStatement(node) {
+ var current;
+
+ if (node.type !== 'IfStatement') {
+ return false;
+ }
+ if (node.alternate == null) {
+ return false;
+ }
+ current = node.consequent;
+ do {
+ if (current.type === 'IfStatement') {
+ if (current.alternate == null) {
+ return true;
+ }
+ }
+ current = trailingStatement(current);
+ } while (current);
+
+ return false;
+ }
+
+ module.exports = {
+ isExpression: isExpression,
+ isStatement: isStatement,
+ isIterationStatement: isIterationStatement,
+ isSourceElement: isSourceElement,
+ isProblematicIfStatement: isProblematicIfStatement,
+
+ trailingStatement: trailingStatement
+ };
+}());
+/* vim: set sw=4 ts=4 et tw=80 : */
diff --git a/node_modules/esutils/lib/code.js b/node_modules/esutils/lib/code.js
new file mode 100644
index 00000000..2a7c19d6
--- /dev/null
+++ b/node_modules/esutils/lib/code.js
@@ -0,0 +1,135 @@
+/*
+ Copyright (C) 2013-2014 Yusuke Suzuki
+ Copyright (C) 2014 Ivan Nikulin
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY
+ DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+(function () {
+ 'use strict';
+
+ var ES6Regex, ES5Regex, NON_ASCII_WHITESPACES, IDENTIFIER_START, IDENTIFIER_PART, ch;
+
+ // See `tools/generate-identifier-regex.js`.
+ ES5Regex = {
+ // ECMAScript 5.1/Unicode v7.0.0 NonAsciiIdentifierStart:
+ NonAsciiIdentifierStart: /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B2\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA7AD\uA7B0\uA7B1\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB5F\uAB64\uAB65\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,
+ // ECMAScript 5.1/Unicode v7.0.0 NonAsciiIdentifierPart:
+ NonAsciiIdentifierPart: /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B2\u08E4-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58\u0C59\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D60-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA69D\uA69F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA7AD\uA7B0\uA7B1\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB5F\uAB64\uAB65\uABC0-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2D\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/
+ };
+
+ ES6Regex = {
+ // ECMAScript 6/Unicode v7.0.0 NonAsciiIdentifierStart:
+ NonAsciiIdentifierStart: /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B2\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA7AD\uA7B0\uA7B1\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB5F\uAB64\uAB65\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDE00-\uDE11\uDE13-\uDE2B\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF5D-\uDF61]|\uD805[\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDE00-\uDE2F\uDE44\uDE80-\uDEAA]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF98]|\uD809[\uDC00-\uDC6E]|[\uD80C\uD840-\uD868\uD86A-\uD86C][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D]|\uD87E[\uDC00-\uDE1D]/,
+ // ECMAScript 6/Unicode v7.0.0 NonAsciiIdentifierPart:
+ NonAsciiIdentifierPart: /[\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B2\u08E4-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58\u0C59\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D60-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA69D\uA69F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA7AD\uA7B0\uA7B1\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB5F\uAB64\uAB65\uABC0-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2D\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDD0-\uDDDA\uDE00-\uDE11\uDE13-\uDE37\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF01-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9]|\uD806[\uDCA0-\uDCE9\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF98]|\uD809[\uDC00-\uDC6E]|[\uD80C\uD840-\uD868\uD86A-\uD86C][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/
+ };
+
+ function isDecimalDigit(ch) {
+ return 0x30 <= ch && ch <= 0x39; // 0..9
+ }
+
+ function isHexDigit(ch) {
+ return 0x30 <= ch && ch <= 0x39 || // 0..9
+ 0x61 <= ch && ch <= 0x66 || // a..f
+ 0x41 <= ch && ch <= 0x46; // A..F
+ }
+
+ function isOctalDigit(ch) {
+ return ch >= 0x30 && ch <= 0x37; // 0..7
+ }
+
+ // 7.2 White Space
+
+ NON_ASCII_WHITESPACES = [
+ 0x1680, 0x180E,
+ 0x2000, 0x2001, 0x2002, 0x2003, 0x2004, 0x2005, 0x2006, 0x2007, 0x2008, 0x2009, 0x200A,
+ 0x202F, 0x205F,
+ 0x3000,
+ 0xFEFF
+ ];
+
+ function isWhiteSpace(ch) {
+ return ch === 0x20 || ch === 0x09 || ch === 0x0B || ch === 0x0C || ch === 0xA0 ||
+ ch >= 0x1680 && NON_ASCII_WHITESPACES.indexOf(ch) >= 0;
+ }
+
+ // 7.3 Line Terminators
+
+ function isLineTerminator(ch) {
+ return ch === 0x0A || ch === 0x0D || ch === 0x2028 || ch === 0x2029;
+ }
+
+ // 7.6 Identifier Names and Identifiers
+
+ function fromCodePoint(cp) {
+ if (cp <= 0xFFFF) { return String.fromCharCode(cp); }
+ var cu1 = String.fromCharCode(Math.floor((cp - 0x10000) / 0x400) + 0xD800);
+ var cu2 = String.fromCharCode(((cp - 0x10000) % 0x400) + 0xDC00);
+ return cu1 + cu2;
+ }
+
+ IDENTIFIER_START = new Array(0x80);
+ for(ch = 0; ch < 0x80; ++ch) {
+ IDENTIFIER_START[ch] =
+ ch >= 0x61 && ch <= 0x7A || // a..z
+ ch >= 0x41 && ch <= 0x5A || // A..Z
+ ch === 0x24 || ch === 0x5F; // $ (dollar) and _ (underscore)
+ }
+
+ IDENTIFIER_PART = new Array(0x80);
+ for(ch = 0; ch < 0x80; ++ch) {
+ IDENTIFIER_PART[ch] =
+ ch >= 0x61 && ch <= 0x7A || // a..z
+ ch >= 0x41 && ch <= 0x5A || // A..Z
+ ch >= 0x30 && ch <= 0x39 || // 0..9
+ ch === 0x24 || ch === 0x5F; // $ (dollar) and _ (underscore)
+ }
+
+ function isIdentifierStartES5(ch) {
+ return ch < 0x80 ? IDENTIFIER_START[ch] : ES5Regex.NonAsciiIdentifierStart.test(fromCodePoint(ch));
+ }
+
+ function isIdentifierPartES5(ch) {
+ return ch < 0x80 ? IDENTIFIER_PART[ch] : ES5Regex.NonAsciiIdentifierPart.test(fromCodePoint(ch));
+ }
+
+ function isIdentifierStartES6(ch) {
+ return ch < 0x80 ? IDENTIFIER_START[ch] : ES6Regex.NonAsciiIdentifierStart.test(fromCodePoint(ch));
+ }
+
+ function isIdentifierPartES6(ch) {
+ return ch < 0x80 ? IDENTIFIER_PART[ch] : ES6Regex.NonAsciiIdentifierPart.test(fromCodePoint(ch));
+ }
+
+ module.exports = {
+ isDecimalDigit: isDecimalDigit,
+ isHexDigit: isHexDigit,
+ isOctalDigit: isOctalDigit,
+ isWhiteSpace: isWhiteSpace,
+ isLineTerminator: isLineTerminator,
+ isIdentifierStartES5: isIdentifierStartES5,
+ isIdentifierPartES5: isIdentifierPartES5,
+ isIdentifierStartES6: isIdentifierStartES6,
+ isIdentifierPartES6: isIdentifierPartES6
+ };
+}());
+/* vim: set sw=4 ts=4 et tw=80 : */
diff --git a/node_modules/esutils/lib/keyword.js b/node_modules/esutils/lib/keyword.js
new file mode 100644
index 00000000..13c8c6a9
--- /dev/null
+++ b/node_modules/esutils/lib/keyword.js
@@ -0,0 +1,165 @@
+/*
+ Copyright (C) 2013 Yusuke Suzuki
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY
+ DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+(function () {
+ 'use strict';
+
+ var code = require('./code');
+
+ function isStrictModeReservedWordES6(id) {
+ switch (id) {
+ case 'implements':
+ case 'interface':
+ case 'package':
+ case 'private':
+ case 'protected':
+ case 'public':
+ case 'static':
+ case 'let':
+ return true;
+ default:
+ return false;
+ }
+ }
+
+ function isKeywordES5(id, strict) {
+ // yield should not be treated as keyword under non-strict mode.
+ if (!strict && id === 'yield') {
+ return false;
+ }
+ return isKeywordES6(id, strict);
+ }
+
+ function isKeywordES6(id, strict) {
+ if (strict && isStrictModeReservedWordES6(id)) {
+ return true;
+ }
+
+ switch (id.length) {
+ case 2:
+ return (id === 'if') || (id === 'in') || (id === 'do');
+ case 3:
+ return (id === 'var') || (id === 'for') || (id === 'new') || (id === 'try');
+ case 4:
+ return (id === 'this') || (id === 'else') || (id === 'case') ||
+ (id === 'void') || (id === 'with') || (id === 'enum');
+ case 5:
+ return (id === 'while') || (id === 'break') || (id === 'catch') ||
+ (id === 'throw') || (id === 'const') || (id === 'yield') ||
+ (id === 'class') || (id === 'super');
+ case 6:
+ return (id === 'return') || (id === 'typeof') || (id === 'delete') ||
+ (id === 'switch') || (id === 'export') || (id === 'import');
+ case 7:
+ return (id === 'default') || (id === 'finally') || (id === 'extends');
+ case 8:
+ return (id === 'function') || (id === 'continue') || (id === 'debugger');
+ case 10:
+ return (id === 'instanceof');
+ default:
+ return false;
+ }
+ }
+
+ function isReservedWordES5(id, strict) {
+ return id === 'null' || id === 'true' || id === 'false' || isKeywordES5(id, strict);
+ }
+
+ function isReservedWordES6(id, strict) {
+ return id === 'null' || id === 'true' || id === 'false' || isKeywordES6(id, strict);
+ }
+
+ function isRestrictedWord(id) {
+ return id === 'eval' || id === 'arguments';
+ }
+
+ function isIdentifierNameES5(id) {
+ var i, iz, ch;
+
+ if (id.length === 0) { return false; }
+
+ ch = id.charCodeAt(0);
+ if (!code.isIdentifierStartES5(ch)) {
+ return false;
+ }
+
+ for (i = 1, iz = id.length; i < iz; ++i) {
+ ch = id.charCodeAt(i);
+ if (!code.isIdentifierPartES5(ch)) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+ function decodeUtf16(lead, trail) {
+ return (lead - 0xD800) * 0x400 + (trail - 0xDC00) + 0x10000;
+ }
+
+ function isIdentifierNameES6(id) {
+ var i, iz, ch, lowCh, check;
+
+ if (id.length === 0) { return false; }
+
+ check = code.isIdentifierStartES6;
+ for (i = 0, iz = id.length; i < iz; ++i) {
+ ch = id.charCodeAt(i);
+ if (0xD800 <= ch && ch <= 0xDBFF) {
+ ++i;
+ if (i >= iz) { return false; }
+ lowCh = id.charCodeAt(i);
+ if (!(0xDC00 <= lowCh && lowCh <= 0xDFFF)) {
+ return false;
+ }
+ ch = decodeUtf16(ch, lowCh);
+ }
+ if (!check(ch)) {
+ return false;
+ }
+ check = code.isIdentifierPartES6;
+ }
+ return true;
+ }
+
+ function isIdentifierES5(id, strict) {
+ return isIdentifierNameES5(id) && !isReservedWordES5(id, strict);
+ }
+
+ function isIdentifierES6(id, strict) {
+ return isIdentifierNameES6(id) && !isReservedWordES6(id, strict);
+ }
+
+ module.exports = {
+ isKeywordES5: isKeywordES5,
+ isKeywordES6: isKeywordES6,
+ isReservedWordES5: isReservedWordES5,
+ isReservedWordES6: isReservedWordES6,
+ isRestrictedWord: isRestrictedWord,
+ isIdentifierNameES5: isIdentifierNameES5,
+ isIdentifierNameES6: isIdentifierNameES6,
+ isIdentifierES5: isIdentifierES5,
+ isIdentifierES6: isIdentifierES6
+ };
+}());
+/* vim: set sw=4 ts=4 et tw=80 : */
diff --git a/node_modules/esutils/lib/utils.js b/node_modules/esutils/lib/utils.js
new file mode 100644
index 00000000..ce18faa6
--- /dev/null
+++ b/node_modules/esutils/lib/utils.js
@@ -0,0 +1,33 @@
+/*
+ Copyright (C) 2013 Yusuke Suzuki
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY
+ DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+
+(function () {
+ 'use strict';
+
+ exports.ast = require('./ast');
+ exports.code = require('./code');
+ exports.keyword = require('./keyword');
+}());
+/* vim: set sw=4 ts=4 et tw=80 : */
diff --git a/node_modules/esutils/package.json b/node_modules/esutils/package.json
new file mode 100644
index 00000000..eab5e67c
--- /dev/null
+++ b/node_modules/esutils/package.json
@@ -0,0 +1,106 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "esutils@^2.0.2",
+ "scope": null,
+ "escapedName": "esutils",
+ "name": "esutils",
+ "rawSpec": "^2.0.2",
+ "spec": ">=2.0.2 <3.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/babel-code-frame"
+ ]
+ ],
+ "_from": "esutils@>=2.0.2 <3.0.0",
+ "_id": "esutils@2.0.2",
+ "_inCache": true,
+ "_location": "/esutils",
+ "_nodeVersion": "0.12.0",
+ "_npmUser": {
+ "name": "michaelficarra",
+ "email": "npm@michael.ficarra.me"
+ },
+ "_npmVersion": "2.5.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "esutils@^2.0.2",
+ "scope": null,
+ "escapedName": "esutils",
+ "name": "esutils",
+ "rawSpec": "^2.0.2",
+ "spec": ">=2.0.2 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/babel-code-frame",
+ "/babel-types"
+ ],
+ "_resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz",
+ "_shasum": "0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b",
+ "_shrinkwrap": null,
+ "_spec": "esutils@^2.0.2",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/babel-code-frame",
+ "bugs": {
+ "url": "https://github.com/estools/esutils/issues"
+ },
+ "dependencies": {},
+ "description": "utility box for ECMAScript language tools",
+ "devDependencies": {
+ "chai": "~1.7.2",
+ "coffee-script": "~1.6.3",
+ "jshint": "2.6.3",
+ "mocha": "~2.2.1",
+ "regenerate": "~1.2.1",
+ "unicode-7.0.0": "^0.1.5"
+ },
+ "directories": {
+ "lib": "./lib"
+ },
+ "dist": {
+ "shasum": "0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b",
+ "tarball": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "LICENSE.BSD",
+ "README.md",
+ "lib"
+ ],
+ "gitHead": "3ffd1c403f3f29db9e8a9574b1895682e57b6a7f",
+ "homepage": "https://github.com/estools/esutils",
+ "licenses": [
+ {
+ "type": "BSD",
+ "url": "http://github.com/estools/esutils/raw/master/LICENSE.BSD"
+ }
+ ],
+ "main": "lib/utils.js",
+ "maintainers": [
+ {
+ "name": "constellation",
+ "email": "utatane.tea@gmail.com"
+ },
+ {
+ "name": "michaelficarra",
+ "email": "npm@michael.ficarra.me"
+ }
+ ],
+ "name": "esutils",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+ssh://git@github.com/estools/esutils.git"
+ },
+ "scripts": {
+ "generate-regex": "node tools/generate-identifier-regex.js",
+ "lint": "jshint lib/*.js",
+ "test": "npm run-script lint && npm run-script unit-test",
+ "unit-test": "mocha --compilers coffee:coffee-script -R spec"
+ },
+ "version": "2.0.2"
+}
diff --git a/node_modules/etag/HISTORY.md b/node_modules/etag/HISTORY.md
new file mode 100644
index 00000000..bd0f26df
--- /dev/null
+++ b/node_modules/etag/HISTORY.md
@@ -0,0 +1,71 @@
+1.7.0 / 2015-06-08
+==================
+
+ * Always include entity length in ETags for hash length extensions
+ * Generate non-Stats ETags using MD5 only (no longer CRC32)
+ * Improve stat performance by removing hashing
+ * Remove base64 padding in ETags to shorten
+ * Use MD5 instead of MD4 in weak ETags over 1KB
+
+1.6.0 / 2015-05-10
+==================
+
+ * Improve support for JXcore
+ * Remove requirement of `atime` in the stats object
+ * Support "fake" stats objects in environments without `fs`
+
+1.5.1 / 2014-11-19
+==================
+
+ * deps: crc@3.2.1
+ - Minor fixes
+
+1.5.0 / 2014-10-14
+==================
+
+ * Improve string performance
+ * Slightly improve speed for weak ETags over 1KB
+
+1.4.0 / 2014-09-21
+==================
+
+ * Support "fake" stats objects
+ * Support Node.js 0.6
+
+1.3.1 / 2014-09-14
+==================
+
+ * Use the (new and improved) `crc` for crc32
+
+1.3.0 / 2014-08-29
+==================
+
+ * Default strings to strong ETags
+ * Improve speed for weak ETags over 1KB
+
+1.2.1 / 2014-08-29
+==================
+
+ * Use the (much faster) `buffer-crc32` for crc32
+
+1.2.0 / 2014-08-24
+==================
+
+ * Add support for file stat objects
+
+1.1.0 / 2014-08-24
+==================
+
+ * Add fast-path for empty entity
+ * Add weak ETag generation
+ * Shrink size of generated ETags
+
+1.0.1 / 2014-08-24
+==================
+
+ * Fix behavior of string containing Unicode
+
+1.0.0 / 2014-05-18
+==================
+
+ * Initial release
diff --git a/node_modules/etag/LICENSE b/node_modules/etag/LICENSE
new file mode 100644
index 00000000..142ede38
--- /dev/null
+++ b/node_modules/etag/LICENSE
@@ -0,0 +1,22 @@
+(The MIT License)
+
+Copyright (c) 2014-2015 Douglas Christopher Wilson
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/etag/README.md b/node_modules/etag/README.md
new file mode 100644
index 00000000..8da9e059
--- /dev/null
+++ b/node_modules/etag/README.md
@@ -0,0 +1,165 @@
+# etag
+
+[![NPM Version][npm-image]][npm-url]
+[![NPM Downloads][downloads-image]][downloads-url]
+[![Node.js Version][node-version-image]][node-version-url]
+[![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
+
+Create simple ETags
+
+## Installation
+
+```sh
+$ npm install etag
+```
+
+## API
+
+```js
+var etag = require('etag')
+```
+
+### etag(entity, [options])
+
+Generate a strong ETag for the given entity. This should be the complete
+body of the entity. Strings, `Buffer`s, and `fs.Stats` are accepted. By
+default, a strong ETag is generated except for `fs.Stats`, which will
+generate a weak ETag (this can be overwritten by `options.weak`).
+
+```js
+res.setHeader('ETag', etag(body))
+```
+
+#### Options
+
+`etag` accepts these properties in the options object.
+
+##### weak
+
+Specifies if the generated ETag will include the weak validator mark (that
+is, the leading `W/`). The actual entity tag is the same. The default value
+is `false`, unless the `entity` is `fs.Stats`, in which case it is `true`.
+
+## Testing
+
+```sh
+$ npm test
+```
+
+## Benchmark
+
+```bash
+$ npm run-script bench
+
+> etag@1.6.0 bench nodejs-etag
+> node benchmark/index.js
+
+ http_parser@1.0
+ node@0.10.33
+ v8@3.14.5.9
+ ares@1.9.0-DEV
+ uv@0.10.29
+ zlib@1.2.3
+ modules@11
+ openssl@1.0.1j
+
+> node benchmark/body0-100b.js
+
+ 100B body
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+ 4 tests completed.
+
+* buffer - strong x 289,198 ops/sec ±1.09% (190 runs sampled)
+* buffer - weak x 287,838 ops/sec ±0.91% (189 runs sampled)
+* string - strong x 284,586 ops/sec ±1.05% (192 runs sampled)
+* string - weak x 287,439 ops/sec ±0.82% (192 runs sampled)
+
+> node benchmark/body1-1kb.js
+
+ 1KB body
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+ 4 tests completed.
+
+* buffer - strong x 212,423 ops/sec ±0.75% (193 runs sampled)
+* buffer - weak x 211,871 ops/sec ±0.74% (194 runs sampled)
+ string - strong x 205,291 ops/sec ±0.86% (194 runs sampled)
+ string - weak x 208,463 ops/sec ±0.79% (192 runs sampled)
+
+> node benchmark/body2-5kb.js
+
+ 5KB body
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+ 4 tests completed.
+
+* buffer - strong x 92,901 ops/sec ±0.58% (195 runs sampled)
+* buffer - weak x 93,045 ops/sec ±0.65% (192 runs sampled)
+ string - strong x 89,621 ops/sec ±0.68% (194 runs sampled)
+ string - weak x 90,070 ops/sec ±0.70% (196 runs sampled)
+
+> node benchmark/body3-10kb.js
+
+ 10KB body
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+ 4 tests completed.
+
+* buffer - strong x 54,220 ops/sec ±0.85% (192 runs sampled)
+* buffer - weak x 54,069 ops/sec ±0.83% (191 runs sampled)
+ string - strong x 53,078 ops/sec ±0.53% (194 runs sampled)
+ string - weak x 53,849 ops/sec ±0.47% (197 runs sampled)
+
+> node benchmark/body4-100kb.js
+
+ 100KB body
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+ 4 tests completed.
+
+* buffer - strong x 6,673 ops/sec ±0.15% (197 runs sampled)
+* buffer - weak x 6,716 ops/sec ±0.12% (198 runs sampled)
+ string - strong x 6,357 ops/sec ±0.14% (197 runs sampled)
+ string - weak x 6,344 ops/sec ±0.21% (197 runs sampled)
+
+> node benchmark/stats.js
+
+ stats
+
+ 1 test completed.
+ 2 tests completed.
+ 3 tests completed.
+ 4 tests completed.
+
+* real - strong x 1,671,989 ops/sec ±0.13% (197 runs sampled)
+* real - weak x 1,681,297 ops/sec ±0.12% (198 runs sampled)
+ fake - strong x 927,063 ops/sec ±0.14% (198 runs sampled)
+ fake - weak x 914,461 ops/sec ±0.41% (191 runs sampled)
+```
+
+## License
+
+[MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/etag.svg
+[npm-url]: https://npmjs.org/package/etag
+[node-version-image]: https://img.shields.io/node/v/etag.svg
+[node-version-url]: http://nodejs.org/download/
+[travis-image]: https://img.shields.io/travis/jshttp/etag/master.svg
+[travis-url]: https://travis-ci.org/jshttp/etag
+[coveralls-image]: https://img.shields.io/coveralls/jshttp/etag/master.svg
+[coveralls-url]: https://coveralls.io/r/jshttp/etag?branch=master
+[downloads-image]: https://img.shields.io/npm/dm/etag.svg
+[downloads-url]: https://npmjs.org/package/etag
diff --git a/node_modules/etag/index.js b/node_modules/etag/index.js
new file mode 100644
index 00000000..b582c84c
--- /dev/null
+++ b/node_modules/etag/index.js
@@ -0,0 +1,132 @@
+/*!
+ * etag
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict'
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = etag
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var crypto = require('crypto')
+var Stats = require('fs').Stats
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var base64PadCharRegExp = /=+$/
+var toString = Object.prototype.toString
+
+/**
+ * Generate an entity tag.
+ *
+ * @param {Buffer|string} entity
+ * @return {string}
+ * @private
+ */
+
+function entitytag(entity) {
+ if (entity.length === 0) {
+ // fast-path empty
+ return '"0-1B2M2Y8AsgTpgAmY7PhCfg"'
+ }
+
+ // compute hash of entity
+ var hash = crypto
+ .createHash('md5')
+ .update(entity, 'utf8')
+ .digest('base64')
+ .replace(base64PadCharRegExp, '')
+
+ // compute length of entity
+ var len = typeof entity === 'string'
+ ? Buffer.byteLength(entity, 'utf8')
+ : entity.length
+
+ return '"' + len.toString(16) + '-' + hash + '"'
+}
+
+/**
+ * Create a simple ETag.
+ *
+ * @param {string|Buffer|Stats} entity
+ * @param {object} [options]
+ * @param {boolean} [options.weak]
+ * @return {String}
+ * @public
+ */
+
+function etag(entity, options) {
+ if (entity == null) {
+ throw new TypeError('argument entity is required')
+ }
+
+ // support fs.Stats object
+ var isStats = isstats(entity)
+ var weak = options && typeof options.weak === 'boolean'
+ ? options.weak
+ : isStats
+
+ // validate argument
+ if (!isStats && typeof entity !== 'string' && !Buffer.isBuffer(entity)) {
+ throw new TypeError('argument entity must be string, Buffer, or fs.Stats')
+ }
+
+ // generate entity tag
+ var tag = isStats
+ ? stattag(entity)
+ : entitytag(entity)
+
+ return weak
+ ? 'W/' + tag
+ : tag
+}
+
+/**
+ * Determine if object is a Stats object.
+ *
+ * @param {object} obj
+ * @return {boolean}
+ * @api private
+ */
+
+function isstats(obj) {
+ // genuine fs.Stats
+ if (typeof Stats === 'function' && obj instanceof Stats) {
+ return true
+ }
+
+ // quack quack
+ return obj && typeof obj === 'object'
+ && 'ctime' in obj && toString.call(obj.ctime) === '[object Date]'
+ && 'mtime' in obj && toString.call(obj.mtime) === '[object Date]'
+ && 'ino' in obj && typeof obj.ino === 'number'
+ && 'size' in obj && typeof obj.size === 'number'
+}
+
+/**
+ * Generate a tag for a stat.
+ *
+ * @param {object} stat
+ * @return {string}
+ * @private
+ */
+
+function stattag(stat) {
+ var mtime = stat.mtime.getTime().toString(16)
+ var size = stat.size.toString(16)
+
+ return '"' + size + '-' + mtime + '"'
+}
diff --git a/node_modules/etag/package.json b/node_modules/etag/package.json
new file mode 100644
index 00000000..e7813672
--- /dev/null
+++ b/node_modules/etag/package.json
@@ -0,0 +1,108 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "etag@~1.7.0",
+ "scope": null,
+ "escapedName": "etag",
+ "name": "etag",
+ "rawSpec": "~1.7.0",
+ "spec": ">=1.7.0 <1.8.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express"
+ ]
+ ],
+ "_from": "etag@>=1.7.0 <1.8.0",
+ "_id": "etag@1.7.0",
+ "_inCache": true,
+ "_location": "/etag",
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "etag@~1.7.0",
+ "scope": null,
+ "escapedName": "etag",
+ "name": "etag",
+ "rawSpec": "~1.7.0",
+ "spec": ">=1.7.0 <1.8.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/express",
+ "/send"
+ ],
+ "_resolved": "https://registry.npmjs.org/etag/-/etag-1.7.0.tgz",
+ "_shasum": "03d30b5f67dd6e632d2945d30d6652731a34d5d8",
+ "_shrinkwrap": null,
+ "_spec": "etag@~1.7.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express",
+ "bugs": {
+ "url": "https://github.com/jshttp/etag/issues"
+ },
+ "contributors": [
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ },
+ {
+ "name": "David Björklund",
+ "email": "david.bjorklund@gmail.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "Create simple ETags",
+ "devDependencies": {
+ "beautify-benchmark": "0.2.4",
+ "benchmark": "1.0.0",
+ "istanbul": "0.3.14",
+ "mocha": "~1.21.4",
+ "seedrandom": "2.3.11"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "03d30b5f67dd6e632d2945d30d6652731a34d5d8",
+ "tarball": "https://registry.npmjs.org/etag/-/etag-1.7.0.tgz"
+ },
+ "engines": {
+ "node": ">= 0.6"
+ },
+ "files": [
+ "LICENSE",
+ "HISTORY.md",
+ "README.md",
+ "index.js"
+ ],
+ "gitHead": "a511f5c8c930fd9546dbd88acb080f96bc788cfc",
+ "homepage": "https://github.com/jshttp/etag",
+ "keywords": [
+ "etag",
+ "http",
+ "res"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "etag",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jshttp/etag.git"
+ },
+ "scripts": {
+ "bench": "node benchmark/index.js",
+ "test": "mocha --reporter spec --bail --check-leaks test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
+ },
+ "version": "1.7.0"
+}
diff --git a/node_modules/eventemitter3/LICENSE b/node_modules/eventemitter3/LICENSE
new file mode 100644
index 00000000..abcbd54e
--- /dev/null
+++ b/node_modules/eventemitter3/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014 Arnout Kazemier
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/eventemitter3/README.md b/node_modules/eventemitter3/README.md
new file mode 100644
index 00000000..ff209654
--- /dev/null
+++ b/node_modules/eventemitter3/README.md
@@ -0,0 +1,89 @@
+# EventEmitter3
+
+[](http://browsenpm.org/package/eventemitter3)[](https://travis-ci.org/primus/eventemitter3)[](https://david-dm.org/primus/eventemitter3)[](https://coveralls.io/r/primus/eventemitter3?branch=master)[](https://webchat.freenode.net/?channels=primus)
+
+[](https://saucelabs.com/u/eventemitter3)
+
+EventEmitter3 is a high performance EventEmitter. It has been micro-optimized
+for various of code paths making this, one of, if not the fastest EventEmitter
+available for Node.js and browsers. The module is API compatible with the
+EventEmitter that ships by default with Node.js but there are some slight
+differences:
+
+- Domain support has been removed.
+- We do not `throw` an error when you emit an `error` event and nobody is
+ listening.
+- The `newListener` event is removed as the use-cases for this functionality are
+ really just edge cases.
+- No `setMaxListeners` and it's pointless memory leak warnings. If you want to
+ add `end` listeners you should be able to do that without modules complaining.
+- No `listenerCount` function. Use `EE.listeners(event).length` instead.
+- Support for custom context for events so there is no need to use `fn.bind`.
+- `listeners` method can do existence checking instead of returning only arrays.
+
+It's a drop in replacement for existing EventEmitters, but just faster. Free
+performance, who wouldn't want that? The EventEmitter is written in EcmaScript 3
+so it will work in the oldest browsers and node versions that you need to
+support.
+
+## Installation
+
+```bash
+$ npm install --save eventemitter3 # npm
+$ component install primus/eventemitter3 # Component
+$ bower install eventemitter3 # Bower
+```
+
+## Usage
+
+After installation the only thing you need to do is require the module:
+
+```js
+var EventEmitter = require('eventemitter3');
+```
+
+And you're ready to create your own EventEmitter instances. For the API
+documentation, please follow the official Node.js documentation:
+
+http://nodejs.org/api/events.html
+
+### Contextual emits
+
+We've upgraded the API of the `EventEmitter.on`, `EventEmitter.once` and
+`EventEmitter.removeListener` to accept an extra argument which is the `context`
+or `this` value that should be set for the emitted events. This means you no
+longer have the overhead of an event that required `fn.bind` in order to get a
+custom `this` value.
+
+```js
+var EE = new EventEmitter()
+ , context = { foo: 'bar' };
+
+function emitted() {
+ console.log(this === context); // true
+}
+
+EE.once('event-name', emitted, context);
+EE.on('another-event', emitted, context);
+EE.removeListener('another-event', emitted, context);
+```
+
+### Existence
+
+To check if there is already a listener for a given event you can supply the
+`listeners` method with an extra boolean argument. This will transform the
+output from an array, to a boolean value which indicates if there are listeners
+in place for the given event:
+
+```js
+var EE = new EventEmitter();
+EE.once('event-name', function () {});
+EE.on('another-event', function () {});
+
+EE.listeners('event-name', true); // returns true
+EE.listeners('unknown-name', true); // returns false
+```
+
+## License
+
+[MIT](LICENSE)
diff --git a/node_modules/eventemitter3/index.js b/node_modules/eventemitter3/index.js
new file mode 100644
index 00000000..40819dfe
--- /dev/null
+++ b/node_modules/eventemitter3/index.js
@@ -0,0 +1,289 @@
+'use strict';
+
+var has = Object.prototype.hasOwnProperty;
+
+//
+// We store our EE objects in a plain object whose properties are event names.
+// If `Object.create(null)` is not supported we prefix the event names with a
+// `~` to make sure that the built-in object properties are not overridden or
+// used as an attack vector.
+// We also assume that `Object.create(null)` is available when the event name
+// is an ES6 Symbol.
+//
+var prefix = typeof Object.create !== 'function' ? '~' : false;
+
+/**
+ * Representation of a single EventEmitter function.
+ *
+ * @param {Function} fn Event handler to be called.
+ * @param {Mixed} context Context for function execution.
+ * @param {Boolean} [once=false] Only emit once
+ * @api private
+ */
+function EE(fn, context, once) {
+ this.fn = fn;
+ this.context = context;
+ this.once = once || false;
+}
+
+/**
+ * Minimal EventEmitter interface that is molded against the Node.js
+ * EventEmitter interface.
+ *
+ * @constructor
+ * @api public
+ */
+function EventEmitter() { /* Nothing to set */ }
+
+/**
+ * Hold the assigned EventEmitters by name.
+ *
+ * @type {Object}
+ * @private
+ */
+EventEmitter.prototype._events = undefined;
+
+/**
+ * Return an array listing the events for which the emitter has registered
+ * listeners.
+ *
+ * @returns {Array}
+ * @api public
+ */
+EventEmitter.prototype.eventNames = function eventNames() {
+ var events = this._events
+ , names = []
+ , name;
+
+ if (!events) return names;
+
+ for (name in events) {
+ if (has.call(events, name)) names.push(prefix ? name.slice(1) : name);
+ }
+
+ if (Object.getOwnPropertySymbols) {
+ return names.concat(Object.getOwnPropertySymbols(events));
+ }
+
+ return names;
+};
+
+/**
+ * Return a list of assigned event listeners.
+ *
+ * @param {String} event The events that should be listed.
+ * @param {Boolean} exists We only need to know if there are listeners.
+ * @returns {Array|Boolean}
+ * @api public
+ */
+EventEmitter.prototype.listeners = function listeners(event, exists) {
+ var evt = prefix ? prefix + event : event
+ , available = this._events && this._events[evt];
+
+ if (exists) return !!available;
+ if (!available) return [];
+ if (available.fn) return [available.fn];
+
+ for (var i = 0, l = available.length, ee = new Array(l); i < l; i++) {
+ ee[i] = available[i].fn;
+ }
+
+ return ee;
+};
+
+/**
+ * Emit an event to all registered event listeners.
+ *
+ * @param {String} event The name of the event.
+ * @returns {Boolean} Indication if we've emitted an event.
+ * @api public
+ */
+EventEmitter.prototype.emit = function emit(event, a1, a2, a3, a4, a5) {
+ var evt = prefix ? prefix + event : event;
+
+ if (!this._events || !this._events[evt]) return false;
+
+ var listeners = this._events[evt]
+ , len = arguments.length
+ , args
+ , i;
+
+ if ('function' === typeof listeners.fn) {
+ if (listeners.once) this.removeListener(event, listeners.fn, undefined, true);
+
+ switch (len) {
+ case 1: return listeners.fn.call(listeners.context), true;
+ case 2: return listeners.fn.call(listeners.context, a1), true;
+ case 3: return listeners.fn.call(listeners.context, a1, a2), true;
+ case 4: return listeners.fn.call(listeners.context, a1, a2, a3), true;
+ case 5: return listeners.fn.call(listeners.context, a1, a2, a3, a4), true;
+ case 6: return listeners.fn.call(listeners.context, a1, a2, a3, a4, a5), true;
+ }
+
+ for (i = 1, args = new Array(len -1); i < len; i++) {
+ args[i - 1] = arguments[i];
+ }
+
+ listeners.fn.apply(listeners.context, args);
+ } else {
+ var length = listeners.length
+ , j;
+
+ for (i = 0; i < length; i++) {
+ if (listeners[i].once) this.removeListener(event, listeners[i].fn, undefined, true);
+
+ switch (len) {
+ case 1: listeners[i].fn.call(listeners[i].context); break;
+ case 2: listeners[i].fn.call(listeners[i].context, a1); break;
+ case 3: listeners[i].fn.call(listeners[i].context, a1, a2); break;
+ default:
+ if (!args) for (j = 1, args = new Array(len -1); j < len; j++) {
+ args[j - 1] = arguments[j];
+ }
+
+ listeners[i].fn.apply(listeners[i].context, args);
+ }
+ }
+ }
+
+ return true;
+};
+
+/**
+ * Register a new EventListener for the given event.
+ *
+ * @param {String} event Name of the event.
+ * @param {Function} fn Callback function.
+ * @param {Mixed} [context=this] The context of the function.
+ * @api public
+ */
+EventEmitter.prototype.on = function on(event, fn, context) {
+ var listener = new EE(fn, context || this)
+ , evt = prefix ? prefix + event : event;
+
+ if (!this._events) this._events = prefix ? {} : Object.create(null);
+ if (!this._events[evt]) this._events[evt] = listener;
+ else {
+ if (!this._events[evt].fn) this._events[evt].push(listener);
+ else this._events[evt] = [
+ this._events[evt], listener
+ ];
+ }
+
+ return this;
+};
+
+/**
+ * Add an EventListener that's only called once.
+ *
+ * @param {String} event Name of the event.
+ * @param {Function} fn Callback function.
+ * @param {Mixed} [context=this] The context of the function.
+ * @api public
+ */
+EventEmitter.prototype.once = function once(event, fn, context) {
+ var listener = new EE(fn, context || this, true)
+ , evt = prefix ? prefix + event : event;
+
+ if (!this._events) this._events = prefix ? {} : Object.create(null);
+ if (!this._events[evt]) this._events[evt] = listener;
+ else {
+ if (!this._events[evt].fn) this._events[evt].push(listener);
+ else this._events[evt] = [
+ this._events[evt], listener
+ ];
+ }
+
+ return this;
+};
+
+/**
+ * Remove event listeners.
+ *
+ * @param {String} event The event we want to remove.
+ * @param {Function} fn The listener that we need to find.
+ * @param {Mixed} context Only remove listeners matching this context.
+ * @param {Boolean} once Only remove once listeners.
+ * @api public
+ */
+EventEmitter.prototype.removeListener = function removeListener(event, fn, context, once) {
+ var evt = prefix ? prefix + event : event;
+
+ if (!this._events || !this._events[evt]) return this;
+
+ var listeners = this._events[evt]
+ , events = [];
+
+ if (fn) {
+ if (listeners.fn) {
+ if (
+ listeners.fn !== fn
+ || (once && !listeners.once)
+ || (context && listeners.context !== context)
+ ) {
+ events.push(listeners);
+ }
+ } else {
+ for (var i = 0, length = listeners.length; i < length; i++) {
+ if (
+ listeners[i].fn !== fn
+ || (once && !listeners[i].once)
+ || (context && listeners[i].context !== context)
+ ) {
+ events.push(listeners[i]);
+ }
+ }
+ }
+ }
+
+ //
+ // Reset the array, or remove it completely if we have no more listeners.
+ //
+ if (events.length) {
+ this._events[evt] = events.length === 1 ? events[0] : events;
+ } else {
+ delete this._events[evt];
+ }
+
+ return this;
+};
+
+/**
+ * Remove all listeners or only the listeners for the specified event.
+ *
+ * @param {String} event The event want to remove all listeners for.
+ * @api public
+ */
+EventEmitter.prototype.removeAllListeners = function removeAllListeners(event) {
+ if (!this._events) return this;
+
+ if (event) delete this._events[prefix ? prefix + event : event];
+ else this._events = prefix ? {} : Object.create(null);
+
+ return this;
+};
+
+//
+// Alias methods names because people roll like that.
+//
+EventEmitter.prototype.off = EventEmitter.prototype.removeListener;
+EventEmitter.prototype.addListener = EventEmitter.prototype.on;
+
+//
+// This function doesn't apply anymore.
+//
+EventEmitter.prototype.setMaxListeners = function setMaxListeners() {
+ return this;
+};
+
+//
+// Expose the prefix.
+//
+EventEmitter.prefixed = prefix;
+
+//
+// Expose the module.
+//
+if ('undefined' !== typeof module) {
+ module.exports = EventEmitter;
+}
diff --git a/node_modules/eventemitter3/package.json b/node_modules/eventemitter3/package.json
new file mode 100644
index 00000000..c796b990
--- /dev/null
+++ b/node_modules/eventemitter3/package.json
@@ -0,0 +1,119 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "eventemitter3@1.x.x",
+ "scope": null,
+ "escapedName": "eventemitter3",
+ "name": "eventemitter3",
+ "rawSpec": "1.x.x",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/http-proxy"
+ ]
+ ],
+ "_from": "eventemitter3@>=1.0.0 <2.0.0",
+ "_id": "eventemitter3@1.2.0",
+ "_inCache": true,
+ "_location": "/eventemitter3",
+ "_nodeVersion": "4.3.1",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/eventemitter3-1.2.0.tgz_1458148661717_0.1867425285745412"
+ },
+ "_npmUser": {
+ "name": "3rdeden",
+ "email": "npm@3rd-Eden.com"
+ },
+ "_npmVersion": "3.8.0",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "eventemitter3@1.x.x",
+ "scope": null,
+ "escapedName": "eventemitter3",
+ "name": "eventemitter3",
+ "rawSpec": "1.x.x",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/http-proxy"
+ ],
+ "_resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-1.2.0.tgz",
+ "_shasum": "1c86991d816ad1e504750e73874224ecf3bec508",
+ "_shrinkwrap": null,
+ "_spec": "eventemitter3@1.x.x",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/http-proxy",
+ "author": {
+ "name": "Arnout Kazemier"
+ },
+ "bugs": {
+ "url": "https://github.com/primus/eventemitter3/issues"
+ },
+ "dependencies": {},
+ "description": "EventEmitter3 focuses on performance while maintaining a Node.js AND browser compatible interface.",
+ "devDependencies": {
+ "assume": "1.3.x",
+ "istanbul": "0.4.x",
+ "mocha": "2.4.x",
+ "pre-commit": "1.1.x",
+ "zuul": "3.10.x"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "1c86991d816ad1e504750e73874224ecf3bec508",
+ "tarball": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-1.2.0.tgz"
+ },
+ "gitHead": "c78d597fed80952c259b916c0a1f4dca91d940e4",
+ "homepage": "https://github.com/primus/eventemitter3#readme",
+ "keywords": [
+ "EventEmitter",
+ "EventEmitter2",
+ "EventEmitter3",
+ "Events",
+ "addEventListener",
+ "addListener",
+ "emit",
+ "emits",
+ "emitter",
+ "event",
+ "once",
+ "pub/sub",
+ "publish",
+ "reactor",
+ "subscribe"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "v1",
+ "email": "npm@3rd-Eden.com"
+ },
+ {
+ "name": "3rdeden",
+ "email": "npm@3rd-Eden.com"
+ },
+ {
+ "name": "lpinca",
+ "email": "luigipinca@gmail.com"
+ }
+ ],
+ "name": "eventemitter3",
+ "optionalDependencies": {},
+ "pre-commit": "sync, test",
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/primus/eventemitter3.git"
+ },
+ "scripts": {
+ "coverage": "istanbul cover _mocha -- test.js",
+ "sync": "node versions.js",
+ "test": "mocha test.js",
+ "test-browser": "zuul -- test.js",
+ "test-node": "istanbul cover _mocha --report lcovonly -- test.js"
+ },
+ "version": "1.2.0"
+}
diff --git a/node_modules/events/.npmignore b/node_modules/events/.npmignore
new file mode 100644
index 00000000..3c3629e6
--- /dev/null
+++ b/node_modules/events/.npmignore
@@ -0,0 +1 @@
+node_modules
diff --git a/node_modules/events/.travis.yml b/node_modules/events/.travis.yml
new file mode 100644
index 00000000..002b0422
--- /dev/null
+++ b/node_modules/events/.travis.yml
@@ -0,0 +1,8 @@
+sudo: false
+language: node_js
+node_js:
+- '0.10'
+env:
+ global:
+ - secure: XcBiD8yReflut9q7leKsigDZ0mI3qTKH+QrNVY8DaqlomJOZw8aOrVuX9Jz12l86ZJ41nbxmKnRNkFzcVr9mbP9YaeTb3DpeOBWmvaoSfud9Wnc16VfXtc1FCcwDhSVcSiM3UtnrmFU5cH+Dw1LPh5PbfylYOS/nJxUvG0FFLqI=
+ - secure: jNWtEbqhUdQ0xXDHvCYfUbKYeJCi6a7B4LsrcxYCyWWn4NIgncE5x2YbB+FSUUFVYfz0dsn5RKP1oHB99f0laUEo18HBNkrAS/rtyOdVzcpJjbQ6kgSILGjnJD/Ty1B57Rcz3iyev5Y7bLZ6Y1FbDnk/i9/l0faOGz8vTC3Vdkc=
diff --git a/node_modules/events/.zuul.yml b/node_modules/events/.zuul.yml
new file mode 100644
index 00000000..a8e35afd
--- /dev/null
+++ b/node_modules/events/.zuul.yml
@@ -0,0 +1,12 @@
+ui: mocha-qunit
+browsers:
+ - name: chrome
+ version: latest
+ - name: firefox
+ version: latest
+ - name: safari
+ version: 5..latest
+ - name: iphone
+ version: latest
+ - name: ie
+ version: 8..latest
diff --git a/node_modules/events/History.md b/node_modules/events/History.md
new file mode 100644
index 00000000..b345858e
--- /dev/null
+++ b/node_modules/events/History.md
@@ -0,0 +1,42 @@
+# 1.1.1 (2016-06-22)
+
+ - add more context to errors if they are not instanceof Error
+
+# 1.1.0 (2015-09-29)
+
+ - add Emitter#listerCount (to match node v4 api)
+
+# 1.0.2 (2014-08-28)
+
+ - remove un-reachable code
+ - update devDeps
+
+## 1.0.1 / 2014-05-11
+
+ - check for console.trace before using it
+
+## 1.0.0 / 2013-12-10
+
+ - Update to latest events code from node.js 0.10
+ - copy tests from node.js
+
+## 0.4.0 / 2011-07-03 ##
+
+ - Switching to graphquire@0.8.0
+
+## 0.3.0 / 2011-07-03 ##
+
+ - Switching to URL based module require.
+
+## 0.2.0 / 2011-06-10 ##
+
+ - Simplified package structure.
+ - Graphquire for dependency management.
+
+## 0.1.1 / 2011-05-16 ##
+
+ - Unhandled errors are logged via console.error
+
+## 0.1.0 / 2011-04-22 ##
+
+ - Initial release
diff --git a/node_modules/events/LICENSE b/node_modules/events/LICENSE
new file mode 100644
index 00000000..52ed3b0a
--- /dev/null
+++ b/node_modules/events/LICENSE
@@ -0,0 +1,22 @@
+MIT
+
+Copyright Joyent, Inc. and other Node contributors.
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to permit
+persons to whom the Software is furnished to do so, subject to the
+following conditions:
+
+The above copyright notice and this permission notice shall be included
+in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/events/Readme.md b/node_modules/events/Readme.md
new file mode 100644
index 00000000..02694efa
--- /dev/null
+++ b/node_modules/events/Readme.md
@@ -0,0 +1,19 @@
+# events [](https://travis-ci.org/Gozala/events)
+
+Node's event emitter for all engines.
+
+## Install ##
+
+```
+npm install events
+```
+
+## Require ##
+
+```javascript
+var EventEmitter = require('events').EventEmitter
+```
+
+## Usage ##
+
+See the [node.js event emitter docs](http://nodejs.org/api/events.html)
diff --git a/node_modules/events/events.js b/node_modules/events/events.js
new file mode 100644
index 00000000..1619a623
--- /dev/null
+++ b/node_modules/events/events.js
@@ -0,0 +1,302 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+function EventEmitter() {
+ this._events = this._events || {};
+ this._maxListeners = this._maxListeners || undefined;
+}
+module.exports = EventEmitter;
+
+// Backwards-compat with node 0.10.x
+EventEmitter.EventEmitter = EventEmitter;
+
+EventEmitter.prototype._events = undefined;
+EventEmitter.prototype._maxListeners = undefined;
+
+// By default EventEmitters will print a warning if more than 10 listeners are
+// added to it. This is a useful default which helps finding memory leaks.
+EventEmitter.defaultMaxListeners = 10;
+
+// Obviously not all Emitters should be limited to 10. This function allows
+// that to be increased. Set to zero for unlimited.
+EventEmitter.prototype.setMaxListeners = function(n) {
+ if (!isNumber(n) || n < 0 || isNaN(n))
+ throw TypeError('n must be a positive number');
+ this._maxListeners = n;
+ return this;
+};
+
+EventEmitter.prototype.emit = function(type) {
+ var er, handler, len, args, i, listeners;
+
+ if (!this._events)
+ this._events = {};
+
+ // If there is no 'error' event listener then throw.
+ if (type === 'error') {
+ if (!this._events.error ||
+ (isObject(this._events.error) && !this._events.error.length)) {
+ er = arguments[1];
+ if (er instanceof Error) {
+ throw er; // Unhandled 'error' event
+ } else {
+ // At least give some kind of context to the user
+ var err = new Error('Uncaught, unspecified "error" event. (' + er + ')');
+ err.context = er;
+ throw err;
+ }
+ }
+ }
+
+ handler = this._events[type];
+
+ if (isUndefined(handler))
+ return false;
+
+ if (isFunction(handler)) {
+ switch (arguments.length) {
+ // fast cases
+ case 1:
+ handler.call(this);
+ break;
+ case 2:
+ handler.call(this, arguments[1]);
+ break;
+ case 3:
+ handler.call(this, arguments[1], arguments[2]);
+ break;
+ // slower
+ default:
+ args = Array.prototype.slice.call(arguments, 1);
+ handler.apply(this, args);
+ }
+ } else if (isObject(handler)) {
+ args = Array.prototype.slice.call(arguments, 1);
+ listeners = handler.slice();
+ len = listeners.length;
+ for (i = 0; i < len; i++)
+ listeners[i].apply(this, args);
+ }
+
+ return true;
+};
+
+EventEmitter.prototype.addListener = function(type, listener) {
+ var m;
+
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ if (!this._events)
+ this._events = {};
+
+ // To avoid recursion in the case that type === "newListener"! Before
+ // adding it to the listeners, first emit "newListener".
+ if (this._events.newListener)
+ this.emit('newListener', type,
+ isFunction(listener.listener) ?
+ listener.listener : listener);
+
+ if (!this._events[type])
+ // Optimize the case of one listener. Don't need the extra array object.
+ this._events[type] = listener;
+ else if (isObject(this._events[type]))
+ // If we've already got an array, just append.
+ this._events[type].push(listener);
+ else
+ // Adding the second element, need to change to array.
+ this._events[type] = [this._events[type], listener];
+
+ // Check for listener leak
+ if (isObject(this._events[type]) && !this._events[type].warned) {
+ if (!isUndefined(this._maxListeners)) {
+ m = this._maxListeners;
+ } else {
+ m = EventEmitter.defaultMaxListeners;
+ }
+
+ if (m && m > 0 && this._events[type].length > m) {
+ this._events[type].warned = true;
+ console.error('(node) warning: possible EventEmitter memory ' +
+ 'leak detected. %d listeners added. ' +
+ 'Use emitter.setMaxListeners() to increase limit.',
+ this._events[type].length);
+ if (typeof console.trace === 'function') {
+ // not supported in IE 10
+ console.trace();
+ }
+ }
+ }
+
+ return this;
+};
+
+EventEmitter.prototype.on = EventEmitter.prototype.addListener;
+
+EventEmitter.prototype.once = function(type, listener) {
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ var fired = false;
+
+ function g() {
+ this.removeListener(type, g);
+
+ if (!fired) {
+ fired = true;
+ listener.apply(this, arguments);
+ }
+ }
+
+ g.listener = listener;
+ this.on(type, g);
+
+ return this;
+};
+
+// emits a 'removeListener' event iff the listener was removed
+EventEmitter.prototype.removeListener = function(type, listener) {
+ var list, position, length, i;
+
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ if (!this._events || !this._events[type])
+ return this;
+
+ list = this._events[type];
+ length = list.length;
+ position = -1;
+
+ if (list === listener ||
+ (isFunction(list.listener) && list.listener === listener)) {
+ delete this._events[type];
+ if (this._events.removeListener)
+ this.emit('removeListener', type, listener);
+
+ } else if (isObject(list)) {
+ for (i = length; i-- > 0;) {
+ if (list[i] === listener ||
+ (list[i].listener && list[i].listener === listener)) {
+ position = i;
+ break;
+ }
+ }
+
+ if (position < 0)
+ return this;
+
+ if (list.length === 1) {
+ list.length = 0;
+ delete this._events[type];
+ } else {
+ list.splice(position, 1);
+ }
+
+ if (this._events.removeListener)
+ this.emit('removeListener', type, listener);
+ }
+
+ return this;
+};
+
+EventEmitter.prototype.removeAllListeners = function(type) {
+ var key, listeners;
+
+ if (!this._events)
+ return this;
+
+ // not listening for removeListener, no need to emit
+ if (!this._events.removeListener) {
+ if (arguments.length === 0)
+ this._events = {};
+ else if (this._events[type])
+ delete this._events[type];
+ return this;
+ }
+
+ // emit removeListener for all listeners on all events
+ if (arguments.length === 0) {
+ for (key in this._events) {
+ if (key === 'removeListener') continue;
+ this.removeAllListeners(key);
+ }
+ this.removeAllListeners('removeListener');
+ this._events = {};
+ return this;
+ }
+
+ listeners = this._events[type];
+
+ if (isFunction(listeners)) {
+ this.removeListener(type, listeners);
+ } else if (listeners) {
+ // LIFO order
+ while (listeners.length)
+ this.removeListener(type, listeners[listeners.length - 1]);
+ }
+ delete this._events[type];
+
+ return this;
+};
+
+EventEmitter.prototype.listeners = function(type) {
+ var ret;
+ if (!this._events || !this._events[type])
+ ret = [];
+ else if (isFunction(this._events[type]))
+ ret = [this._events[type]];
+ else
+ ret = this._events[type].slice();
+ return ret;
+};
+
+EventEmitter.prototype.listenerCount = function(type) {
+ if (this._events) {
+ var evlistener = this._events[type];
+
+ if (isFunction(evlistener))
+ return 1;
+ else if (evlistener)
+ return evlistener.length;
+ }
+ return 0;
+};
+
+EventEmitter.listenerCount = function(emitter, type) {
+ return emitter.listenerCount(type);
+};
+
+function isFunction(arg) {
+ return typeof arg === 'function';
+}
+
+function isNumber(arg) {
+ return typeof arg === 'number';
+}
+
+function isObject(arg) {
+ return typeof arg === 'object' && arg !== null;
+}
+
+function isUndefined(arg) {
+ return arg === void 0;
+}
diff --git a/node_modules/events/package.json b/node_modules/events/package.json
new file mode 100644
index 00000000..1ad2e7e5
--- /dev/null
+++ b/node_modules/events/package.json
@@ -0,0 +1,103 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "events@^1.0.0",
+ "scope": null,
+ "escapedName": "events",
+ "name": "events",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/node-libs-browser"
+ ]
+ ],
+ "_from": "events@>=1.0.0 <2.0.0",
+ "_id": "events@1.1.1",
+ "_inCache": true,
+ "_location": "/events",
+ "_nodeVersion": "6.2.0",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/events-1.1.1.tgz_1466611759829_0.353814059169963"
+ },
+ "_npmUser": {
+ "name": "defunctzombie",
+ "email": "shtylman@gmail.com"
+ },
+ "_npmVersion": "3.8.9",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "events@^1.0.0",
+ "scope": null,
+ "escapedName": "events",
+ "name": "events",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/node-libs-browser"
+ ],
+ "_resolved": "https://registry.npmjs.org/events/-/events-1.1.1.tgz",
+ "_shasum": "9ebdb7635ad099c70dcc4c2a1f5004288e8bd924",
+ "_shrinkwrap": null,
+ "_spec": "events@^1.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/node-libs-browser",
+ "author": {
+ "name": "Irakli Gozalishvili",
+ "email": "rfobic@gmail.com",
+ "url": "http://jeditoolkit.com"
+ },
+ "bugs": {
+ "url": "http://github.com/Gozala/events/issues/"
+ },
+ "dependencies": {},
+ "description": "Node's event emitter for all engines.",
+ "devDependencies": {
+ "mocha": "~1.21.4",
+ "zuul": "~1.10.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "9ebdb7635ad099c70dcc4c2a1f5004288e8bd924",
+ "tarball": "https://registry.npmjs.org/events/-/events-1.1.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.4.x"
+ },
+ "gitHead": "623b6f54f3cdccedd71b8b0f5e4b755bacdb5c62",
+ "homepage": "https://github.com/Gozala/events#readme",
+ "id": "events",
+ "keywords": [
+ "events",
+ "eventEmitter",
+ "eventDispatcher",
+ "listeners"
+ ],
+ "license": "MIT",
+ "main": "./events.js",
+ "maintainers": [
+ {
+ "name": "gozala",
+ "email": "rfobic@gmail.com"
+ },
+ {
+ "name": "defunctzombie",
+ "email": "shtylman@gmail.com"
+ }
+ ],
+ "name": "events",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/Gozala/events.git",
+ "web": "https://github.com/Gozala/events"
+ },
+ "scripts": {
+ "test": "mocha --ui qunit -- tests/index.js && zuul -- tests/index.js"
+ },
+ "version": "1.1.1"
+}
diff --git a/node_modules/events/tests/add-listeners.js b/node_modules/events/tests/add-listeners.js
new file mode 100644
index 00000000..5ab874ce
--- /dev/null
+++ b/node_modules/events/tests/add-listeners.js
@@ -0,0 +1,63 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+var assert = require('assert');
+var events = require('../');
+
+var e = new events.EventEmitter();
+
+var events_new_listener_emited = [];
+var listeners_new_listener_emited = [];
+var times_hello_emited = 0;
+
+// sanity check
+assert.equal(e.addListener, e.on);
+
+e.on('newListener', function(event, listener) {
+ console.log('newListener: ' + event);
+ events_new_listener_emited.push(event);
+ listeners_new_listener_emited.push(listener);
+});
+
+function hello(a, b) {
+ console.log('hello');
+ times_hello_emited += 1;
+ assert.equal('a', a);
+ assert.equal('b', b);
+}
+e.on('hello', hello);
+
+var foo = function() {};
+e.once('foo', foo);
+
+console.log('start');
+
+e.emit('hello', 'a', 'b');
+
+
+// just make sure that this doesn't throw:
+var f = new events.EventEmitter();
+f.setMaxListeners(0);
+
+assert.deepEqual(['hello', 'foo'], events_new_listener_emited);
+assert.deepEqual([hello, foo], listeners_new_listener_emited);
+assert.equal(1, times_hello_emited);
+
diff --git a/node_modules/events/tests/check-listener-leaks.js b/node_modules/events/tests/check-listener-leaks.js
new file mode 100644
index 00000000..e07866a5
--- /dev/null
+++ b/node_modules/events/tests/check-listener-leaks.js
@@ -0,0 +1,86 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+var assert = require('assert');
+var events = require('../');
+
+var e = new events.EventEmitter();
+
+// default
+for (var i = 0; i < 10; i++) {
+ e.on('default', function() {});
+}
+assert.ok(!e._events['default'].hasOwnProperty('warned'));
+e.on('default', function() {});
+assert.ok(e._events['default'].warned);
+
+// specific
+e.setMaxListeners(5);
+for (var i = 0; i < 5; i++) {
+ e.on('specific', function() {});
+}
+assert.ok(!e._events['specific'].hasOwnProperty('warned'));
+e.on('specific', function() {});
+assert.ok(e._events['specific'].warned);
+
+// only one
+e.setMaxListeners(1);
+e.on('only one', function() {});
+assert.ok(!e._events['only one'].hasOwnProperty('warned'));
+e.on('only one', function() {});
+assert.ok(e._events['only one'].hasOwnProperty('warned'));
+
+// unlimited
+e.setMaxListeners(0);
+for (var i = 0; i < 1000; i++) {
+ e.on('unlimited', function() {});
+}
+assert.ok(!e._events['unlimited'].hasOwnProperty('warned'));
+
+// process-wide
+events.EventEmitter.defaultMaxListeners = 42;
+e = new events.EventEmitter();
+
+for (var i = 0; i < 42; ++i) {
+ e.on('fortytwo', function() {});
+}
+assert.ok(!e._events['fortytwo'].hasOwnProperty('warned'));
+e.on('fortytwo', function() {});
+assert.ok(e._events['fortytwo'].hasOwnProperty('warned'));
+delete e._events['fortytwo'].warned;
+
+events.EventEmitter.defaultMaxListeners = 44;
+e.on('fortytwo', function() {});
+assert.ok(!e._events['fortytwo'].hasOwnProperty('warned'));
+e.on('fortytwo', function() {});
+assert.ok(e._events['fortytwo'].hasOwnProperty('warned'));
+
+// but _maxListeners still has precedence over defaultMaxListeners
+events.EventEmitter.defaultMaxListeners = 42;
+e = new events.EventEmitter();
+e.setMaxListeners(1);
+e.on('uno', function() {});
+assert.ok(!e._events['uno'].hasOwnProperty('warned'));
+e.on('uno', function() {});
+assert.ok(e._events['uno'].hasOwnProperty('warned'));
+
+// chainable
+assert.strictEqual(e, e.setMaxListeners(1));
diff --git a/node_modules/events/tests/common.js b/node_modules/events/tests/common.js
new file mode 100644
index 00000000..66f70a39
--- /dev/null
+++ b/node_modules/events/tests/common.js
@@ -0,0 +1,42 @@
+var assert = require('assert');
+
+var mustCallChecks = [];
+
+function runCallChecks() {
+ var failed_count = 0;
+ for (var i=0 ; i< mustCallChecks.length; ++i) {
+ var context = mustCallChecks[i];
+ if (context.actual === context.expected) {
+ continue;
+ }
+
+ failed_count++;
+ console.log('Mismatched %s function calls. Expected %d, actual %d.',
+ context.name,
+ context.expected,
+ context.actual);
+ console.log(context.stack.split('\n').slice(2).join('\n'));
+ }
+
+ assert(failed_count === 0);
+}
+
+after(runCallChecks);
+
+exports.mustCall = function(fn, expected) {
+ if (typeof expected !== 'number') expected = 1;
+
+ var context = {
+ expected: expected,
+ actual: 0,
+ stack: (new Error).stack,
+ name: fn.name || ''
+ };
+
+ mustCallChecks.push(context);
+
+ return function() {
+ context.actual++;
+ return fn.apply(this, arguments);
+ };
+};
diff --git a/node_modules/events/tests/index.js b/node_modules/events/tests/index.js
new file mode 100644
index 00000000..f144530b
--- /dev/null
+++ b/node_modules/events/tests/index.js
@@ -0,0 +1,25 @@
+
+require('./legacy-compat');
+
+// we do this to easily wrap each file in a mocha test
+// and also have browserify be able to statically analyze this file
+var orig_require = require;
+var require = function(file) {
+ test(file, function() {
+ orig_require(file);
+ });
+}
+
+require('./add-listeners.js');
+require('./check-listener-leaks.js');
+require('./listener-count.js');
+require('./listeners-side-effects.js');
+require('./listeners.js');
+require('./max-listeners.js');
+require('./modify-in-emit.js');
+require('./num-args.js');
+require('./once.js');
+require('./set-max-listeners-side-effects.js');
+require('./subclass.js');
+require('./remove-all-listeners.js');
+require('./remove-listeners.js');
diff --git a/node_modules/events/tests/legacy-compat.js b/node_modules/events/tests/legacy-compat.js
new file mode 100644
index 00000000..afbc0ab8
--- /dev/null
+++ b/node_modules/events/tests/legacy-compat.js
@@ -0,0 +1,18 @@
+// sigh... life is hard
+if (!global.console) {
+ console = {}
+}
+
+var fns = ['log', 'error', 'trace'];
+for (var i=0 ; ifoo should not be emitted', '!');
+};
+
+e.once('foo', remove);
+e.removeListener('foo', remove);
+e.emit('foo');
+
+var times_recurse_emitted = 0;
+
+e.once('e', function() {
+ e.emit('e');
+ times_recurse_emitted++;
+});
+
+e.once('e', function() {
+ times_recurse_emitted++;
+});
+
+e.emit('e');
+
+assert.equal(1, times_hello_emited);
+assert.equal(2, times_recurse_emitted);
diff --git a/node_modules/events/tests/remove-all-listeners.js b/node_modules/events/tests/remove-all-listeners.js
new file mode 100644
index 00000000..b3dc886e
--- /dev/null
+++ b/node_modules/events/tests/remove-all-listeners.js
@@ -0,0 +1,80 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+var common = require('./common');
+var assert = require('assert');
+var events = require('../');
+
+var after_checks = [];
+after(function() {
+ for (var i=0 ; i 0) {
+ buf = buf.slice(pos);
+ }
+ });
+ });
+
+ req.on('error', onConnectionClosed);
+ req.setNoDelay(true);
+ req.end();
+ }
+
+ connect();
+
+ function _emit() {
+ if (self.listeners(arguments[0]).length > 0) {
+ self.emit.apply(self, arguments);
+ }
+ }
+
+ this.close = function () {
+ if (readyState == EventSource.CLOSED) return;
+ readyState = EventSource.CLOSED;
+ req.abort();
+ };
+
+ function parseEventStreamLine(buf, pos, fieldLength, lineLength) {
+ if (lineLength === 0) {
+ if (data.length > 0) {
+ var type = eventName || 'message';
+ _emit(type, new MessageEvent(type, {
+ data: data.slice(0, -1), // remove trailing newline
+ lastEventId: lastEventId,
+ origin: original(url)
+ }));
+ data = '';
+ }
+ eventName = void 0;
+ } else if (fieldLength > 0) {
+ var noValue = fieldLength < 0
+ , step = 0
+ , field = buf.slice(pos, pos + (noValue ? lineLength : fieldLength));
+
+ if (noValue) {
+ step = lineLength;
+ } else if (buf[pos + fieldLength + 1] !== ' ') {
+ step = fieldLength + 1;
+ } else {
+ step = fieldLength + 2;
+ }
+ pos += step;
+ var valueLength = lineLength - step
+ , value = buf.slice(pos, pos + valueLength);
+
+ if (field === 'data') {
+ data += value + '\n';
+ } else if (field === 'event') {
+ eventName = value;
+ } else if (field === 'id') {
+ lastEventId = value;
+ } else if (field === 'retry') {
+ var retry = parseInt(value, 10);
+ if (!Number.isNaN(retry)) {
+ self.reconnectInterval = retry;
+ }
+ }
+ }
+ }
+}
+
+module.exports = EventSource;
+
+util.inherits(EventSource, events.EventEmitter);
+EventSource.prototype.constructor = EventSource; // make stacktraces readable
+
+['open', 'error', 'message'].forEach(function (method) {
+ Object.defineProperty(EventSource.prototype, 'on' + method, {
+ /**
+ * Returns the current listener
+ *
+ * @return {Mixed} the set function or undefined
+ * @api private
+ */
+ get: function get() {
+ var listener = this.listeners(method)[0];
+ return listener ? (listener._listener ? listener._listener : listener) : undefined;
+ },
+
+ /**
+ * Start listening for events
+ *
+ * @param {Function} listener the listener
+ * @return {Mixed} the set function or undefined
+ * @api private
+ */
+ set: function set(listener) {
+ this.removeAllListeners(method);
+ this.addEventListener(method, listener);
+ }
+ });
+});
+
+/**
+ * Ready states
+ */
+Object.defineProperty(EventSource, 'CONNECTING', { enumerable: true, value: 0});
+Object.defineProperty(EventSource, 'OPEN', { enumerable: true, value: 1});
+Object.defineProperty(EventSource, 'CLOSED', { enumerable: true, value: 2});
+
+/**
+ * Emulates the W3C Browser based WebSocket interface using addEventListener.
+ *
+ * @param {String} method Listen for an event
+ * @param {Function} listener callback
+ * @see https://developer.mozilla.org/en/DOM/element.addEventListener
+ * @see http://dev.w3.org/html5/websockets/#the-websocket-interface
+ * @api public
+ */
+EventSource.prototype.addEventListener = function addEventListener(method, listener) {
+ if (typeof listener === 'function') {
+ // store a reference so we can return the original function again
+ listener._listener = listener;
+ this.on(method, listener);
+ }
+};
+
+/**
+ * W3C Event
+ *
+ * @see http://www.w3.org/TR/DOM-Level-3-Events/#interface-Event
+ * @api private
+ */
+function Event(type, optionalProperties) {
+ Object.defineProperty(this, 'type', { writable: false, value: type, enumerable: true });
+ if (optionalProperties) {
+ for (var f in optionalProperties) {
+ if (optionalProperties.hasOwnProperty(f)) {
+ Object.defineProperty(this, f, { writable: false, value: optionalProperties[f], enumerable: true });
+ }
+ }
+ }
+}
+
+/**
+ * W3C MessageEvent
+ *
+ * @see http://www.w3.org/TR/webmessaging/#event-definitions
+ * @api private
+ */
+function MessageEvent(type, eventInitDict) {
+ Object.defineProperty(this, 'type', { writable: false, value: type, enumerable: true });
+ for (var f in eventInitDict) {
+ if (eventInitDict.hasOwnProperty(f)) {
+ Object.defineProperty(this, f, { writable: false, value: eventInitDict[f], enumerable: true });
+ }
+ }
+}
diff --git a/node_modules/eventsource/package.json b/node_modules/eventsource/package.json
new file mode 100644
index 00000000..10cd76c7
--- /dev/null
+++ b/node_modules/eventsource/package.json
@@ -0,0 +1,101 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "eventsource@0.1.6",
+ "scope": null,
+ "escapedName": "eventsource",
+ "name": "eventsource",
+ "rawSpec": "0.1.6",
+ "spec": "0.1.6",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/sockjs-client"
+ ]
+ ],
+ "_from": "eventsource@0.1.6",
+ "_id": "eventsource@0.1.6",
+ "_inCache": true,
+ "_location": "/eventsource",
+ "_nodeVersion": "0.12.0",
+ "_npmUser": {
+ "name": "aslakhellesoy",
+ "email": "aslak.hellesoy@gmail.com"
+ },
+ "_npmVersion": "2.5.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "eventsource@0.1.6",
+ "scope": null,
+ "escapedName": "eventsource",
+ "name": "eventsource",
+ "rawSpec": "0.1.6",
+ "spec": "0.1.6",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/sockjs-client"
+ ],
+ "_resolved": "https://registry.npmjs.org/eventsource/-/eventsource-0.1.6.tgz",
+ "_shasum": "0acede849ed7dd1ccc32c811bb11b944d4f29232",
+ "_shrinkwrap": null,
+ "_spec": "eventsource@0.1.6",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/sockjs-client",
+ "author": {
+ "name": "Aslak Hellesøy",
+ "email": "aslak.hellesoy@gmail.com"
+ },
+ "bugs": {
+ "url": "http://github.com/aslakhellesoy/eventsource-node/issues"
+ },
+ "dependencies": {
+ "original": ">=0.0.5"
+ },
+ "description": "W3C compliant EventSource client for Node.js",
+ "devDependencies": {
+ "mocha": ">=1.21.4"
+ },
+ "directories": {
+ "lib": "./lib"
+ },
+ "dist": {
+ "shasum": "0acede849ed7dd1ccc32c811bb11b944d4f29232",
+ "tarball": "https://registry.npmjs.org/eventsource/-/eventsource-0.1.6.tgz"
+ },
+ "engines": {
+ "node": ">=0.8.0"
+ },
+ "gitHead": "c93edb547891f7cbd8d576751427445029bb782b",
+ "homepage": "http://github.com/aslakhellesoy/eventsource-node",
+ "keywords": [
+ "eventsource",
+ "http",
+ "streaming",
+ "sse"
+ ],
+ "licenses": [
+ {
+ "type": "MIT",
+ "url": "http://github.com/aslakhellesoy/eventsource-node/raw/master/LICENSE"
+ }
+ ],
+ "main": "./lib/eventsource",
+ "maintainers": [
+ {
+ "name": "aslakhellesoy",
+ "email": "aslak.hellesoy@gmail.com"
+ }
+ ],
+ "name": "eventsource",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/aslakhellesoy/eventsource-node.git"
+ },
+ "scripts": {
+ "postpublish": "git push && git push --tags",
+ "test": "mocha --reporter spec"
+ },
+ "version": "0.1.6"
+}
diff --git a/node_modules/eventsource/test/certificate.pem b/node_modules/eventsource/test/certificate.pem
new file mode 100644
index 00000000..0efc2ef5
--- /dev/null
+++ b/node_modules/eventsource/test/certificate.pem
@@ -0,0 +1,13 @@
+-----BEGIN CERTIFICATE-----
+MIICATCCAWoCCQDPufXH86n2QzANBgkqhkiG9w0BAQUFADBFMQswCQYDVQQGEwJu
+bzETMBEGA1UECAwKU29tZS1TdGF0ZTEhMB8GA1UECgwYSW50ZXJuZXQgV2lkZ2l0
+cyBQdHkgTHRkMB4XDTEyMDEwMTE0NDQwMFoXDTIwMDMxOTE0NDQwMFowRTELMAkG
+A1UEBhMCbm8xEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMGEludGVybmV0
+IFdpZGdpdHMgUHR5IEx0ZDCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAtrQ7
++r//2iV/B6F+4boH0XqFn7alcV9lpjvAmwRXNKnxAoa0f97AjYPGNLKrjpkNXXhB
+JROIdbRbZnCNeC5fzX1a+JCo7KStzBXuGSZr27TtFmcV4H+9gIRIcNHtZmJLnxbJ
+sIhkGR8yVYdmJZe4eT5ldk1zoB1adgPF1hZhCBMCAwEAATANBgkqhkiG9w0BAQUF
+AAOBgQCeWBEHYJ4mCB5McwSSUox0T+/mJ4W48L/ZUE4LtRhHasU9hiW92xZkTa7E
+QLcoJKQiWfiLX2ysAro0NX4+V8iqLziMqvswnPzz5nezaOLE/9U/QvH3l8qqNkXu
+rNbsW1h/IO6FV8avWFYVFoutUwOaZ809k7iMh2F2JMgXQ5EymQ==
+-----END CERTIFICATE-----
diff --git a/node_modules/eventsource/test/eventsource_test.js b/node_modules/eventsource/test/eventsource_test.js
new file mode 100644
index 00000000..79f0709a
--- /dev/null
+++ b/node_modules/eventsource/test/eventsource_test.js
@@ -0,0 +1,875 @@
+var EventSource = require('../lib/eventsource')
+ , http = require('http')
+ , https = require('https')
+ , fs = require('fs')
+ , assert = require('assert')
+ , u = require('url');
+
+var _port = 20000;
+var servers = 0;
+process.on('exit', function () {
+ if (servers != 0) {
+ console.error("************ Didn't kill all servers - there is still %d running.", servers);
+ }
+});
+
+function createServer(callback) {
+ var server = http.createServer();
+ configureServer(server, 'http', _port++, callback);
+}
+
+function createHttpsServer(callback) {
+ var options = {
+ key: fs.readFileSync(__dirname + '/key.pem'),
+ cert: fs.readFileSync(__dirname + '/certificate.pem')
+ };
+ var server = https.createServer(options);
+ configureServer(server, 'https', _port++, callback);
+}
+
+function configureServer(server, protocol, port, callback) {
+ var responses = [];
+
+ var oldClose = server.close;
+ server.close = function() {
+ responses.forEach(function (res) {
+ res.end();
+ });
+ servers--;
+ oldClose.apply(this, arguments);
+ };
+
+ server.on('request', function (req, res) {
+ responses.push(res);
+ });
+
+ server.url = protocol + '://localhost:' + port;
+
+ server.listen(port, function onOpen(err) {
+ servers++;
+ callback(err, server);
+ });
+}
+
+function writeEvents(chunks) {
+ return function (req, res) {
+ res.writeHead(200, {'Content-Type': 'text/event-stream'});
+ chunks.forEach(function (chunk) {
+ res.write(chunk);
+ });
+ res.write(':'); // send a dummy comment to ensure that the head is flushed
+ };
+}
+
+describe('Parser', function () {
+ it('parses multibyte characters', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["id: 1\ndata: €豆腐\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ assert.equal("€豆腐", m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('parses empty lines with multibyte characters', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["\n\n\n\nid: 1\ndata: 我現在都看實況不玩遊戲\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ assert.equal("我現在都看實況不玩遊戲", m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('parses one one-line message in one chunk', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: Hello\n\n"]));
+ var es = new EventSource(server.url);
+ es.onmessage = function (m) {
+ assert.equal("Hello", m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('parses one one-line message in two chunks', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: Hel", "lo\n\n"]));
+ var es = new EventSource(server.url);
+ es.onmessage = function (m) {
+ assert.equal("Hello", m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('parses two one-line messages in one chunk', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: Hello\n\n", "data: World\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first(m) {
+ assert.equal("Hello", m.data);
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal("World", m.data);
+ server.close(done);
+ }
+ });
+ });
+
+ it('parses one two-line message in one chunk', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: Hello\ndata:World\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ assert.equal("Hello\nWorld", m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('parses really chopped up unicode data', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ var chopped = "data: Aslak\n\ndata: Hellesøy\n\n".split("");
+ server.on('request', writeEvents(chopped));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first(m) {
+ assert.equal("Aslak", m.data);
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal("Hellesøy", m.data);
+ server.close(done);
+ }
+ });
+ });
+
+ it('accepts CRLF as separator', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ var chopped = "data: Aslak\r\n\r\ndata: Hellesøy\r\n\r\n".split("");
+ server.on('request', writeEvents(chopped));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first(m) {
+ assert.equal("Aslak", m.data);
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal("Hellesøy", m.data);
+ server.close(done);
+ }
+ });
+ });
+
+ it('accepts CR as separator', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ var chopped = "data: Aslak\r\rdata: Hellesøy\r\r".split("");
+ server.on('request', writeEvents(chopped));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first(m) {
+ assert.equal("Aslak", m.data);
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal("Hellesøy", m.data);
+ server.close(done);
+ }
+ });
+ });
+
+ it('delivers message with explicit event', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["event: greeting\ndata: Hello\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.addEventListener('greeting', function (m) {
+ assert.equal("Hello", m.data);
+ server.close(done);
+ });
+ });
+ });
+
+ it('ignores comments', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: Hello\n\n:nothing to see here\n\ndata: World\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first(m) {
+ assert.equal("Hello", m.data);
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal("World", m.data);
+ server.close(done);
+ }
+ });
+ });
+
+ it('ignores empty comments', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: Hello\n\n:\n\ndata: World\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first(m) {
+ assert.equal("Hello", m.data);
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal("World", m.data);
+ server.close(done);
+ }
+ });
+ });
+
+ it('does not ignore multilines strings', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data: line one\ndata:\ndata: line two\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ assert.equal('line one\n\nline two', m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('does not ignore multilines strings even in data beginning', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["data:\ndata:line one\ndata: line two\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ assert.equal('\nline one\nline two', m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('causes entire event to be ignored for empty event field', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', writeEvents(["event:\n\ndata: Hello\n\n"]));
+ var es = new EventSource(server.url);
+
+ var originalEmit = es.emit;
+ es.emit = function (event) {
+ assert.ok(event === 'message' || event === 'newListener');
+ return originalEmit.apply(this, arguments);
+ };
+ es.onmessage = function (m) {
+ assert.equal('Hello', m.data);
+ server.close(done);
+ };
+ });
+ });
+
+ it('parses relatively huge messages efficiently', function (done) {
+ this.timeout(1000);
+
+ createServer(function (err, server) {
+ if (err) return done(err);
+ var longMessage = "data: " + new Array(100000).join('a') + "\n\n";
+ server.on('request', writeEvents([longMessage]));
+
+ var es = new EventSource(server.url);
+
+ es.onmessage = function () {
+ server.close(done);
+ };
+ });
+ });
+});
+
+describe('HTTP Request', function () {
+ it('passes cache-control: no-cache to server', function (done) {
+ createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', function (req) {
+ assert.equal('no-cache', req.headers['cache-control']);
+ server.close(done);
+ });
+ new EventSource(server.url);
+ });
+ });
+
+ it('sets request headers', function (done) {
+ var server = createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', function (req) {
+ assert.equal(req.headers['user-agent'], 'test');
+ assert.equal(req.headers['cookie'], 'test=test');
+ assert.equal(req.headers['last-event-id'], '99');
+ server.close(done);
+ });
+
+ var headers = {
+ 'User-Agent': 'test',
+ 'Cookie': 'test=test',
+ 'Last-Event-ID': '99'
+ };
+ new EventSource(server.url, {headers: headers});
+ });
+ });
+
+ it("does not set request headers that don't have a value", function (done) {
+ var server = createServer(function (err, server) {
+ if (err) return done(err);
+
+ server.on('request', function (req) {
+ assert.equal(req.headers['user-agent'], 'test');
+ assert.equal(req.headers['cookie'], 'test=test');
+ assert.equal(req.headers['last-event-id'], '99');
+ assert.equal(req.headers['X-Something'], undefined);
+ server.close(done);
+ });
+
+ var headers = {
+ 'User-Agent': 'test',
+ 'Cookie': 'test=test',
+ 'Last-Event-ID': '99',
+ 'X-Something': null
+ };
+
+ assert.doesNotThrow(
+ function() {
+ new EventSource(server.url, {headers: headers});
+ }
+ );
+ });
+ });
+
+ [301, 307].forEach(function (status) {
+ it('follows http ' + status + ' redirect', function (done) {
+ var redirectSuffix = '/foobar';
+ var clientRequestedRedirectUrl = false;
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', function (req, res) {
+ if (req.url === '/') {
+ res.writeHead(status, {
+ 'Connection': 'Close',
+ 'Location': server.url + redirectSuffix
+ });
+ res.end();
+ } else if (req.url === redirectSuffix) {
+ clientRequestedRedirectUrl = true;
+ res.writeHead(200, {'Content-Type': 'text/event-stream'});
+ res.end();
+ }
+ });
+
+ var es = new EventSource(server.url);
+ es.onopen = function () {
+ assert.ok(clientRequestedRedirectUrl);
+ assert.equal(server.url + redirectSuffix, es.url);
+ server.close(done);
+ };
+ });
+ });
+
+
+ it('causes error event when response is ' + status + ' with missing location', function (done) {
+ var redirectSuffix = '/foobar';
+ var clientRequestedRedirectUrl = false;
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', function (req, res) {
+ res.writeHead(status, {
+ 'Connection': 'Close'
+ });
+ res.end();
+ });
+
+ var es = new EventSource(server.url);
+ es.onerror = function (err) {
+ assert.equal(err.status, status);
+ server.close(done);
+ };
+ });
+ });
+ });
+
+ [401, 403].forEach(function (status) {
+ it('causes error event when response status is ' + status, function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', function (req, res) {
+ res.writeHead(status, {'Content-Type': 'text/html'});
+ res.end();
+ });
+
+ var es = new EventSource(server.url);
+ es.onerror = function (err) {
+ assert.equal(err.status, status);
+ server.close(done);
+ };
+ });
+ });
+ });
+});
+
+describe('HTTPS Support', function () {
+ it('uses https for https urls', function (done) {
+ createHttpsServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["data: hello\n\n"]));
+ var es = new EventSource(server.url, {rejectUnauthorized: false});
+
+ es.onmessage = function (m) {
+ assert.equal("hello", m.data);
+ server.close(done);
+ }
+ });
+ });
+});
+
+describe('Reconnection', function () {
+ it('is attempted when server is down', function (done) {
+ var es = new EventSource('http://localhost:' + _port);
+ es.reconnectInterval = 0;
+
+ es.onerror = function () {
+ es.onerror = null;
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["data: hello\n\n"]));
+
+ es.onmessage = function (m) {
+ assert.equal("hello", m.data);
+ server.close(done);
+ }
+ });
+ };
+ });
+
+ it('is attempted when server goes down after connection', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["data: hello\n\n"]));
+ var es = new EventSource(server.url);
+ es.reconnectInterval = 0;
+
+ es.onmessage = function (m) {
+ assert.equal("hello", m.data);
+ server.close(function (err) {
+ if(err) return done(err);
+
+ var port = u.parse(es.url).port;
+ configureServer(http.createServer(), 'http', port, function (err, server2) {
+ if(err) return done(err);
+
+ server2.on('request', writeEvents(["data: world\n\n"]));
+ es.onmessage = function (m) {
+ assert.equal("world", m.data);
+ server2.close(done);
+ };
+ });
+ });
+ };
+ });
+ });
+
+ it('is stopped when server goes down and eventsource is being closed', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["data: hello\n\n"]));
+ var es = new EventSource(server.url);
+ es.reconnectInterval = 0;
+
+ es.onmessage = function (m) {
+ assert.equal("hello", m.data);
+ server.close(function (err) {
+ if(err) return done(err);
+ // The server has closed down. es.onerror should now get called,
+ // because es's remote connection was dropped.
+ });
+ };
+
+ es.onerror = function () {
+ // We received an error because the remote connection was closed.
+ // We close es, so we do not want es to reconnect.
+ es.close();
+
+ var port = u.parse(es.url).port;
+ configureServer(http.createServer(), 'http', port, function (err, server2) {
+ if(err) return done(err);
+ server2.on('request', writeEvents(["data: world\n\n"]));
+
+ es.onmessage = function (m) {
+ return done(new Error("Unexpected message: " + m.data));
+ };
+
+ setTimeout(function () {
+ // We have not received any message within 100ms, we can
+ // presume this works correctly.
+ server2.close(done);
+ }, 100);
+ });
+ };
+ });
+ });
+
+ it('is not attempted when server responds with HTTP 204', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', function (req, res) {
+ res.writeHead(204);
+ res.end();
+ });
+
+ var es = new EventSource(server.url);
+ es.reconnectInterval = 0;
+
+ es.onerror = function (e) {
+ assert.equal(e.status, 204);
+ server.close(function (err) {
+ if(err) return done(err);
+
+ var port = u.parse(es.url).port;
+ configureServer(http.createServer(), 'http', port, function (err, server2) {
+ if(err) return done(err);
+
+ // this will be verified by the readyState
+ // going from CONNECTING to CLOSED,
+ // along with the tests verifying that the
+ // state is CONNECTING when a server closes.
+ // it's next to impossible to write a fail-safe
+ // test for this, though.
+ var ival = setInterval(function () {
+ if (es.readyState == EventSource.CLOSED) {
+ clearInterval(ival);
+ server2.close(done);
+ }
+ }, 5);
+ });
+ });
+ };
+ });
+ });
+
+ it('sends Last-Event-ID http header when it has previously been passed in an event from the server', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(['id: 10\ndata: Hello\n\n']));
+
+ var es = new EventSource(server.url);
+ es.reconnectInterval = 0;
+
+ es.onmessage = function () {
+ server.close(function (err) {
+ if(err) return done(err);
+
+ var port = u.parse(es.url).port;
+ configureServer(http.createServer(), 'http', port, function (err, server2) {
+ server2.on('request', function (req, res) {
+ assert.equal('10', req.headers['last-event-id']);
+ server2.close(done);
+ });
+ });
+ });
+ };
+ });
+ });
+
+ it('sends correct Last-Event-ID http header when an initial Last-Event-ID header was specified in the constructor', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', function (req, res) {
+ assert.equal('9', req.headers['last-event-id']);
+ server.close(done);
+ });
+
+ new EventSource(server.url, {headers: {'Last-Event-ID': '9'}});
+ });
+ });
+
+ it('does not send Last-Event-ID http header when it has not been previously sent by the server', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(['data: Hello\n\n']));
+
+ var es = new EventSource(server.url);
+ es.reconnectInterval = 0;
+
+ es.onmessage = function () {
+ server.close(function (err) {
+ if(err) return done(err);
+
+ var port = u.parse(es.url).port;
+ configureServer(http.createServer(), 'http', port, function (err, server2) {
+ server2.on('request', function (req, res) {
+ assert.equal(undefined, req.headers['last-event-id']);
+ server2.close(done);
+ });
+ });
+ });
+ };
+ });
+ });
+});
+
+describe('readyState', function () {
+ it('has CONNECTING constant', function () {
+ assert.equal(0, EventSource.CONNECTING);
+ });
+
+ it('has OPEN constant', function () {
+ assert.equal(1, EventSource.OPEN);
+ });
+
+ it('has CLOSED constant', function () {
+ assert.equal(2, EventSource.CLOSED);
+ });
+
+ it('is CONNECTING before connection has been established', function (done) {
+ var es = new EventSource('http://localhost:' + _port);
+ assert.equal(EventSource.CONNECTING, es.readyState);
+ es.onerror = function () {
+ es.close();
+ done();
+ }
+ });
+
+ it('is CONNECTING when server has closed the connection', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents([]));
+ var es = new EventSource(server.url);
+ es.reconnectInterval = 0;
+
+ es.onopen = function (m) {
+ server.close(function (err) {
+ if(err) return done(err);
+
+ es.onerror = function () {
+ es.onerror = null;
+ assert.equal(EventSource.CONNECTING, es.readyState);
+ done();
+ };
+ });
+ };
+ });
+ });
+
+ it('is OPEN when connection has been established', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents([]));
+ var es = new EventSource(server.url);
+
+ es.onopen = function () {
+ assert.equal(EventSource.OPEN, es.readyState);
+ server.close(done);
+ }
+ });
+ });
+
+ it('is CLOSED after connection has been closed', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents([]));
+ var es = new EventSource(server.url);
+
+ es.onopen = function () {
+ es.close();
+ assert.equal(EventSource.CLOSED, es.readyState);
+ server.close(done);
+ }
+ });
+ });
+});
+
+describe('Properties', function () {
+ it('url exposes original request url', function () {
+ var url = 'http://localhost:' + _port;
+ var es = new EventSource(url);
+ assert.equal(url, es.url);
+ });
+});
+
+describe('Events', function () {
+ it('calls onopen when connection is established', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents([]));
+ var es = new EventSource(server.url);
+
+ es.onopen = function (event) {
+ assert.equal(event.type, 'open');
+ server.close(done);
+ }
+ });
+ });
+
+ it('supplies the correct origin', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["data: hello\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (event) {
+ assert.equal(event.origin, server.url);
+ server.close(done);
+ }
+ });
+ });
+
+ it('emits open event when connection is established', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents([]));
+ var es = new EventSource(server.url);
+
+ es.addEventListener('open', function (event) {
+ assert.equal(event.type, 'open');
+ server.close(done);
+ });
+ });
+ });
+
+ it('does not emit error when connection is closed by client', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents([]));
+ var es = new EventSource(server.url);
+
+ es.addEventListener('open', function () {
+ es.close();
+ process.nextTick(function () {
+ server.close(done);
+ });
+ });
+ es.addEventListener('error', function () {
+ done(new Error('error should not be emitted'));
+ });
+ });
+ });
+
+ it('populates message\'s lastEventId correctly when the last event has an associated id', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["id: 123\ndata: hello\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ assert.equal(m.lastEventId, "123");
+ server.close(done);
+ };
+ });
+ });
+
+ it('populates message\'s lastEventId correctly when the last event doesn\'t have an associated id', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["id: 123\ndata: Hello\n\n", "data: World\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = first;
+
+ function first() {
+ es.onmessage = second;
+ }
+
+ function second(m) {
+ assert.equal(m.data, "World");
+ assert.equal(m.lastEventId, "123"); //expect to get back the previous event id
+ server.close(done);
+ }
+ });
+ });
+
+ it('populates messages with enumerable properties so they can be inspected via console.log().', function (done) {
+ createServer(function (err, server) {
+ if(err) return done(err);
+
+ server.on('request', writeEvents(["data: World\n\n"]));
+ var es = new EventSource(server.url);
+
+ es.onmessage = function (m) {
+ var enumerableAttributes = Object.keys(m);
+ assert.notEqual(enumerableAttributes.indexOf("data"), -1);
+ assert.notEqual(enumerableAttributes.indexOf("type"), -1);
+ server.close(done);
+ };
+ });
+ });
+});
diff --git a/node_modules/eventsource/test/key.pem b/node_modules/eventsource/test/key.pem
new file mode 100644
index 00000000..176fe320
--- /dev/null
+++ b/node_modules/eventsource/test/key.pem
@@ -0,0 +1,15 @@
+-----BEGIN RSA PRIVATE KEY-----
+MIICXAIBAAKBgQC2tDv6v//aJX8HoX7hugfReoWftqVxX2WmO8CbBFc0qfEChrR/
+3sCNg8Y0squOmQ1deEElE4h1tFtmcI14Ll/NfVr4kKjspK3MFe4ZJmvbtO0WZxXg
+f72AhEhw0e1mYkufFsmwiGQZHzJVh2Yll7h5PmV2TXOgHVp2A8XWFmEIEwIDAQAB
+AoGAAlVY8sHi/aE+9xT77twWX3mGHV0SzdjfDnly40fx6S1Gc7bOtVdd9DC7pk6l
+3ENeJVR02IlgU8iC5lMHq4JEHPE272jtPrLlrpWLTGmHEqoVFv9AITPqUDLhB9Kk
+Hjl7h8NYBKbr2JHKICr3DIPKOT+RnXVb1PD4EORbJ3ooYmkCQQDfknUnVxPgxUGs
+ouABw1WJIOVgcCY/IFt4Ihf6VWTsxBgzTJKxn3HtgvE0oqTH7V480XoH0QxHhjLq
+DrgobWU9AkEA0TRJ8/ouXGnFEPAXjWr9GdPQRZ1Use2MrFjneH2+Sxc0CmYtwwqL
+Kr5kS6mqJrxprJeluSjBd+3/ElxURrEXjwJAUvmlN1OPEhXDmRHd92mKnlkyKEeX
+OkiFCiIFKih1S5Y/sRJTQ0781nyJjtJqO7UyC3pnQu1oFEePL+UEniRztQJAMfav
+AtnpYKDSM+1jcp7uu9BemYGtzKDTTAYfoiNF42EzSJiGrWJDQn4eLgPjY0T0aAf/
+yGz3Z9ErbhMm/Ysl+QJBAL4kBxRT8gM4ByJw4sdOvSeCCANFq8fhbgm8pGWlCPb5
+JGmX3/GHFM8x2tbWMGpyZP1DLtiNEFz7eCGktWK5rqE=
+-----END RSA PRIVATE KEY-----
diff --git a/node_modules/execspawn/.npmignore b/node_modules/execspawn/.npmignore
new file mode 100644
index 00000000..b2e08124
--- /dev/null
+++ b/node_modules/execspawn/.npmignore
@@ -0,0 +1,2 @@
+
+/node_modules/
diff --git a/node_modules/execspawn/LICENSE.md b/node_modules/execspawn/LICENSE.md
new file mode 100644
index 00000000..62803503
--- /dev/null
+++ b/node_modules/execspawn/LICENSE.md
@@ -0,0 +1,19 @@
+Copyright (c) 2013 Andreas Madsen
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
\ No newline at end of file
diff --git a/node_modules/execspawn/README.md b/node_modules/execspawn/README.md
new file mode 100644
index 00000000..6dd91bd1
--- /dev/null
+++ b/node_modules/execspawn/README.md
@@ -0,0 +1,52 @@
+#execspawn
+
+> spawn stream for child_process.exec
+
+## Installation
+
+```sheel
+npm install execspawn
+```
+
+## Documentation
+
+```JavaScript
+var execspawn = require('execspawn');
+
+var cmd = execspawn('echo "hallo world";', {
+ cwd: __dirname, // all the spawn options
+ shell: '/bin/bash' // shell to execute the command with
+});
+
+// all the streams
+cmd.stderr;
+cmd.stdout;
+cmd.stdin;
+```
+
+See node.js [documentation](http://nodejs.org/api/child_process.html#child_process_child_process_spawn_command_args_options)
+for more info.
+
+##License
+
+**The software is license under "MIT"**
+
+> Copyright (c) 2013 Andreas Madsen
+>
+> Permission is hereby granted, free of charge, to any person obtaining a copy
+> of this software and associated documentation files (the "Software"), to deal
+> in the Software without restriction, including without limitation the rights
+> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+> copies of the Software, and to permit persons to whom the Software is
+> furnished to do so, subject to the following conditions:
+>
+> The above copyright notice and this permission notice shall be included in
+> all copies or substantial portions of the Software.
+>
+> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+> THE SOFTWARE.
diff --git a/node_modules/execspawn/execspawn.js b/node_modules/execspawn/execspawn.js
new file mode 100644
index 00000000..8d323c0d
--- /dev/null
+++ b/node_modules/execspawn/execspawn.js
@@ -0,0 +1,25 @@
+
+var extend = require('util-extend');
+var spawn = require('child_process').spawn;
+
+module.exports = function execstream(command, options) {
+ var file, args;
+ options = extend({}, options);
+
+ if (process.platform === 'win32') {
+ file = process.env.comspec || 'cmd.exe';
+ args = ['/s', '/c', '"' + command + '"'];
+ options.windowsVerbatimArguments = true;
+ } else {
+ file = '/bin/sh';
+ args = ['-c', command];
+ options.windowsVerbatimArguments = false;
+ }
+
+ if (options && options.shell) {
+ file = options.shell;
+ delete options.shell;
+ }
+
+ return spawn(file, args, options);
+};
diff --git a/node_modules/execspawn/package.json b/node_modules/execspawn/package.json
new file mode 100644
index 00000000..688a8951
--- /dev/null
+++ b/node_modules/execspawn/package.json
@@ -0,0 +1,94 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "execspawn@^1.0.0",
+ "scope": null,
+ "escapedName": "execspawn",
+ "name": "execspawn",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/npm-execspawn"
+ ]
+ ],
+ "_from": "execspawn@>=1.0.0 <2.0.0",
+ "_id": "execspawn@1.0.1",
+ "_inCache": true,
+ "_location": "/execspawn",
+ "_nodeVersion": "5.7.0",
+ "_npmOperationalInternal": {
+ "host": "packages-9-west.internal.npmjs.com",
+ "tmp": "tmp/execspawn-1.0.1.tgz_1456761959847_0.8310068673454225"
+ },
+ "_npmUser": {
+ "name": "andreasmadsen",
+ "email": "amwebdk@gmail.com"
+ },
+ "_npmVersion": "3.6.0",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "execspawn@^1.0.0",
+ "scope": null,
+ "escapedName": "execspawn",
+ "name": "execspawn",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/npm-execspawn"
+ ],
+ "_resolved": "https://registry.npmjs.org/execspawn/-/execspawn-1.0.1.tgz",
+ "_shasum": "8286f9dde7cecde7905fbdc04e24f368f23f8da6",
+ "_shrinkwrap": null,
+ "_spec": "execspawn@^1.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/npm-execspawn",
+ "author": {
+ "name": "Andreas Madsen",
+ "email": "amwebdk@gmail.com"
+ },
+ "bugs": {
+ "url": "https://github.com/AndreasMadsen/execspawn/issues"
+ },
+ "dependencies": {
+ "util-extend": "^1.0.1"
+ },
+ "description": "spawn stream for child_process.exec",
+ "devDependencies": {
+ "endpoint": "^0.4.5",
+ "tap": "^5.0.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "8286f9dde7cecde7905fbdc04e24f368f23f8da6",
+ "tarball": "https://registry.npmjs.org/execspawn/-/execspawn-1.0.1.tgz"
+ },
+ "gitHead": "6c11a755af6a666399e8e654b042d01d4ac116a4",
+ "homepage": "https://github.com/AndreasMadsen/execspawn#readme",
+ "keywords": [
+ "exec",
+ "stream",
+ "spawn"
+ ],
+ "license": "MIT",
+ "main": "./execspawn.js",
+ "maintainers": [
+ {
+ "name": "andreasmadsen",
+ "email": "amwebdk@gmail.com"
+ }
+ ],
+ "name": "execspawn",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/AndreasMadsen/execspawn.git"
+ },
+ "scripts": {
+ "test": "tap test.js"
+ },
+ "version": "1.0.1"
+}
diff --git a/node_modules/execspawn/test.js b/node_modules/execspawn/test.js
new file mode 100644
index 00000000..bbe9faa7
--- /dev/null
+++ b/node_modules/execspawn/test.js
@@ -0,0 +1,20 @@
+
+var test = require('tap').test;
+var execstream = require('./execspawn.js');
+var endpoint = require('endpoint');
+
+test('default', function (t) {
+ execstream('echo "hallo world";').stdout.pipe(endpoint(function (err, out) {
+ t.equal(err, null);
+ t.equal(out.toString(), 'hallo world\n');
+ t.end();
+ }));
+});
+
+test('shell option', function (t) {
+ execstream('hallo world', { shell: 'echo' }).stdout.pipe(endpoint(function (err, out) {
+ t.equal(err, null);
+ t.equal(out.toString(), '-c hallo world\n');
+ t.end();
+ }));
+});
diff --git a/node_modules/expand-brackets/LICENSE b/node_modules/expand-brackets/LICENSE
new file mode 100644
index 00000000..1e49edf8
--- /dev/null
+++ b/node_modules/expand-brackets/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2015-2016, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/expand-brackets/README.md b/node_modules/expand-brackets/README.md
new file mode 100644
index 00000000..d3c913e7
--- /dev/null
+++ b/node_modules/expand-brackets/README.md
@@ -0,0 +1,107 @@
+# expand-brackets [](https://www.npmjs.com/package/expand-brackets) [](https://npmjs.org/package/expand-brackets) [](https://travis-ci.org/jonschlinkert/expand-brackets)
+
+> Expand POSIX bracket expressions (character classes) in glob patterns.
+
+## Install
+
+Install with [npm](https://www.npmjs.com/):
+
+```sh
+$ npm install expand-brackets --save
+```
+
+## Usage
+
+```js
+var brackets = require('expand-brackets');
+
+brackets('[![:lower:]]');
+//=> '[^a-z]'
+```
+
+## .isMatch
+
+Return true if the given string matches the bracket expression:
+
+```js
+brackets.isMatch('A', '[![:lower:]]');
+//=> true
+
+brackets.isMatch('a', '[![:lower:]]');
+//=> false
+```
+
+## .makeRe
+
+Make a regular expression from a bracket expression:
+
+```js
+brackets.makeRe('[![:lower:]]');
+//=> /[^a-z]/
+```
+
+The following named POSIX bracket expressions are supported:
+
+* `[:alnum:]`: Alphanumeric characters (`a-zA-Z0-9]`)
+* `[:alpha:]`: Alphabetic characters (`a-zA-Z]`)
+* `[:blank:]`: Space and tab (`[ t]`)
+* `[:digit:]`: Digits (`[0-9]`)
+* `[:lower:]`: Lowercase letters (`[a-z]`)
+* `[:punct:]`: Punctuation and symbols. (`[!"#$%&'()*+, -./:;<=>?@ [\]^_``{|}~]`)
+* `[:upper:]`: Uppercase letters (`[A-Z]`)
+* `[:word:]`: Word characters (letters, numbers and underscores) (`[A-Za-z0-9_]`)
+* `[:xdigit:]`: Hexadecimal digits (`[A-Fa-f0-9]`)
+
+Collating sequences are not supported.
+
+## Related projects
+
+You might also be interested in these projects:
+
+* [extglob](https://www.npmjs.com/package/extglob): Convert extended globs to regex-compatible strings. Add (almost) the expressive power of regular expressions to… [more](https://www.npmjs.com/package/extglob) | [homepage](https://github.com/jonschlinkert/extglob)
+* [is-extglob](https://www.npmjs.com/package/is-extglob): Returns true if a string has an extglob. | [homepage](https://github.com/jonschlinkert/is-extglob)
+* [is-glob](https://www.npmjs.com/package/is-glob): Returns `true` if the given string looks like a glob pattern or an extglob pattern.… [more](https://www.npmjs.com/package/is-glob) | [homepage](https://github.com/jonschlinkert/is-glob)
+* [is-posix-bracket](https://www.npmjs.com/package/is-posix-bracket): Returns true if the given string is a POSIX bracket expression (POSIX character class). | [homepage](https://github.com/jonschlinkert/is-posix-bracket)
+* [micromatch](https://www.npmjs.com/package/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. Just… [more](https://www.npmjs.com/package/micromatch) | [homepage](https://github.com/jonschlinkert/micromatch)
+
+## Contributing
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/expand-brackets/issues/new).
+
+## Building docs
+
+Generate readme and API documentation with [verb](https://github.com/verbose/verb):
+
+```sh
+$ npm install verb && npm run docs
+```
+
+Or, if [verb](https://github.com/verbose/verb) is installed globally:
+
+```sh
+$ verb
+```
+
+## Running tests
+
+Install dev dependencies:
+
+```sh
+$ npm install -d && npm test
+```
+
+## Author
+
+**Jon Schlinkert**
+
+* [github/jonschlinkert](https://github.com/jonschlinkert)
+* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+## License
+
+verb © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).
+Released under the [MIT license](https://github.com/jonschlinkert/expand-brackets/blob/master/LICENSE).
+
+***
+
+_This file was generated by [verb](https://github.com/verbose/verb), v, on April 01, 2016._
\ No newline at end of file
diff --git a/node_modules/expand-brackets/index.js b/node_modules/expand-brackets/index.js
new file mode 100644
index 00000000..b843cc2b
--- /dev/null
+++ b/node_modules/expand-brackets/index.js
@@ -0,0 +1,163 @@
+/*!
+ * expand-brackets
+ *
+ * Copyright (c) 2015 Jon Schlinkert.
+ * Licensed under the MIT license.
+ */
+
+'use strict';
+
+var isPosixBracket = require('is-posix-bracket');
+
+/**
+ * POSIX character classes
+ */
+
+var POSIX = {
+ alnum: 'a-zA-Z0-9',
+ alpha: 'a-zA-Z',
+ blank: ' \\t',
+ cntrl: '\\x00-\\x1F\\x7F',
+ digit: '0-9',
+ graph: '\\x21-\\x7E',
+ lower: 'a-z',
+ print: '\\x20-\\x7E',
+ punct: '-!"#$%&\'()\\*+,./:;<=>?@[\\]^_`{|}~',
+ space: ' \\t\\r\\n\\v\\f',
+ upper: 'A-Z',
+ word: 'A-Za-z0-9_',
+ xdigit: 'A-Fa-f0-9',
+};
+
+/**
+ * Expose `brackets`
+ */
+
+module.exports = brackets;
+
+function brackets(str) {
+ if (!isPosixBracket(str)) {
+ return str;
+ }
+
+ var negated = false;
+ if (str.indexOf('[^') !== -1) {
+ negated = true;
+ str = str.split('[^').join('[');
+ }
+ if (str.indexOf('[!') !== -1) {
+ negated = true;
+ str = str.split('[!').join('[');
+ }
+
+ var a = str.split('[');
+ var b = str.split(']');
+ var imbalanced = a.length !== b.length;
+
+ var parts = str.split(/(?::\]\[:|\[?\[:|:\]\]?)/);
+ var len = parts.length, i = 0;
+ var end = '', beg = '';
+ var res = [];
+
+ // start at the end (innermost) first
+ while (len--) {
+ var inner = parts[i++];
+ if (inner === '^[!' || inner === '[!') {
+ inner = '';
+ negated = true;
+ }
+
+ var prefix = negated ? '^' : '';
+ var ch = POSIX[inner];
+
+ if (ch) {
+ res.push('[' + prefix + ch + ']');
+ } else if (inner) {
+ if (/^\[?\w-\w\]?$/.test(inner)) {
+ if (i === parts.length) {
+ res.push('[' + prefix + inner);
+ } else if (i === 1) {
+ res.push(prefix + inner + ']');
+ } else {
+ res.push(prefix + inner);
+ }
+ } else {
+ if (i === 1) {
+ beg += inner;
+ } else if (i === parts.length) {
+ end += inner;
+ } else {
+ res.push('[' + prefix + inner + ']');
+ }
+ }
+ }
+ }
+
+ var result = res.join('|');
+ var rlen = res.length || 1;
+ if (rlen > 1) {
+ result = '(?:' + result + ')';
+ rlen = 1;
+ }
+ if (beg) {
+ rlen++;
+ if (beg.charAt(0) === '[') {
+ if (imbalanced) {
+ beg = '\\[' + beg.slice(1);
+ } else {
+ beg += ']';
+ }
+ }
+ result = beg + result;
+ }
+ if (end) {
+ rlen++;
+ if (end.slice(-1) === ']') {
+ if (imbalanced) {
+ end = end.slice(0, end.length - 1) + '\\]';
+ } else {
+ end = '[' + end;
+ }
+ }
+ result += end;
+ }
+
+ if (rlen > 1) {
+ result = result.split('][').join(']|[');
+ if (result.indexOf('|') !== -1 && !/\(\?/.test(result)) {
+ result = '(?:' + result + ')';
+ }
+ }
+
+ result = result.replace(/\[+=|=\]+/g, '\\b');
+ return result;
+}
+
+brackets.makeRe = function(pattern) {
+ try {
+ return new RegExp(brackets(pattern));
+ } catch (err) {}
+};
+
+brackets.isMatch = function(str, pattern) {
+ try {
+ return brackets.makeRe(pattern).test(str);
+ } catch (err) {
+ return false;
+ }
+};
+
+brackets.match = function(arr, pattern) {
+ var len = arr.length, i = 0;
+ var res = arr.slice();
+
+ var re = brackets.makeRe(pattern);
+ while (i < len) {
+ var ele = arr[i++];
+ if (!re.test(ele)) {
+ continue;
+ }
+ res.splice(i, 1);
+ }
+ return res;
+};
diff --git a/node_modules/expand-brackets/package.json b/node_modules/expand-brackets/package.json
new file mode 100644
index 00000000..ffdcc2c6
--- /dev/null
+++ b/node_modules/expand-brackets/package.json
@@ -0,0 +1,136 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "expand-brackets@^0.1.4",
+ "scope": null,
+ "escapedName": "expand-brackets",
+ "name": "expand-brackets",
+ "rawSpec": "^0.1.4",
+ "spec": ">=0.1.4 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/micromatch"
+ ]
+ ],
+ "_from": "expand-brackets@>=0.1.4 <0.2.0",
+ "_id": "expand-brackets@0.1.5",
+ "_inCache": true,
+ "_location": "/expand-brackets",
+ "_nodeVersion": "5.5.0",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/expand-brackets-0.1.5.tgz_1459554506001_0.9547659594099969"
+ },
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "3.6.0",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "expand-brackets@^0.1.4",
+ "scope": null,
+ "escapedName": "expand-brackets",
+ "name": "expand-brackets",
+ "rawSpec": "^0.1.4",
+ "spec": ">=0.1.4 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/micromatch"
+ ],
+ "_resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz",
+ "_shasum": "df07284e342a807cd733ac5af72411e581d1177b",
+ "_shrinkwrap": null,
+ "_spec": "expand-brackets@^0.1.4",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/micromatch",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/expand-brackets/issues"
+ },
+ "dependencies": {
+ "is-posix-bracket": "^0.1.0"
+ },
+ "description": "Expand POSIX bracket expressions (character classes) in glob patterns.",
+ "devDependencies": {
+ "gulp-format-md": "^0.1.7",
+ "mocha": "^2.2.5",
+ "should": "^7.0.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "df07284e342a807cd733ac5af72411e581d1177b",
+ "tarball": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "1b07fda8ee8b6426d95e6539785b74c57e9ee542",
+ "homepage": "https://github.com/jonschlinkert/expand-brackets",
+ "keywords": [
+ "bracket",
+ "character class",
+ "expression",
+ "posix"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ {
+ "name": "es128",
+ "email": "elan.shanker+npm@gmail.com"
+ },
+ {
+ "name": "doowb",
+ "email": "brian.woodward@gmail.com"
+ }
+ ],
+ "name": "expand-brackets",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonschlinkert/expand-brackets.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "run": true,
+ "toc": false,
+ "layout": "default",
+ "tasks": [
+ "readme"
+ ],
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "related": {
+ "list": [
+ "extglob",
+ "is-extglob",
+ "is-glob",
+ "is-posix-bracket",
+ "micromatch"
+ ]
+ },
+ "reflinks": [
+ "verb"
+ ],
+ "lint": {
+ "reflinks": true
+ }
+ },
+ "version": "0.1.5"
+}
diff --git a/node_modules/expand-range/LICENSE b/node_modules/expand-range/LICENSE
new file mode 100644
index 00000000..b1e51ff7
--- /dev/null
+++ b/node_modules/expand-range/LICENSE
@@ -0,0 +1,24 @@
+The MIT License (MIT)
+
+Copyright (c) 2014-2016, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/expand-range/README.md b/node_modules/expand-range/README.md
new file mode 100644
index 00000000..72c7e8c6
--- /dev/null
+++ b/node_modules/expand-range/README.md
@@ -0,0 +1,145 @@
+# expand-range [](https://www.npmjs.com/package/expand-range) [](https://npmjs.org/package/expand-range) [](https://travis-ci.org/jonschlinkert/expand-range)
+
+Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. See the benchmarks. Used by micromatch.
+
+## Install
+
+Install with [npm](https://www.npmjs.com/):
+
+```sh
+$ npm install expand-range --save
+```
+
+Wraps [fill-range] to do range expansion using `..` separated strings. See [fill-range] for the full list of options and features.
+
+## Example usage
+
+```js
+var expand = require('expand-range');
+```
+
+**Params**
+
+```js
+expand(start, stop, increment);
+```
+
+* `start`: the number or letter to start with
+* `end`: the number or letter to end with
+* `increment`: optionally pass the increment to use. works for letters or numbers
+
+**Examples**
+
+```js
+expand('a..e')
+//=> ['a', 'b', 'c', 'd', 'e']
+
+expand('a..e..2')
+//=> ['a', 'c', 'e']
+
+expand('A..E..2')
+//=> ['A', 'C', 'E']
+
+expand('1..3')
+//=> ['1', '2', '3']
+
+expand('0..-5')
+//=> [ '0', '-1', '-2', '-3', '-4', '-5' ]
+
+expand('-9..9..3')
+//=> [ '-9', '-6', '-3', '0', '3', '6', '9' ])
+
+expand('-1..-10..-2')
+//=> [ '-1', '-3', '-5', '-7', '-9' ]
+
+expand('1..10..2')
+//=> [ '1', '3', '5', '7', '9' ]
+```
+
+### Custom function
+
+Optionally pass a custom function as the second argument:
+
+```js
+expand('a..e', function (val, isNumber, pad, i) {
+ if (!isNumber) {
+ return String.fromCharCode(val) + i;
+ }
+ return val;
+});
+//=> ['a0', 'b1', 'c2', 'd3', 'e4']
+```
+
+## Benchmarks
+
+```sh
+# benchmark/fixtures/alpha-lower.js (29 bytes)
+ brace-expansion x 145,653 ops/sec ±0.89% (87 runs sampled)
+ expand-range x 453,213 ops/sec ±1.66% (85 runs sampled)
+ minimatch x 152,193 ops/sec ±1.17% (86 runs sampled)
+
+# benchmark/fixtures/alpha-upper.js (29 bytes)
+ brace-expansion x 149,975 ops/sec ±1.10% (88 runs sampled)
+ expand-range x 459,390 ops/sec ±1.27% (84 runs sampled)
+ minimatch x 155,253 ops/sec ±1.25% (88 runs sampled)
+
+# benchmark/fixtures/padded.js (33 bytes)
+ brace-expansion x 14,694 ops/sec ±1.37% (85 runs sampled)
+ expand-range x 169,393 ops/sec ±1.76% (80 runs sampled)
+ minimatch x 15,052 ops/sec ±1.15% (88 runs sampled)
+
+# benchmark/fixtures/range.js (29 bytes)
+ brace-expansion x 142,968 ops/sec ±1.35% (86 runs sampled)
+ expand-range x 465,579 ops/sec ±1.43% (86 runs sampled)
+ minimatch x 126,872 ops/sec ±1.18% (90 runs sampled)
+```
+
+## Related projects
+
+You might also be interested in these projects:
+
+* [braces](https://www.npmjs.com/package/braces): Fastest brace expansion for node.js, with the most complete support for the Bash 4.3 braces… [more](https://www.npmjs.com/package/braces) | [homepage](https://github.com/jonschlinkert/braces)
+* [fill-range](https://www.npmjs.com/package/fill-range): Fill in a range of numbers or letters, optionally passing an increment or multiplier to… [more](https://www.npmjs.com/package/fill-range) | [homepage](https://github.com/jonschlinkert/fill-range)
+* [micromatch](https://www.npmjs.com/package/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. | [homepage](https://github.com/jonschlinkert/micromatch)
+
+## Contributing
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/expand-range/issues/new).
+
+## Building docs
+
+Generate readme and API documentation with [verb](https://github.com/verbose/verb):
+
+```sh
+$ npm install verb && npm run docs
+```
+
+Or, if [verb](https://github.com/verbose/verb) is installed globally:
+
+```sh
+$ verb
+```
+
+## Running tests
+
+Install dev dependencies:
+
+```sh
+$ npm install -d && npm test
+```
+
+## Author
+
+**Jon Schlinkert**
+
+* [github/jonschlinkert](https://github.com/jonschlinkert)
+* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+## License
+
+Copyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).
+Released under the [MIT license](https://github.com/jonschlinkert/expand-range/blob/master/LICENSE).
+
+***
+
+_This file was generated by [verb](https://github.com/verbose/verb), v0.9.0, on May 05, 2016._
\ No newline at end of file
diff --git a/node_modules/expand-range/index.js b/node_modules/expand-range/index.js
new file mode 100644
index 00000000..369962a8
--- /dev/null
+++ b/node_modules/expand-range/index.js
@@ -0,0 +1,43 @@
+/*!
+ * expand-range
+ *
+ * Copyright (c) 2014-2015, Jon Schlinkert.
+ * Licensed under the MIT license.
+ */
+
+'use strict';
+
+var fill = require('fill-range');
+
+module.exports = function expandRange(str, options, fn) {
+ if (typeof str !== 'string') {
+ throw new TypeError('expand-range expects a string.');
+ }
+
+ if (typeof options === 'function') {
+ fn = options;
+ options = {};
+ }
+
+ if (typeof options === 'boolean') {
+ options = {};
+ options.makeRe = true;
+ }
+
+ // create arguments to pass to fill-range
+ var opts = options || {};
+ var args = str.split('..');
+ var len = args.length;
+ if (len > 3) { return str; }
+
+ // if only one argument, it can't expand so return it
+ if (len === 1) { return args; }
+
+ // if `true`, tell fill-range to regexify the string
+ if (typeof fn === 'boolean' && fn === true) {
+ opts.makeRe = true;
+ }
+
+ args.push(opts);
+ return fill.apply(null, args.concat(fn));
+};
diff --git a/node_modules/expand-range/package.json b/node_modules/expand-range/package.json
new file mode 100644
index 00000000..bc58d241
--- /dev/null
+++ b/node_modules/expand-range/package.json
@@ -0,0 +1,143 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "expand-range@^1.8.1",
+ "scope": null,
+ "escapedName": "expand-range",
+ "name": "expand-range",
+ "rawSpec": "^1.8.1",
+ "spec": ">=1.8.1 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/braces"
+ ]
+ ],
+ "_from": "expand-range@>=1.8.1 <2.0.0",
+ "_id": "expand-range@1.8.2",
+ "_inCache": true,
+ "_location": "/expand-range",
+ "_nodeVersion": "5.5.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/expand-range-1.8.2.tgz_1462440434873_0.7174076174851507"
+ },
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "3.6.0",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "expand-range@^1.8.1",
+ "scope": null,
+ "escapedName": "expand-range",
+ "name": "expand-range",
+ "rawSpec": "^1.8.1",
+ "spec": ">=1.8.1 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/braces"
+ ],
+ "_resolved": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz",
+ "_shasum": "a299effd335fe2721ebae8e257ec79644fc85337",
+ "_shrinkwrap": null,
+ "_spec": "expand-range@^1.8.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/braces",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/expand-range/issues"
+ },
+ "dependencies": {
+ "fill-range": "^2.1.0"
+ },
+ "description": "Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. See the benchmarks. Used by micromatch.",
+ "devDependencies": {
+ "benchmarked": "^0.2.4",
+ "brace-expansion": "^1.1.4",
+ "glob": "^7.0.3",
+ "gulp-format-md": "^0.1.9",
+ "minimatch": "^3.0.0",
+ "mocha": "^2.4.5"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "a299effd335fe2721ebae8e257ec79644fc85337",
+ "tarball": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "4c873af0870df8382bafc66a93d5c89e3aad3d4d",
+ "homepage": "https://github.com/jonschlinkert/expand-range",
+ "keywords": [
+ "alpha",
+ "alphabetical",
+ "bash",
+ "brace",
+ "expand",
+ "expansion",
+ "glob",
+ "match",
+ "matches",
+ "matching",
+ "number",
+ "numerical",
+ "range",
+ "ranges",
+ "sh"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ {
+ "name": "doowb",
+ "email": "brian.woodward@gmail.com"
+ }
+ ],
+ "name": "expand-range",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonschlinkert/expand-range.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "reflinks": [
+ "verb"
+ ],
+ "toc": false,
+ "layout": "default",
+ "lint": {
+ "reflinks": true
+ },
+ "tasks": [
+ "readme"
+ ],
+ "related": {
+ "list": [
+ "micromatch",
+ "fill-range",
+ "braces"
+ ]
+ }
+ },
+ "version": "1.8.2"
+}
diff --git a/node_modules/express/History.md b/node_modules/express/History.md
new file mode 100644
index 00000000..4a706a4d
--- /dev/null
+++ b/node_modules/express/History.md
@@ -0,0 +1,3162 @@
+4.14.1 / 2017-01-28
+===================
+
+ * deps: content-disposition@0.5.2
+ * deps: finalhandler@0.5.1
+ - Fix exception when `err.headers` is not an object
+ - deps: statuses@~1.3.1
+ - perf: hoist regular expressions
+ - perf: remove duplicate validation path
+ * deps: proxy-addr@~1.1.3
+ - deps: ipaddr.js@1.2.0
+ * deps: send@0.14.2
+ - deps: http-errors@~1.5.1
+ - deps: ms@0.7.2
+ - deps: statuses@~1.3.1
+ * deps: serve-static@~1.11.2
+ - deps: send@0.14.2
+ * deps: type-is@~1.6.14
+ - deps: mime-types@~2.1.13
+
+4.14.0 / 2016-06-16
+===================
+
+ * Add `acceptRanges` option to `res.sendFile`/`res.sendfile`
+ * Add `cacheControl` option to `res.sendFile`/`res.sendfile`
+ * Add `options` argument to `req.range`
+ - Includes the `combine` option
+ * Encode URL in `res.location`/`res.redirect` if not already encoded
+ * Fix some redirect handling in `res.sendFile`/`res.sendfile`
+ * Fix Windows absolute path check using forward slashes
+ * Improve error with invalid arguments to `req.get()`
+ * Improve performance for `res.json`/`res.jsonp` in most cases
+ * Improve `Range` header handling in `res.sendFile`/`res.sendfile`
+ * deps: accepts@~1.3.3
+ - Fix including type extensions in parameters in `Accept` parsing
+ - Fix parsing `Accept` parameters with quoted equals
+ - Fix parsing `Accept` parameters with quoted semicolons
+ - Many performance improvments
+ - deps: mime-types@~2.1.11
+ - deps: negotiator@0.6.1
+ * deps: content-type@~1.0.2
+ - perf: enable strict mode
+ * deps: cookie@0.3.1
+ - Add `sameSite` option
+ - Fix cookie `Max-Age` to never be a floating point number
+ - Improve error message when `encode` is not a function
+ - Improve error message when `expires` is not a `Date`
+ - Throw better error for invalid argument to parse
+ - Throw on invalid values provided to `serialize`
+ - perf: enable strict mode
+ - perf: hoist regular expression
+ - perf: use for loop in parse
+ - perf: use string concatination for serialization
+ * deps: finalhandler@0.5.0
+ - Change invalid or non-numeric status code to 500
+ - Overwrite status message to match set status code
+ - Prefer `err.statusCode` if `err.status` is invalid
+ - Set response headers from `err.headers` object
+ - Use `statuses` instead of `http` module for status messages
+ * deps: proxy-addr@~1.1.2
+ - Fix accepting various invalid netmasks
+ - Fix IPv6-mapped IPv4 validation edge cases
+ - IPv4 netmasks must be contingous
+ - IPv6 addresses cannot be used as a netmask
+ - deps: ipaddr.js@1.1.1
+ * deps: qs@6.2.0
+ - Add `decoder` option in `parse` function
+ * deps: range-parser@~1.2.0
+ - Add `combine` option to combine overlapping ranges
+ - Fix incorrectly returning -1 when there is at least one valid range
+ - perf: remove internal function
+ * deps: send@0.14.1
+ - Add `acceptRanges` option
+ - Add `cacheControl` option
+ - Attempt to combine multiple ranges into single range
+ - Correctly inherit from `Stream` class
+ - Fix `Content-Range` header in 416 responses when using `start`/`end` options
+ - Fix `Content-Range` header missing from default 416 responses
+ - Fix redirect error when `path` contains raw non-URL characters
+ - Fix redirect when `path` starts with multiple forward slashes
+ - Ignore non-byte `Range` headers
+ - deps: http-errors@~1.5.0
+ - deps: range-parser@~1.2.0
+ - deps: statuses@~1.3.0
+ - perf: remove argument reassignment
+ * deps: serve-static@~1.11.1
+ - Add `acceptRanges` option
+ - Add `cacheControl` option
+ - Attempt to combine multiple ranges into single range
+ - Fix redirect error when `req.url` contains raw non-URL characters
+ - Ignore non-byte `Range` headers
+ - Use status code 301 for redirects
+ - deps: send@0.14.1
+ * deps: type-is@~1.6.13
+ - Fix type error when given invalid type to match against
+ - deps: mime-types@~2.1.11
+ * deps: vary@~1.1.0
+ - Only accept valid field names in the `field` argument
+ * perf: use strict equality when possible
+
+4.13.4 / 2016-01-21
+===================
+
+ * deps: content-disposition@0.5.1
+ - perf: enable strict mode
+ * deps: cookie@0.1.5
+ - Throw on invalid values provided to `serialize`
+ * deps: depd@~1.1.0
+ - Support web browser loading
+ - perf: enable strict mode
+ * deps: escape-html@~1.0.3
+ - perf: enable strict mode
+ - perf: optimize string replacement
+ - perf: use faster string coercion
+ * deps: finalhandler@0.4.1
+ - deps: escape-html@~1.0.3
+ * deps: merge-descriptors@1.0.1
+ - perf: enable strict mode
+ * deps: methods@~1.1.2
+ - perf: enable strict mode
+ * deps: parseurl@~1.3.1
+ - perf: enable strict mode
+ * deps: proxy-addr@~1.0.10
+ - deps: ipaddr.js@1.0.5
+ - perf: enable strict mode
+ * deps: range-parser@~1.0.3
+ - perf: enable strict mode
+ * deps: send@0.13.1
+ - deps: depd@~1.1.0
+ - deps: destroy@~1.0.4
+ - deps: escape-html@~1.0.3
+ - deps: range-parser@~1.0.3
+ * deps: serve-static@~1.10.2
+ - deps: escape-html@~1.0.3
+ - deps: parseurl@~1.3.0
+ - deps: send@0.13.1
+
+4.13.3 / 2015-08-02
+===================
+
+ * Fix infinite loop condition using `mergeParams: true`
+ * Fix inner numeric indices incorrectly altering parent `req.params`
+
+4.13.2 / 2015-07-31
+===================
+
+ * deps: accepts@~1.2.12
+ - deps: mime-types@~2.1.4
+ * deps: array-flatten@1.1.1
+ - perf: enable strict mode
+ * deps: path-to-regexp@0.1.7
+ - Fix regression with escaped round brackets and matching groups
+ * deps: type-is@~1.6.6
+ - deps: mime-types@~2.1.4
+
+4.13.1 / 2015-07-05
+===================
+
+ * deps: accepts@~1.2.10
+ - deps: mime-types@~2.1.2
+ * deps: qs@4.0.0
+ - Fix dropping parameters like `hasOwnProperty`
+ - Fix various parsing edge cases
+ * deps: type-is@~1.6.4
+ - deps: mime-types@~2.1.2
+ - perf: enable strict mode
+ - perf: remove argument reassignment
+
+4.13.0 / 2015-06-20
+===================
+
+ * Add settings to debug output
+ * Fix `res.format` error when only `default` provided
+ * Fix issue where `next('route')` in `app.param` would incorrectly skip values
+ * Fix hiding platform issues with `decodeURIComponent`
+ - Only `URIError`s are a 400
+ * Fix using `*` before params in routes
+ * Fix using capture groups before params in routes
+ * Simplify `res.cookie` to call `res.append`
+ * Use `array-flatten` module for flattening arrays
+ * deps: accepts@~1.2.9
+ - deps: mime-types@~2.1.1
+ - perf: avoid argument reassignment & argument slice
+ - perf: avoid negotiator recursive construction
+ - perf: enable strict mode
+ - perf: remove unnecessary bitwise operator
+ * deps: cookie@0.1.3
+ - perf: deduce the scope of try-catch deopt
+ - perf: remove argument reassignments
+ * deps: escape-html@1.0.2
+ * deps: etag@~1.7.0
+ - Always include entity length in ETags for hash length extensions
+ - Generate non-Stats ETags using MD5 only (no longer CRC32)
+ - Improve stat performance by removing hashing
+ - Improve support for JXcore
+ - Remove base64 padding in ETags to shorten
+ - Support "fake" stats objects in environments without fs
+ - Use MD5 instead of MD4 in weak ETags over 1KB
+ * deps: finalhandler@0.4.0
+ - Fix a false-positive when unpiping in Node.js 0.8
+ - Support `statusCode` property on `Error` objects
+ - Use `unpipe` module for unpiping requests
+ - deps: escape-html@1.0.2
+ - deps: on-finished@~2.3.0
+ - perf: enable strict mode
+ - perf: remove argument reassignment
+ * deps: fresh@0.3.0
+ - Add weak `ETag` matching support
+ * deps: on-finished@~2.3.0
+ - Add defined behavior for HTTP `CONNECT` requests
+ - Add defined behavior for HTTP `Upgrade` requests
+ - deps: ee-first@1.1.1
+ * deps: path-to-regexp@0.1.6
+ * deps: send@0.13.0
+ - Allow Node.js HTTP server to set `Date` response header
+ - Fix incorrectly removing `Content-Location` on 304 response
+ - Improve the default redirect response headers
+ - Send appropriate headers on default error response
+ - Use `http-errors` for standard emitted errors
+ - Use `statuses` instead of `http` module for status messages
+ - deps: escape-html@1.0.2
+ - deps: etag@~1.7.0
+ - deps: fresh@0.3.0
+ - deps: on-finished@~2.3.0
+ - perf: enable strict mode
+ - perf: remove unnecessary array allocations
+ * deps: serve-static@~1.10.0
+ - Add `fallthrough` option
+ - Fix reading options from options prototype
+ - Improve the default redirect response headers
+ - Malformed URLs now `next()` instead of 400
+ - deps: escape-html@1.0.2
+ - deps: send@0.13.0
+ - perf: enable strict mode
+ - perf: remove argument reassignment
+ * deps: type-is@~1.6.3
+ - deps: mime-types@~2.1.1
+ - perf: reduce try block size
+ - perf: remove bitwise operations
+ * perf: enable strict mode
+ * perf: isolate `app.render` try block
+ * perf: remove argument reassignments in application
+ * perf: remove argument reassignments in request prototype
+ * perf: remove argument reassignments in response prototype
+ * perf: remove argument reassignments in routing
+ * perf: remove argument reassignments in `View`
+ * perf: skip attempting to decode zero length string
+ * perf: use saved reference to `http.STATUS_CODES`
+
+4.12.4 / 2015-05-17
+===================
+
+ * deps: accepts@~1.2.7
+ - deps: mime-types@~2.0.11
+ - deps: negotiator@0.5.3
+ * deps: debug@~2.2.0
+ - deps: ms@0.7.1
+ * deps: depd@~1.0.1
+ * deps: etag@~1.6.0
+ - Improve support for JXcore
+ - Support "fake" stats objects in environments without `fs`
+ * deps: finalhandler@0.3.6
+ - deps: debug@~2.2.0
+ - deps: on-finished@~2.2.1
+ * deps: on-finished@~2.2.1
+ - Fix `isFinished(req)` when data buffered
+ * deps: proxy-addr@~1.0.8
+ - deps: ipaddr.js@1.0.1
+ * deps: qs@2.4.2
+ - Fix allowing parameters like `constructor`
+ * deps: send@0.12.3
+ - deps: debug@~2.2.0
+ - deps: depd@~1.0.1
+ - deps: etag@~1.6.0
+ - deps: ms@0.7.1
+ - deps: on-finished@~2.2.1
+ * deps: serve-static@~1.9.3
+ - deps: send@0.12.3
+ * deps: type-is@~1.6.2
+ - deps: mime-types@~2.0.11
+
+4.12.3 / 2015-03-17
+===================
+
+ * deps: accepts@~1.2.5
+ - deps: mime-types@~2.0.10
+ * deps: debug@~2.1.3
+ - Fix high intensity foreground color for bold
+ - deps: ms@0.7.0
+ * deps: finalhandler@0.3.4
+ - deps: debug@~2.1.3
+ * deps: proxy-addr@~1.0.7
+ - deps: ipaddr.js@0.1.9
+ * deps: qs@2.4.1
+ - Fix error when parameter `hasOwnProperty` is present
+ * deps: send@0.12.2
+ - Throw errors early for invalid `extensions` or `index` options
+ - deps: debug@~2.1.3
+ * deps: serve-static@~1.9.2
+ - deps: send@0.12.2
+ * deps: type-is@~1.6.1
+ - deps: mime-types@~2.0.10
+
+4.12.2 / 2015-03-02
+===================
+
+ * Fix regression where `"Request aborted"` is logged using `res.sendFile`
+
+4.12.1 / 2015-03-01
+===================
+
+ * Fix constructing application with non-configurable prototype properties
+ * Fix `ECONNRESET` errors from `res.sendFile` usage
+ * Fix `req.host` when using "trust proxy" hops count
+ * Fix `req.protocol`/`req.secure` when using "trust proxy" hops count
+ * Fix wrong `code` on aborted connections from `res.sendFile`
+ * deps: merge-descriptors@1.0.0
+
+4.12.0 / 2015-02-23
+===================
+
+ * Fix `"trust proxy"` setting to inherit when app is mounted
+ * Generate `ETag`s for all request responses
+ - No longer restricted to only responses for `GET` and `HEAD` requests
+ * Use `content-type` to parse `Content-Type` headers
+ * deps: accepts@~1.2.4
+ - Fix preference sorting to be stable for long acceptable lists
+ - deps: mime-types@~2.0.9
+ - deps: negotiator@0.5.1
+ * deps: cookie-signature@1.0.6
+ * deps: send@0.12.1
+ - Always read the stat size from the file
+ - Fix mutating passed-in `options`
+ - deps: mime@1.3.4
+ * deps: serve-static@~1.9.1
+ - deps: send@0.12.1
+ * deps: type-is@~1.6.0
+ - fix argument reassignment
+ - fix false-positives in `hasBody` `Transfer-Encoding` check
+ - support wildcard for both type and subtype (`*/*`)
+ - deps: mime-types@~2.0.9
+
+4.11.2 / 2015-02-01
+===================
+
+ * Fix `res.redirect` double-calling `res.end` for `HEAD` requests
+ * deps: accepts@~1.2.3
+ - deps: mime-types@~2.0.8
+ * deps: proxy-addr@~1.0.6
+ - deps: ipaddr.js@0.1.8
+ * deps: type-is@~1.5.6
+ - deps: mime-types@~2.0.8
+
+4.11.1 / 2015-01-20
+===================
+
+ * deps: send@0.11.1
+ - Fix root path disclosure
+ * deps: serve-static@~1.8.1
+ - Fix redirect loop in Node.js 0.11.14
+ - Fix root path disclosure
+ - deps: send@0.11.1
+
+4.11.0 / 2015-01-13
+===================
+
+ * Add `res.append(field, val)` to append headers
+ * Deprecate leading `:` in `name` for `app.param(name, fn)`
+ * Deprecate `req.param()` -- use `req.params`, `req.body`, or `req.query` instead
+ * Deprecate `app.param(fn)`
+ * Fix `OPTIONS` responses to include the `HEAD` method properly
+ * Fix `res.sendFile` not always detecting aborted connection
+ * Match routes iteratively to prevent stack overflows
+ * deps: accepts@~1.2.2
+ - deps: mime-types@~2.0.7
+ - deps: negotiator@0.5.0
+ * deps: send@0.11.0
+ - deps: debug@~2.1.1
+ - deps: etag@~1.5.1
+ - deps: ms@0.7.0
+ - deps: on-finished@~2.2.0
+ * deps: serve-static@~1.8.0
+ - deps: send@0.11.0
+
+4.10.8 / 2015-01-13
+===================
+
+ * Fix crash from error within `OPTIONS` response handler
+ * deps: proxy-addr@~1.0.5
+ - deps: ipaddr.js@0.1.6
+
+4.10.7 / 2015-01-04
+===================
+
+ * Fix `Allow` header for `OPTIONS` to not contain duplicate methods
+ * Fix incorrect "Request aborted" for `res.sendFile` when `HEAD` or 304
+ * deps: debug@~2.1.1
+ * deps: finalhandler@0.3.3
+ - deps: debug@~2.1.1
+ - deps: on-finished@~2.2.0
+ * deps: methods@~1.1.1
+ * deps: on-finished@~2.2.0
+ * deps: serve-static@~1.7.2
+ - Fix potential open redirect when mounted at root
+ * deps: type-is@~1.5.5
+ - deps: mime-types@~2.0.7
+
+4.10.6 / 2014-12-12
+===================
+
+ * Fix exception in `req.fresh`/`req.stale` without response headers
+
+4.10.5 / 2014-12-10
+===================
+
+ * Fix `res.send` double-calling `res.end` for `HEAD` requests
+ * deps: accepts@~1.1.4
+ - deps: mime-types@~2.0.4
+ * deps: type-is@~1.5.4
+ - deps: mime-types@~2.0.4
+
+4.10.4 / 2014-11-24
+===================
+
+ * Fix `res.sendfile` logging standard write errors
+
+4.10.3 / 2014-11-23
+===================
+
+ * Fix `res.sendFile` logging standard write errors
+ * deps: etag@~1.5.1
+ * deps: proxy-addr@~1.0.4
+ - deps: ipaddr.js@0.1.5
+ * deps: qs@2.3.3
+ - Fix `arrayLimit` behavior
+
+4.10.2 / 2014-11-09
+===================
+
+ * Correctly invoke async router callback asynchronously
+ * deps: accepts@~1.1.3
+ - deps: mime-types@~2.0.3
+ * deps: type-is@~1.5.3
+ - deps: mime-types@~2.0.3
+
+4.10.1 / 2014-10-28
+===================
+
+ * Fix handling of URLs containing `://` in the path
+ * deps: qs@2.3.2
+ - Fix parsing of mixed objects and values
+
+4.10.0 / 2014-10-23
+===================
+
+ * Add support for `app.set('views', array)`
+ - Views are looked up in sequence in array of directories
+ * Fix `res.send(status)` to mention `res.sendStatus(status)`
+ * Fix handling of invalid empty URLs
+ * Use `content-disposition` module for `res.attachment`/`res.download`
+ - Sends standards-compliant `Content-Disposition` header
+ - Full Unicode support
+ * Use `path.resolve` in view lookup
+ * deps: debug@~2.1.0
+ - Implement `DEBUG_FD` env variable support
+ * deps: depd@~1.0.0
+ * deps: etag@~1.5.0
+ - Improve string performance
+ - Slightly improve speed for weak ETags over 1KB
+ * deps: finalhandler@0.3.2
+ - Terminate in progress response only on error
+ - Use `on-finished` to determine request status
+ - deps: debug@~2.1.0
+ - deps: on-finished@~2.1.1
+ * deps: on-finished@~2.1.1
+ - Fix handling of pipelined requests
+ * deps: qs@2.3.0
+ - Fix parsing of mixed implicit and explicit arrays
+ * deps: send@0.10.1
+ - deps: debug@~2.1.0
+ - deps: depd@~1.0.0
+ - deps: etag@~1.5.0
+ - deps: on-finished@~2.1.1
+ * deps: serve-static@~1.7.1
+ - deps: send@0.10.1
+
+4.9.8 / 2014-10-17
+==================
+
+ * Fix `res.redirect` body when redirect status specified
+ * deps: accepts@~1.1.2
+ - Fix error when media type has invalid parameter
+ - deps: negotiator@0.4.9
+
+4.9.7 / 2014-10-10
+==================
+
+ * Fix using same param name in array of paths
+
+4.9.6 / 2014-10-08
+==================
+
+ * deps: accepts@~1.1.1
+ - deps: mime-types@~2.0.2
+ - deps: negotiator@0.4.8
+ * deps: serve-static@~1.6.4
+ - Fix redirect loop when index file serving disabled
+ * deps: type-is@~1.5.2
+ - deps: mime-types@~2.0.2
+
+4.9.5 / 2014-09-24
+==================
+
+ * deps: etag@~1.4.0
+ * deps: proxy-addr@~1.0.3
+ - Use `forwarded` npm module
+ * deps: send@0.9.3
+ - deps: etag@~1.4.0
+ * deps: serve-static@~1.6.3
+ - deps: send@0.9.3
+
+4.9.4 / 2014-09-19
+==================
+
+ * deps: qs@2.2.4
+ - Fix issue with object keys starting with numbers truncated
+
+4.9.3 / 2014-09-18
+==================
+
+ * deps: proxy-addr@~1.0.2
+ - Fix a global leak when multiple subnets are trusted
+ - deps: ipaddr.js@0.1.3
+
+4.9.2 / 2014-09-17
+==================
+
+ * Fix regression for empty string `path` in `app.use`
+ * Fix `router.use` to accept array of middleware without path
+ * Improve error message for bad `app.use` arguments
+
+4.9.1 / 2014-09-16
+==================
+
+ * Fix `app.use` to accept array of middleware without path
+ * deps: depd@0.4.5
+ * deps: etag@~1.3.1
+ * deps: send@0.9.2
+ - deps: depd@0.4.5
+ - deps: etag@~1.3.1
+ - deps: range-parser@~1.0.2
+ * deps: serve-static@~1.6.2
+ - deps: send@0.9.2
+
+4.9.0 / 2014-09-08
+==================
+
+ * Add `res.sendStatus`
+ * Invoke callback for sendfile when client aborts
+ - Applies to `res.sendFile`, `res.sendfile`, and `res.download`
+ - `err` will be populated with request aborted error
+ * Support IP address host in `req.subdomains`
+ * Use `etag` to generate `ETag` headers
+ * deps: accepts@~1.1.0
+ - update `mime-types`
+ * deps: cookie-signature@1.0.5
+ * deps: debug@~2.0.0
+ * deps: finalhandler@0.2.0
+ - Set `X-Content-Type-Options: nosniff` header
+ - deps: debug@~2.0.0
+ * deps: fresh@0.2.4
+ * deps: media-typer@0.3.0
+ - Throw error when parameter format invalid on parse
+ * deps: qs@2.2.3
+ - Fix issue where first empty value in array is discarded
+ * deps: range-parser@~1.0.2
+ * deps: send@0.9.1
+ - Add `lastModified` option
+ - Use `etag` to generate `ETag` header
+ - deps: debug@~2.0.0
+ - deps: fresh@0.2.4
+ * deps: serve-static@~1.6.1
+ - Add `lastModified` option
+ - deps: send@0.9.1
+ * deps: type-is@~1.5.1
+ - fix `hasbody` to be true for `content-length: 0`
+ - deps: media-typer@0.3.0
+ - deps: mime-types@~2.0.1
+ * deps: vary@~1.0.0
+ - Accept valid `Vary` header string as `field`
+
+4.8.8 / 2014-09-04
+==================
+
+ * deps: send@0.8.5
+ - Fix a path traversal issue when using `root`
+ - Fix malicious path detection for empty string path
+ * deps: serve-static@~1.5.4
+ - deps: send@0.8.5
+
+4.8.7 / 2014-08-29
+==================
+
+ * deps: qs@2.2.2
+ - Remove unnecessary cloning
+
+4.8.6 / 2014-08-27
+==================
+
+ * deps: qs@2.2.0
+ - Array parsing fix
+ - Performance improvements
+
+4.8.5 / 2014-08-18
+==================
+
+ * deps: send@0.8.3
+ - deps: destroy@1.0.3
+ - deps: on-finished@2.1.0
+ * deps: serve-static@~1.5.3
+ - deps: send@0.8.3
+
+4.8.4 / 2014-08-14
+==================
+
+ * deps: qs@1.2.2
+ * deps: send@0.8.2
+ - Work around `fd` leak in Node.js 0.10 for `fs.ReadStream`
+ * deps: serve-static@~1.5.2
+ - deps: send@0.8.2
+
+4.8.3 / 2014-08-10
+==================
+
+ * deps: parseurl@~1.3.0
+ * deps: qs@1.2.1
+ * deps: serve-static@~1.5.1
+ - Fix parsing of weird `req.originalUrl` values
+ - deps: parseurl@~1.3.0
+ - deps: utils-merge@1.0.0
+
+4.8.2 / 2014-08-07
+==================
+
+ * deps: qs@1.2.0
+ - Fix parsing array of objects
+
+4.8.1 / 2014-08-06
+==================
+
+ * fix incorrect deprecation warnings on `res.download`
+ * deps: qs@1.1.0
+ - Accept urlencoded square brackets
+ - Accept empty values in implicit array notation
+
+4.8.0 / 2014-08-05
+==================
+
+ * add `res.sendFile`
+ - accepts a file system path instead of a URL
+ - requires an absolute path or `root` option specified
+ * deprecate `res.sendfile` -- use `res.sendFile` instead
+ * support mounted app as any argument to `app.use()`
+ * deps: qs@1.0.2
+ - Complete rewrite
+ - Limits array length to 20
+ - Limits object depth to 5
+ - Limits parameters to 1,000
+ * deps: send@0.8.1
+ - Add `extensions` option
+ * deps: serve-static@~1.5.0
+ - Add `extensions` option
+ - deps: send@0.8.1
+
+4.7.4 / 2014-08-04
+==================
+
+ * fix `res.sendfile` regression for serving directory index files
+ * deps: send@0.7.4
+ - Fix incorrect 403 on Windows and Node.js 0.11
+ - Fix serving index files without root dir
+ * deps: serve-static@~1.4.4
+ - deps: send@0.7.4
+
+4.7.3 / 2014-08-04
+==================
+
+ * deps: send@0.7.3
+ - Fix incorrect 403 on Windows and Node.js 0.11
+ * deps: serve-static@~1.4.3
+ - Fix incorrect 403 on Windows and Node.js 0.11
+ - deps: send@0.7.3
+
+4.7.2 / 2014-07-27
+==================
+
+ * deps: depd@0.4.4
+ - Work-around v8 generating empty stack traces
+ * deps: send@0.7.2
+ - deps: depd@0.4.4
+ * deps: serve-static@~1.4.2
+
+4.7.1 / 2014-07-26
+==================
+
+ * deps: depd@0.4.3
+ - Fix exception when global `Error.stackTraceLimit` is too low
+ * deps: send@0.7.1
+ - deps: depd@0.4.3
+ * deps: serve-static@~1.4.1
+
+4.7.0 / 2014-07-25
+==================
+
+ * fix `req.protocol` for proxy-direct connections
+ * configurable query parser with `app.set('query parser', parser)`
+ - `app.set('query parser', 'extended')` parse with "qs" module
+ - `app.set('query parser', 'simple')` parse with "querystring" core module
+ - `app.set('query parser', false)` disable query string parsing
+ - `app.set('query parser', true)` enable simple parsing
+ * deprecate `res.json(status, obj)` -- use `res.status(status).json(obj)` instead
+ * deprecate `res.jsonp(status, obj)` -- use `res.status(status).jsonp(obj)` instead
+ * deprecate `res.send(status, body)` -- use `res.status(status).send(body)` instead
+ * deps: debug@1.0.4
+ * deps: depd@0.4.2
+ - Add `TRACE_DEPRECATION` environment variable
+ - Remove non-standard grey color from color output
+ - Support `--no-deprecation` argument
+ - Support `--trace-deprecation` argument
+ * deps: finalhandler@0.1.0
+ - Respond after request fully read
+ - deps: debug@1.0.4
+ * deps: parseurl@~1.2.0
+ - Cache URLs based on original value
+ - Remove no-longer-needed URL mis-parse work-around
+ - Simplify the "fast-path" `RegExp`
+ * deps: send@0.7.0
+ - Add `dotfiles` option
+ - Cap `maxAge` value to 1 year
+ - deps: debug@1.0.4
+ - deps: depd@0.4.2
+ * deps: serve-static@~1.4.0
+ - deps: parseurl@~1.2.0
+ - deps: send@0.7.0
+ * perf: prevent multiple `Buffer` creation in `res.send`
+
+4.6.1 / 2014-07-12
+==================
+
+ * fix `subapp.mountpath` regression for `app.use(subapp)`
+
+4.6.0 / 2014-07-11
+==================
+
+ * accept multiple callbacks to `app.use()`
+ * add explicit "Rosetta Flash JSONP abuse" protection
+ - previous versions are not vulnerable; this is just explicit protection
+ * catch errors in multiple `req.param(name, fn)` handlers
+ * deprecate `res.redirect(url, status)` -- use `res.redirect(status, url)` instead
+ * fix `res.send(status, num)` to send `num` as json (not error)
+ * remove unnecessary escaping when `res.jsonp` returns JSON response
+ * support non-string `path` in `app.use(path, fn)`
+ - supports array of paths
+ - supports `RegExp`
+ * router: fix optimization on router exit
+ * router: refactor location of `try` blocks
+ * router: speed up standard `app.use(fn)`
+ * deps: debug@1.0.3
+ - Add support for multiple wildcards in namespaces
+ * deps: finalhandler@0.0.3
+ - deps: debug@1.0.3
+ * deps: methods@1.1.0
+ - add `CONNECT`
+ * deps: parseurl@~1.1.3
+ - faster parsing of href-only URLs
+ * deps: path-to-regexp@0.1.3
+ * deps: send@0.6.0
+ - deps: debug@1.0.3
+ * deps: serve-static@~1.3.2
+ - deps: parseurl@~1.1.3
+ - deps: send@0.6.0
+ * perf: fix arguments reassign deopt in some `res` methods
+
+4.5.1 / 2014-07-06
+==================
+
+ * fix routing regression when altering `req.method`
+
+4.5.0 / 2014-07-04
+==================
+
+ * add deprecation message to non-plural `req.accepts*`
+ * add deprecation message to `res.send(body, status)`
+ * add deprecation message to `res.vary()`
+ * add `headers` option to `res.sendfile`
+ - use to set headers on successful file transfer
+ * add `mergeParams` option to `Router`
+ - merges `req.params` from parent routes
+ * add `req.hostname` -- correct name for what `req.host` returns
+ * deprecate things with `depd` module
+ * deprecate `req.host` -- use `req.hostname` instead
+ * fix behavior when handling request without routes
+ * fix handling when `route.all` is only route
+ * invoke `router.param()` only when route matches
+ * restore `req.params` after invoking router
+ * use `finalhandler` for final response handling
+ * use `media-typer` to alter content-type charset
+ * deps: accepts@~1.0.7
+ * deps: send@0.5.0
+ - Accept string for `maxage` (converted by `ms`)
+ - Include link in default redirect response
+ * deps: serve-static@~1.3.0
+ - Accept string for `maxAge` (converted by `ms`)
+ - Add `setHeaders` option
+ - Include HTML link in redirect response
+ - deps: send@0.5.0
+ * deps: type-is@~1.3.2
+
+4.4.5 / 2014-06-26
+==================
+
+ * deps: cookie-signature@1.0.4
+ - fix for timing attacks
+
+4.4.4 / 2014-06-20
+==================
+
+ * fix `res.attachment` Unicode filenames in Safari
+ * fix "trim prefix" debug message in `express:router`
+ * deps: accepts@~1.0.5
+ * deps: buffer-crc32@0.2.3
+
+4.4.3 / 2014-06-11
+==================
+
+ * fix persistence of modified `req.params[name]` from `app.param()`
+ * deps: accepts@1.0.3
+ - deps: negotiator@0.4.6
+ * deps: debug@1.0.2
+ * deps: send@0.4.3
+ - Do not throw un-catchable error on file open race condition
+ - Use `escape-html` for HTML escaping
+ - deps: debug@1.0.2
+ - deps: finished@1.2.2
+ - deps: fresh@0.2.2
+ * deps: serve-static@1.2.3
+ - Do not throw un-catchable error on file open race condition
+ - deps: send@0.4.3
+
+4.4.2 / 2014-06-09
+==================
+
+ * fix catching errors from top-level handlers
+ * use `vary` module for `res.vary`
+ * deps: debug@1.0.1
+ * deps: proxy-addr@1.0.1
+ * deps: send@0.4.2
+ - fix "event emitter leak" warnings
+ - deps: debug@1.0.1
+ - deps: finished@1.2.1
+ * deps: serve-static@1.2.2
+ - fix "event emitter leak" warnings
+ - deps: send@0.4.2
+ * deps: type-is@1.2.1
+
+4.4.1 / 2014-06-02
+==================
+
+ * deps: methods@1.0.1
+ * deps: send@0.4.1
+ - Send `max-age` in `Cache-Control` in correct format
+ * deps: serve-static@1.2.1
+ - use `escape-html` for escaping
+ - deps: send@0.4.1
+
+4.4.0 / 2014-05-30
+==================
+
+ * custom etag control with `app.set('etag', val)`
+ - `app.set('etag', function(body, encoding){ return '"etag"' })` custom etag generation
+ - `app.set('etag', 'weak')` weak tag
+ - `app.set('etag', 'strong')` strong etag
+ - `app.set('etag', false)` turn off
+ - `app.set('etag', true)` standard etag
+ * mark `res.send` ETag as weak and reduce collisions
+ * update accepts to 1.0.2
+ - Fix interpretation when header not in request
+ * update send to 0.4.0
+ - Calculate ETag with md5 for reduced collisions
+ - Ignore stream errors after request ends
+ - deps: debug@0.8.1
+ * update serve-static to 1.2.0
+ - Calculate ETag with md5 for reduced collisions
+ - Ignore stream errors after request ends
+ - deps: send@0.4.0
+
+4.3.2 / 2014-05-28
+==================
+
+ * fix handling of errors from `router.param()` callbacks
+
+4.3.1 / 2014-05-23
+==================
+
+ * revert "fix behavior of multiple `app.VERB` for the same path"
+ - this caused a regression in the order of route execution
+
+4.3.0 / 2014-05-21
+==================
+
+ * add `req.baseUrl` to access the path stripped from `req.url` in routes
+ * fix behavior of multiple `app.VERB` for the same path
+ * fix issue routing requests among sub routers
+ * invoke `router.param()` only when necessary instead of every match
+ * proper proxy trust with `app.set('trust proxy', trust)`
+ - `app.set('trust proxy', 1)` trust first hop
+ - `app.set('trust proxy', 'loopback')` trust loopback addresses
+ - `app.set('trust proxy', '10.0.0.1')` trust single IP
+ - `app.set('trust proxy', '10.0.0.1/16')` trust subnet
+ - `app.set('trust proxy', '10.0.0.1, 10.0.0.2')` trust list
+ - `app.set('trust proxy', false)` turn off
+ - `app.set('trust proxy', true)` trust everything
+ * set proper `charset` in `Content-Type` for `res.send`
+ * update type-is to 1.2.0
+ - support suffix matching
+
+4.2.0 / 2014-05-11
+==================
+
+ * deprecate `app.del()` -- use `app.delete()` instead
+ * deprecate `res.json(obj, status)` -- use `res.json(status, obj)` instead
+ - the edge-case `res.json(status, num)` requires `res.status(status).json(num)`
+ * deprecate `res.jsonp(obj, status)` -- use `res.jsonp(status, obj)` instead
+ - the edge-case `res.jsonp(status, num)` requires `res.status(status).jsonp(num)`
+ * fix `req.next` when inside router instance
+ * include `ETag` header in `HEAD` requests
+ * keep previous `Content-Type` for `res.jsonp`
+ * support PURGE method
+ - add `app.purge`
+ - add `router.purge`
+ - include PURGE in `app.all`
+ * update debug to 0.8.0
+ - add `enable()` method
+ - change from stderr to stdout
+ * update methods to 1.0.0
+ - add PURGE
+
+4.1.2 / 2014-05-08
+==================
+
+ * fix `req.host` for IPv6 literals
+ * fix `res.jsonp` error if callback param is object
+
+4.1.1 / 2014-04-27
+==================
+
+ * fix package.json to reflect supported node version
+
+4.1.0 / 2014-04-24
+==================
+
+ * pass options from `res.sendfile` to `send`
+ * preserve casing of headers in `res.header` and `res.set`
+ * support unicode file names in `res.attachment` and `res.download`
+ * update accepts to 1.0.1
+ - deps: negotiator@0.4.0
+ * update cookie to 0.1.2
+ - Fix for maxAge == 0
+ - made compat with expires field
+ * update send to 0.3.0
+ - Accept API options in options object
+ - Coerce option types
+ - Control whether to generate etags
+ - Default directory access to 403 when index disabled
+ - Fix sending files with dots without root set
+ - Include file path in etag
+ - Make "Can't set headers after they are sent." catchable
+ - Send full entity-body for multi range requests
+ - Set etags to "weak"
+ - Support "If-Range" header
+ - Support multiple index paths
+ - deps: mime@1.2.11
+ * update serve-static to 1.1.0
+ - Accept options directly to `send` module
+ - Resolve relative paths at middleware setup
+ - Use parseurl to parse the URL from request
+ - deps: send@0.3.0
+ * update type-is to 1.1.0
+ - add non-array values support
+ - add `multipart` as a shorthand
+
+4.0.0 / 2014-04-09
+==================
+
+ * remove:
+ - node 0.8 support
+ - connect and connect's patches except for charset handling
+ - express(1) - moved to [express-generator](https://github.com/expressjs/generator)
+ - `express.createServer()` - it has been deprecated for a long time. Use `express()`
+ - `app.configure` - use logic in your own app code
+ - `app.router` - is removed
+ - `req.auth` - use `basic-auth` instead
+ - `req.accepted*` - use `req.accepts*()` instead
+ - `res.location` - relative URL resolution is removed
+ - `res.charset` - include the charset in the content type when using `res.set()`
+ - all bundled middleware except `static`
+ * change:
+ - `app.route` -> `app.mountpath` when mounting an express app in another express app
+ - `json spaces` no longer enabled by default in development
+ - `req.accepts*` -> `req.accepts*s` - i.e. `req.acceptsEncoding` -> `req.acceptsEncodings`
+ - `req.params` is now an object instead of an array
+ - `res.locals` is no longer a function. It is a plain js object. Treat it as such.
+ - `res.headerSent` -> `res.headersSent` to match node.js ServerResponse object
+ * refactor:
+ - `req.accepts*` with [accepts](https://github.com/expressjs/accepts)
+ - `req.is` with [type-is](https://github.com/expressjs/type-is)
+ - [path-to-regexp](https://github.com/component/path-to-regexp)
+ * add:
+ - `app.router()` - returns the app Router instance
+ - `app.route()` - Proxy to the app's `Router#route()` method to create a new route
+ - Router & Route - public API
+
+3.21.2 / 2015-07-31
+===================
+
+ * deps: connect@2.30.2
+ - deps: body-parser@~1.13.3
+ - deps: compression@~1.5.2
+ - deps: errorhandler@~1.4.2
+ - deps: method-override@~2.3.5
+ - deps: serve-index@~1.7.2
+ - deps: type-is@~1.6.6
+ - deps: vhost@~3.0.1
+ * deps: vary@~1.0.1
+ - Fix setting empty header from empty `field`
+ - perf: enable strict mode
+ - perf: remove argument reassignments
+
+3.21.1 / 2015-07-05
+===================
+
+ * deps: basic-auth@~1.0.3
+ * deps: connect@2.30.1
+ - deps: body-parser@~1.13.2
+ - deps: compression@~1.5.1
+ - deps: errorhandler@~1.4.1
+ - deps: morgan@~1.6.1
+ - deps: pause@0.1.0
+ - deps: qs@4.0.0
+ - deps: serve-index@~1.7.1
+ - deps: type-is@~1.6.4
+
+3.21.0 / 2015-06-18
+===================
+
+ * deps: basic-auth@1.0.2
+ - perf: enable strict mode
+ - perf: hoist regular expression
+ - perf: parse with regular expressions
+ - perf: remove argument reassignment
+ * deps: connect@2.30.0
+ - deps: body-parser@~1.13.1
+ - deps: bytes@2.1.0
+ - deps: compression@~1.5.0
+ - deps: cookie@0.1.3
+ - deps: cookie-parser@~1.3.5
+ - deps: csurf@~1.8.3
+ - deps: errorhandler@~1.4.0
+ - deps: express-session@~1.11.3
+ - deps: finalhandler@0.4.0
+ - deps: fresh@0.3.0
+ - deps: morgan@~1.6.0
+ - deps: serve-favicon@~2.3.0
+ - deps: serve-index@~1.7.0
+ - deps: serve-static@~1.10.0
+ - deps: type-is@~1.6.3
+ * deps: cookie@0.1.3
+ - perf: deduce the scope of try-catch deopt
+ - perf: remove argument reassignments
+ * deps: escape-html@1.0.2
+ * deps: etag@~1.7.0
+ - Always include entity length in ETags for hash length extensions
+ - Generate non-Stats ETags using MD5 only (no longer CRC32)
+ - Improve stat performance by removing hashing
+ - Improve support for JXcore
+ - Remove base64 padding in ETags to shorten
+ - Support "fake" stats objects in environments without fs
+ - Use MD5 instead of MD4 in weak ETags over 1KB
+ * deps: fresh@0.3.0
+ - Add weak `ETag` matching support
+ * deps: mkdirp@0.5.1
+ - Work in global strict mode
+ * deps: send@0.13.0
+ - Allow Node.js HTTP server to set `Date` response header
+ - Fix incorrectly removing `Content-Location` on 304 response
+ - Improve the default redirect response headers
+ - Send appropriate headers on default error response
+ - Use `http-errors` for standard emitted errors
+ - Use `statuses` instead of `http` module for status messages
+ - deps: escape-html@1.0.2
+ - deps: etag@~1.7.0
+ - deps: fresh@0.3.0
+ - deps: on-finished@~2.3.0
+ - perf: enable strict mode
+ - perf: remove unnecessary array allocations
+
+3.20.3 / 2015-05-17
+===================
+
+ * deps: connect@2.29.2
+ - deps: body-parser@~1.12.4
+ - deps: compression@~1.4.4
+ - deps: connect-timeout@~1.6.2
+ - deps: debug@~2.2.0
+ - deps: depd@~1.0.1
+ - deps: errorhandler@~1.3.6
+ - deps: finalhandler@0.3.6
+ - deps: method-override@~2.3.3
+ - deps: morgan@~1.5.3
+ - deps: qs@2.4.2
+ - deps: response-time@~2.3.1
+ - deps: serve-favicon@~2.2.1
+ - deps: serve-index@~1.6.4
+ - deps: serve-static@~1.9.3
+ - deps: type-is@~1.6.2
+ * deps: debug@~2.2.0
+ - deps: ms@0.7.1
+ * deps: depd@~1.0.1
+ * deps: proxy-addr@~1.0.8
+ - deps: ipaddr.js@1.0.1
+ * deps: send@0.12.3
+ - deps: debug@~2.2.0
+ - deps: depd@~1.0.1
+ - deps: etag@~1.6.0
+ - deps: ms@0.7.1
+ - deps: on-finished@~2.2.1
+
+3.20.2 / 2015-03-16
+===================
+
+ * deps: connect@2.29.1
+ - deps: body-parser@~1.12.2
+ - deps: compression@~1.4.3
+ - deps: connect-timeout@~1.6.1
+ - deps: debug@~2.1.3
+ - deps: errorhandler@~1.3.5
+ - deps: express-session@~1.10.4
+ - deps: finalhandler@0.3.4
+ - deps: method-override@~2.3.2
+ - deps: morgan@~1.5.2
+ - deps: qs@2.4.1
+ - deps: serve-index@~1.6.3
+ - deps: serve-static@~1.9.2
+ - deps: type-is@~1.6.1
+ * deps: debug@~2.1.3
+ - Fix high intensity foreground color for bold
+ - deps: ms@0.7.0
+ * deps: merge-descriptors@1.0.0
+ * deps: proxy-addr@~1.0.7
+ - deps: ipaddr.js@0.1.9
+ * deps: send@0.12.2
+ - Throw errors early for invalid `extensions` or `index` options
+ - deps: debug@~2.1.3
+
+3.20.1 / 2015-02-28
+===================
+
+ * Fix `req.host` when using "trust proxy" hops count
+ * Fix `req.protocol`/`req.secure` when using "trust proxy" hops count
+
+3.20.0 / 2015-02-18
+===================
+
+ * Fix `"trust proxy"` setting to inherit when app is mounted
+ * Generate `ETag`s for all request responses
+ - No longer restricted to only responses for `GET` and `HEAD` requests
+ * Use `content-type` to parse `Content-Type` headers
+ * deps: connect@2.29.0
+ - Use `content-type` to parse `Content-Type` headers
+ - deps: body-parser@~1.12.0
+ - deps: compression@~1.4.1
+ - deps: connect-timeout@~1.6.0
+ - deps: cookie-parser@~1.3.4
+ - deps: cookie-signature@1.0.6
+ - deps: csurf@~1.7.0
+ - deps: errorhandler@~1.3.4
+ - deps: express-session@~1.10.3
+ - deps: http-errors@~1.3.1
+ - deps: response-time@~2.3.0
+ - deps: serve-index@~1.6.2
+ - deps: serve-static@~1.9.1
+ - deps: type-is@~1.6.0
+ * deps: cookie-signature@1.0.6
+ * deps: send@0.12.1
+ - Always read the stat size from the file
+ - Fix mutating passed-in `options`
+ - deps: mime@1.3.4
+
+3.19.2 / 2015-02-01
+===================
+
+ * deps: connect@2.28.3
+ - deps: compression@~1.3.1
+ - deps: csurf@~1.6.6
+ - deps: errorhandler@~1.3.3
+ - deps: express-session@~1.10.2
+ - deps: serve-index@~1.6.1
+ - deps: type-is@~1.5.6
+ * deps: proxy-addr@~1.0.6
+ - deps: ipaddr.js@0.1.8
+
+3.19.1 / 2015-01-20
+===================
+
+ * deps: connect@2.28.2
+ - deps: body-parser@~1.10.2
+ - deps: serve-static@~1.8.1
+ * deps: send@0.11.1
+ - Fix root path disclosure
+
+3.19.0 / 2015-01-09
+===================
+
+ * Fix `OPTIONS` responses to include the `HEAD` method property
+ * Use `readline` for prompt in `express(1)`
+ * deps: commander@2.6.0
+ * deps: connect@2.28.1
+ - deps: body-parser@~1.10.1
+ - deps: compression@~1.3.0
+ - deps: connect-timeout@~1.5.0
+ - deps: csurf@~1.6.4
+ - deps: debug@~2.1.1
+ - deps: errorhandler@~1.3.2
+ - deps: express-session@~1.10.1
+ - deps: finalhandler@0.3.3
+ - deps: method-override@~2.3.1
+ - deps: morgan@~1.5.1
+ - deps: serve-favicon@~2.2.0
+ - deps: serve-index@~1.6.0
+ - deps: serve-static@~1.8.0
+ - deps: type-is@~1.5.5
+ * deps: debug@~2.1.1
+ * deps: methods@~1.1.1
+ * deps: proxy-addr@~1.0.5
+ - deps: ipaddr.js@0.1.6
+ * deps: send@0.11.0
+ - deps: debug@~2.1.1
+ - deps: etag@~1.5.1
+ - deps: ms@0.7.0
+ - deps: on-finished@~2.2.0
+
+3.18.6 / 2014-12-12
+===================
+
+ * Fix exception in `req.fresh`/`req.stale` without response headers
+
+3.18.5 / 2014-12-11
+===================
+
+ * deps: connect@2.27.6
+ - deps: compression@~1.2.2
+ - deps: express-session@~1.9.3
+ - deps: http-errors@~1.2.8
+ - deps: serve-index@~1.5.3
+ - deps: type-is@~1.5.4
+
+3.18.4 / 2014-11-23
+===================
+
+ * deps: connect@2.27.4
+ - deps: body-parser@~1.9.3
+ - deps: compression@~1.2.1
+ - deps: errorhandler@~1.2.3
+ - deps: express-session@~1.9.2
+ - deps: qs@2.3.3
+ - deps: serve-favicon@~2.1.7
+ - deps: serve-static@~1.5.1
+ - deps: type-is@~1.5.3
+ * deps: etag@~1.5.1
+ * deps: proxy-addr@~1.0.4
+ - deps: ipaddr.js@0.1.5
+
+3.18.3 / 2014-11-09
+===================
+
+ * deps: connect@2.27.3
+ - Correctly invoke async callback asynchronously
+ - deps: csurf@~1.6.3
+
+3.18.2 / 2014-10-28
+===================
+
+ * deps: connect@2.27.2
+ - Fix handling of URLs containing `://` in the path
+ - deps: body-parser@~1.9.2
+ - deps: qs@2.3.2
+
+3.18.1 / 2014-10-22
+===================
+
+ * Fix internal `utils.merge` deprecation warnings
+ * deps: connect@2.27.1
+ - deps: body-parser@~1.9.1
+ - deps: express-session@~1.9.1
+ - deps: finalhandler@0.3.2
+ - deps: morgan@~1.4.1
+ - deps: qs@2.3.0
+ - deps: serve-static@~1.7.1
+ * deps: send@0.10.1
+ - deps: on-finished@~2.1.1
+
+3.18.0 / 2014-10-17
+===================
+
+ * Use `content-disposition` module for `res.attachment`/`res.download`
+ - Sends standards-compliant `Content-Disposition` header
+ - Full Unicode support
+ * Use `etag` module to generate `ETag` headers
+ * deps: connect@2.27.0
+ - Use `http-errors` module for creating errors
+ - Use `utils-merge` module for merging objects
+ - deps: body-parser@~1.9.0
+ - deps: compression@~1.2.0
+ - deps: connect-timeout@~1.4.0
+ - deps: debug@~2.1.0
+ - deps: depd@~1.0.0
+ - deps: express-session@~1.9.0
+ - deps: finalhandler@0.3.1
+ - deps: method-override@~2.3.0
+ - deps: morgan@~1.4.0
+ - deps: response-time@~2.2.0
+ - deps: serve-favicon@~2.1.6
+ - deps: serve-index@~1.5.0
+ - deps: serve-static@~1.7.0
+ * deps: debug@~2.1.0
+ - Implement `DEBUG_FD` env variable support
+ * deps: depd@~1.0.0
+ * deps: send@0.10.0
+ - deps: debug@~2.1.0
+ - deps: depd@~1.0.0
+ - deps: etag@~1.5.0
+
+3.17.8 / 2014-10-15
+===================
+
+ * deps: connect@2.26.6
+ - deps: compression@~1.1.2
+ - deps: csurf@~1.6.2
+ - deps: errorhandler@~1.2.2
+
+3.17.7 / 2014-10-08
+===================
+
+ * deps: connect@2.26.5
+ - Fix accepting non-object arguments to `logger`
+ - deps: serve-static@~1.6.4
+
+3.17.6 / 2014-10-02
+===================
+
+ * deps: connect@2.26.4
+ - deps: morgan@~1.3.2
+ - deps: type-is@~1.5.2
+
+3.17.5 / 2014-09-24
+===================
+
+ * deps: connect@2.26.3
+ - deps: body-parser@~1.8.4
+ - deps: serve-favicon@~2.1.5
+ - deps: serve-static@~1.6.3
+ * deps: proxy-addr@~1.0.3
+ - Use `forwarded` npm module
+ * deps: send@0.9.3
+ - deps: etag@~1.4.0
+
+3.17.4 / 2014-09-19
+===================
+
+ * deps: connect@2.26.2
+ - deps: body-parser@~1.8.3
+ - deps: qs@2.2.4
+
+3.17.3 / 2014-09-18
+===================
+
+ * deps: proxy-addr@~1.0.2
+ - Fix a global leak when multiple subnets are trusted
+ - deps: ipaddr.js@0.1.3
+
+3.17.2 / 2014-09-15
+===================
+
+ * Use `crc` instead of `buffer-crc32` for speed
+ * deps: connect@2.26.1
+ - deps: body-parser@~1.8.2
+ - deps: depd@0.4.5
+ - deps: express-session@~1.8.2
+ - deps: morgan@~1.3.1
+ - deps: serve-favicon@~2.1.3
+ - deps: serve-static@~1.6.2
+ * deps: depd@0.4.5
+ * deps: send@0.9.2
+ - deps: depd@0.4.5
+ - deps: etag@~1.3.1
+ - deps: range-parser@~1.0.2
+
+3.17.1 / 2014-09-08
+===================
+
+ * Fix error in `req.subdomains` on empty host
+
+3.17.0 / 2014-09-08
+===================
+
+ * Support `X-Forwarded-Host` in `req.subdomains`
+ * Support IP address host in `req.subdomains`
+ * deps: connect@2.26.0
+ - deps: body-parser@~1.8.1
+ - deps: compression@~1.1.0
+ - deps: connect-timeout@~1.3.0
+ - deps: cookie-parser@~1.3.3
+ - deps: cookie-signature@1.0.5
+ - deps: csurf@~1.6.1
+ - deps: debug@~2.0.0
+ - deps: errorhandler@~1.2.0
+ - deps: express-session@~1.8.1
+ - deps: finalhandler@0.2.0
+ - deps: fresh@0.2.4
+ - deps: media-typer@0.3.0
+ - deps: method-override@~2.2.0
+ - deps: morgan@~1.3.0
+ - deps: qs@2.2.3
+ - deps: serve-favicon@~2.1.3
+ - deps: serve-index@~1.2.1
+ - deps: serve-static@~1.6.1
+ - deps: type-is@~1.5.1
+ - deps: vhost@~3.0.0
+ * deps: cookie-signature@1.0.5
+ * deps: debug@~2.0.0
+ * deps: fresh@0.2.4
+ * deps: media-typer@0.3.0
+ - Throw error when parameter format invalid on parse
+ * deps: range-parser@~1.0.2
+ * deps: send@0.9.1
+ - Add `lastModified` option
+ - Use `etag` to generate `ETag` header
+ - deps: debug@~2.0.0
+ - deps: fresh@0.2.4
+ * deps: vary@~1.0.0
+ - Accept valid `Vary` header string as `field`
+
+3.16.10 / 2014-09-04
+====================
+
+ * deps: connect@2.25.10
+ - deps: serve-static@~1.5.4
+ * deps: send@0.8.5
+ - Fix a path traversal issue when using `root`
+ - Fix malicious path detection for empty string path
+
+3.16.9 / 2014-08-29
+===================
+
+ * deps: connect@2.25.9
+ - deps: body-parser@~1.6.7
+ - deps: qs@2.2.2
+
+3.16.8 / 2014-08-27
+===================
+
+ * deps: connect@2.25.8
+ - deps: body-parser@~1.6.6
+ - deps: csurf@~1.4.1
+ - deps: qs@2.2.0
+
+3.16.7 / 2014-08-18
+===================
+
+ * deps: connect@2.25.7
+ - deps: body-parser@~1.6.5
+ - deps: express-session@~1.7.6
+ - deps: morgan@~1.2.3
+ - deps: serve-static@~1.5.3
+ * deps: send@0.8.3
+ - deps: destroy@1.0.3
+ - deps: on-finished@2.1.0
+
+3.16.6 / 2014-08-14
+===================
+
+ * deps: connect@2.25.6
+ - deps: body-parser@~1.6.4
+ - deps: qs@1.2.2
+ - deps: serve-static@~1.5.2
+ * deps: send@0.8.2
+ - Work around `fd` leak in Node.js 0.10 for `fs.ReadStream`
+
+3.16.5 / 2014-08-11
+===================
+
+ * deps: connect@2.25.5
+ - Fix backwards compatibility in `logger`
+
+3.16.4 / 2014-08-10
+===================
+
+ * Fix original URL parsing in `res.location`
+ * deps: connect@2.25.4
+ - Fix `query` middleware breaking with argument
+ - deps: body-parser@~1.6.3
+ - deps: compression@~1.0.11
+ - deps: connect-timeout@~1.2.2
+ - deps: express-session@~1.7.5
+ - deps: method-override@~2.1.3
+ - deps: on-headers@~1.0.0
+ - deps: parseurl@~1.3.0
+ - deps: qs@1.2.1
+ - deps: response-time@~2.0.1
+ - deps: serve-index@~1.1.6
+ - deps: serve-static@~1.5.1
+ * deps: parseurl@~1.3.0
+
+3.16.3 / 2014-08-07
+===================
+
+ * deps: connect@2.25.3
+ - deps: multiparty@3.3.2
+
+3.16.2 / 2014-08-07
+===================
+
+ * deps: connect@2.25.2
+ - deps: body-parser@~1.6.2
+ - deps: qs@1.2.0
+
+3.16.1 / 2014-08-06
+===================
+
+ * deps: connect@2.25.1
+ - deps: body-parser@~1.6.1
+ - deps: qs@1.1.0
+
+3.16.0 / 2014-08-05
+===================
+
+ * deps: connect@2.25.0
+ - deps: body-parser@~1.6.0
+ - deps: compression@~1.0.10
+ - deps: csurf@~1.4.0
+ - deps: express-session@~1.7.4
+ - deps: qs@1.0.2
+ - deps: serve-static@~1.5.0
+ * deps: send@0.8.1
+ - Add `extensions` option
+
+3.15.3 / 2014-08-04
+===================
+
+ * fix `res.sendfile` regression for serving directory index files
+ * deps: connect@2.24.3
+ - deps: serve-index@~1.1.5
+ - deps: serve-static@~1.4.4
+ * deps: send@0.7.4
+ - Fix incorrect 403 on Windows and Node.js 0.11
+ - Fix serving index files without root dir
+
+3.15.2 / 2014-07-27
+===================
+
+ * deps: connect@2.24.2
+ - deps: body-parser@~1.5.2
+ - deps: depd@0.4.4
+ - deps: express-session@~1.7.2
+ - deps: morgan@~1.2.2
+ - deps: serve-static@~1.4.2
+ * deps: depd@0.4.4
+ - Work-around v8 generating empty stack traces
+ * deps: send@0.7.2
+ - deps: depd@0.4.4
+
+3.15.1 / 2014-07-26
+===================
+
+ * deps: connect@2.24.1
+ - deps: body-parser@~1.5.1
+ - deps: depd@0.4.3
+ - deps: express-session@~1.7.1
+ - deps: morgan@~1.2.1
+ - deps: serve-index@~1.1.4
+ - deps: serve-static@~1.4.1
+ * deps: depd@0.4.3
+ - Fix exception when global `Error.stackTraceLimit` is too low
+ * deps: send@0.7.1
+ - deps: depd@0.4.3
+
+3.15.0 / 2014-07-22
+===================
+
+ * Fix `req.protocol` for proxy-direct connections
+ * Pass options from `res.sendfile` to `send`
+ * deps: connect@2.24.0
+ - deps: body-parser@~1.5.0
+ - deps: compression@~1.0.9
+ - deps: connect-timeout@~1.2.1
+ - deps: debug@1.0.4
+ - deps: depd@0.4.2
+ - deps: express-session@~1.7.0
+ - deps: finalhandler@0.1.0
+ - deps: method-override@~2.1.2
+ - deps: morgan@~1.2.0
+ - deps: multiparty@3.3.1
+ - deps: parseurl@~1.2.0
+ - deps: serve-static@~1.4.0
+ * deps: debug@1.0.4
+ * deps: depd@0.4.2
+ - Add `TRACE_DEPRECATION` environment variable
+ - Remove non-standard grey color from color output
+ - Support `--no-deprecation` argument
+ - Support `--trace-deprecation` argument
+ * deps: parseurl@~1.2.0
+ - Cache URLs based on original value
+ - Remove no-longer-needed URL mis-parse work-around
+ - Simplify the "fast-path" `RegExp`
+ * deps: send@0.7.0
+ - Add `dotfiles` option
+ - Cap `maxAge` value to 1 year
+ - deps: debug@1.0.4
+ - deps: depd@0.4.2
+
+3.14.0 / 2014-07-11
+===================
+
+ * add explicit "Rosetta Flash JSONP abuse" protection
+ - previous versions are not vulnerable; this is just explicit protection
+ * deprecate `res.redirect(url, status)` -- use `res.redirect(status, url)` instead
+ * fix `res.send(status, num)` to send `num` as json (not error)
+ * remove unnecessary escaping when `res.jsonp` returns JSON response
+ * deps: basic-auth@1.0.0
+ - support empty password
+ - support empty username
+ * deps: connect@2.23.0
+ - deps: debug@1.0.3
+ - deps: express-session@~1.6.4
+ - deps: method-override@~2.1.0
+ - deps: parseurl@~1.1.3
+ - deps: serve-static@~1.3.1
+ * deps: debug@1.0.3
+ - Add support for multiple wildcards in namespaces
+ * deps: methods@1.1.0
+ - add `CONNECT`
+ * deps: parseurl@~1.1.3
+ - faster parsing of href-only URLs
+
+3.13.0 / 2014-07-03
+===================
+
+ * add deprecation message to `app.configure`
+ * add deprecation message to `req.auth`
+ * use `basic-auth` to parse `Authorization` header
+ * deps: connect@2.22.0
+ - deps: csurf@~1.3.0
+ - deps: express-session@~1.6.1
+ - deps: multiparty@3.3.0
+ - deps: serve-static@~1.3.0
+ * deps: send@0.5.0
+ - Accept string for `maxage` (converted by `ms`)
+ - Include link in default redirect response
+
+3.12.1 / 2014-06-26
+===================
+
+ * deps: connect@2.21.1
+ - deps: cookie-parser@1.3.2
+ - deps: cookie-signature@1.0.4
+ - deps: express-session@~1.5.2
+ - deps: type-is@~1.3.2
+ * deps: cookie-signature@1.0.4
+ - fix for timing attacks
+
+3.12.0 / 2014-06-21
+===================
+
+ * use `media-typer` to alter content-type charset
+ * deps: connect@2.21.0
+ - deprecate `connect(middleware)` -- use `app.use(middleware)` instead
+ - deprecate `connect.createServer()` -- use `connect()` instead
+ - fix `res.setHeader()` patch to work with with get -> append -> set pattern
+ - deps: compression@~1.0.8
+ - deps: errorhandler@~1.1.1
+ - deps: express-session@~1.5.0
+ - deps: serve-index@~1.1.3
+
+3.11.0 / 2014-06-19
+===================
+
+ * deprecate things with `depd` module
+ * deps: buffer-crc32@0.2.3
+ * deps: connect@2.20.2
+ - deprecate `verify` option to `json` -- use `body-parser` npm module instead
+ - deprecate `verify` option to `urlencoded` -- use `body-parser` npm module instead
+ - deprecate things with `depd` module
+ - use `finalhandler` for final response handling
+ - use `media-typer` to parse `content-type` for charset
+ - deps: body-parser@1.4.3
+ - deps: connect-timeout@1.1.1
+ - deps: cookie-parser@1.3.1
+ - deps: csurf@1.2.2
+ - deps: errorhandler@1.1.0
+ - deps: express-session@1.4.0
+ - deps: multiparty@3.2.9
+ - deps: serve-index@1.1.2
+ - deps: type-is@1.3.1
+ - deps: vhost@2.0.0
+
+3.10.5 / 2014-06-11
+===================
+
+ * deps: connect@2.19.6
+ - deps: body-parser@1.3.1
+ - deps: compression@1.0.7
+ - deps: debug@1.0.2
+ - deps: serve-index@1.1.1
+ - deps: serve-static@1.2.3
+ * deps: debug@1.0.2
+ * deps: send@0.4.3
+ - Do not throw un-catchable error on file open race condition
+ - Use `escape-html` for HTML escaping
+ - deps: debug@1.0.2
+ - deps: finished@1.2.2
+ - deps: fresh@0.2.2
+
+3.10.4 / 2014-06-09
+===================
+
+ * deps: connect@2.19.5
+ - fix "event emitter leak" warnings
+ - deps: csurf@1.2.1
+ - deps: debug@1.0.1
+ - deps: serve-static@1.2.2
+ - deps: type-is@1.2.1
+ * deps: debug@1.0.1
+ * deps: send@0.4.2
+ - fix "event emitter leak" warnings
+ - deps: finished@1.2.1
+ - deps: debug@1.0.1
+
+3.10.3 / 2014-06-05
+===================
+
+ * use `vary` module for `res.vary`
+ * deps: connect@2.19.4
+ - deps: errorhandler@1.0.2
+ - deps: method-override@2.0.2
+ - deps: serve-favicon@2.0.1
+ * deps: debug@1.0.0
+
+3.10.2 / 2014-06-03
+===================
+
+ * deps: connect@2.19.3
+ - deps: compression@1.0.6
+
+3.10.1 / 2014-06-03
+===================
+
+ * deps: connect@2.19.2
+ - deps: compression@1.0.4
+ * deps: proxy-addr@1.0.1
+
+3.10.0 / 2014-06-02
+===================
+
+ * deps: connect@2.19.1
+ - deprecate `methodOverride()` -- use `method-override` npm module instead
+ - deps: body-parser@1.3.0
+ - deps: method-override@2.0.1
+ - deps: multiparty@3.2.8
+ - deps: response-time@2.0.0
+ - deps: serve-static@1.2.1
+ * deps: methods@1.0.1
+ * deps: send@0.4.1
+ - Send `max-age` in `Cache-Control` in correct format
+
+3.9.0 / 2014-05-30
+==================
+
+ * custom etag control with `app.set('etag', val)`
+ - `app.set('etag', function(body, encoding){ return '"etag"' })` custom etag generation
+ - `app.set('etag', 'weak')` weak tag
+ - `app.set('etag', 'strong')` strong etag
+ - `app.set('etag', false)` turn off
+ - `app.set('etag', true)` standard etag
+ * Include ETag in HEAD requests
+ * mark `res.send` ETag as weak and reduce collisions
+ * update connect to 2.18.0
+ - deps: compression@1.0.3
+ - deps: serve-index@1.1.0
+ - deps: serve-static@1.2.0
+ * update send to 0.4.0
+ - Calculate ETag with md5 for reduced collisions
+ - Ignore stream errors after request ends
+ - deps: debug@0.8.1
+
+3.8.1 / 2014-05-27
+==================
+
+ * update connect to 2.17.3
+ - deps: body-parser@1.2.2
+ - deps: express-session@1.2.1
+ - deps: method-override@1.0.2
+
+3.8.0 / 2014-05-21
+==================
+
+ * keep previous `Content-Type` for `res.jsonp`
+ * set proper `charset` in `Content-Type` for `res.send`
+ * update connect to 2.17.1
+ - fix `res.charset` appending charset when `content-type` has one
+ - deps: express-session@1.2.0
+ - deps: morgan@1.1.1
+ - deps: serve-index@1.0.3
+
+3.7.0 / 2014-05-18
+==================
+
+ * proper proxy trust with `app.set('trust proxy', trust)`
+ - `app.set('trust proxy', 1)` trust first hop
+ - `app.set('trust proxy', 'loopback')` trust loopback addresses
+ - `app.set('trust proxy', '10.0.0.1')` trust single IP
+ - `app.set('trust proxy', '10.0.0.1/16')` trust subnet
+ - `app.set('trust proxy', '10.0.0.1, 10.0.0.2')` trust list
+ - `app.set('trust proxy', false)` turn off
+ - `app.set('trust proxy', true)` trust everything
+ * update connect to 2.16.2
+ - deprecate `res.headerSent` -- use `res.headersSent`
+ - deprecate `res.on("header")` -- use on-headers module instead
+ - fix edge-case in `res.appendHeader` that would append in wrong order
+ - json: use body-parser
+ - urlencoded: use body-parser
+ - dep: bytes@1.0.0
+ - dep: cookie-parser@1.1.0
+ - dep: csurf@1.2.0
+ - dep: express-session@1.1.0
+ - dep: method-override@1.0.1
+
+3.6.0 / 2014-05-09
+==================
+
+ * deprecate `app.del()` -- use `app.delete()` instead
+ * deprecate `res.json(obj, status)` -- use `res.json(status, obj)` instead
+ - the edge-case `res.json(status, num)` requires `res.status(status).json(num)`
+ * deprecate `res.jsonp(obj, status)` -- use `res.jsonp(status, obj)` instead
+ - the edge-case `res.jsonp(status, num)` requires `res.status(status).jsonp(num)`
+ * support PURGE method
+ - add `app.purge`
+ - add `router.purge`
+ - include PURGE in `app.all`
+ * update connect to 2.15.0
+ * Add `res.appendHeader`
+ * Call error stack even when response has been sent
+ * Patch `res.headerSent` to return Boolean
+ * Patch `res.headersSent` for node.js 0.8
+ * Prevent default 404 handler after response sent
+ * dep: compression@1.0.2
+ * dep: connect-timeout@1.1.0
+ * dep: debug@^0.8.0
+ * dep: errorhandler@1.0.1
+ * dep: express-session@1.0.4
+ * dep: morgan@1.0.1
+ * dep: serve-favicon@2.0.0
+ * dep: serve-index@1.0.2
+ * update debug to 0.8.0
+ * add `enable()` method
+ * change from stderr to stdout
+ * update methods to 1.0.0
+ - add PURGE
+ * update mkdirp to 0.5.0
+
+3.5.3 / 2014-05-08
+==================
+
+ * fix `req.host` for IPv6 literals
+ * fix `res.jsonp` error if callback param is object
+
+3.5.2 / 2014-04-24
+==================
+
+ * update connect to 2.14.5
+ * update cookie to 0.1.2
+ * update mkdirp to 0.4.0
+ * update send to 0.3.0
+
+3.5.1 / 2014-03-25
+==================
+
+ * pin less-middleware in generated app
+
+3.5.0 / 2014-03-06
+==================
+
+ * bump deps
+
+3.4.8 / 2014-01-13
+==================
+
+ * prevent incorrect automatic OPTIONS responses #1868 @dpatti
+ * update binary and examples for jade 1.0 #1876 @yossi, #1877 @reqshark, #1892 @matheusazzi
+ * throw 400 in case of malformed paths @rlidwka
+
+3.4.7 / 2013-12-10
+==================
+
+ * update connect
+
+3.4.6 / 2013-12-01
+==================
+
+ * update connect (raw-body)
+
+3.4.5 / 2013-11-27
+==================
+
+ * update connect
+ * res.location: remove leading ./ #1802 @kapouer
+ * res.redirect: fix `res.redirect('toString') #1829 @michaelficarra
+ * res.send: always send ETag when content-length > 0
+ * router: add Router.all() method
+
+3.4.4 / 2013-10-29
+==================
+
+ * update connect
+ * update supertest
+ * update methods
+ * express(1): replace bodyParser() with urlencoded() and json() #1795 @chirag04
+
+3.4.3 / 2013-10-23
+==================
+
+ * update connect
+
+3.4.2 / 2013-10-18
+==================
+
+ * update connect
+ * downgrade commander
+
+3.4.1 / 2013-10-15
+==================
+
+ * update connect
+ * update commander
+ * jsonp: check if callback is a function
+ * router: wrap encodeURIComponent in a try/catch #1735 (@lxe)
+ * res.format: now includes charset @1747 (@sorribas)
+ * res.links: allow multiple calls @1746 (@sorribas)
+
+3.4.0 / 2013-09-07
+==================
+
+ * add res.vary(). Closes #1682
+ * update connect
+
+3.3.8 / 2013-09-02
+==================
+
+ * update connect
+
+3.3.7 / 2013-08-28
+==================
+
+ * update connect
+
+3.3.6 / 2013-08-27
+==================
+
+ * Revert "remove charset from json responses. Closes #1631" (causes issues in some clients)
+ * add: req.accepts take an argument list
+
+3.3.4 / 2013-07-08
+==================
+
+ * update send and connect
+
+3.3.3 / 2013-07-04
+==================
+
+ * update connect
+
+3.3.2 / 2013-07-03
+==================
+
+ * update connect
+ * update send
+ * remove .version export
+
+3.3.1 / 2013-06-27
+==================
+
+ * update connect
+
+3.3.0 / 2013-06-26
+==================
+
+ * update connect
+ * add support for multiple X-Forwarded-Proto values. Closes #1646
+ * change: remove charset from json responses. Closes #1631
+ * change: return actual booleans from req.accept* functions
+ * fix jsonp callback array throw
+
+3.2.6 / 2013-06-02
+==================
+
+ * update connect
+
+3.2.5 / 2013-05-21
+==================
+
+ * update connect
+ * update node-cookie
+ * add: throw a meaningful error when there is no default engine
+ * change generation of ETags with res.send() to GET requests only. Closes #1619
+
+3.2.4 / 2013-05-09
+==================
+
+ * fix `req.subdomains` when no Host is present
+ * fix `req.host` when no Host is present, return undefined
+
+3.2.3 / 2013-05-07
+==================
+
+ * update connect / qs
+
+3.2.2 / 2013-05-03
+==================
+
+ * update qs
+
+3.2.1 / 2013-04-29
+==================
+
+ * add app.VERB() paths array deprecation warning
+ * update connect
+ * update qs and remove all ~ semver crap
+ * fix: accept number as value of Signed Cookie
+
+3.2.0 / 2013-04-15
+==================
+
+ * add "view" constructor setting to override view behaviour
+ * add req.acceptsEncoding(name)
+ * add req.acceptedEncodings
+ * revert cookie signature change causing session race conditions
+ * fix sorting of Accept values of the same quality
+
+3.1.2 / 2013-04-12
+==================
+
+ * add support for custom Accept parameters
+ * update cookie-signature
+
+3.1.1 / 2013-04-01
+==================
+
+ * add X-Forwarded-Host support to `req.host`
+ * fix relative redirects
+ * update mkdirp
+ * update buffer-crc32
+ * remove legacy app.configure() method from app template.
+
+3.1.0 / 2013-01-25
+==================
+
+ * add support for leading "." in "view engine" setting
+ * add array support to `res.set()`
+ * add node 0.8.x to travis.yml
+ * add "subdomain offset" setting for tweaking `req.subdomains`
+ * add `res.location(url)` implementing `res.redirect()`-like setting of Location
+ * use app.get() for x-powered-by setting for inheritance
+ * fix colons in passwords for `req.auth`
+
+3.0.6 / 2013-01-04
+==================
+
+ * add http verb methods to Router
+ * update connect
+ * fix mangling of the `res.cookie()` options object
+ * fix jsonp whitespace escape. Closes #1132
+
+3.0.5 / 2012-12-19
+==================
+
+ * add throwing when a non-function is passed to a route
+ * fix: explicitly remove Transfer-Encoding header from 204 and 304 responses
+ * revert "add 'etag' option"
+
+3.0.4 / 2012-12-05
+==================
+
+ * add 'etag' option to disable `res.send()` Etags
+ * add escaping of urls in text/plain in `res.redirect()`
+ for old browsers interpreting as html
+ * change crc32 module for a more liberal license
+ * update connect
+
+3.0.3 / 2012-11-13
+==================
+
+ * update connect
+ * update cookie module
+ * fix cookie max-age
+
+3.0.2 / 2012-11-08
+==================
+
+ * add OPTIONS to cors example. Closes #1398
+ * fix route chaining regression. Closes #1397
+
+3.0.1 / 2012-11-01
+==================
+
+ * update connect
+
+3.0.0 / 2012-10-23
+==================
+
+ * add `make clean`
+ * add "Basic" check to req.auth
+ * add `req.auth` test coverage
+ * add cb && cb(payload) to `res.jsonp()`. Closes #1374
+ * add backwards compat for `res.redirect()` status. Closes #1336
+ * add support for `res.json()` to retain previously defined Content-Types. Closes #1349
+ * update connect
+ * change `res.redirect()` to utilize a pathname-relative Location again. Closes #1382
+ * remove non-primitive string support for `res.send()`
+ * fix view-locals example. Closes #1370
+ * fix route-separation example
+
+3.0.0rc5 / 2012-09-18
+==================
+
+ * update connect
+ * add redis search example
+ * add static-files example
+ * add "x-powered-by" setting (`app.disable('x-powered-by')`)
+ * add "application/octet-stream" redirect Accept test case. Closes #1317
+
+3.0.0rc4 / 2012-08-30
+==================
+
+ * add `res.jsonp()`. Closes #1307
+ * add "verbose errors" option to error-pages example
+ * add another route example to express(1) so people are not so confused
+ * add redis online user activity tracking example
+ * update connect dep
+ * fix etag quoting. Closes #1310
+ * fix error-pages 404 status
+ * fix jsonp callback char restrictions
+ * remove old OPTIONS default response
+
+3.0.0rc3 / 2012-08-13
+==================
+
+ * update connect dep
+ * fix signed cookies to work with `connect.cookieParser()` ("s:" prefix was missing) [tnydwrds]
+ * fix `res.render()` clobbering of "locals"
+
+3.0.0rc2 / 2012-08-03
+==================
+
+ * add CORS example
+ * update connect dep
+ * deprecate `.createServer()` & remove old stale examples
+ * fix: escape `res.redirect()` link
+ * fix vhost example
+
+3.0.0rc1 / 2012-07-24
+==================
+
+ * add more examples to view-locals
+ * add scheme-relative redirects (`res.redirect("//foo.com")`) support
+ * update cookie dep
+ * update connect dep
+ * update send dep
+ * fix `express(1)` -h flag, use -H for hogan. Closes #1245
+ * fix `res.sendfile()` socket error handling regression
+
+3.0.0beta7 / 2012-07-16
+==================
+
+ * update connect dep for `send()` root normalization regression
+
+3.0.0beta6 / 2012-07-13
+==================
+
+ * add `err.view` property for view errors. Closes #1226
+ * add "jsonp callback name" setting
+ * add support for "/foo/:bar*" non-greedy matches
+ * change `res.sendfile()` to use `send()` module
+ * change `res.send` to use "response-send" module
+ * remove `app.locals.use` and `res.locals.use`, use regular middleware
+
+3.0.0beta5 / 2012-07-03
+==================
+
+ * add "make check" support
+ * add route-map example
+ * add `res.json(obj, status)` support back for BC
+ * add "methods" dep, remove internal methods module
+ * update connect dep
+ * update auth example to utilize cores pbkdf2
+ * updated tests to use "supertest"
+
+3.0.0beta4 / 2012-06-25
+==================
+
+ * Added `req.auth`
+ * Added `req.range(size)`
+ * Added `res.links(obj)`
+ * Added `res.send(body, status)` support back for backwards compat
+ * Added `.default()` support to `res.format()`
+ * Added 2xx / 304 check to `req.fresh`
+ * Revert "Added + support to the router"
+ * Fixed `res.send()` freshness check, respect res.statusCode
+
+3.0.0beta3 / 2012-06-15
+==================
+
+ * Added hogan `--hjs` to express(1) [nullfirm]
+ * Added another example to content-negotiation
+ * Added `fresh` dep
+ * Changed: `res.send()` always checks freshness
+ * Fixed: expose connects mime module. Closes #1165
+
+3.0.0beta2 / 2012-06-06
+==================
+
+ * Added `+` support to the router
+ * Added `req.host`
+ * Changed `req.param()` to check route first
+ * Update connect dep
+
+3.0.0beta1 / 2012-06-01
+==================
+
+ * Added `res.format()` callback to override default 406 behaviour
+ * Fixed `res.redirect()` 406. Closes #1154
+
+3.0.0alpha5 / 2012-05-30
+==================
+
+ * Added `req.ip`
+ * Added `{ signed: true }` option to `res.cookie()`
+ * Removed `res.signedCookie()`
+ * Changed: dont reverse `req.ips`
+ * Fixed "trust proxy" setting check for `req.ips`
+
+3.0.0alpha4 / 2012-05-09
+==================
+
+ * Added: allow `[]` in jsonp callback. Closes #1128
+ * Added `PORT` env var support in generated template. Closes #1118 [benatkin]
+ * Updated: connect 2.2.2
+
+3.0.0alpha3 / 2012-05-04
+==================
+
+ * Added public `app.routes`. Closes #887
+ * Added _view-locals_ example
+ * Added _mvc_ example
+ * Added `res.locals.use()`. Closes #1120
+ * Added conditional-GET support to `res.send()`
+ * Added: coerce `res.set()` values to strings
+ * Changed: moved `static()` in generated apps below router
+ * Changed: `res.send()` only set ETag when not previously set
+ * Changed connect 2.2.1 dep
+ * Changed: `make test` now runs unit / acceptance tests
+ * Fixed req/res proto inheritance
+
+3.0.0alpha2 / 2012-04-26
+==================
+
+ * Added `make benchmark` back
+ * Added `res.send()` support for `String` objects
+ * Added client-side data exposing example
+ * Added `res.header()` and `req.header()` aliases for BC
+ * Added `express.createServer()` for BC
+ * Perf: memoize parsed urls
+ * Perf: connect 2.2.0 dep
+ * Changed: make `expressInit()` middleware self-aware
+ * Fixed: use app.get() for all core settings
+ * Fixed redis session example
+ * Fixed session example. Closes #1105
+ * Fixed generated express dep. Closes #1078
+
+3.0.0alpha1 / 2012-04-15
+==================
+
+ * Added `app.locals.use(callback)`
+ * Added `app.locals` object
+ * Added `app.locals(obj)`
+ * Added `res.locals` object
+ * Added `res.locals(obj)`
+ * Added `res.format()` for content-negotiation
+ * Added `app.engine()`
+ * Added `res.cookie()` JSON cookie support
+ * Added "trust proxy" setting
+ * Added `req.subdomains`
+ * Added `req.protocol`
+ * Added `req.secure`
+ * Added `req.path`
+ * Added `req.ips`
+ * Added `req.fresh`
+ * Added `req.stale`
+ * Added comma-delimited / array support for `req.accepts()`
+ * Added debug instrumentation
+ * Added `res.set(obj)`
+ * Added `res.set(field, value)`
+ * Added `res.get(field)`
+ * Added `app.get(setting)`. Closes #842
+ * Added `req.acceptsLanguage()`
+ * Added `req.acceptsCharset()`
+ * Added `req.accepted`
+ * Added `req.acceptedLanguages`
+ * Added `req.acceptedCharsets`
+ * Added "json replacer" setting
+ * Added "json spaces" setting
+ * Added X-Forwarded-Proto support to `res.redirect()`. Closes #92
+ * Added `--less` support to express(1)
+ * Added `express.response` prototype
+ * Added `express.request` prototype
+ * Added `express.application` prototype
+ * Added `app.path()`
+ * Added `app.render()`
+ * Added `res.type()` to replace `res.contentType()`
+ * Changed: `res.redirect()` to add relative support
+ * Changed: enable "jsonp callback" by default
+ * Changed: renamed "case sensitive routes" to "case sensitive routing"
+ * Rewrite of all tests with mocha
+ * Removed "root" setting
+ * Removed `res.redirect('home')` support
+ * Removed `req.notify()`
+ * Removed `app.register()`
+ * Removed `app.redirect()`
+ * Removed `app.is()`
+ * Removed `app.helpers()`
+ * Removed `app.dynamicHelpers()`
+ * Fixed `res.sendfile()` with non-GET. Closes #723
+ * Fixed express(1) public dir for windows. Closes #866
+
+2.5.9/ 2012-04-02
+==================
+
+ * Added support for PURGE request method [pbuyle]
+ * Fixed `express(1)` generated app `app.address()` before `listening` [mmalecki]
+
+2.5.8 / 2012-02-08
+==================
+
+ * Update mkdirp dep. Closes #991
+
+2.5.7 / 2012-02-06
+==================
+
+ * Fixed `app.all` duplicate DELETE requests [mscdex]
+
+2.5.6 / 2012-01-13
+==================
+
+ * Updated hamljs dev dep. Closes #953
+
+2.5.5 / 2012-01-08
+==================
+
+ * Fixed: set `filename` on cached templates [matthewleon]
+
+2.5.4 / 2012-01-02
+==================
+
+ * Fixed `express(1)` eol on 0.4.x. Closes #947
+
+2.5.3 / 2011-12-30
+==================
+
+ * Fixed `req.is()` when a charset is present
+
+2.5.2 / 2011-12-10
+==================
+
+ * Fixed: express(1) LF -> CRLF for windows
+
+2.5.1 / 2011-11-17
+==================
+
+ * Changed: updated connect to 1.8.x
+ * Removed sass.js support from express(1)
+
+2.5.0 / 2011-10-24
+==================
+
+ * Added ./routes dir for generated app by default
+ * Added npm install reminder to express(1) app gen
+ * Added 0.5.x support
+ * Removed `make test-cov` since it wont work with node 0.5.x
+ * Fixed express(1) public dir for windows. Closes #866
+
+2.4.7 / 2011-10-05
+==================
+
+ * Added mkdirp to express(1). Closes #795
+ * Added simple _json-config_ example
+ * Added shorthand for the parsed request's pathname via `req.path`
+ * Changed connect dep to 1.7.x to fix npm issue...
+ * Fixed `res.redirect()` __HEAD__ support. [reported by xerox]
+ * Fixed `req.flash()`, only escape args
+ * Fixed absolute path checking on windows. Closes #829 [reported by andrewpmckenzie]
+
+2.4.6 / 2011-08-22
+==================
+
+ * Fixed multiple param callback regression. Closes #824 [reported by TroyGoode]
+
+2.4.5 / 2011-08-19
+==================
+
+ * Added support for routes to handle errors. Closes #809
+ * Added `app.routes.all()`. Closes #803
+ * Added "basepath" setting to work in conjunction with reverse proxies etc.
+ * Refactored `Route` to use a single array of callbacks
+ * Added support for multiple callbacks for `app.param()`. Closes #801
+Closes #805
+ * Changed: removed .call(self) for route callbacks
+ * Dependency: `qs >= 0.3.1`
+ * Fixed `res.redirect()` on windows due to `join()` usage. Closes #808
+
+2.4.4 / 2011-08-05
+==================
+
+ * Fixed `res.header()` intention of a set, even when `undefined`
+ * Fixed `*`, value no longer required
+ * Fixed `res.send(204)` support. Closes #771
+
+2.4.3 / 2011-07-14
+==================
+
+ * Added docs for `status` option special-case. Closes #739
+ * Fixed `options.filename`, exposing the view path to template engines
+
+2.4.2. / 2011-07-06
+==================
+
+ * Revert "removed jsonp stripping" for XSS
+
+2.4.1 / 2011-07-06
+==================
+
+ * Added `res.json()` JSONP support. Closes #737
+ * Added _extending-templates_ example. Closes #730
+ * Added "strict routing" setting for trailing slashes
+ * Added support for multiple envs in `app.configure()` calls. Closes #735
+ * Changed: `res.send()` using `res.json()`
+ * Changed: when cookie `path === null` don't default it
+ * Changed; default cookie path to "home" setting. Closes #731
+ * Removed _pids/logs_ creation from express(1)
+
+2.4.0 / 2011-06-28
+==================
+
+ * Added chainable `res.status(code)`
+ * Added `res.json()`, an explicit version of `res.send(obj)`
+ * Added simple web-service example
+
+2.3.12 / 2011-06-22
+==================
+
+ * \#express is now on freenode! come join!
+ * Added `req.get(field, param)`
+ * Added links to Japanese documentation, thanks @hideyukisaito!
+ * Added; the `express(1)` generated app outputs the env
+ * Added `content-negotiation` example
+ * Dependency: connect >= 1.5.1 < 2.0.0
+ * Fixed view layout bug. Closes #720
+ * Fixed; ignore body on 304. Closes #701
+
+2.3.11 / 2011-06-04
+==================
+
+ * Added `npm test`
+ * Removed generation of dummy test file from `express(1)`
+ * Fixed; `express(1)` adds express as a dep
+ * Fixed; prune on `prepublish`
+
+2.3.10 / 2011-05-27
+==================
+
+ * Added `req.route`, exposing the current route
+ * Added _package.json_ generation support to `express(1)`
+ * Fixed call to `app.param()` function for optional params. Closes #682
+
+2.3.9 / 2011-05-25
+==================
+
+ * Fixed bug-ish with `../' in `res.partial()` calls
+
+2.3.8 / 2011-05-24
+==================
+
+ * Fixed `app.options()`
+
+2.3.7 / 2011-05-23
+==================
+
+ * Added route `Collection`, ex: `app.get('/user/:id').remove();`
+ * Added support for `app.param(fn)` to define param logic
+ * Removed `app.param()` support for callback with return value
+ * Removed module.parent check from express(1) generated app. Closes #670
+ * Refactored router. Closes #639
+
+2.3.6 / 2011-05-20
+==================
+
+ * Changed; using devDependencies instead of git submodules
+ * Fixed redis session example
+ * Fixed markdown example
+ * Fixed view caching, should not be enabled in development
+
+2.3.5 / 2011-05-20
+==================
+
+ * Added export `.view` as alias for `.View`
+
+2.3.4 / 2011-05-08
+==================
+
+ * Added `./examples/say`
+ * Fixed `res.sendfile()` bug preventing the transfer of files with spaces
+
+2.3.3 / 2011-05-03
+==================
+
+ * Added "case sensitive routes" option.
+ * Changed; split methods supported per rfc [slaskis]
+ * Fixed route-specific middleware when using the same callback function several times
+
+2.3.2 / 2011-04-27
+==================
+
+ * Fixed view hints
+
+2.3.1 / 2011-04-26
+==================
+
+ * Added `app.match()` as `app.match.all()`
+ * Added `app.lookup()` as `app.lookup.all()`
+ * Added `app.remove()` for `app.remove.all()`
+ * Added `app.remove.VERB()`
+ * Fixed template caching collision issue. Closes #644
+ * Moved router over from connect and started refactor
+
+2.3.0 / 2011-04-25
+==================
+
+ * Added options support to `res.clearCookie()`
+ * Added `res.helpers()` as alias of `res.locals()`
+ * Added; json defaults to UTF-8 with `res.send()`. Closes #632. [Daniel * Dependency `connect >= 1.4.0`
+ * Changed; auto set Content-Type in res.attachement [Aaron Heckmann]
+ * Renamed "cache views" to "view cache". Closes #628
+ * Fixed caching of views when using several apps. Closes #637
+ * Fixed gotcha invoking `app.param()` callbacks once per route middleware.
+Closes #638
+ * Fixed partial lookup precedence. Closes #631
+Shaw]
+
+2.2.2 / 2011-04-12
+==================
+
+ * Added second callback support for `res.download()` connection errors
+ * Fixed `filename` option passing to template engine
+
+2.2.1 / 2011-04-04
+==================
+
+ * Added `layout(path)` helper to change the layout within a view. Closes #610
+ * Fixed `partial()` collection object support.
+ Previously only anything with `.length` would work.
+ When `.length` is present one must still be aware of holes,
+ however now `{ collection: {foo: 'bar'}}` is valid, exposes
+ `keyInCollection` and `keysInCollection`.
+
+ * Performance improved with better view caching
+ * Removed `request` and `response` locals
+ * Changed; errorHandler page title is now `Express` instead of `Connect`
+
+2.2.0 / 2011-03-30
+==================
+
+ * Added `app.lookup.VERB()`, ex `app.lookup.put('/user/:id')`. Closes #606
+ * Added `app.match.VERB()`, ex `app.match.put('/user/12')`. Closes #606
+ * Added `app.VERB(path)` as alias of `app.lookup.VERB()`.
+ * Dependency `connect >= 1.2.0`
+
+2.1.1 / 2011-03-29
+==================
+
+ * Added; expose `err.view` object when failing to locate a view
+ * Fixed `res.partial()` call `next(err)` when no callback is given [reported by aheckmann]
+ * Fixed; `res.send(undefined)` responds with 204 [aheckmann]
+
+2.1.0 / 2011-03-24
+==================
+
+ * Added `/_?` partial lookup support. Closes #447
+ * Added `request`, `response`, and `app` local variables
+ * Added `settings` local variable, containing the app's settings
+ * Added `req.flash()` exception if `req.session` is not available
+ * Added `res.send(bool)` support (json response)
+ * Fixed stylus example for latest version
+ * Fixed; wrap try/catch around `res.render()`
+
+2.0.0 / 2011-03-17
+==================
+
+ * Fixed up index view path alternative.
+ * Changed; `res.locals()` without object returns the locals
+
+2.0.0rc3 / 2011-03-17
+==================
+
+ * Added `res.locals(obj)` to compliment `res.local(key, val)`
+ * Added `res.partial()` callback support
+ * Fixed recursive error reporting issue in `res.render()`
+
+2.0.0rc2 / 2011-03-17
+==================
+
+ * Changed; `partial()` "locals" are now optional
+ * Fixed `SlowBuffer` support. Closes #584 [reported by tyrda01]
+ * Fixed .filename view engine option [reported by drudge]
+ * Fixed blog example
+ * Fixed `{req,res}.app` reference when mounting [Ben Weaver]
+
+2.0.0rc / 2011-03-14
+==================
+
+ * Fixed; expose `HTTPSServer` constructor
+ * Fixed express(1) default test charset. Closes #579 [reported by secoif]
+ * Fixed; default charset to utf-8 instead of utf8 for lame IE [reported by NickP]
+
+2.0.0beta3 / 2011-03-09
+==================
+
+ * Added support for `res.contentType()` literal
+ The original `res.contentType('.json')`,
+ `res.contentType('application/json')`, and `res.contentType('json')`
+ will work now.
+ * Added `res.render()` status option support back
+ * Added charset option for `res.render()`
+ * Added `.charset` support (via connect 1.0.4)
+ * Added view resolution hints when in development and a lookup fails
+ * Added layout lookup support relative to the page view.
+ For example while rendering `./views/user/index.jade` if you create
+ `./views/user/layout.jade` it will be used in favour of the root layout.
+ * Fixed `res.redirect()`. RFC states absolute url [reported by unlink]
+ * Fixed; default `res.send()` string charset to utf8
+ * Removed `Partial` constructor (not currently used)
+
+2.0.0beta2 / 2011-03-07
+==================
+
+ * Added res.render() `.locals` support back to aid in migration process
+ * Fixed flash example
+
+2.0.0beta / 2011-03-03
+==================
+
+ * Added HTTPS support
+ * Added `res.cookie()` maxAge support
+ * Added `req.header()` _Referrer_ / _Referer_ special-case, either works
+ * Added mount support for `res.redirect()`, now respects the mount-point
+ * Added `union()` util, taking place of `merge(clone())` combo
+ * Added stylus support to express(1) generated app
+ * Added secret to session middleware used in examples and generated app
+ * Added `res.local(name, val)` for progressive view locals
+ * Added default param support to `req.param(name, default)`
+ * Added `app.disabled()` and `app.enabled()`
+ * Added `app.register()` support for omitting leading ".", either works
+ * Added `res.partial()`, using the same interface as `partial()` within a view. Closes #539
+ * Added `app.param()` to map route params to async/sync logic
+ * Added; aliased `app.helpers()` as `app.locals()`. Closes #481
+ * Added extname with no leading "." support to `res.contentType()`
+ * Added `cache views` setting, defaulting to enabled in "production" env
+ * Added index file partial resolution, eg: partial('user') may try _views/user/index.jade_.
+ * Added `req.accepts()` support for extensions
+ * Changed; `res.download()` and `res.sendfile()` now utilize Connect's
+ static file server `connect.static.send()`.
+ * Changed; replaced `connect.utils.mime()` with npm _mime_ module
+ * Changed; allow `req.query` to be pre-defined (via middleware or other parent
+ * Changed view partial resolution, now relative to parent view
+ * Changed view engine signature. no longer `engine.render(str, options, callback)`, now `engine.compile(str, options) -> Function`, the returned function accepts `fn(locals)`.
+ * Fixed `req.param()` bug returning Array.prototype methods. Closes #552
+ * Fixed; using `Stream#pipe()` instead of `sys.pump()` in `res.sendfile()`
+ * Fixed; using _qs_ module instead of _querystring_
+ * Fixed; strip unsafe chars from jsonp callbacks
+ * Removed "stream threshold" setting
+
+1.0.8 / 2011-03-01
+==================
+
+ * Allow `req.query` to be pre-defined (via middleware or other parent app)
+ * "connect": ">= 0.5.0 < 1.0.0". Closes #547
+ * Removed the long deprecated __EXPRESS_ENV__ support
+
+1.0.7 / 2011-02-07
+==================
+
+ * Fixed `render()` setting inheritance.
+ Mounted apps would not inherit "view engine"
+
+1.0.6 / 2011-02-07
+==================
+
+ * Fixed `view engine` setting bug when period is in dirname
+
+1.0.5 / 2011-02-05
+==================
+
+ * Added secret to generated app `session()` call
+
+1.0.4 / 2011-02-05
+==================
+
+ * Added `qs` dependency to _package.json_
+ * Fixed namespaced `require()`s for latest connect support
+
+1.0.3 / 2011-01-13
+==================
+
+ * Remove unsafe characters from JSONP callback names [Ryan Grove]
+
+1.0.2 / 2011-01-10
+==================
+
+ * Removed nested require, using `connect.router`
+
+1.0.1 / 2010-12-29
+==================
+
+ * Fixed for middleware stacked via `createServer()`
+ previously the `foo` middleware passed to `createServer(foo)`
+ would not have access to Express methods such as `res.send()`
+ or props like `req.query` etc.
+
+1.0.0 / 2010-11-16
+==================
+
+ * Added; deduce partial object names from the last segment.
+ For example by default `partial('forum/post', postObject)` will
+ give you the _post_ object, providing a meaningful default.
+ * Added http status code string representation to `res.redirect()` body
+ * Added; `res.redirect()` supporting _text/plain_ and _text/html_ via __Accept__.
+ * Added `req.is()` to aid in content negotiation
+ * Added partial local inheritance [suggested by masylum]. Closes #102
+ providing access to parent template locals.
+ * Added _-s, --session[s]_ flag to express(1) to add session related middleware
+ * Added _--template_ flag to express(1) to specify the
+ template engine to use.
+ * Added _--css_ flag to express(1) to specify the
+ stylesheet engine to use (or just plain css by default).
+ * Added `app.all()` support [thanks aheckmann]
+ * Added partial direct object support.
+ You may now `partial('user', user)` providing the "user" local,
+ vs previously `partial('user', { object: user })`.
+ * Added _route-separation_ example since many people question ways
+ to do this with CommonJS modules. Also view the _blog_ example for
+ an alternative.
+ * Performance; caching view path derived partial object names
+ * Fixed partial local inheritance precedence. [reported by Nick Poulden] Closes #454
+ * Fixed jsonp support; _text/javascript_ as per mailinglist discussion
+
+1.0.0rc4 / 2010-10-14
+==================
+
+ * Added _NODE_ENV_ support, _EXPRESS_ENV_ is deprecated and will be removed in 1.0.0
+ * Added route-middleware support (very helpful, see the [docs](http://expressjs.com/guide.html#Route-Middleware))
+ * Added _jsonp callback_ setting to enable/disable jsonp autowrapping [Dav Glass]
+ * Added callback query check on response.send to autowrap JSON objects for simple webservice implementations [Dav Glass]
+ * Added `partial()` support for array-like collections. Closes #434
+ * Added support for swappable querystring parsers
+ * Added session usage docs. Closes #443
+ * Added dynamic helper caching. Closes #439 [suggested by maritz]
+ * Added authentication example
+ * Added basic Range support to `res.sendfile()` (and `res.download()` etc)
+ * Changed; `express(1)` generated app using 2 spaces instead of 4
+ * Default env to "development" again [aheckmann]
+ * Removed _context_ option is no more, use "scope"
+ * Fixed; exposing _./support_ libs to examples so they can run without installs
+ * Fixed mvc example
+
+1.0.0rc3 / 2010-09-20
+==================
+
+ * Added confirmation for `express(1)` app generation. Closes #391
+ * Added extending of flash formatters via `app.flashFormatters`
+ * Added flash formatter support. Closes #411
+ * Added streaming support to `res.sendfile()` using `sys.pump()` when >= "stream threshold"
+ * Added _stream threshold_ setting for `res.sendfile()`
+ * Added `res.send()` __HEAD__ support
+ * Added `res.clearCookie()`
+ * Added `res.cookie()`
+ * Added `res.render()` headers option
+ * Added `res.redirect()` response bodies
+ * Added `res.render()` status option support. Closes #425 [thanks aheckmann]
+ * Fixed `res.sendfile()` responding with 403 on malicious path
+ * Fixed `res.download()` bug; when an error occurs remove _Content-Disposition_
+ * Fixed; mounted apps settings now inherit from parent app [aheckmann]
+ * Fixed; stripping Content-Length / Content-Type when 204
+ * Fixed `res.send()` 204. Closes #419
+ * Fixed multiple _Set-Cookie_ headers via `res.header()`. Closes #402
+ * Fixed bug messing with error handlers when `listenFD()` is called instead of `listen()`. [thanks guillermo]
+
+
+1.0.0rc2 / 2010-08-17
+==================
+
+ * Added `app.register()` for template engine mapping. Closes #390
+ * Added `res.render()` callback support as second argument (no options)
+ * Added callback support to `res.download()`
+ * Added callback support for `res.sendfile()`
+ * Added support for middleware access via `express.middlewareName()` vs `connect.middlewareName()`
+ * Added "partials" setting to docs
+ * Added default expresso tests to `express(1)` generated app. Closes #384
+ * Fixed `res.sendfile()` error handling, defer via `next()`
+ * Fixed `res.render()` callback when a layout is used [thanks guillermo]
+ * Fixed; `make install` creating ~/.node_libraries when not present
+ * Fixed issue preventing error handlers from being defined anywhere. Closes #387
+
+1.0.0rc / 2010-07-28
+==================
+
+ * Added mounted hook. Closes #369
+ * Added connect dependency to _package.json_
+
+ * Removed "reload views" setting and support code
+ development env never caches, production always caches.
+
+ * Removed _param_ in route callbacks, signature is now
+ simply (req, res, next), previously (req, res, params, next).
+ Use _req.params_ for path captures, _req.query_ for GET params.
+
+ * Fixed "home" setting
+ * Fixed middleware/router precedence issue. Closes #366
+ * Fixed; _configure()_ callbacks called immediately. Closes #368
+
+1.0.0beta2 / 2010-07-23
+==================
+
+ * Added more examples
+ * Added; exporting `Server` constructor
+ * Added `Server#helpers()` for view locals
+ * Added `Server#dynamicHelpers()` for dynamic view locals. Closes #349
+ * Added support for absolute view paths
+ * Added; _home_ setting defaults to `Server#route` for mounted apps. Closes #363
+ * Added Guillermo Rauch to the contributor list
+ * Added support for "as" for non-collection partials. Closes #341
+ * Fixed _install.sh_, ensuring _~/.node_libraries_ exists. Closes #362 [thanks jf]
+ * Fixed `res.render()` exceptions, now passed to `next()` when no callback is given [thanks guillermo]
+ * Fixed instanceof `Array` checks, now `Array.isArray()`
+ * Fixed express(1) expansion of public dirs. Closes #348
+ * Fixed middleware precedence. Closes #345
+ * Fixed view watcher, now async [thanks aheckmann]
+
+1.0.0beta / 2010-07-15
+==================
+
+ * Re-write
+ - much faster
+ - much lighter
+ - Check [ExpressJS.com](http://expressjs.com) for migration guide and updated docs
+
+0.14.0 / 2010-06-15
+==================
+
+ * Utilize relative requires
+ * Added Static bufferSize option [aheckmann]
+ * Fixed caching of view and partial subdirectories [aheckmann]
+ * Fixed mime.type() comments now that ".ext" is not supported
+ * Updated haml submodule
+ * Updated class submodule
+ * Removed bin/express
+
+0.13.0 / 2010-06-01
+==================
+
+ * Added node v0.1.97 compatibility
+ * Added support for deleting cookies via Request#cookie('key', null)
+ * Updated haml submodule
+ * Fixed not-found page, now using using charset utf-8
+ * Fixed show-exceptions page, now using using charset utf-8
+ * Fixed view support due to fs.readFile Buffers
+ * Changed; mime.type() no longer accepts ".type" due to node extname() changes
+
+0.12.0 / 2010-05-22
+==================
+
+ * Added node v0.1.96 compatibility
+ * Added view `helpers` export which act as additional local variables
+ * Updated haml submodule
+ * Changed ETag; removed inode, modified time only
+ * Fixed LF to CRLF for setting multiple cookies
+ * Fixed cookie complation; values are now urlencoded
+ * Fixed cookies parsing; accepts quoted values and url escaped cookies
+
+0.11.0 / 2010-05-06
+==================
+
+ * Added support for layouts using different engines
+ - this.render('page.html.haml', { layout: 'super-cool-layout.html.ejs' })
+ - this.render('page.html.haml', { layout: 'foo' }) // assumes 'foo.html.haml'
+ - this.render('page.html.haml', { layout: false }) // no layout
+ * Updated ext submodule
+ * Updated haml submodule
+ * Fixed EJS partial support by passing along the context. Issue #307
+
+0.10.1 / 2010-05-03
+==================
+
+ * Fixed binary uploads.
+
+0.10.0 / 2010-04-30
+==================
+
+ * Added charset support via Request#charset (automatically assigned to 'UTF-8' when respond()'s
+ encoding is set to 'utf8' or 'utf-8'.
+ * Added "encoding" option to Request#render(). Closes #299
+ * Added "dump exceptions" setting, which is enabled by default.
+ * Added simple ejs template engine support
+ * Added error response support for text/plain, application/json. Closes #297
+ * Added callback function param to Request#error()
+ * Added Request#sendHead()
+ * Added Request#stream()
+ * Added support for Request#respond(304, null) for empty response bodies
+ * Added ETag support to Request#sendfile()
+ * Added options to Request#sendfile(), passed to fs.createReadStream()
+ * Added filename arg to Request#download()
+ * Performance enhanced due to pre-reversing plugins so that plugins.reverse() is not called on each request
+ * Performance enhanced by preventing several calls to toLowerCase() in Router#match()
+ * Changed; Request#sendfile() now streams
+ * Changed; Renamed Request#halt() to Request#respond(). Closes #289
+ * Changed; Using sys.inspect() instead of JSON.encode() for error output
+ * Changed; run() returns the http.Server instance. Closes #298
+ * Changed; Defaulting Server#host to null (INADDR_ANY)
+ * Changed; Logger "common" format scale of 0.4f
+ * Removed Logger "request" format
+ * Fixed; Catching ENOENT in view caching, preventing error when "views/partials" is not found
+ * Fixed several issues with http client
+ * Fixed Logger Content-Length output
+ * Fixed bug preventing Opera from retaining the generated session id. Closes #292
+
+0.9.0 / 2010-04-14
+==================
+
+ * Added DSL level error() route support
+ * Added DSL level notFound() route support
+ * Added Request#error()
+ * Added Request#notFound()
+ * Added Request#render() callback function. Closes #258
+ * Added "max upload size" setting
+ * Added "magic" variables to collection partials (\_\_index\_\_, \_\_length\_\_, \_\_isFirst\_\_, \_\_isLast\_\_). Closes #254
+ * Added [haml.js](http://github.com/visionmedia/haml.js) submodule; removed haml-js
+ * Added callback function support to Request#halt() as 3rd/4th arg
+ * Added preprocessing of route param wildcards using param(). Closes #251
+ * Added view partial support (with collections etc)
+ * Fixed bug preventing falsey params (such as ?page=0). Closes #286
+ * Fixed setting of multiple cookies. Closes #199
+ * Changed; view naming convention is now NAME.TYPE.ENGINE (for example page.html.haml)
+ * Changed; session cookie is now httpOnly
+ * Changed; Request is no longer global
+ * Changed; Event is no longer global
+ * Changed; "sys" module is no longer global
+ * Changed; moved Request#download to Static plugin where it belongs
+ * Changed; Request instance created before body parsing. Closes #262
+ * Changed; Pre-caching views in memory when "cache view contents" is enabled. Closes #253
+ * Changed; Pre-caching view partials in memory when "cache view partials" is enabled
+ * Updated support to node --version 0.1.90
+ * Updated dependencies
+ * Removed set("session cookie") in favour of use(Session, { cookie: { ... }})
+ * Removed utils.mixin(); use Object#mergeDeep()
+
+0.8.0 / 2010-03-19
+==================
+
+ * Added coffeescript example app. Closes #242
+ * Changed; cache api now async friendly. Closes #240
+ * Removed deprecated 'express/static' support. Use 'express/plugins/static'
+
+0.7.6 / 2010-03-19
+==================
+
+ * Added Request#isXHR. Closes #229
+ * Added `make install` (for the executable)
+ * Added `express` executable for setting up simple app templates
+ * Added "GET /public/*" to Static plugin, defaulting to /public
+ * Added Static plugin
+ * Fixed; Request#render() only calls cache.get() once
+ * Fixed; Namespacing View caches with "view:"
+ * Fixed; Namespacing Static caches with "static:"
+ * Fixed; Both example apps now use the Static plugin
+ * Fixed set("views"). Closes #239
+ * Fixed missing space for combined log format
+ * Deprecated Request#sendfile() and 'express/static'
+ * Removed Server#running
+
+0.7.5 / 2010-03-16
+==================
+
+ * Added Request#flash() support without args, now returns all flashes
+ * Updated ext submodule
+
+0.7.4 / 2010-03-16
+==================
+
+ * Fixed session reaper
+ * Changed; class.js replacing js-oo Class implementation (quite a bit faster, no browser cruft)
+
+0.7.3 / 2010-03-16
+==================
+
+ * Added package.json
+ * Fixed requiring of haml / sass due to kiwi removal
+
+0.7.2 / 2010-03-16
+==================
+
+ * Fixed GIT submodules (HAH!)
+
+0.7.1 / 2010-03-16
+==================
+
+ * Changed; Express now using submodules again until a PM is adopted
+ * Changed; chat example using millisecond conversions from ext
+
+0.7.0 / 2010-03-15
+==================
+
+ * Added Request#pass() support (finds the next matching route, or the given path)
+ * Added Logger plugin (default "common" format replaces CommonLogger)
+ * Removed Profiler plugin
+ * Removed CommonLogger plugin
+
+0.6.0 / 2010-03-11
+==================
+
+ * Added seed.yml for kiwi package management support
+ * Added HTTP client query string support when method is GET. Closes #205
+
+ * Added support for arbitrary view engines.
+ For example "foo.engine.html" will now require('engine'),
+ the exports from this module are cached after the first require().
+
+ * Added async plugin support
+
+ * Removed usage of RESTful route funcs as http client
+ get() etc, use http.get() and friends
+
+ * Removed custom exceptions
+
+0.5.0 / 2010-03-10
+==================
+
+ * Added ext dependency (library of js extensions)
+ * Removed extname() / basename() utils. Use path module
+ * Removed toArray() util. Use arguments.values
+ * Removed escapeRegexp() util. Use RegExp.escape()
+ * Removed process.mixin() dependency. Use utils.mixin()
+ * Removed Collection
+ * Removed ElementCollection
+ * Shameless self promotion of ebook "Advanced JavaScript" (http://dev-mag.com) ;)
+
+0.4.0 / 2010-02-11
+==================
+
+ * Added flash() example to sample upload app
+ * Added high level restful http client module (express/http)
+ * Changed; RESTful route functions double as HTTP clients. Closes #69
+ * Changed; throwing error when routes are added at runtime
+ * Changed; defaulting render() context to the current Request. Closes #197
+ * Updated haml submodule
+
+0.3.0 / 2010-02-11
+==================
+
+ * Updated haml / sass submodules. Closes #200
+ * Added flash message support. Closes #64
+ * Added accepts() now allows multiple args. fixes #117
+ * Added support for plugins to halt. Closes #189
+ * Added alternate layout support. Closes #119
+ * Removed Route#run(). Closes #188
+ * Fixed broken specs due to use(Cookie) missing
+
+0.2.1 / 2010-02-05
+==================
+
+ * Added "plot" format option for Profiler (for gnuplot processing)
+ * Added request number to Profiler plugin
+ * Fixed binary encoding for multi-part file uploads, was previously defaulting to UTF8
+ * Fixed issue with routes not firing when not files are present. Closes #184
+ * Fixed process.Promise -> events.Promise
+
+0.2.0 / 2010-02-03
+==================
+
+ * Added parseParam() support for name[] etc. (allows for file inputs with "multiple" attr) Closes #180
+ * Added Both Cache and Session option "reapInterval" may be "reapEvery". Closes #174
+ * Added expiration support to cache api with reaper. Closes #133
+ * Added cache Store.Memory#reap()
+ * Added Cache; cache api now uses first class Cache instances
+ * Added abstract session Store. Closes #172
+ * Changed; cache Memory.Store#get() utilizing Collection
+ * Renamed MemoryStore -> Store.Memory
+ * Fixed use() of the same plugin several time will always use latest options. Closes #176
+
+0.1.0 / 2010-02-03
+==================
+
+ * Changed; Hooks (before / after) pass request as arg as well as evaluated in their context
+ * Updated node support to 0.1.27 Closes #169
+ * Updated dirname(__filename) -> __dirname
+ * Updated libxmljs support to v0.2.0
+ * Added session support with memory store / reaping
+ * Added quick uid() helper
+ * Added multi-part upload support
+ * Added Sass.js support / submodule
+ * Added production env caching view contents and static files
+ * Added static file caching. Closes #136
+ * Added cache plugin with memory stores
+ * Added support to StaticFile so that it works with non-textual files.
+ * Removed dirname() helper
+ * Removed several globals (now their modules must be required)
+
+0.0.2 / 2010-01-10
+==================
+
+ * Added view benchmarks; currently haml vs ejs
+ * Added Request#attachment() specs. Closes #116
+ * Added use of node's parseQuery() util. Closes #123
+ * Added `make init` for submodules
+ * Updated Haml
+ * Updated sample chat app to show messages on load
+ * Updated libxmljs parseString -> parseHtmlString
+ * Fixed `make init` to work with older versions of git
+ * Fixed specs can now run independent specs for those who cant build deps. Closes #127
+ * Fixed issues introduced by the node url module changes. Closes 126.
+ * Fixed two assertions failing due to Collection#keys() returning strings
+ * Fixed faulty Collection#toArray() spec due to keys() returning strings
+ * Fixed `make test` now builds libxmljs.node before testing
+
+0.0.1 / 2010-01-03
+==================
+
+ * Initial release
diff --git a/node_modules/express/LICENSE b/node_modules/express/LICENSE
new file mode 100644
index 00000000..aa927e44
--- /dev/null
+++ b/node_modules/express/LICENSE
@@ -0,0 +1,24 @@
+(The MIT License)
+
+Copyright (c) 2009-2014 TJ Holowaychuk
+Copyright (c) 2013-2014 Roman Shtylman
+Copyright (c) 2014-2015 Douglas Christopher Wilson
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/express/Readme.md b/node_modules/express/Readme.md
new file mode 100644
index 00000000..e9bfaeba
--- /dev/null
+++ b/node_modules/express/Readme.md
@@ -0,0 +1,142 @@
+[](http://expressjs.com/)
+
+ Fast, unopinionated, minimalist web framework for [node](http://nodejs.org).
+
+ [![NPM Version][npm-image]][npm-url]
+ [![NPM Downloads][downloads-image]][downloads-url]
+ [![Linux Build][travis-image]][travis-url]
+ [![Windows Build][appveyor-image]][appveyor-url]
+ [![Test Coverage][coveralls-image]][coveralls-url]
+
+```js
+var express = require('express')
+var app = express()
+
+app.get('/', function (req, res) {
+ res.send('Hello World')
+})
+
+app.listen(3000)
+```
+
+## Installation
+
+```bash
+$ npm install express
+```
+
+## Features
+
+ * Robust routing
+ * Focus on high performance
+ * Super-high test coverage
+ * HTTP helpers (redirection, caching, etc)
+ * View system supporting 14+ template engines
+ * Content negotiation
+ * Executable for generating applications quickly
+
+## Docs & Community
+
+ * [Website and Documentation](http://expressjs.com/) - [[website repo](https://github.com/strongloop/expressjs.com)]
+ * [#express](https://webchat.freenode.net/?channels=express) on freenode IRC
+ * [Github Organization](https://github.com/expressjs) for Official Middleware & Modules
+ * Visit the [Wiki](https://github.com/expressjs/express/wiki)
+ * [Google Group](https://groups.google.com/group/express-js) for discussion
+ * [Gitter](https://gitter.im/expressjs/express) for support and discussion
+ * [Русскоязычная документация](http://jsman.ru/express/)
+
+**PROTIP** Be sure to read [Migrating from 3.x to 4.x](https://github.com/expressjs/express/wiki/Migrating-from-3.x-to-4.x) as well as [New features in 4.x](https://github.com/expressjs/express/wiki/New-features-in-4.x).
+
+###Security Issues
+
+If you discover a security vulnerability in Express, please see [Security Policies and Procedures](Security.md).
+
+## Quick Start
+
+ The quickest way to get started with express is to utilize the executable [`express(1)`](https://github.com/expressjs/generator) to generate an application as shown below:
+
+ Install the executable. The executable's major version will match Express's:
+
+```bash
+$ npm install -g express-generator@4
+```
+
+ Create the app:
+
+```bash
+$ express /tmp/foo && cd /tmp/foo
+```
+
+ Install dependencies:
+
+```bash
+$ npm install
+```
+
+ Start the server:
+
+```bash
+$ npm start
+```
+
+## Philosophy
+
+ The Express philosophy is to provide small, robust tooling for HTTP servers, making
+ it a great solution for single page applications, web sites, hybrids, or public
+ HTTP APIs.
+
+ Express does not force you to use any specific ORM or template engine. With support for over
+ 14 template engines via [Consolidate.js](https://github.com/tj/consolidate.js),
+ you can quickly craft your perfect framework.
+
+## Examples
+
+ To view the examples, clone the Express repo and install the dependencies:
+
+```bash
+$ git clone git://github.com/expressjs/express.git --depth 1
+$ cd express
+$ npm install
+```
+
+ Then run whichever example you want:
+
+```bash
+$ node examples/content-negotiation
+```
+
+## Tests
+
+ To run the test suite, first install the dependencies, then run `npm test`:
+
+```bash
+$ npm install
+$ npm test
+```
+
+## People
+
+The original author of Express is [TJ Holowaychuk](https://github.com/tj) [![TJ's Gratipay][gratipay-image-visionmedia]][gratipay-url-visionmedia]
+
+The current lead maintainer is [Douglas Christopher Wilson](https://github.com/dougwilson) [![Doug's Gratipay][gratipay-image-dougwilson]][gratipay-url-dougwilson]
+
+[List of all contributors](https://github.com/expressjs/express/graphs/contributors)
+
+## License
+
+ [MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/express.svg
+[npm-url]: https://npmjs.org/package/express
+[downloads-image]: https://img.shields.io/npm/dm/express.svg
+[downloads-url]: https://npmjs.org/package/express
+[travis-image]: https://img.shields.io/travis/expressjs/express/master.svg?label=linux
+[travis-url]: https://travis-ci.org/expressjs/express
+[appveyor-image]: https://img.shields.io/appveyor/ci/dougwilson/express/master.svg?label=windows
+[appveyor-url]: https://ci.appveyor.com/project/dougwilson/express
+[coveralls-image]: https://img.shields.io/coveralls/expressjs/express/master.svg
+[coveralls-url]: https://coveralls.io/r/expressjs/express?branch=master
+[gratipay-image-visionmedia]: https://img.shields.io/gratipay/visionmedia.svg
+[gratipay-url-visionmedia]: https://gratipay.com/visionmedia/
+[gratipay-image-dougwilson]: https://img.shields.io/gratipay/dougwilson.svg
+[gratipay-url-dougwilson]: https://gratipay.com/dougwilson/
diff --git a/node_modules/express/index.js b/node_modules/express/index.js
new file mode 100644
index 00000000..d219b0c8
--- /dev/null
+++ b/node_modules/express/index.js
@@ -0,0 +1,11 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+module.exports = require('./lib/express');
diff --git a/node_modules/express/lib/application.js b/node_modules/express/lib/application.js
new file mode 100644
index 00000000..0ee4def3
--- /dev/null
+++ b/node_modules/express/lib/application.js
@@ -0,0 +1,643 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var finalhandler = require('finalhandler');
+var Router = require('./router');
+var methods = require('methods');
+var middleware = require('./middleware/init');
+var query = require('./middleware/query');
+var debug = require('debug')('express:application');
+var View = require('./view');
+var http = require('http');
+var compileETag = require('./utils').compileETag;
+var compileQueryParser = require('./utils').compileQueryParser;
+var compileTrust = require('./utils').compileTrust;
+var deprecate = require('depd')('express');
+var flatten = require('array-flatten');
+var merge = require('utils-merge');
+var resolve = require('path').resolve;
+var slice = Array.prototype.slice;
+
+/**
+ * Application prototype.
+ */
+
+var app = exports = module.exports = {};
+
+/**
+ * Variable for trust proxy inheritance back-compat
+ * @private
+ */
+
+var trustProxyDefaultSymbol = '@@symbol:trust_proxy_default';
+
+/**
+ * Initialize the server.
+ *
+ * - setup default configuration
+ * - setup default middleware
+ * - setup route reflection methods
+ *
+ * @private
+ */
+
+app.init = function init() {
+ this.cache = {};
+ this.engines = {};
+ this.settings = {};
+
+ this.defaultConfiguration();
+};
+
+/**
+ * Initialize application configuration.
+ * @private
+ */
+
+app.defaultConfiguration = function defaultConfiguration() {
+ var env = process.env.NODE_ENV || 'development';
+
+ // default settings
+ this.enable('x-powered-by');
+ this.set('etag', 'weak');
+ this.set('env', env);
+ this.set('query parser', 'extended');
+ this.set('subdomain offset', 2);
+ this.set('trust proxy', false);
+
+ // trust proxy inherit back-compat
+ Object.defineProperty(this.settings, trustProxyDefaultSymbol, {
+ configurable: true,
+ value: true
+ });
+
+ debug('booting in %s mode', env);
+
+ this.on('mount', function onmount(parent) {
+ // inherit trust proxy
+ if (this.settings[trustProxyDefaultSymbol] === true
+ && typeof parent.settings['trust proxy fn'] === 'function') {
+ delete this.settings['trust proxy'];
+ delete this.settings['trust proxy fn'];
+ }
+
+ // inherit protos
+ this.request.__proto__ = parent.request;
+ this.response.__proto__ = parent.response;
+ this.engines.__proto__ = parent.engines;
+ this.settings.__proto__ = parent.settings;
+ });
+
+ // setup locals
+ this.locals = Object.create(null);
+
+ // top-most app is mounted at /
+ this.mountpath = '/';
+
+ // default locals
+ this.locals.settings = this.settings;
+
+ // default configuration
+ this.set('view', View);
+ this.set('views', resolve('views'));
+ this.set('jsonp callback name', 'callback');
+
+ if (env === 'production') {
+ this.enable('view cache');
+ }
+
+ Object.defineProperty(this, 'router', {
+ get: function() {
+ throw new Error('\'app.router\' is deprecated!\nPlease see the 3.x to 4.x migration guide for details on how to update your app.');
+ }
+ });
+};
+
+/**
+ * lazily adds the base router if it has not yet been added.
+ *
+ * We cannot add the base router in the defaultConfiguration because
+ * it reads app settings which might be set after that has run.
+ *
+ * @private
+ */
+app.lazyrouter = function lazyrouter() {
+ if (!this._router) {
+ this._router = new Router({
+ caseSensitive: this.enabled('case sensitive routing'),
+ strict: this.enabled('strict routing')
+ });
+
+ this._router.use(query(this.get('query parser fn')));
+ this._router.use(middleware.init(this));
+ }
+};
+
+/**
+ * Dispatch a req, res pair into the application. Starts pipeline processing.
+ *
+ * If no callback is provided, then default error handlers will respond
+ * in the event of an error bubbling through the stack.
+ *
+ * @private
+ */
+
+app.handle = function handle(req, res, callback) {
+ var router = this._router;
+
+ // final handler
+ var done = callback || finalhandler(req, res, {
+ env: this.get('env'),
+ onerror: logerror.bind(this)
+ });
+
+ // no routes
+ if (!router) {
+ debug('no routes defined on app');
+ done();
+ return;
+ }
+
+ router.handle(req, res, done);
+};
+
+/**
+ * Proxy `Router#use()` to add middleware to the app router.
+ * See Router#use() documentation for details.
+ *
+ * If the _fn_ parameter is an express app, then it will be
+ * mounted at the _route_ specified.
+ *
+ * @public
+ */
+
+app.use = function use(fn) {
+ var offset = 0;
+ var path = '/';
+
+ // default path to '/'
+ // disambiguate app.use([fn])
+ if (typeof fn !== 'function') {
+ var arg = fn;
+
+ while (Array.isArray(arg) && arg.length !== 0) {
+ arg = arg[0];
+ }
+
+ // first arg is the path
+ if (typeof arg !== 'function') {
+ offset = 1;
+ path = fn;
+ }
+ }
+
+ var fns = flatten(slice.call(arguments, offset));
+
+ if (fns.length === 0) {
+ throw new TypeError('app.use() requires middleware functions');
+ }
+
+ // setup router
+ this.lazyrouter();
+ var router = this._router;
+
+ fns.forEach(function (fn) {
+ // non-express app
+ if (!fn || !fn.handle || !fn.set) {
+ return router.use(path, fn);
+ }
+
+ debug('.use app under %s', path);
+ fn.mountpath = path;
+ fn.parent = this;
+
+ // restore .app property on req and res
+ router.use(path, function mounted_app(req, res, next) {
+ var orig = req.app;
+ fn.handle(req, res, function (err) {
+ req.__proto__ = orig.request;
+ res.__proto__ = orig.response;
+ next(err);
+ });
+ });
+
+ // mounted an app
+ fn.emit('mount', this);
+ }, this);
+
+ return this;
+};
+
+/**
+ * Proxy to the app `Router#route()`
+ * Returns a new `Route` instance for the _path_.
+ *
+ * Routes are isolated middleware stacks for specific paths.
+ * See the Route api docs for details.
+ *
+ * @public
+ */
+
+app.route = function route(path) {
+ this.lazyrouter();
+ return this._router.route(path);
+};
+
+/**
+ * Register the given template engine callback `fn`
+ * as `ext`.
+ *
+ * By default will `require()` the engine based on the
+ * file extension. For example if you try to render
+ * a "foo.jade" file Express will invoke the following internally:
+ *
+ * app.engine('jade', require('jade').__express);
+ *
+ * For engines that do not provide `.__express` out of the box,
+ * or if you wish to "map" a different extension to the template engine
+ * you may use this method. For example mapping the EJS template engine to
+ * ".html" files:
+ *
+ * app.engine('html', require('ejs').renderFile);
+ *
+ * In this case EJS provides a `.renderFile()` method with
+ * the same signature that Express expects: `(path, options, callback)`,
+ * though note that it aliases this method as `ejs.__express` internally
+ * so if you're using ".ejs" extensions you dont need to do anything.
+ *
+ * Some template engines do not follow this convention, the
+ * [Consolidate.js](https://github.com/tj/consolidate.js)
+ * library was created to map all of node's popular template
+ * engines to follow this convention, thus allowing them to
+ * work seamlessly within Express.
+ *
+ * @param {String} ext
+ * @param {Function} fn
+ * @return {app} for chaining
+ * @public
+ */
+
+app.engine = function engine(ext, fn) {
+ if (typeof fn !== 'function') {
+ throw new Error('callback function required');
+ }
+
+ // get file extension
+ var extension = ext[0] !== '.'
+ ? '.' + ext
+ : ext;
+
+ // store engine
+ this.engines[extension] = fn;
+
+ return this;
+};
+
+/**
+ * Proxy to `Router#param()` with one added api feature. The _name_ parameter
+ * can be an array of names.
+ *
+ * See the Router#param() docs for more details.
+ *
+ * @param {String|Array} name
+ * @param {Function} fn
+ * @return {app} for chaining
+ * @public
+ */
+
+app.param = function param(name, fn) {
+ this.lazyrouter();
+
+ if (Array.isArray(name)) {
+ for (var i = 0; i < name.length; i++) {
+ this.param(name[i], fn);
+ }
+
+ return this;
+ }
+
+ this._router.param(name, fn);
+
+ return this;
+};
+
+/**
+ * Assign `setting` to `val`, or return `setting`'s value.
+ *
+ * app.set('foo', 'bar');
+ * app.get('foo');
+ * // => "bar"
+ *
+ * Mounted servers inherit their parent server's settings.
+ *
+ * @param {String} setting
+ * @param {*} [val]
+ * @return {Server} for chaining
+ * @public
+ */
+
+app.set = function set(setting, val) {
+ if (arguments.length === 1) {
+ // app.get(setting)
+ return this.settings[setting];
+ }
+
+ debug('set "%s" to %o', setting, val);
+
+ // set value
+ this.settings[setting] = val;
+
+ // trigger matched settings
+ switch (setting) {
+ case 'etag':
+ this.set('etag fn', compileETag(val));
+ break;
+ case 'query parser':
+ this.set('query parser fn', compileQueryParser(val));
+ break;
+ case 'trust proxy':
+ this.set('trust proxy fn', compileTrust(val));
+
+ // trust proxy inherit back-compat
+ Object.defineProperty(this.settings, trustProxyDefaultSymbol, {
+ configurable: true,
+ value: false
+ });
+
+ break;
+ }
+
+ return this;
+};
+
+/**
+ * Return the app's absolute pathname
+ * based on the parent(s) that have
+ * mounted it.
+ *
+ * For example if the application was
+ * mounted as "/admin", which itself
+ * was mounted as "/blog" then the
+ * return value would be "/blog/admin".
+ *
+ * @return {String}
+ * @private
+ */
+
+app.path = function path() {
+ return this.parent
+ ? this.parent.path() + this.mountpath
+ : '';
+};
+
+/**
+ * Check if `setting` is enabled (truthy).
+ *
+ * app.enabled('foo')
+ * // => false
+ *
+ * app.enable('foo')
+ * app.enabled('foo')
+ * // => true
+ *
+ * @param {String} setting
+ * @return {Boolean}
+ * @public
+ */
+
+app.enabled = function enabled(setting) {
+ return Boolean(this.set(setting));
+};
+
+/**
+ * Check if `setting` is disabled.
+ *
+ * app.disabled('foo')
+ * // => true
+ *
+ * app.enable('foo')
+ * app.disabled('foo')
+ * // => false
+ *
+ * @param {String} setting
+ * @return {Boolean}
+ * @public
+ */
+
+app.disabled = function disabled(setting) {
+ return !this.set(setting);
+};
+
+/**
+ * Enable `setting`.
+ *
+ * @param {String} setting
+ * @return {app} for chaining
+ * @public
+ */
+
+app.enable = function enable(setting) {
+ return this.set(setting, true);
+};
+
+/**
+ * Disable `setting`.
+ *
+ * @param {String} setting
+ * @return {app} for chaining
+ * @public
+ */
+
+app.disable = function disable(setting) {
+ return this.set(setting, false);
+};
+
+/**
+ * Delegate `.VERB(...)` calls to `router.VERB(...)`.
+ */
+
+methods.forEach(function(method){
+ app[method] = function(path){
+ if (method === 'get' && arguments.length === 1) {
+ // app.get(setting)
+ return this.set(path);
+ }
+
+ this.lazyrouter();
+
+ var route = this._router.route(path);
+ route[method].apply(route, slice.call(arguments, 1));
+ return this;
+ };
+});
+
+/**
+ * Special-cased "all" method, applying the given route `path`,
+ * middleware, and callback to _every_ HTTP method.
+ *
+ * @param {String} path
+ * @param {Function} ...
+ * @return {app} for chaining
+ * @public
+ */
+
+app.all = function all(path) {
+ this.lazyrouter();
+
+ var route = this._router.route(path);
+ var args = slice.call(arguments, 1);
+
+ for (var i = 0; i < methods.length; i++) {
+ route[methods[i]].apply(route, args);
+ }
+
+ return this;
+};
+
+// del -> delete alias
+
+app.del = deprecate.function(app.delete, 'app.del: Use app.delete instead');
+
+/**
+ * Render the given view `name` name with `options`
+ * and a callback accepting an error and the
+ * rendered template string.
+ *
+ * Example:
+ *
+ * app.render('email', { name: 'Tobi' }, function(err, html){
+ * // ...
+ * })
+ *
+ * @param {String} name
+ * @param {Object|Function} options or fn
+ * @param {Function} callback
+ * @public
+ */
+
+app.render = function render(name, options, callback) {
+ var cache = this.cache;
+ var done = callback;
+ var engines = this.engines;
+ var opts = options;
+ var renderOptions = {};
+ var view;
+
+ // support callback function as second arg
+ if (typeof options === 'function') {
+ done = options;
+ opts = {};
+ }
+
+ // merge app.locals
+ merge(renderOptions, this.locals);
+
+ // merge options._locals
+ if (opts._locals) {
+ merge(renderOptions, opts._locals);
+ }
+
+ // merge options
+ merge(renderOptions, opts);
+
+ // set .cache unless explicitly provided
+ if (renderOptions.cache == null) {
+ renderOptions.cache = this.enabled('view cache');
+ }
+
+ // primed cache
+ if (renderOptions.cache) {
+ view = cache[name];
+ }
+
+ // view
+ if (!view) {
+ var View = this.get('view');
+
+ view = new View(name, {
+ defaultEngine: this.get('view engine'),
+ root: this.get('views'),
+ engines: engines
+ });
+
+ if (!view.path) {
+ var dirs = Array.isArray(view.root) && view.root.length > 1
+ ? 'directories "' + view.root.slice(0, -1).join('", "') + '" or "' + view.root[view.root.length - 1] + '"'
+ : 'directory "' + view.root + '"'
+ var err = new Error('Failed to lookup view "' + name + '" in views ' + dirs);
+ err.view = view;
+ return done(err);
+ }
+
+ // prime the cache
+ if (renderOptions.cache) {
+ cache[name] = view;
+ }
+ }
+
+ // render
+ tryRender(view, renderOptions, done);
+};
+
+/**
+ * Listen for connections.
+ *
+ * A node `http.Server` is returned, with this
+ * application (which is a `Function`) as its
+ * callback. If you wish to create both an HTTP
+ * and HTTPS server you may do so with the "http"
+ * and "https" modules as shown here:
+ *
+ * var http = require('http')
+ * , https = require('https')
+ * , express = require('express')
+ * , app = express();
+ *
+ * http.createServer(app).listen(80);
+ * https.createServer({ ... }, app).listen(443);
+ *
+ * @return {http.Server}
+ * @public
+ */
+
+app.listen = function listen() {
+ var server = http.createServer(this);
+ return server.listen.apply(server, arguments);
+};
+
+/**
+ * Log error using console.error.
+ *
+ * @param {Error} err
+ * @private
+ */
+
+function logerror(err) {
+ /* istanbul ignore next */
+ if (this.get('env') !== 'test') console.error(err.stack || err.toString());
+}
+
+/**
+ * Try rendering a view.
+ * @private
+ */
+
+function tryRender(view, options, callback) {
+ try {
+ view.render(options, callback);
+ } catch (err) {
+ callback(err);
+ }
+}
diff --git a/node_modules/express/lib/express.js b/node_modules/express/lib/express.js
new file mode 100644
index 00000000..540c8be6
--- /dev/null
+++ b/node_modules/express/lib/express.js
@@ -0,0 +1,103 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ */
+
+var EventEmitter = require('events').EventEmitter;
+var mixin = require('merge-descriptors');
+var proto = require('./application');
+var Route = require('./router/route');
+var Router = require('./router');
+var req = require('./request');
+var res = require('./response');
+
+/**
+ * Expose `createApplication()`.
+ */
+
+exports = module.exports = createApplication;
+
+/**
+ * Create an express application.
+ *
+ * @return {Function}
+ * @api public
+ */
+
+function createApplication() {
+ var app = function(req, res, next) {
+ app.handle(req, res, next);
+ };
+
+ mixin(app, EventEmitter.prototype, false);
+ mixin(app, proto, false);
+
+ app.request = { __proto__: req, app: app };
+ app.response = { __proto__: res, app: app };
+ app.init();
+ return app;
+}
+
+/**
+ * Expose the prototypes.
+ */
+
+exports.application = proto;
+exports.request = req;
+exports.response = res;
+
+/**
+ * Expose constructors.
+ */
+
+exports.Route = Route;
+exports.Router = Router;
+
+/**
+ * Expose middleware
+ */
+
+exports.query = require('./middleware/query');
+exports.static = require('serve-static');
+
+/**
+ * Replace removed middleware with an appropriate error message.
+ */
+
+[
+ 'json',
+ 'urlencoded',
+ 'bodyParser',
+ 'compress',
+ 'cookieSession',
+ 'session',
+ 'logger',
+ 'cookieParser',
+ 'favicon',
+ 'responseTime',
+ 'errorHandler',
+ 'timeout',
+ 'methodOverride',
+ 'vhost',
+ 'csrf',
+ 'directory',
+ 'limit',
+ 'multipart',
+ 'staticCache',
+].forEach(function (name) {
+ Object.defineProperty(exports, name, {
+ get: function () {
+ throw new Error('Most middleware (like ' + name + ') is no longer bundled with Express and must be installed separately. Please see https://github.com/senchalabs/connect#middleware.');
+ },
+ configurable: true
+ });
+});
diff --git a/node_modules/express/lib/middleware/init.js b/node_modules/express/lib/middleware/init.js
new file mode 100644
index 00000000..f3119ed3
--- /dev/null
+++ b/node_modules/express/lib/middleware/init.js
@@ -0,0 +1,36 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Initialization middleware, exposing the
+ * request and response to each other, as well
+ * as defaulting the X-Powered-By header field.
+ *
+ * @param {Function} app
+ * @return {Function}
+ * @api private
+ */
+
+exports.init = function(app){
+ return function expressInit(req, res, next){
+ if (app.enabled('x-powered-by')) res.setHeader('X-Powered-By', 'Express');
+ req.res = res;
+ res.req = req;
+ req.next = next;
+
+ req.__proto__ = app.request;
+ res.__proto__ = app.response;
+
+ res.locals = res.locals || Object.create(null);
+
+ next();
+ };
+};
+
diff --git a/node_modules/express/lib/middleware/query.js b/node_modules/express/lib/middleware/query.js
new file mode 100644
index 00000000..5f76f845
--- /dev/null
+++ b/node_modules/express/lib/middleware/query.js
@@ -0,0 +1,46 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ */
+
+var parseUrl = require('parseurl');
+var qs = require('qs');
+
+/**
+ * @param {Object} options
+ * @return {Function}
+ * @api public
+ */
+
+module.exports = function query(options) {
+ var opts = Object.create(options || null);
+ var queryparse = qs.parse;
+
+ if (typeof options === 'function') {
+ queryparse = options;
+ opts = undefined;
+ }
+
+ if (opts !== undefined && opts.allowPrototypes === undefined) {
+ // back-compat for qs module
+ opts.allowPrototypes = true;
+ }
+
+ return function query(req, res, next){
+ if (!req.query) {
+ var val = parseUrl(req).query;
+ req.query = queryparse(val, opts);
+ }
+
+ next();
+ };
+};
diff --git a/node_modules/express/lib/request.js b/node_modules/express/lib/request.js
new file mode 100644
index 00000000..557d050f
--- /dev/null
+++ b/node_modules/express/lib/request.js
@@ -0,0 +1,502 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var accepts = require('accepts');
+var deprecate = require('depd')('express');
+var isIP = require('net').isIP;
+var typeis = require('type-is');
+var http = require('http');
+var fresh = require('fresh');
+var parseRange = require('range-parser');
+var parse = require('parseurl');
+var proxyaddr = require('proxy-addr');
+
+/**
+ * Request prototype.
+ */
+
+var req = exports = module.exports = {
+ __proto__: http.IncomingMessage.prototype
+};
+
+/**
+ * Return request header.
+ *
+ * The `Referrer` header field is special-cased,
+ * both `Referrer` and `Referer` are interchangeable.
+ *
+ * Examples:
+ *
+ * req.get('Content-Type');
+ * // => "text/plain"
+ *
+ * req.get('content-type');
+ * // => "text/plain"
+ *
+ * req.get('Something');
+ * // => undefined
+ *
+ * Aliased as `req.header()`.
+ *
+ * @param {String} name
+ * @return {String}
+ * @public
+ */
+
+req.get =
+req.header = function header(name) {
+ if (!name) {
+ throw new TypeError('name argument is required to req.get');
+ }
+
+ if (typeof name !== 'string') {
+ throw new TypeError('name must be a string to req.get');
+ }
+
+ var lc = name.toLowerCase();
+
+ switch (lc) {
+ case 'referer':
+ case 'referrer':
+ return this.headers.referrer
+ || this.headers.referer;
+ default:
+ return this.headers[lc];
+ }
+};
+
+/**
+ * To do: update docs.
+ *
+ * Check if the given `type(s)` is acceptable, returning
+ * the best match when true, otherwise `undefined`, in which
+ * case you should respond with 406 "Not Acceptable".
+ *
+ * The `type` value may be a single MIME type string
+ * such as "application/json", an extension name
+ * such as "json", a comma-delimited list such as "json, html, text/plain",
+ * an argument list such as `"json", "html", "text/plain"`,
+ * or an array `["json", "html", "text/plain"]`. When a list
+ * or array is given, the _best_ match, if any is returned.
+ *
+ * Examples:
+ *
+ * // Accept: text/html
+ * req.accepts('html');
+ * // => "html"
+ *
+ * // Accept: text/*, application/json
+ * req.accepts('html');
+ * // => "html"
+ * req.accepts('text/html');
+ * // => "text/html"
+ * req.accepts('json, text');
+ * // => "json"
+ * req.accepts('application/json');
+ * // => "application/json"
+ *
+ * // Accept: text/*, application/json
+ * req.accepts('image/png');
+ * req.accepts('png');
+ * // => undefined
+ *
+ * // Accept: text/*;q=.5, application/json
+ * req.accepts(['html', 'json']);
+ * req.accepts('html', 'json');
+ * req.accepts('html, json');
+ * // => "json"
+ *
+ * @param {String|Array} type(s)
+ * @return {String|Array|Boolean}
+ * @public
+ */
+
+req.accepts = function(){
+ var accept = accepts(this);
+ return accept.types.apply(accept, arguments);
+};
+
+/**
+ * Check if the given `encoding`s are accepted.
+ *
+ * @param {String} ...encoding
+ * @return {String|Array}
+ * @public
+ */
+
+req.acceptsEncodings = function(){
+ var accept = accepts(this);
+ return accept.encodings.apply(accept, arguments);
+};
+
+req.acceptsEncoding = deprecate.function(req.acceptsEncodings,
+ 'req.acceptsEncoding: Use acceptsEncodings instead');
+
+/**
+ * Check if the given `charset`s are acceptable,
+ * otherwise you should respond with 406 "Not Acceptable".
+ *
+ * @param {String} ...charset
+ * @return {String|Array}
+ * @public
+ */
+
+req.acceptsCharsets = function(){
+ var accept = accepts(this);
+ return accept.charsets.apply(accept, arguments);
+};
+
+req.acceptsCharset = deprecate.function(req.acceptsCharsets,
+ 'req.acceptsCharset: Use acceptsCharsets instead');
+
+/**
+ * Check if the given `lang`s are acceptable,
+ * otherwise you should respond with 406 "Not Acceptable".
+ *
+ * @param {String} ...lang
+ * @return {String|Array}
+ * @public
+ */
+
+req.acceptsLanguages = function(){
+ var accept = accepts(this);
+ return accept.languages.apply(accept, arguments);
+};
+
+req.acceptsLanguage = deprecate.function(req.acceptsLanguages,
+ 'req.acceptsLanguage: Use acceptsLanguages instead');
+
+/**
+ * Parse Range header field, capping to the given `size`.
+ *
+ * Unspecified ranges such as "0-" require knowledge of your resource length. In
+ * the case of a byte range this is of course the total number of bytes. If the
+ * Range header field is not given `undefined` is returned, `-1` when unsatisfiable,
+ * and `-2` when syntactically invalid.
+ *
+ * When ranges are returned, the array has a "type" property which is the type of
+ * range that is required (most commonly, "bytes"). Each array element is an object
+ * with a "start" and "end" property for the portion of the range.
+ *
+ * The "combine" option can be set to `true` and overlapping & adjacent ranges
+ * will be combined into a single range.
+ *
+ * NOTE: remember that ranges are inclusive, so for example "Range: users=0-3"
+ * should respond with 4 users when available, not 3.
+ *
+ * @param {number} size
+ * @param {object} [options]
+ * @param {boolean} [options.combine=false]
+ * @return {number|array}
+ * @public
+ */
+
+req.range = function range(size, options) {
+ var range = this.get('Range');
+ if (!range) return;
+ return parseRange(size, range, options);
+};
+
+/**
+ * Return the value of param `name` when present or `defaultValue`.
+ *
+ * - Checks route placeholders, ex: _/user/:id_
+ * - Checks body params, ex: id=12, {"id":12}
+ * - Checks query string params, ex: ?id=12
+ *
+ * To utilize request bodies, `req.body`
+ * should be an object. This can be done by using
+ * the `bodyParser()` middleware.
+ *
+ * @param {String} name
+ * @param {Mixed} [defaultValue]
+ * @return {String}
+ * @public
+ */
+
+req.param = function param(name, defaultValue) {
+ var params = this.params || {};
+ var body = this.body || {};
+ var query = this.query || {};
+
+ var args = arguments.length === 1
+ ? 'name'
+ : 'name, default';
+ deprecate('req.param(' + args + '): Use req.params, req.body, or req.query instead');
+
+ if (null != params[name] && params.hasOwnProperty(name)) return params[name];
+ if (null != body[name]) return body[name];
+ if (null != query[name]) return query[name];
+
+ return defaultValue;
+};
+
+/**
+ * Check if the incoming request contains the "Content-Type"
+ * header field, and it contains the give mime `type`.
+ *
+ * Examples:
+ *
+ * // With Content-Type: text/html; charset=utf-8
+ * req.is('html');
+ * req.is('text/html');
+ * req.is('text/*');
+ * // => true
+ *
+ * // When Content-Type is application/json
+ * req.is('json');
+ * req.is('application/json');
+ * req.is('application/*');
+ * // => true
+ *
+ * req.is('html');
+ * // => false
+ *
+ * @param {String|Array} types...
+ * @return {String|false|null}
+ * @public
+ */
+
+req.is = function is(types) {
+ var arr = types;
+
+ // support flattened arguments
+ if (!Array.isArray(types)) {
+ arr = new Array(arguments.length);
+ for (var i = 0; i < arr.length; i++) {
+ arr[i] = arguments[i];
+ }
+ }
+
+ return typeis(this, arr);
+};
+
+/**
+ * Return the protocol string "http" or "https"
+ * when requested with TLS. When the "trust proxy"
+ * setting trusts the socket address, the
+ * "X-Forwarded-Proto" header field will be trusted
+ * and used if present.
+ *
+ * If you're running behind a reverse proxy that
+ * supplies https for you this may be enabled.
+ *
+ * @return {String}
+ * @public
+ */
+
+defineGetter(req, 'protocol', function protocol(){
+ var proto = this.connection.encrypted
+ ? 'https'
+ : 'http';
+ var trust = this.app.get('trust proxy fn');
+
+ if (!trust(this.connection.remoteAddress, 0)) {
+ return proto;
+ }
+
+ // Note: X-Forwarded-Proto is normally only ever a
+ // single value, but this is to be safe.
+ proto = this.get('X-Forwarded-Proto') || proto;
+ return proto.split(/\s*,\s*/)[0];
+});
+
+/**
+ * Short-hand for:
+ *
+ * req.protocol === 'https'
+ *
+ * @return {Boolean}
+ * @public
+ */
+
+defineGetter(req, 'secure', function secure(){
+ return this.protocol === 'https';
+});
+
+/**
+ * Return the remote address from the trusted proxy.
+ *
+ * The is the remote address on the socket unless
+ * "trust proxy" is set.
+ *
+ * @return {String}
+ * @public
+ */
+
+defineGetter(req, 'ip', function ip(){
+ var trust = this.app.get('trust proxy fn');
+ return proxyaddr(this, trust);
+});
+
+/**
+ * When "trust proxy" is set, trusted proxy addresses + client.
+ *
+ * For example if the value were "client, proxy1, proxy2"
+ * you would receive the array `["client", "proxy1", "proxy2"]`
+ * where "proxy2" is the furthest down-stream and "proxy1" and
+ * "proxy2" were trusted.
+ *
+ * @return {Array}
+ * @public
+ */
+
+defineGetter(req, 'ips', function ips() {
+ var trust = this.app.get('trust proxy fn');
+ var addrs = proxyaddr.all(this, trust);
+ return addrs.slice(1).reverse();
+});
+
+/**
+ * Return subdomains as an array.
+ *
+ * Subdomains are the dot-separated parts of the host before the main domain of
+ * the app. By default, the domain of the app is assumed to be the last two
+ * parts of the host. This can be changed by setting "subdomain offset".
+ *
+ * For example, if the domain is "tobi.ferrets.example.com":
+ * If "subdomain offset" is not set, req.subdomains is `["ferrets", "tobi"]`.
+ * If "subdomain offset" is 3, req.subdomains is `["tobi"]`.
+ *
+ * @return {Array}
+ * @public
+ */
+
+defineGetter(req, 'subdomains', function subdomains() {
+ var hostname = this.hostname;
+
+ if (!hostname) return [];
+
+ var offset = this.app.get('subdomain offset');
+ var subdomains = !isIP(hostname)
+ ? hostname.split('.').reverse()
+ : [hostname];
+
+ return subdomains.slice(offset);
+});
+
+/**
+ * Short-hand for `url.parse(req.url).pathname`.
+ *
+ * @return {String}
+ * @public
+ */
+
+defineGetter(req, 'path', function path() {
+ return parse(this).pathname;
+});
+
+/**
+ * Parse the "Host" header field to a hostname.
+ *
+ * When the "trust proxy" setting trusts the socket
+ * address, the "X-Forwarded-Host" header field will
+ * be trusted.
+ *
+ * @return {String}
+ * @public
+ */
+
+defineGetter(req, 'hostname', function hostname(){
+ var trust = this.app.get('trust proxy fn');
+ var host = this.get('X-Forwarded-Host');
+
+ if (!host || !trust(this.connection.remoteAddress, 0)) {
+ host = this.get('Host');
+ }
+
+ if (!host) return;
+
+ // IPv6 literal support
+ var offset = host[0] === '['
+ ? host.indexOf(']') + 1
+ : 0;
+ var index = host.indexOf(':', offset);
+
+ return index !== -1
+ ? host.substring(0, index)
+ : host;
+});
+
+// TODO: change req.host to return host in next major
+
+defineGetter(req, 'host', deprecate.function(function host(){
+ return this.hostname;
+}, 'req.host: Use req.hostname instead'));
+
+/**
+ * Check if the request is fresh, aka
+ * Last-Modified and/or the ETag
+ * still match.
+ *
+ * @return {Boolean}
+ * @public
+ */
+
+defineGetter(req, 'fresh', function(){
+ var method = this.method;
+ var s = this.res.statusCode;
+
+ // GET or HEAD for weak freshness validation only
+ if ('GET' !== method && 'HEAD' !== method) return false;
+
+ // 2xx or 304 as per rfc2616 14.26
+ if ((s >= 200 && s < 300) || 304 === s) {
+ return fresh(this.headers, (this.res._headers || {}));
+ }
+
+ return false;
+});
+
+/**
+ * Check if the request is stale, aka
+ * "Last-Modified" and / or the "ETag" for the
+ * resource has changed.
+ *
+ * @return {Boolean}
+ * @public
+ */
+
+defineGetter(req, 'stale', function stale(){
+ return !this.fresh;
+});
+
+/**
+ * Check if the request was an _XMLHttpRequest_.
+ *
+ * @return {Boolean}
+ * @public
+ */
+
+defineGetter(req, 'xhr', function xhr(){
+ var val = this.get('X-Requested-With') || '';
+ return val.toLowerCase() === 'xmlhttprequest';
+});
+
+/**
+ * Helper function for creating a getter on an object.
+ *
+ * @param {Object} obj
+ * @param {String} name
+ * @param {Function} getter
+ * @private
+ */
+function defineGetter(obj, name, getter) {
+ Object.defineProperty(obj, name, {
+ configurable: true,
+ enumerable: true,
+ get: getter
+ });
+};
diff --git a/node_modules/express/lib/response.js b/node_modules/express/lib/response.js
new file mode 100644
index 00000000..6128f450
--- /dev/null
+++ b/node_modules/express/lib/response.js
@@ -0,0 +1,1065 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var contentDisposition = require('content-disposition');
+var deprecate = require('depd')('express');
+var encodeUrl = require('encodeurl');
+var escapeHtml = require('escape-html');
+var http = require('http');
+var isAbsolute = require('./utils').isAbsolute;
+var onFinished = require('on-finished');
+var path = require('path');
+var merge = require('utils-merge');
+var sign = require('cookie-signature').sign;
+var normalizeType = require('./utils').normalizeType;
+var normalizeTypes = require('./utils').normalizeTypes;
+var setCharset = require('./utils').setCharset;
+var statusCodes = http.STATUS_CODES;
+var cookie = require('cookie');
+var send = require('send');
+var extname = path.extname;
+var mime = send.mime;
+var resolve = path.resolve;
+var vary = require('vary');
+
+/**
+ * Response prototype.
+ */
+
+var res = module.exports = {
+ __proto__: http.ServerResponse.prototype
+};
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var charsetRegExp = /;\s*charset\s*=/;
+
+/**
+ * Set status `code`.
+ *
+ * @param {Number} code
+ * @return {ServerResponse}
+ * @public
+ */
+
+res.status = function status(code) {
+ this.statusCode = code;
+ return this;
+};
+
+/**
+ * Set Link header field with the given `links`.
+ *
+ * Examples:
+ *
+ * res.links({
+ * next: 'http://api.example.com/users?page=2',
+ * last: 'http://api.example.com/users?page=5'
+ * });
+ *
+ * @param {Object} links
+ * @return {ServerResponse}
+ * @public
+ */
+
+res.links = function(links){
+ var link = this.get('Link') || '';
+ if (link) link += ', ';
+ return this.set('Link', link + Object.keys(links).map(function(rel){
+ return '<' + links[rel] + '>; rel="' + rel + '"';
+ }).join(', '));
+};
+
+/**
+ * Send a response.
+ *
+ * Examples:
+ *
+ * res.send(new Buffer('wahoo'));
+ * res.send({ some: 'json' });
+ * res.send('some html
');
+ *
+ * @param {string|number|boolean|object|Buffer} body
+ * @public
+ */
+
+res.send = function send(body) {
+ var chunk = body;
+ var encoding;
+ var len;
+ var req = this.req;
+ var type;
+
+ // settings
+ var app = this.app;
+
+ // allow status / body
+ if (arguments.length === 2) {
+ // res.send(body, status) backwards compat
+ if (typeof arguments[0] !== 'number' && typeof arguments[1] === 'number') {
+ deprecate('res.send(body, status): Use res.status(status).send(body) instead');
+ this.statusCode = arguments[1];
+ } else {
+ deprecate('res.send(status, body): Use res.status(status).send(body) instead');
+ this.statusCode = arguments[0];
+ chunk = arguments[1];
+ }
+ }
+
+ // disambiguate res.send(status) and res.send(status, num)
+ if (typeof chunk === 'number' && arguments.length === 1) {
+ // res.send(status) will set status message as text string
+ if (!this.get('Content-Type')) {
+ this.type('txt');
+ }
+
+ deprecate('res.send(status): Use res.sendStatus(status) instead');
+ this.statusCode = chunk;
+ chunk = statusCodes[chunk];
+ }
+
+ switch (typeof chunk) {
+ // string defaulting to html
+ case 'string':
+ if (!this.get('Content-Type')) {
+ this.type('html');
+ }
+ break;
+ case 'boolean':
+ case 'number':
+ case 'object':
+ if (chunk === null) {
+ chunk = '';
+ } else if (Buffer.isBuffer(chunk)) {
+ if (!this.get('Content-Type')) {
+ this.type('bin');
+ }
+ } else {
+ return this.json(chunk);
+ }
+ break;
+ }
+
+ // write strings in utf-8
+ if (typeof chunk === 'string') {
+ encoding = 'utf8';
+ type = this.get('Content-Type');
+
+ // reflect this in content-type
+ if (typeof type === 'string') {
+ this.set('Content-Type', setCharset(type, 'utf-8'));
+ }
+ }
+
+ // populate Content-Length
+ if (chunk !== undefined) {
+ if (!Buffer.isBuffer(chunk)) {
+ // convert chunk to Buffer; saves later double conversions
+ chunk = new Buffer(chunk, encoding);
+ encoding = undefined;
+ }
+
+ len = chunk.length;
+ this.set('Content-Length', len);
+ }
+
+ // populate ETag
+ var etag;
+ var generateETag = len !== undefined && app.get('etag fn');
+ if (typeof generateETag === 'function' && !this.get('ETag')) {
+ if ((etag = generateETag(chunk, encoding))) {
+ this.set('ETag', etag);
+ }
+ }
+
+ // freshness
+ if (req.fresh) this.statusCode = 304;
+
+ // strip irrelevant headers
+ if (204 === this.statusCode || 304 === this.statusCode) {
+ this.removeHeader('Content-Type');
+ this.removeHeader('Content-Length');
+ this.removeHeader('Transfer-Encoding');
+ chunk = '';
+ }
+
+ if (req.method === 'HEAD') {
+ // skip body for HEAD
+ this.end();
+ } else {
+ // respond
+ this.end(chunk, encoding);
+ }
+
+ return this;
+};
+
+/**
+ * Send JSON response.
+ *
+ * Examples:
+ *
+ * res.json(null);
+ * res.json({ user: 'tj' });
+ *
+ * @param {string|number|boolean|object} obj
+ * @public
+ */
+
+res.json = function json(obj) {
+ var val = obj;
+
+ // allow status / body
+ if (arguments.length === 2) {
+ // res.json(body, status) backwards compat
+ if (typeof arguments[1] === 'number') {
+ deprecate('res.json(obj, status): Use res.status(status).json(obj) instead');
+ this.statusCode = arguments[1];
+ } else {
+ deprecate('res.json(status, obj): Use res.status(status).json(obj) instead');
+ this.statusCode = arguments[0];
+ val = arguments[1];
+ }
+ }
+
+ // settings
+ var app = this.app;
+ var replacer = app.get('json replacer');
+ var spaces = app.get('json spaces');
+ var body = stringify(val, replacer, spaces);
+
+ // content-type
+ if (!this.get('Content-Type')) {
+ this.set('Content-Type', 'application/json');
+ }
+
+ return this.send(body);
+};
+
+/**
+ * Send JSON response with JSONP callback support.
+ *
+ * Examples:
+ *
+ * res.jsonp(null);
+ * res.jsonp({ user: 'tj' });
+ *
+ * @param {string|number|boolean|object} obj
+ * @public
+ */
+
+res.jsonp = function jsonp(obj) {
+ var val = obj;
+
+ // allow status / body
+ if (arguments.length === 2) {
+ // res.json(body, status) backwards compat
+ if (typeof arguments[1] === 'number') {
+ deprecate('res.jsonp(obj, status): Use res.status(status).json(obj) instead');
+ this.statusCode = arguments[1];
+ } else {
+ deprecate('res.jsonp(status, obj): Use res.status(status).jsonp(obj) instead');
+ this.statusCode = arguments[0];
+ val = arguments[1];
+ }
+ }
+
+ // settings
+ var app = this.app;
+ var replacer = app.get('json replacer');
+ var spaces = app.get('json spaces');
+ var body = stringify(val, replacer, spaces);
+ var callback = this.req.query[app.get('jsonp callback name')];
+
+ // content-type
+ if (!this.get('Content-Type')) {
+ this.set('X-Content-Type-Options', 'nosniff');
+ this.set('Content-Type', 'application/json');
+ }
+
+ // fixup callback
+ if (Array.isArray(callback)) {
+ callback = callback[0];
+ }
+
+ // jsonp
+ if (typeof callback === 'string' && callback.length !== 0) {
+ this.charset = 'utf-8';
+ this.set('X-Content-Type-Options', 'nosniff');
+ this.set('Content-Type', 'text/javascript');
+
+ // restrict callback charset
+ callback = callback.replace(/[^\[\]\w$.]/g, '');
+
+ // replace chars not allowed in JavaScript that are in JSON
+ body = body
+ .replace(/\u2028/g, '\\u2028')
+ .replace(/\u2029/g, '\\u2029');
+
+ // the /**/ is a specific security mitigation for "Rosetta Flash JSONP abuse"
+ // the typeof check is just to reduce client error noise
+ body = '/**/ typeof ' + callback + ' === \'function\' && ' + callback + '(' + body + ');';
+ }
+
+ return this.send(body);
+};
+
+/**
+ * Send given HTTP status code.
+ *
+ * Sets the response status to `statusCode` and the body of the
+ * response to the standard description from node's http.STATUS_CODES
+ * or the statusCode number if no description.
+ *
+ * Examples:
+ *
+ * res.sendStatus(200);
+ *
+ * @param {number} statusCode
+ * @public
+ */
+
+res.sendStatus = function sendStatus(statusCode) {
+ var body = statusCodes[statusCode] || String(statusCode);
+
+ this.statusCode = statusCode;
+ this.type('txt');
+
+ return this.send(body);
+};
+
+/**
+ * Transfer the file at the given `path`.
+ *
+ * Automatically sets the _Content-Type_ response header field.
+ * The callback `callback(err)` is invoked when the transfer is complete
+ * or when an error occurs. Be sure to check `res.sentHeader`
+ * if you wish to attempt responding, as the header and some data
+ * may have already been transferred.
+ *
+ * Options:
+ *
+ * - `maxAge` defaulting to 0 (can be string converted by `ms`)
+ * - `root` root directory for relative filenames
+ * - `headers` object of headers to serve with file
+ * - `dotfiles` serve dotfiles, defaulting to false; can be `"allow"` to send them
+ *
+ * Other options are passed along to `send`.
+ *
+ * Examples:
+ *
+ * The following example illustrates how `res.sendFile()` may
+ * be used as an alternative for the `static()` middleware for
+ * dynamic situations. The code backing `res.sendFile()` is actually
+ * the same code, so HTTP cache support etc is identical.
+ *
+ * app.get('/user/:uid/photos/:file', function(req, res){
+ * var uid = req.params.uid
+ * , file = req.params.file;
+ *
+ * req.user.mayViewFilesFrom(uid, function(yes){
+ * if (yes) {
+ * res.sendFile('/uploads/' + uid + '/' + file);
+ * } else {
+ * res.send(403, 'Sorry! you cant see that.');
+ * }
+ * });
+ * });
+ *
+ * @public
+ */
+
+res.sendFile = function sendFile(path, options, callback) {
+ var done = callback;
+ var req = this.req;
+ var res = this;
+ var next = req.next;
+ var opts = options || {};
+
+ if (!path) {
+ throw new TypeError('path argument is required to res.sendFile');
+ }
+
+ // support function as second arg
+ if (typeof options === 'function') {
+ done = options;
+ opts = {};
+ }
+
+ if (!opts.root && !isAbsolute(path)) {
+ throw new TypeError('path must be absolute or specify root to res.sendFile');
+ }
+
+ // create file stream
+ var pathname = encodeURI(path);
+ var file = send(req, pathname, opts);
+
+ // transfer
+ sendfile(res, file, opts, function (err) {
+ if (done) return done(err);
+ if (err && err.code === 'EISDIR') return next();
+
+ // next() all but write errors
+ if (err && err.code !== 'ECONNABORTED' && err.syscall !== 'write') {
+ next(err);
+ }
+ });
+};
+
+/**
+ * Transfer the file at the given `path`.
+ *
+ * Automatically sets the _Content-Type_ response header field.
+ * The callback `callback(err)` is invoked when the transfer is complete
+ * or when an error occurs. Be sure to check `res.sentHeader`
+ * if you wish to attempt responding, as the header and some data
+ * may have already been transferred.
+ *
+ * Options:
+ *
+ * - `maxAge` defaulting to 0 (can be string converted by `ms`)
+ * - `root` root directory for relative filenames
+ * - `headers` object of headers to serve with file
+ * - `dotfiles` serve dotfiles, defaulting to false; can be `"allow"` to send them
+ *
+ * Other options are passed along to `send`.
+ *
+ * Examples:
+ *
+ * The following example illustrates how `res.sendfile()` may
+ * be used as an alternative for the `static()` middleware for
+ * dynamic situations. The code backing `res.sendfile()` is actually
+ * the same code, so HTTP cache support etc is identical.
+ *
+ * app.get('/user/:uid/photos/:file', function(req, res){
+ * var uid = req.params.uid
+ * , file = req.params.file;
+ *
+ * req.user.mayViewFilesFrom(uid, function(yes){
+ * if (yes) {
+ * res.sendfile('/uploads/' + uid + '/' + file);
+ * } else {
+ * res.send(403, 'Sorry! you cant see that.');
+ * }
+ * });
+ * });
+ *
+ * @public
+ */
+
+res.sendfile = function (path, options, callback) {
+ var done = callback;
+ var req = this.req;
+ var res = this;
+ var next = req.next;
+ var opts = options || {};
+
+ // support function as second arg
+ if (typeof options === 'function') {
+ done = options;
+ opts = {};
+ }
+
+ // create file stream
+ var file = send(req, path, opts);
+
+ // transfer
+ sendfile(res, file, opts, function (err) {
+ if (done) return done(err);
+ if (err && err.code === 'EISDIR') return next();
+
+ // next() all but write errors
+ if (err && err.code !== 'ECONNABORT' && err.syscall !== 'write') {
+ next(err);
+ }
+ });
+};
+
+res.sendfile = deprecate.function(res.sendfile,
+ 'res.sendfile: Use res.sendFile instead');
+
+/**
+ * Transfer the file at the given `path` as an attachment.
+ *
+ * Optionally providing an alternate attachment `filename`,
+ * and optional callback `callback(err)`. The callback is invoked
+ * when the data transfer is complete, or when an error has
+ * ocurred. Be sure to check `res.headersSent` if you plan to respond.
+ *
+ * This method uses `res.sendfile()`.
+ *
+ * @public
+ */
+
+res.download = function download(path, filename, callback) {
+ var done = callback;
+ var name = filename;
+
+ // support function as second arg
+ if (typeof filename === 'function') {
+ done = filename;
+ name = null;
+ }
+
+ // set Content-Disposition when file is sent
+ var headers = {
+ 'Content-Disposition': contentDisposition(name || path)
+ };
+
+ // Resolve the full path for sendFile
+ var fullPath = resolve(path);
+
+ return this.sendFile(fullPath, { headers: headers }, done);
+};
+
+/**
+ * Set _Content-Type_ response header with `type` through `mime.lookup()`
+ * when it does not contain "/", or set the Content-Type to `type` otherwise.
+ *
+ * Examples:
+ *
+ * res.type('.html');
+ * res.type('html');
+ * res.type('json');
+ * res.type('application/json');
+ * res.type('png');
+ *
+ * @param {String} type
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.contentType =
+res.type = function contentType(type) {
+ var ct = type.indexOf('/') === -1
+ ? mime.lookup(type)
+ : type;
+
+ return this.set('Content-Type', ct);
+};
+
+/**
+ * Respond to the Acceptable formats using an `obj`
+ * of mime-type callbacks.
+ *
+ * This method uses `req.accepted`, an array of
+ * acceptable types ordered by their quality values.
+ * When "Accept" is not present the _first_ callback
+ * is invoked, otherwise the first match is used. When
+ * no match is performed the server responds with
+ * 406 "Not Acceptable".
+ *
+ * Content-Type is set for you, however if you choose
+ * you may alter this within the callback using `res.type()`
+ * or `res.set('Content-Type', ...)`.
+ *
+ * res.format({
+ * 'text/plain': function(){
+ * res.send('hey');
+ * },
+ *
+ * 'text/html': function(){
+ * res.send('hey
');
+ * },
+ *
+ * 'appliation/json': function(){
+ * res.send({ message: 'hey' });
+ * }
+ * });
+ *
+ * In addition to canonicalized MIME types you may
+ * also use extnames mapped to these types:
+ *
+ * res.format({
+ * text: function(){
+ * res.send('hey');
+ * },
+ *
+ * html: function(){
+ * res.send('hey
');
+ * },
+ *
+ * json: function(){
+ * res.send({ message: 'hey' });
+ * }
+ * });
+ *
+ * By default Express passes an `Error`
+ * with a `.status` of 406 to `next(err)`
+ * if a match is not made. If you provide
+ * a `.default` callback it will be invoked
+ * instead.
+ *
+ * @param {Object} obj
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.format = function(obj){
+ var req = this.req;
+ var next = req.next;
+
+ var fn = obj.default;
+ if (fn) delete obj.default;
+ var keys = Object.keys(obj);
+
+ var key = keys.length > 0
+ ? req.accepts(keys)
+ : false;
+
+ this.vary("Accept");
+
+ if (key) {
+ this.set('Content-Type', normalizeType(key).value);
+ obj[key](req, this, next);
+ } else if (fn) {
+ fn();
+ } else {
+ var err = new Error('Not Acceptable');
+ err.status = err.statusCode = 406;
+ err.types = normalizeTypes(keys).map(function(o){ return o.value });
+ next(err);
+ }
+
+ return this;
+};
+
+/**
+ * Set _Content-Disposition_ header to _attachment_ with optional `filename`.
+ *
+ * @param {String} filename
+ * @return {ServerResponse}
+ * @public
+ */
+
+res.attachment = function attachment(filename) {
+ if (filename) {
+ this.type(extname(filename));
+ }
+
+ this.set('Content-Disposition', contentDisposition(filename));
+
+ return this;
+};
+
+/**
+ * Append additional header `field` with value `val`.
+ *
+ * Example:
+ *
+ * res.append('Link', [' ', ' ']);
+ * res.append('Set-Cookie', 'foo=bar; Path=/; HttpOnly');
+ * res.append('Warning', '199 Miscellaneous warning');
+ *
+ * @param {String} field
+ * @param {String|Array} val
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.append = function append(field, val) {
+ var prev = this.get(field);
+ var value = val;
+
+ if (prev) {
+ // concat the new and prev vals
+ value = Array.isArray(prev) ? prev.concat(val)
+ : Array.isArray(val) ? [prev].concat(val)
+ : [prev, val];
+ }
+
+ return this.set(field, value);
+};
+
+/**
+ * Set header `field` to `val`, or pass
+ * an object of header fields.
+ *
+ * Examples:
+ *
+ * res.set('Foo', ['bar', 'baz']);
+ * res.set('Accept', 'application/json');
+ * res.set({ Accept: 'text/plain', 'X-API-Key': 'tobi' });
+ *
+ * Aliased as `res.header()`.
+ *
+ * @param {String|Object} field
+ * @param {String|Array} val
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.set =
+res.header = function header(field, val) {
+ if (arguments.length === 2) {
+ var value = Array.isArray(val)
+ ? val.map(String)
+ : String(val);
+
+ // add charset to content-type
+ if (field.toLowerCase() === 'content-type' && !charsetRegExp.test(value)) {
+ var charset = mime.charsets.lookup(value.split(';')[0]);
+ if (charset) value += '; charset=' + charset.toLowerCase();
+ }
+
+ this.setHeader(field, value);
+ } else {
+ for (var key in field) {
+ this.set(key, field[key]);
+ }
+ }
+ return this;
+};
+
+/**
+ * Get value for header `field`.
+ *
+ * @param {String} field
+ * @return {String}
+ * @public
+ */
+
+res.get = function(field){
+ return this.getHeader(field);
+};
+
+/**
+ * Clear cookie `name`.
+ *
+ * @param {String} name
+ * @param {Object} [options]
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.clearCookie = function clearCookie(name, options) {
+ var opts = merge({ expires: new Date(1), path: '/' }, options);
+
+ return this.cookie(name, '', opts);
+};
+
+/**
+ * Set cookie `name` to `value`, with the given `options`.
+ *
+ * Options:
+ *
+ * - `maxAge` max-age in milliseconds, converted to `expires`
+ * - `signed` sign the cookie
+ * - `path` defaults to "/"
+ *
+ * Examples:
+ *
+ * // "Remember Me" for 15 minutes
+ * res.cookie('rememberme', '1', { expires: new Date(Date.now() + 900000), httpOnly: true });
+ *
+ * // save as above
+ * res.cookie('rememberme', '1', { maxAge: 900000, httpOnly: true })
+ *
+ * @param {String} name
+ * @param {String|Object} value
+ * @param {Options} options
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.cookie = function (name, value, options) {
+ var opts = merge({}, options);
+ var secret = this.req.secret;
+ var signed = opts.signed;
+
+ if (signed && !secret) {
+ throw new Error('cookieParser("secret") required for signed cookies');
+ }
+
+ var val = typeof value === 'object'
+ ? 'j:' + JSON.stringify(value)
+ : String(value);
+
+ if (signed) {
+ val = 's:' + sign(val, secret);
+ }
+
+ if ('maxAge' in opts) {
+ opts.expires = new Date(Date.now() + opts.maxAge);
+ opts.maxAge /= 1000;
+ }
+
+ if (opts.path == null) {
+ opts.path = '/';
+ }
+
+ this.append('Set-Cookie', cookie.serialize(name, String(val), opts));
+
+ return this;
+};
+
+/**
+ * Set the location header to `url`.
+ *
+ * The given `url` can also be "back", which redirects
+ * to the _Referrer_ or _Referer_ headers or "/".
+ *
+ * Examples:
+ *
+ * res.location('/foo/bar').;
+ * res.location('http://example.com');
+ * res.location('../login');
+ *
+ * @param {String} url
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.location = function location(url) {
+ var loc = url;
+
+ // "back" is an alias for the referrer
+ if (url === 'back') {
+ loc = this.req.get('Referrer') || '/';
+ }
+
+ // set location
+ return this.set('Location', encodeUrl(loc));
+};
+
+/**
+ * Redirect to the given `url` with optional response `status`
+ * defaulting to 302.
+ *
+ * The resulting `url` is determined by `res.location()`, so
+ * it will play nicely with mounted apps, relative paths,
+ * `"back"` etc.
+ *
+ * Examples:
+ *
+ * res.redirect('/foo/bar');
+ * res.redirect('http://example.com');
+ * res.redirect(301, 'http://example.com');
+ * res.redirect('../login'); // /blog/post/1 -> /blog/login
+ *
+ * @public
+ */
+
+res.redirect = function redirect(url) {
+ var address = url;
+ var body;
+ var status = 302;
+
+ // allow status / url
+ if (arguments.length === 2) {
+ if (typeof arguments[0] === 'number') {
+ status = arguments[0];
+ address = arguments[1];
+ } else {
+ deprecate('res.redirect(url, status): Use res.redirect(status, url) instead');
+ status = arguments[1];
+ }
+ }
+
+ // Set location header
+ address = this.location(address).get('Location');
+
+ // Support text/{plain,html} by default
+ this.format({
+ text: function(){
+ body = statusCodes[status] + '. Redirecting to ' + address;
+ },
+
+ html: function(){
+ var u = escapeHtml(address);
+ body = '' + statusCodes[status] + '. Redirecting to ' + u + '
';
+ },
+
+ default: function(){
+ body = '';
+ }
+ });
+
+ // Respond
+ this.statusCode = status;
+ this.set('Content-Length', Buffer.byteLength(body));
+
+ if (this.req.method === 'HEAD') {
+ this.end();
+ } else {
+ this.end(body);
+ }
+};
+
+/**
+ * Add `field` to Vary. If already present in the Vary set, then
+ * this call is simply ignored.
+ *
+ * @param {Array|String} field
+ * @return {ServerResponse} for chaining
+ * @public
+ */
+
+res.vary = function(field){
+ // checks for back-compat
+ if (!field || (Array.isArray(field) && !field.length)) {
+ deprecate('res.vary(): Provide a field name');
+ return this;
+ }
+
+ vary(this, field);
+
+ return this;
+};
+
+/**
+ * Render `view` with the given `options` and optional callback `fn`.
+ * When a callback function is given a response will _not_ be made
+ * automatically, otherwise a response of _200_ and _text/html_ is given.
+ *
+ * Options:
+ *
+ * - `cache` boolean hinting to the engine it should cache
+ * - `filename` filename of the view being rendered
+ *
+ * @public
+ */
+
+res.render = function render(view, options, callback) {
+ var app = this.req.app;
+ var done = callback;
+ var opts = options || {};
+ var req = this.req;
+ var self = this;
+
+ // support callback function as second arg
+ if (typeof options === 'function') {
+ done = options;
+ opts = {};
+ }
+
+ // merge res.locals
+ opts._locals = self.locals;
+
+ // default callback to respond
+ done = done || function (err, str) {
+ if (err) return req.next(err);
+ self.send(str);
+ };
+
+ // render
+ app.render(view, opts, done);
+};
+
+// pipe the send file stream
+function sendfile(res, file, options, callback) {
+ var done = false;
+ var streaming;
+
+ // request aborted
+ function onaborted() {
+ if (done) return;
+ done = true;
+
+ var err = new Error('Request aborted');
+ err.code = 'ECONNABORTED';
+ callback(err);
+ }
+
+ // directory
+ function ondirectory() {
+ if (done) return;
+ done = true;
+
+ var err = new Error('EISDIR, read');
+ err.code = 'EISDIR';
+ callback(err);
+ }
+
+ // errors
+ function onerror(err) {
+ if (done) return;
+ done = true;
+ callback(err);
+ }
+
+ // ended
+ function onend() {
+ if (done) return;
+ done = true;
+ callback();
+ }
+
+ // file
+ function onfile() {
+ streaming = false;
+ }
+
+ // finished
+ function onfinish(err) {
+ if (err && err.code === 'ECONNRESET') return onaborted();
+ if (err) return onerror(err);
+ if (done) return;
+
+ setImmediate(function () {
+ if (streaming !== false && !done) {
+ onaborted();
+ return;
+ }
+
+ if (done) return;
+ done = true;
+ callback();
+ });
+ }
+
+ // streaming
+ function onstream() {
+ streaming = true;
+ }
+
+ file.on('directory', ondirectory);
+ file.on('end', onend);
+ file.on('error', onerror);
+ file.on('file', onfile);
+ file.on('stream', onstream);
+ onFinished(res, onfinish);
+
+ if (options.headers) {
+ // set headers on successful transfer
+ file.on('headers', function headers(res) {
+ var obj = options.headers;
+ var keys = Object.keys(obj);
+
+ for (var i = 0; i < keys.length; i++) {
+ var k = keys[i];
+ res.setHeader(k, obj[k]);
+ }
+ });
+ }
+
+ // pipe
+ file.pipe(res);
+}
+
+/**
+ * Stringify JSON, like JSON.stringify, but v8 optimized.
+ * @private
+ */
+
+function stringify(value, replacer, spaces) {
+ // v8 checks arguments.length for optimizing simple call
+ // https://bugs.chromium.org/p/v8/issues/detail?id=4730
+ return replacer || spaces
+ ? JSON.stringify(value, replacer, spaces)
+ : JSON.stringify(value);
+}
diff --git a/node_modules/express/lib/router/index.js b/node_modules/express/lib/router/index.js
new file mode 100644
index 00000000..dac25148
--- /dev/null
+++ b/node_modules/express/lib/router/index.js
@@ -0,0 +1,645 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var Route = require('./route');
+var Layer = require('./layer');
+var methods = require('methods');
+var mixin = require('utils-merge');
+var debug = require('debug')('express:router');
+var deprecate = require('depd')('express');
+var flatten = require('array-flatten');
+var parseUrl = require('parseurl');
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var objectRegExp = /^\[object (\S+)\]$/;
+var slice = Array.prototype.slice;
+var toString = Object.prototype.toString;
+
+/**
+ * Initialize a new `Router` with the given `options`.
+ *
+ * @param {Object} options
+ * @return {Router} which is an callable function
+ * @public
+ */
+
+var proto = module.exports = function(options) {
+ var opts = options || {};
+
+ function router(req, res, next) {
+ router.handle(req, res, next);
+ }
+
+ // mixin Router class functions
+ router.__proto__ = proto;
+
+ router.params = {};
+ router._params = [];
+ router.caseSensitive = opts.caseSensitive;
+ router.mergeParams = opts.mergeParams;
+ router.strict = opts.strict;
+ router.stack = [];
+
+ return router;
+};
+
+/**
+ * Map the given param placeholder `name`(s) to the given callback.
+ *
+ * Parameter mapping is used to provide pre-conditions to routes
+ * which use normalized placeholders. For example a _:user_id_ parameter
+ * could automatically load a user's information from the database without
+ * any additional code,
+ *
+ * The callback uses the same signature as middleware, the only difference
+ * being that the value of the placeholder is passed, in this case the _id_
+ * of the user. Once the `next()` function is invoked, just like middleware
+ * it will continue on to execute the route, or subsequent parameter functions.
+ *
+ * Just like in middleware, you must either respond to the request or call next
+ * to avoid stalling the request.
+ *
+ * app.param('user_id', function(req, res, next, id){
+ * User.find(id, function(err, user){
+ * if (err) {
+ * return next(err);
+ * } else if (!user) {
+ * return next(new Error('failed to load user'));
+ * }
+ * req.user = user;
+ * next();
+ * });
+ * });
+ *
+ * @param {String} name
+ * @param {Function} fn
+ * @return {app} for chaining
+ * @public
+ */
+
+proto.param = function param(name, fn) {
+ // param logic
+ if (typeof name === 'function') {
+ deprecate('router.param(fn): Refactor to use path params');
+ this._params.push(name);
+ return;
+ }
+
+ // apply param functions
+ var params = this._params;
+ var len = params.length;
+ var ret;
+
+ if (name[0] === ':') {
+ deprecate('router.param(' + JSON.stringify(name) + ', fn): Use router.param(' + JSON.stringify(name.substr(1)) + ', fn) instead');
+ name = name.substr(1);
+ }
+
+ for (var i = 0; i < len; ++i) {
+ if (ret = params[i](name, fn)) {
+ fn = ret;
+ }
+ }
+
+ // ensure we end up with a
+ // middleware function
+ if ('function' !== typeof fn) {
+ throw new Error('invalid param() call for ' + name + ', got ' + fn);
+ }
+
+ (this.params[name] = this.params[name] || []).push(fn);
+ return this;
+};
+
+/**
+ * Dispatch a req, res into the router.
+ * @private
+ */
+
+proto.handle = function handle(req, res, out) {
+ var self = this;
+
+ debug('dispatching %s %s', req.method, req.url);
+
+ var search = 1 + req.url.indexOf('?');
+ var pathlength = search ? search - 1 : req.url.length;
+ var fqdn = req.url[0] !== '/' && 1 + req.url.substr(0, pathlength).indexOf('://');
+ var protohost = fqdn ? req.url.substr(0, req.url.indexOf('/', 2 + fqdn)) : '';
+ var idx = 0;
+ var removed = '';
+ var slashAdded = false;
+ var paramcalled = {};
+
+ // store options for OPTIONS request
+ // only used if OPTIONS request
+ var options = [];
+
+ // middleware and routes
+ var stack = self.stack;
+
+ // manage inter-router variables
+ var parentParams = req.params;
+ var parentUrl = req.baseUrl || '';
+ var done = restore(out, req, 'baseUrl', 'next', 'params');
+
+ // setup next layer
+ req.next = next;
+
+ // for options requests, respond with a default if nothing else responds
+ if (req.method === 'OPTIONS') {
+ done = wrap(done, function(old, err) {
+ if (err || options.length === 0) return old(err);
+ sendOptionsResponse(res, options, old);
+ });
+ }
+
+ // setup basic req values
+ req.baseUrl = parentUrl;
+ req.originalUrl = req.originalUrl || req.url;
+
+ next();
+
+ function next(err) {
+ var layerError = err === 'route'
+ ? null
+ : err;
+
+ // remove added slash
+ if (slashAdded) {
+ req.url = req.url.substr(1);
+ slashAdded = false;
+ }
+
+ // restore altered req.url
+ if (removed.length !== 0) {
+ req.baseUrl = parentUrl;
+ req.url = protohost + removed + req.url.substr(protohost.length);
+ removed = '';
+ }
+
+ // no more matching layers
+ if (idx >= stack.length) {
+ setImmediate(done, layerError);
+ return;
+ }
+
+ // get pathname of request
+ var path = getPathname(req);
+
+ if (path == null) {
+ return done(layerError);
+ }
+
+ // find next matching layer
+ var layer;
+ var match;
+ var route;
+
+ while (match !== true && idx < stack.length) {
+ layer = stack[idx++];
+ match = matchLayer(layer, path);
+ route = layer.route;
+
+ if (typeof match !== 'boolean') {
+ // hold on to layerError
+ layerError = layerError || match;
+ }
+
+ if (match !== true) {
+ continue;
+ }
+
+ if (!route) {
+ // process non-route handlers normally
+ continue;
+ }
+
+ if (layerError) {
+ // routes do not match with a pending error
+ match = false;
+ continue;
+ }
+
+ var method = req.method;
+ var has_method = route._handles_method(method);
+
+ // build up automatic options response
+ if (!has_method && method === 'OPTIONS') {
+ appendMethods(options, route._options());
+ }
+
+ // don't even bother matching route
+ if (!has_method && method !== 'HEAD') {
+ match = false;
+ continue;
+ }
+ }
+
+ // no match
+ if (match !== true) {
+ return done(layerError);
+ }
+
+ // store route for dispatch on change
+ if (route) {
+ req.route = route;
+ }
+
+ // Capture one-time layer values
+ req.params = self.mergeParams
+ ? mergeParams(layer.params, parentParams)
+ : layer.params;
+ var layerPath = layer.path;
+
+ // this should be done for the layer
+ self.process_params(layer, paramcalled, req, res, function (err) {
+ if (err) {
+ return next(layerError || err);
+ }
+
+ if (route) {
+ return layer.handle_request(req, res, next);
+ }
+
+ trim_prefix(layer, layerError, layerPath, path);
+ });
+ }
+
+ function trim_prefix(layer, layerError, layerPath, path) {
+ var c = path[layerPath.length];
+ if (c && '/' !== c && '.' !== c) return next(layerError);
+
+ // Trim off the part of the url that matches the route
+ // middleware (.use stuff) needs to have the path stripped
+ if (layerPath.length !== 0) {
+ debug('trim prefix (%s) from url %s', layerPath, req.url);
+ removed = layerPath;
+ req.url = protohost + req.url.substr(protohost.length + removed.length);
+
+ // Ensure leading slash
+ if (!fqdn && req.url[0] !== '/') {
+ req.url = '/' + req.url;
+ slashAdded = true;
+ }
+
+ // Setup base URL (no trailing slash)
+ req.baseUrl = parentUrl + (removed[removed.length - 1] === '/'
+ ? removed.substring(0, removed.length - 1)
+ : removed);
+ }
+
+ debug('%s %s : %s', layer.name, layerPath, req.originalUrl);
+
+ if (layerError) {
+ layer.handle_error(layerError, req, res, next);
+ } else {
+ layer.handle_request(req, res, next);
+ }
+ }
+};
+
+/**
+ * Process any parameters for the layer.
+ * @private
+ */
+
+proto.process_params = function process_params(layer, called, req, res, done) {
+ var params = this.params;
+
+ // captured parameters from the layer, keys and values
+ var keys = layer.keys;
+
+ // fast track
+ if (!keys || keys.length === 0) {
+ return done();
+ }
+
+ var i = 0;
+ var name;
+ var paramIndex = 0;
+ var key;
+ var paramVal;
+ var paramCallbacks;
+ var paramCalled;
+
+ // process params in order
+ // param callbacks can be async
+ function param(err) {
+ if (err) {
+ return done(err);
+ }
+
+ if (i >= keys.length ) {
+ return done();
+ }
+
+ paramIndex = 0;
+ key = keys[i++];
+
+ if (!key) {
+ return done();
+ }
+
+ name = key.name;
+ paramVal = req.params[name];
+ paramCallbacks = params[name];
+ paramCalled = called[name];
+
+ if (paramVal === undefined || !paramCallbacks) {
+ return param();
+ }
+
+ // param previously called with same value or error occurred
+ if (paramCalled && (paramCalled.match === paramVal
+ || (paramCalled.error && paramCalled.error !== 'route'))) {
+ // restore value
+ req.params[name] = paramCalled.value;
+
+ // next param
+ return param(paramCalled.error);
+ }
+
+ called[name] = paramCalled = {
+ error: null,
+ match: paramVal,
+ value: paramVal
+ };
+
+ paramCallback();
+ }
+
+ // single param callbacks
+ function paramCallback(err) {
+ var fn = paramCallbacks[paramIndex++];
+
+ // store updated value
+ paramCalled.value = req.params[key.name];
+
+ if (err) {
+ // store error
+ paramCalled.error = err;
+ param(err);
+ return;
+ }
+
+ if (!fn) return param();
+
+ try {
+ fn(req, res, paramCallback, paramVal, key.name);
+ } catch (e) {
+ paramCallback(e);
+ }
+ }
+
+ param();
+};
+
+/**
+ * Use the given middleware function, with optional path, defaulting to "/".
+ *
+ * Use (like `.all`) will run for any http METHOD, but it will not add
+ * handlers for those methods so OPTIONS requests will not consider `.use`
+ * functions even if they could respond.
+ *
+ * The other difference is that _route_ path is stripped and not visible
+ * to the handler function. The main effect of this feature is that mounted
+ * handlers can operate without any code changes regardless of the "prefix"
+ * pathname.
+ *
+ * @public
+ */
+
+proto.use = function use(fn) {
+ var offset = 0;
+ var path = '/';
+
+ // default path to '/'
+ // disambiguate router.use([fn])
+ if (typeof fn !== 'function') {
+ var arg = fn;
+
+ while (Array.isArray(arg) && arg.length !== 0) {
+ arg = arg[0];
+ }
+
+ // first arg is the path
+ if (typeof arg !== 'function') {
+ offset = 1;
+ path = fn;
+ }
+ }
+
+ var callbacks = flatten(slice.call(arguments, offset));
+
+ if (callbacks.length === 0) {
+ throw new TypeError('Router.use() requires middleware functions');
+ }
+
+ for (var i = 0; i < callbacks.length; i++) {
+ var fn = callbacks[i];
+
+ if (typeof fn !== 'function') {
+ throw new TypeError('Router.use() requires middleware function but got a ' + gettype(fn));
+ }
+
+ // add the middleware
+ debug('use %s %s', path, fn.name || '');
+
+ var layer = new Layer(path, {
+ sensitive: this.caseSensitive,
+ strict: false,
+ end: false
+ }, fn);
+
+ layer.route = undefined;
+
+ this.stack.push(layer);
+ }
+
+ return this;
+};
+
+/**
+ * Create a new Route for the given path.
+ *
+ * Each route contains a separate middleware stack and VERB handlers.
+ *
+ * See the Route api documentation for details on adding handlers
+ * and middleware to routes.
+ *
+ * @param {String} path
+ * @return {Route}
+ * @public
+ */
+
+proto.route = function route(path) {
+ var route = new Route(path);
+
+ var layer = new Layer(path, {
+ sensitive: this.caseSensitive,
+ strict: this.strict,
+ end: true
+ }, route.dispatch.bind(route));
+
+ layer.route = route;
+
+ this.stack.push(layer);
+ return route;
+};
+
+// create Router#VERB functions
+methods.concat('all').forEach(function(method){
+ proto[method] = function(path){
+ var route = this.route(path)
+ route[method].apply(route, slice.call(arguments, 1));
+ return this;
+ };
+});
+
+// append methods to a list of methods
+function appendMethods(list, addition) {
+ for (var i = 0; i < addition.length; i++) {
+ var method = addition[i];
+ if (list.indexOf(method) === -1) {
+ list.push(method);
+ }
+ }
+}
+
+// get pathname of request
+function getPathname(req) {
+ try {
+ return parseUrl(req).pathname;
+ } catch (err) {
+ return undefined;
+ }
+}
+
+// get type for error message
+function gettype(obj) {
+ var type = typeof obj;
+
+ if (type !== 'object') {
+ return type;
+ }
+
+ // inspect [[Class]] for objects
+ return toString.call(obj)
+ .replace(objectRegExp, '$1');
+}
+
+/**
+ * Match path to a layer.
+ *
+ * @param {Layer} layer
+ * @param {string} path
+ * @private
+ */
+
+function matchLayer(layer, path) {
+ try {
+ return layer.match(path);
+ } catch (err) {
+ return err;
+ }
+}
+
+// merge params with parent params
+function mergeParams(params, parent) {
+ if (typeof parent !== 'object' || !parent) {
+ return params;
+ }
+
+ // make copy of parent for base
+ var obj = mixin({}, parent);
+
+ // simple non-numeric merging
+ if (!(0 in params) || !(0 in parent)) {
+ return mixin(obj, params);
+ }
+
+ var i = 0;
+ var o = 0;
+
+ // determine numeric gaps
+ while (i in params) {
+ i++;
+ }
+
+ while (o in parent) {
+ o++;
+ }
+
+ // offset numeric indices in params before merge
+ for (i--; i >= 0; i--) {
+ params[i + o] = params[i];
+
+ // create holes for the merge when necessary
+ if (i < o) {
+ delete params[i];
+ }
+ }
+
+ return mixin(obj, params);
+}
+
+// restore obj props after function
+function restore(fn, obj) {
+ var props = new Array(arguments.length - 2);
+ var vals = new Array(arguments.length - 2);
+
+ for (var i = 0; i < props.length; i++) {
+ props[i] = arguments[i + 2];
+ vals[i] = obj[props[i]];
+ }
+
+ return function(err){
+ // restore vals
+ for (var i = 0; i < props.length; i++) {
+ obj[props[i]] = vals[i];
+ }
+
+ return fn.apply(this, arguments);
+ };
+}
+
+// send an OPTIONS response
+function sendOptionsResponse(res, options, next) {
+ try {
+ var body = options.join(',');
+ res.set('Allow', body);
+ res.send(body);
+ } catch (err) {
+ next(err);
+ }
+}
+
+// wrap a function
+function wrap(old, fn) {
+ return function proxy() {
+ var args = new Array(arguments.length + 1);
+
+ args[0] = old;
+ for (var i = 0, len = arguments.length; i < len; i++) {
+ args[i + 1] = arguments[i];
+ }
+
+ fn.apply(this, args);
+ };
+}
diff --git a/node_modules/express/lib/router/layer.js b/node_modules/express/lib/router/layer.js
new file mode 100644
index 00000000..fe9210cb
--- /dev/null
+++ b/node_modules/express/lib/router/layer.js
@@ -0,0 +1,176 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var pathRegexp = require('path-to-regexp');
+var debug = require('debug')('express:router:layer');
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var hasOwnProperty = Object.prototype.hasOwnProperty;
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = Layer;
+
+function Layer(path, options, fn) {
+ if (!(this instanceof Layer)) {
+ return new Layer(path, options, fn);
+ }
+
+ debug('new %s', path);
+ var opts = options || {};
+
+ this.handle = fn;
+ this.name = fn.name || '';
+ this.params = undefined;
+ this.path = undefined;
+ this.regexp = pathRegexp(path, this.keys = [], opts);
+
+ if (path === '/' && opts.end === false) {
+ this.regexp.fast_slash = true;
+ }
+}
+
+/**
+ * Handle the error for the layer.
+ *
+ * @param {Error} error
+ * @param {Request} req
+ * @param {Response} res
+ * @param {function} next
+ * @api private
+ */
+
+Layer.prototype.handle_error = function handle_error(error, req, res, next) {
+ var fn = this.handle;
+
+ if (fn.length !== 4) {
+ // not a standard error handler
+ return next(error);
+ }
+
+ try {
+ fn(error, req, res, next);
+ } catch (err) {
+ next(err);
+ }
+};
+
+/**
+ * Handle the request for the layer.
+ *
+ * @param {Request} req
+ * @param {Response} res
+ * @param {function} next
+ * @api private
+ */
+
+Layer.prototype.handle_request = function handle(req, res, next) {
+ var fn = this.handle;
+
+ if (fn.length > 3) {
+ // not a standard request handler
+ return next();
+ }
+
+ try {
+ fn(req, res, next);
+ } catch (err) {
+ next(err);
+ }
+};
+
+/**
+ * Check if this route matches `path`, if so
+ * populate `.params`.
+ *
+ * @param {String} path
+ * @return {Boolean}
+ * @api private
+ */
+
+Layer.prototype.match = function match(path) {
+ if (path == null) {
+ // no path, nothing matches
+ this.params = undefined;
+ this.path = undefined;
+ return false;
+ }
+
+ if (this.regexp.fast_slash) {
+ // fast path non-ending match for / (everything matches)
+ this.params = {};
+ this.path = '';
+ return true;
+ }
+
+ var m = this.regexp.exec(path);
+
+ if (!m) {
+ this.params = undefined;
+ this.path = undefined;
+ return false;
+ }
+
+ // store values
+ this.params = {};
+ this.path = m[0];
+
+ var keys = this.keys;
+ var params = this.params;
+
+ for (var i = 1; i < m.length; i++) {
+ var key = keys[i - 1];
+ var prop = key.name;
+ var val = decode_param(m[i]);
+
+ if (val !== undefined || !(hasOwnProperty.call(params, prop))) {
+ params[prop] = val;
+ }
+ }
+
+ return true;
+};
+
+/**
+ * Decode param value.
+ *
+ * @param {string} val
+ * @return {string}
+ * @private
+ */
+
+function decode_param(val) {
+ if (typeof val !== 'string' || val.length === 0) {
+ return val;
+ }
+
+ try {
+ return decodeURIComponent(val);
+ } catch (err) {
+ if (err instanceof URIError) {
+ err.message = 'Failed to decode param \'' + val + '\'';
+ err.status = err.statusCode = 400;
+ }
+
+ throw err;
+ }
+}
diff --git a/node_modules/express/lib/router/route.js b/node_modules/express/lib/router/route.js
new file mode 100644
index 00000000..2788d7b7
--- /dev/null
+++ b/node_modules/express/lib/router/route.js
@@ -0,0 +1,210 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var debug = require('debug')('express:router:route');
+var flatten = require('array-flatten');
+var Layer = require('./layer');
+var methods = require('methods');
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var slice = Array.prototype.slice;
+var toString = Object.prototype.toString;
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = Route;
+
+/**
+ * Initialize `Route` with the given `path`,
+ *
+ * @param {String} path
+ * @public
+ */
+
+function Route(path) {
+ this.path = path;
+ this.stack = [];
+
+ debug('new %s', path);
+
+ // route handlers for various http methods
+ this.methods = {};
+}
+
+/**
+ * Determine if the route handles a given method.
+ * @private
+ */
+
+Route.prototype._handles_method = function _handles_method(method) {
+ if (this.methods._all) {
+ return true;
+ }
+
+ var name = method.toLowerCase();
+
+ if (name === 'head' && !this.methods['head']) {
+ name = 'get';
+ }
+
+ return Boolean(this.methods[name]);
+};
+
+/**
+ * @return {Array} supported HTTP methods
+ * @private
+ */
+
+Route.prototype._options = function _options() {
+ var methods = Object.keys(this.methods);
+
+ // append automatic head
+ if (this.methods.get && !this.methods.head) {
+ methods.push('head');
+ }
+
+ for (var i = 0; i < methods.length; i++) {
+ // make upper case
+ methods[i] = methods[i].toUpperCase();
+ }
+
+ return methods;
+};
+
+/**
+ * dispatch req, res into this route
+ * @private
+ */
+
+Route.prototype.dispatch = function dispatch(req, res, done) {
+ var idx = 0;
+ var stack = this.stack;
+ if (stack.length === 0) {
+ return done();
+ }
+
+ var method = req.method.toLowerCase();
+ if (method === 'head' && !this.methods['head']) {
+ method = 'get';
+ }
+
+ req.route = this;
+
+ next();
+
+ function next(err) {
+ if (err && err === 'route') {
+ return done();
+ }
+
+ var layer = stack[idx++];
+ if (!layer) {
+ return done(err);
+ }
+
+ if (layer.method && layer.method !== method) {
+ return next(err);
+ }
+
+ if (err) {
+ layer.handle_error(err, req, res, next);
+ } else {
+ layer.handle_request(req, res, next);
+ }
+ }
+};
+
+/**
+ * Add a handler for all HTTP verbs to this route.
+ *
+ * Behaves just like middleware and can respond or call `next`
+ * to continue processing.
+ *
+ * You can use multiple `.all` call to add multiple handlers.
+ *
+ * function check_something(req, res, next){
+ * next();
+ * };
+ *
+ * function validate_user(req, res, next){
+ * next();
+ * };
+ *
+ * route
+ * .all(validate_user)
+ * .all(check_something)
+ * .get(function(req, res, next){
+ * res.send('hello world');
+ * });
+ *
+ * @param {function} handler
+ * @return {Route} for chaining
+ * @api public
+ */
+
+Route.prototype.all = function all() {
+ var handles = flatten(slice.call(arguments));
+
+ for (var i = 0; i < handles.length; i++) {
+ var handle = handles[i];
+
+ if (typeof handle !== 'function') {
+ var type = toString.call(handle);
+ var msg = 'Route.all() requires callback functions but got a ' + type;
+ throw new TypeError(msg);
+ }
+
+ var layer = Layer('/', {}, handle);
+ layer.method = undefined;
+
+ this.methods._all = true;
+ this.stack.push(layer);
+ }
+
+ return this;
+};
+
+methods.forEach(function(method){
+ Route.prototype[method] = function(){
+ var handles = flatten(slice.call(arguments));
+
+ for (var i = 0; i < handles.length; i++) {
+ var handle = handles[i];
+
+ if (typeof handle !== 'function') {
+ var type = toString.call(handle);
+ var msg = 'Route.' + method + '() requires callback functions but got a ' + type;
+ throw new Error(msg);
+ }
+
+ debug('%s %s', method, this.path);
+
+ var layer = Layer('/', {}, handle);
+ layer.method = method;
+
+ this.methods[method] = true;
+ this.stack.push(layer);
+ }
+
+ return this;
+ };
+});
diff --git a/node_modules/express/lib/utils.js b/node_modules/express/lib/utils.js
new file mode 100644
index 00000000..f418c580
--- /dev/null
+++ b/node_modules/express/lib/utils.js
@@ -0,0 +1,299 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @api private
+ */
+
+var contentDisposition = require('content-disposition');
+var contentType = require('content-type');
+var deprecate = require('depd')('express');
+var flatten = require('array-flatten');
+var mime = require('send').mime;
+var basename = require('path').basename;
+var etag = require('etag');
+var proxyaddr = require('proxy-addr');
+var qs = require('qs');
+var querystring = require('querystring');
+
+/**
+ * Return strong ETag for `body`.
+ *
+ * @param {String|Buffer} body
+ * @param {String} [encoding]
+ * @return {String}
+ * @api private
+ */
+
+exports.etag = function (body, encoding) {
+ var buf = !Buffer.isBuffer(body)
+ ? new Buffer(body, encoding)
+ : body;
+
+ return etag(buf, {weak: false});
+};
+
+/**
+ * Return weak ETag for `body`.
+ *
+ * @param {String|Buffer} body
+ * @param {String} [encoding]
+ * @return {String}
+ * @api private
+ */
+
+exports.wetag = function wetag(body, encoding){
+ var buf = !Buffer.isBuffer(body)
+ ? new Buffer(body, encoding)
+ : body;
+
+ return etag(buf, {weak: true});
+};
+
+/**
+ * Check if `path` looks absolute.
+ *
+ * @param {String} path
+ * @return {Boolean}
+ * @api private
+ */
+
+exports.isAbsolute = function(path){
+ if ('/' === path[0]) return true;
+ if (':' === path[1] && ('\\' === path[2] || '/' === path[2])) return true; // Windows device path
+ if ('\\\\' === path.substring(0, 2)) return true; // Microsoft Azure absolute path
+};
+
+/**
+ * Flatten the given `arr`.
+ *
+ * @param {Array} arr
+ * @return {Array}
+ * @api private
+ */
+
+exports.flatten = deprecate.function(flatten,
+ 'utils.flatten: use array-flatten npm module instead');
+
+/**
+ * Normalize the given `type`, for example "html" becomes "text/html".
+ *
+ * @param {String} type
+ * @return {Object}
+ * @api private
+ */
+
+exports.normalizeType = function(type){
+ return ~type.indexOf('/')
+ ? acceptParams(type)
+ : { value: mime.lookup(type), params: {} };
+};
+
+/**
+ * Normalize `types`, for example "html" becomes "text/html".
+ *
+ * @param {Array} types
+ * @return {Array}
+ * @api private
+ */
+
+exports.normalizeTypes = function(types){
+ var ret = [];
+
+ for (var i = 0; i < types.length; ++i) {
+ ret.push(exports.normalizeType(types[i]));
+ }
+
+ return ret;
+};
+
+/**
+ * Generate Content-Disposition header appropriate for the filename.
+ * non-ascii filenames are urlencoded and a filename* parameter is added
+ *
+ * @param {String} filename
+ * @return {String}
+ * @api private
+ */
+
+exports.contentDisposition = deprecate.function(contentDisposition,
+ 'utils.contentDisposition: use content-disposition npm module instead');
+
+/**
+ * Parse accept params `str` returning an
+ * object with `.value`, `.quality` and `.params`.
+ * also includes `.originalIndex` for stable sorting
+ *
+ * @param {String} str
+ * @return {Object}
+ * @api private
+ */
+
+function acceptParams(str, index) {
+ var parts = str.split(/ *; */);
+ var ret = { value: parts[0], quality: 1, params: {}, originalIndex: index };
+
+ for (var i = 1; i < parts.length; ++i) {
+ var pms = parts[i].split(/ *= */);
+ if ('q' === pms[0]) {
+ ret.quality = parseFloat(pms[1]);
+ } else {
+ ret.params[pms[0]] = pms[1];
+ }
+ }
+
+ return ret;
+}
+
+/**
+ * Compile "etag" value to function.
+ *
+ * @param {Boolean|String|Function} val
+ * @return {Function}
+ * @api private
+ */
+
+exports.compileETag = function(val) {
+ var fn;
+
+ if (typeof val === 'function') {
+ return val;
+ }
+
+ switch (val) {
+ case true:
+ fn = exports.wetag;
+ break;
+ case false:
+ break;
+ case 'strong':
+ fn = exports.etag;
+ break;
+ case 'weak':
+ fn = exports.wetag;
+ break;
+ default:
+ throw new TypeError('unknown value for etag function: ' + val);
+ }
+
+ return fn;
+}
+
+/**
+ * Compile "query parser" value to function.
+ *
+ * @param {String|Function} val
+ * @return {Function}
+ * @api private
+ */
+
+exports.compileQueryParser = function compileQueryParser(val) {
+ var fn;
+
+ if (typeof val === 'function') {
+ return val;
+ }
+
+ switch (val) {
+ case true:
+ fn = querystring.parse;
+ break;
+ case false:
+ fn = newObject;
+ break;
+ case 'extended':
+ fn = parseExtendedQueryString;
+ break;
+ case 'simple':
+ fn = querystring.parse;
+ break;
+ default:
+ throw new TypeError('unknown value for query parser function: ' + val);
+ }
+
+ return fn;
+}
+
+/**
+ * Compile "proxy trust" value to function.
+ *
+ * @param {Boolean|String|Number|Array|Function} val
+ * @return {Function}
+ * @api private
+ */
+
+exports.compileTrust = function(val) {
+ if (typeof val === 'function') return val;
+
+ if (val === true) {
+ // Support plain true/false
+ return function(){ return true };
+ }
+
+ if (typeof val === 'number') {
+ // Support trusting hop count
+ return function(a, i){ return i < val };
+ }
+
+ if (typeof val === 'string') {
+ // Support comma-separated values
+ val = val.split(/ *, */);
+ }
+
+ return proxyaddr.compile(val || []);
+}
+
+/**
+ * Set the charset in a given Content-Type string.
+ *
+ * @param {String} type
+ * @param {String} charset
+ * @return {String}
+ * @api private
+ */
+
+exports.setCharset = function setCharset(type, charset) {
+ if (!type || !charset) {
+ return type;
+ }
+
+ // parse type
+ var parsed = contentType.parse(type);
+
+ // set charset
+ parsed.parameters.charset = charset;
+
+ // format type
+ return contentType.format(parsed);
+};
+
+/**
+ * Parse an extended query string with qs.
+ *
+ * @return {Object}
+ * @private
+ */
+
+function parseExtendedQueryString(str) {
+ return qs.parse(str, {
+ allowPrototypes: true
+ });
+}
+
+/**
+ * Return new empty object.
+ *
+ * @return {Object}
+ * @api private
+ */
+
+function newObject() {
+ return {};
+}
diff --git a/node_modules/express/lib/view.js b/node_modules/express/lib/view.js
new file mode 100644
index 00000000..52415d4c
--- /dev/null
+++ b/node_modules/express/lib/view.js
@@ -0,0 +1,173 @@
+/*!
+ * express
+ * Copyright(c) 2009-2013 TJ Holowaychuk
+ * Copyright(c) 2013 Roman Shtylman
+ * Copyright(c) 2014-2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict';
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var debug = require('debug')('express:view');
+var path = require('path');
+var fs = require('fs');
+var utils = require('./utils');
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var dirname = path.dirname;
+var basename = path.basename;
+var extname = path.extname;
+var join = path.join;
+var resolve = path.resolve;
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = View;
+
+/**
+ * Initialize a new `View` with the given `name`.
+ *
+ * Options:
+ *
+ * - `defaultEngine` the default template engine name
+ * - `engines` template engine require() cache
+ * - `root` root path for view lookup
+ *
+ * @param {string} name
+ * @param {object} options
+ * @public
+ */
+
+function View(name, options) {
+ var opts = options || {};
+
+ this.defaultEngine = opts.defaultEngine;
+ this.ext = extname(name);
+ this.name = name;
+ this.root = opts.root;
+
+ if (!this.ext && !this.defaultEngine) {
+ throw new Error('No default engine was specified and no extension was provided.');
+ }
+
+ var fileName = name;
+
+ if (!this.ext) {
+ // get extension from default engine name
+ this.ext = this.defaultEngine[0] !== '.'
+ ? '.' + this.defaultEngine
+ : this.defaultEngine;
+
+ fileName += this.ext;
+ }
+
+ if (!opts.engines[this.ext]) {
+ // load engine
+ opts.engines[this.ext] = require(this.ext.substr(1)).__express;
+ }
+
+ // store loaded engine
+ this.engine = opts.engines[this.ext];
+
+ // lookup path
+ this.path = this.lookup(fileName);
+}
+
+/**
+ * Lookup view by the given `name`
+ *
+ * @param {string} name
+ * @private
+ */
+
+View.prototype.lookup = function lookup(name) {
+ var path;
+ var roots = [].concat(this.root);
+
+ debug('lookup "%s"', name);
+
+ for (var i = 0; i < roots.length && !path; i++) {
+ var root = roots[i];
+
+ // resolve the path
+ var loc = resolve(root, name);
+ var dir = dirname(loc);
+ var file = basename(loc);
+
+ // resolve the file
+ path = this.resolve(dir, file);
+ }
+
+ return path;
+};
+
+/**
+ * Render with the given options.
+ *
+ * @param {object} options
+ * @param {function} callback
+ * @private
+ */
+
+View.prototype.render = function render(options, callback) {
+ debug('render "%s"', this.path);
+ this.engine(this.path, options, callback);
+};
+
+/**
+ * Resolve the file within the given directory.
+ *
+ * @param {string} dir
+ * @param {string} file
+ * @private
+ */
+
+View.prototype.resolve = function resolve(dir, file) {
+ var ext = this.ext;
+
+ // .
+ var path = join(dir, file);
+ var stat = tryStat(path);
+
+ if (stat && stat.isFile()) {
+ return path;
+ }
+
+ // /index.
+ path = join(dir, basename(file, ext), 'index' + ext);
+ stat = tryStat(path);
+
+ if (stat && stat.isFile()) {
+ return path;
+ }
+};
+
+/**
+ * Return a stat, maybe.
+ *
+ * @param {string} path
+ * @return {fs.Stats}
+ * @private
+ */
+
+function tryStat(path) {
+ debug('stat "%s"', path);
+
+ try {
+ return fs.statSync(path);
+ } catch (e) {
+ return undefined;
+ }
+}
diff --git a/node_modules/express/node_modules/debug/.jshintrc b/node_modules/express/node_modules/debug/.jshintrc
new file mode 100644
index 00000000..299877f2
--- /dev/null
+++ b/node_modules/express/node_modules/debug/.jshintrc
@@ -0,0 +1,3 @@
+{
+ "laxbreak": true
+}
diff --git a/node_modules/express/node_modules/debug/.npmignore b/node_modules/express/node_modules/debug/.npmignore
new file mode 100644
index 00000000..7e6163db
--- /dev/null
+++ b/node_modules/express/node_modules/debug/.npmignore
@@ -0,0 +1,6 @@
+support
+test
+examples
+example
+*.sock
+dist
diff --git a/node_modules/express/node_modules/debug/History.md b/node_modules/express/node_modules/debug/History.md
new file mode 100644
index 00000000..854c9711
--- /dev/null
+++ b/node_modules/express/node_modules/debug/History.md
@@ -0,0 +1,195 @@
+
+2.2.0 / 2015-05-09
+==================
+
+ * package: update "ms" to v0.7.1 (#202, @dougwilson)
+ * README: add logging to file example (#193, @DanielOchoa)
+ * README: fixed a typo (#191, @amir-s)
+ * browser: expose `storage` (#190, @stephenmathieson)
+ * Makefile: add a `distclean` target (#189, @stephenmathieson)
+
+2.1.3 / 2015-03-13
+==================
+
+ * Updated stdout/stderr example (#186)
+ * Updated example/stdout.js to match debug current behaviour
+ * Renamed example/stderr.js to stdout.js
+ * Update Readme.md (#184)
+ * replace high intensity foreground color for bold (#182, #183)
+
+2.1.2 / 2015-03-01
+==================
+
+ * dist: recompile
+ * update "ms" to v0.7.0
+ * package: update "browserify" to v9.0.3
+ * component: fix "ms.js" repo location
+ * changed bower package name
+ * updated documentation about using debug in a browser
+ * fix: security error on safari (#167, #168, @yields)
+
+2.1.1 / 2014-12-29
+==================
+
+ * browser: use `typeof` to check for `console` existence
+ * browser: check for `console.log` truthiness (fix IE 8/9)
+ * browser: add support for Chrome apps
+ * Readme: added Windows usage remarks
+ * Add `bower.json` to properly support bower install
+
+2.1.0 / 2014-10-15
+==================
+
+ * node: implement `DEBUG_FD` env variable support
+ * package: update "browserify" to v6.1.0
+ * package: add "license" field to package.json (#135, @panuhorsmalahti)
+
+2.0.0 / 2014-09-01
+==================
+
+ * package: update "browserify" to v5.11.0
+ * node: use stderr rather than stdout for logging (#29, @stephenmathieson)
+
+1.0.4 / 2014-07-15
+==================
+
+ * dist: recompile
+ * example: remove `console.info()` log usage
+ * example: add "Content-Type" UTF-8 header to browser example
+ * browser: place %c marker after the space character
+ * browser: reset the "content" color via `color: inherit`
+ * browser: add colors support for Firefox >= v31
+ * debug: prefer an instance `log()` function over the global one (#119)
+ * Readme: update documentation about styled console logs for FF v31 (#116, @wryk)
+
+1.0.3 / 2014-07-09
+==================
+
+ * Add support for multiple wildcards in namespaces (#122, @seegno)
+ * browser: fix lint
+
+1.0.2 / 2014-06-10
+==================
+
+ * browser: update color palette (#113, @gscottolson)
+ * common: make console logging function configurable (#108, @timoxley)
+ * node: fix %o colors on old node <= 0.8.x
+ * Makefile: find node path using shell/which (#109, @timoxley)
+
+1.0.1 / 2014-06-06
+==================
+
+ * browser: use `removeItem()` to clear localStorage
+ * browser, node: don't set DEBUG if namespaces is undefined (#107, @leedm777)
+ * package: add "contributors" section
+ * node: fix comment typo
+ * README: list authors
+
+1.0.0 / 2014-06-04
+==================
+
+ * make ms diff be global, not be scope
+ * debug: ignore empty strings in enable()
+ * node: make DEBUG_COLORS able to disable coloring
+ * *: export the `colors` array
+ * npmignore: don't publish the `dist` dir
+ * Makefile: refactor to use browserify
+ * package: add "browserify" as a dev dependency
+ * Readme: add Web Inspector Colors section
+ * node: reset terminal color for the debug content
+ * node: map "%o" to `util.inspect()`
+ * browser: map "%j" to `JSON.stringify()`
+ * debug: add custom "formatters"
+ * debug: use "ms" module for humanizing the diff
+ * Readme: add "bash" syntax highlighting
+ * browser: add Firebug color support
+ * browser: add colors for WebKit browsers
+ * node: apply log to `console`
+ * rewrite: abstract common logic for Node & browsers
+ * add .jshintrc file
+
+0.8.1 / 2014-04-14
+==================
+
+ * package: re-add the "component" section
+
+0.8.0 / 2014-03-30
+==================
+
+ * add `enable()` method for nodejs. Closes #27
+ * change from stderr to stdout
+ * remove unnecessary index.js file
+
+0.7.4 / 2013-11-13
+==================
+
+ * remove "browserify" key from package.json (fixes something in browserify)
+
+0.7.3 / 2013-10-30
+==================
+
+ * fix: catch localStorage security error when cookies are blocked (Chrome)
+ * add debug(err) support. Closes #46
+ * add .browser prop to package.json. Closes #42
+
+0.7.2 / 2013-02-06
+==================
+
+ * fix package.json
+ * fix: Mobile Safari (private mode) is broken with debug
+ * fix: Use unicode to send escape character to shell instead of octal to work with strict mode javascript
+
+0.7.1 / 2013-02-05
+==================
+
+ * add repository URL to package.json
+ * add DEBUG_COLORED to force colored output
+ * add browserify support
+ * fix component. Closes #24
+
+0.7.0 / 2012-05-04
+==================
+
+ * Added .component to package.json
+ * Added debug.component.js build
+
+0.6.0 / 2012-03-16
+==================
+
+ * Added support for "-" prefix in DEBUG [Vinay Pulim]
+ * Added `.enabled` flag to the node version [TooTallNate]
+
+0.5.0 / 2012-02-02
+==================
+
+ * Added: humanize diffs. Closes #8
+ * Added `debug.disable()` to the CS variant
+ * Removed padding. Closes #10
+ * Fixed: persist client-side variant again. Closes #9
+
+0.4.0 / 2012-02-01
+==================
+
+ * Added browser variant support for older browsers [TooTallNate]
+ * Added `debug.enable('project:*')` to browser variant [TooTallNate]
+ * Added padding to diff (moved it to the right)
+
+0.3.0 / 2012-01-26
+==================
+
+ * Added millisecond diff when isatty, otherwise UTC string
+
+0.2.0 / 2012-01-22
+==================
+
+ * Added wildcard support
+
+0.1.0 / 2011-12-02
+==================
+
+ * Added: remove colors unless stderr isatty [TooTallNate]
+
+0.0.1 / 2010-01-03
+==================
+
+ * Initial release
diff --git a/node_modules/express/node_modules/debug/Makefile b/node_modules/express/node_modules/debug/Makefile
new file mode 100644
index 00000000..5cf4a596
--- /dev/null
+++ b/node_modules/express/node_modules/debug/Makefile
@@ -0,0 +1,36 @@
+
+# get Makefile directory name: http://stackoverflow.com/a/5982798/376773
+THIS_MAKEFILE_PATH:=$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
+THIS_DIR:=$(shell cd $(dir $(THIS_MAKEFILE_PATH));pwd)
+
+# BIN directory
+BIN := $(THIS_DIR)/node_modules/.bin
+
+# applications
+NODE ?= $(shell which node)
+NPM ?= $(NODE) $(shell which npm)
+BROWSERIFY ?= $(NODE) $(BIN)/browserify
+
+all: dist/debug.js
+
+install: node_modules
+
+clean:
+ @rm -rf dist
+
+dist:
+ @mkdir -p $@
+
+dist/debug.js: node_modules browser.js debug.js dist
+ @$(BROWSERIFY) \
+ --standalone debug \
+ . > $@
+
+distclean: clean
+ @rm -rf node_modules
+
+node_modules: package.json
+ @NODE_ENV= $(NPM) install
+ @touch node_modules
+
+.PHONY: all install clean distclean
diff --git a/node_modules/express/node_modules/debug/Readme.md b/node_modules/express/node_modules/debug/Readme.md
new file mode 100644
index 00000000..b4f45e3c
--- /dev/null
+++ b/node_modules/express/node_modules/debug/Readme.md
@@ -0,0 +1,188 @@
+# debug
+
+ tiny node.js debugging utility modelled after node core's debugging technique.
+
+## Installation
+
+```bash
+$ npm install debug
+```
+
+## Usage
+
+ With `debug` you simply invoke the exported function to generate your debug function, passing it a name which will determine if a noop function is returned, or a decorated `console.error`, so all of the `console` format string goodies you're used to work fine. A unique color is selected per-function for visibility.
+
+Example _app.js_:
+
+```js
+var debug = require('debug')('http')
+ , http = require('http')
+ , name = 'My App';
+
+// fake app
+
+debug('booting %s', name);
+
+http.createServer(function(req, res){
+ debug(req.method + ' ' + req.url);
+ res.end('hello\n');
+}).listen(3000, function(){
+ debug('listening');
+});
+
+// fake worker of some kind
+
+require('./worker');
+```
+
+Example _worker.js_:
+
+```js
+var debug = require('debug')('worker');
+
+setInterval(function(){
+ debug('doing some work');
+}, 1000);
+```
+
+ The __DEBUG__ environment variable is then used to enable these based on space or comma-delimited names. Here are some examples:
+
+ 
+
+ 
+
+#### Windows note
+
+ On Windows the environment variable is set using the `set` command.
+
+ ```cmd
+ set DEBUG=*,-not_this
+ ```
+
+Then, run the program to be debugged as usual.
+
+## Millisecond diff
+
+ When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls.
+
+ 
+
+ When stdout is not a TTY, `Date#toUTCString()` is used, making it more useful for logging the debug information as shown below:
+
+ 
+
+## Conventions
+
+ If you're using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser".
+
+## Wildcards
+
+ The `*` character may be used as a wildcard. Suppose for example your library has debuggers named "connect:bodyParser", "connect:compress", "connect:session", instead of listing all three with `DEBUG=connect:bodyParser,connect:compress,connect:session`, you may simply do `DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`.
+
+ You can also exclude specific debuggers by prefixing them with a "-" character. For example, `DEBUG=*,-connect:*` would include all debuggers except those starting with "connect:".
+
+## Browser support
+
+ Debug works in the browser as well, currently persisted by `localStorage`. Consider the situation shown below where you have `worker:a` and `worker:b`, and wish to debug both. Somewhere in the code on your page, include:
+
+```js
+window.myDebug = require("debug");
+```
+
+ ("debug" is a global object in the browser so we give this object a different name.) When your page is open in the browser, type the following in the console:
+
+```js
+myDebug.enable("worker:*")
+```
+
+ Refresh the page. Debug output will continue to be sent to the console until it is disabled by typing `myDebug.disable()` in the console.
+
+```js
+a = debug('worker:a');
+b = debug('worker:b');
+
+setInterval(function(){
+ a('doing some work');
+}, 1000);
+
+setInterval(function(){
+ b('doing some work');
+}, 1200);
+```
+
+#### Web Inspector Colors
+
+ Colors are also enabled on "Web Inspectors" that understand the `%c` formatting
+ option. These are WebKit web inspectors, Firefox ([since version
+ 31](https://hacks.mozilla.org/2014/05/editable-box-model-multiple-selection-sublime-text-keys-much-more-firefox-developer-tools-episode-31/))
+ and the Firebug plugin for Firefox (any version).
+
+ Colored output looks something like:
+
+ 
+
+### stderr vs stdout
+
+You can set an alternative logging method per-namespace by overriding the `log` method on a per-namespace or globally:
+
+Example _stdout.js_:
+
+```js
+var debug = require('debug');
+var error = debug('app:error');
+
+// by default stderr is used
+error('goes to stderr!');
+
+var log = debug('app:log');
+// set this namespace to log via console.log
+log.log = console.log.bind(console); // don't forget to bind to console!
+log('goes to stdout');
+error('still goes to stderr!');
+
+// set all output to go via console.info
+// overrides all per-namespace log settings
+debug.log = console.info.bind(console);
+error('now goes to stdout via console.info');
+log('still goes to stdout, but via console.info now');
+```
+
+### Save debug output to a file
+
+You can save all debug statements to a file by piping them.
+
+Example:
+
+```bash
+$ DEBUG_FD=3 node your-app.js 3> whatever.log
+```
+
+## Authors
+
+ - TJ Holowaychuk
+ - Nathan Rajlich
+
+## License
+
+(The MIT License)
+
+Copyright (c) 2014 TJ Holowaychuk <tj@vision-media.ca>
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/express/node_modules/debug/bower.json b/node_modules/express/node_modules/debug/bower.json
new file mode 100644
index 00000000..6af573ff
--- /dev/null
+++ b/node_modules/express/node_modules/debug/bower.json
@@ -0,0 +1,28 @@
+{
+ "name": "visionmedia-debug",
+ "main": "dist/debug.js",
+ "version": "2.2.0",
+ "homepage": "https://github.com/visionmedia/debug",
+ "authors": [
+ "TJ Holowaychuk "
+ ],
+ "description": "visionmedia-debug",
+ "moduleType": [
+ "amd",
+ "es6",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "visionmedia",
+ "debug"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests"
+ ]
+}
diff --git a/node_modules/express/node_modules/debug/browser.js b/node_modules/express/node_modules/debug/browser.js
new file mode 100644
index 00000000..7c764522
--- /dev/null
+++ b/node_modules/express/node_modules/debug/browser.js
@@ -0,0 +1,168 @@
+
+/**
+ * This is the web browser implementation of `debug()`.
+ *
+ * Expose `debug()` as the module.
+ */
+
+exports = module.exports = require('./debug');
+exports.log = log;
+exports.formatArgs = formatArgs;
+exports.save = save;
+exports.load = load;
+exports.useColors = useColors;
+exports.storage = 'undefined' != typeof chrome
+ && 'undefined' != typeof chrome.storage
+ ? chrome.storage.local
+ : localstorage();
+
+/**
+ * Colors.
+ */
+
+exports.colors = [
+ 'lightseagreen',
+ 'forestgreen',
+ 'goldenrod',
+ 'dodgerblue',
+ 'darkorchid',
+ 'crimson'
+];
+
+/**
+ * Currently only WebKit-based Web Inspectors, Firefox >= v31,
+ * and the Firebug extension (any Firefox version) are known
+ * to support "%c" CSS customizations.
+ *
+ * TODO: add a `localStorage` variable to explicitly enable/disable colors
+ */
+
+function useColors() {
+ // is webkit? http://stackoverflow.com/a/16459606/376773
+ return ('WebkitAppearance' in document.documentElement.style) ||
+ // is firebug? http://stackoverflow.com/a/398120/376773
+ (window.console && (console.firebug || (console.exception && console.table))) ||
+ // is firefox >= v31?
+ // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
+ (navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31);
+}
+
+/**
+ * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default.
+ */
+
+exports.formatters.j = function(v) {
+ return JSON.stringify(v);
+};
+
+
+/**
+ * Colorize log arguments if enabled.
+ *
+ * @api public
+ */
+
+function formatArgs() {
+ var args = arguments;
+ var useColors = this.useColors;
+
+ args[0] = (useColors ? '%c' : '')
+ + this.namespace
+ + (useColors ? ' %c' : ' ')
+ + args[0]
+ + (useColors ? '%c ' : ' ')
+ + '+' + exports.humanize(this.diff);
+
+ if (!useColors) return args;
+
+ var c = 'color: ' + this.color;
+ args = [args[0], c, 'color: inherit'].concat(Array.prototype.slice.call(args, 1));
+
+ // the final "%c" is somewhat tricky, because there could be other
+ // arguments passed either before or after the %c, so we need to
+ // figure out the correct index to insert the CSS into
+ var index = 0;
+ var lastC = 0;
+ args[0].replace(/%[a-z%]/g, function(match) {
+ if ('%%' === match) return;
+ index++;
+ if ('%c' === match) {
+ // we only are interested in the *last* %c
+ // (the user may have provided their own)
+ lastC = index;
+ }
+ });
+
+ args.splice(lastC, 0, c);
+ return args;
+}
+
+/**
+ * Invokes `console.log()` when available.
+ * No-op when `console.log` is not a "function".
+ *
+ * @api public
+ */
+
+function log() {
+ // this hackery is required for IE8/9, where
+ // the `console.log` function doesn't have 'apply'
+ return 'object' === typeof console
+ && console.log
+ && Function.prototype.apply.call(console.log, console, arguments);
+}
+
+/**
+ * Save `namespaces`.
+ *
+ * @param {String} namespaces
+ * @api private
+ */
+
+function save(namespaces) {
+ try {
+ if (null == namespaces) {
+ exports.storage.removeItem('debug');
+ } else {
+ exports.storage.debug = namespaces;
+ }
+ } catch(e) {}
+}
+
+/**
+ * Load `namespaces`.
+ *
+ * @return {String} returns the previously persisted debug modes
+ * @api private
+ */
+
+function load() {
+ var r;
+ try {
+ r = exports.storage.debug;
+ } catch(e) {}
+ return r;
+}
+
+/**
+ * Enable namespaces listed in `localStorage.debug` initially.
+ */
+
+exports.enable(load());
+
+/**
+ * Localstorage attempts to return the localstorage.
+ *
+ * This is necessary because safari throws
+ * when a user disables cookies/localstorage
+ * and you attempt to access it.
+ *
+ * @return {LocalStorage}
+ * @api private
+ */
+
+function localstorage(){
+ try {
+ return window.localStorage;
+ } catch (e) {}
+}
diff --git a/node_modules/express/node_modules/debug/component.json b/node_modules/express/node_modules/debug/component.json
new file mode 100644
index 00000000..ca106372
--- /dev/null
+++ b/node_modules/express/node_modules/debug/component.json
@@ -0,0 +1,19 @@
+{
+ "name": "debug",
+ "repo": "visionmedia/debug",
+ "description": "small debugging utility",
+ "version": "2.2.0",
+ "keywords": [
+ "debug",
+ "log",
+ "debugger"
+ ],
+ "main": "browser.js",
+ "scripts": [
+ "browser.js",
+ "debug.js"
+ ],
+ "dependencies": {
+ "rauchg/ms.js": "0.7.1"
+ }
+}
diff --git a/node_modules/express/node_modules/debug/debug.js b/node_modules/express/node_modules/debug/debug.js
new file mode 100644
index 00000000..7571a860
--- /dev/null
+++ b/node_modules/express/node_modules/debug/debug.js
@@ -0,0 +1,197 @@
+
+/**
+ * This is the common logic for both the Node.js and web browser
+ * implementations of `debug()`.
+ *
+ * Expose `debug()` as the module.
+ */
+
+exports = module.exports = debug;
+exports.coerce = coerce;
+exports.disable = disable;
+exports.enable = enable;
+exports.enabled = enabled;
+exports.humanize = require('ms');
+
+/**
+ * The currently active debug mode names, and names to skip.
+ */
+
+exports.names = [];
+exports.skips = [];
+
+/**
+ * Map of special "%n" handling functions, for the debug "format" argument.
+ *
+ * Valid key names are a single, lowercased letter, i.e. "n".
+ */
+
+exports.formatters = {};
+
+/**
+ * Previously assigned color.
+ */
+
+var prevColor = 0;
+
+/**
+ * Previous log timestamp.
+ */
+
+var prevTime;
+
+/**
+ * Select a color.
+ *
+ * @return {Number}
+ * @api private
+ */
+
+function selectColor() {
+ return exports.colors[prevColor++ % exports.colors.length];
+}
+
+/**
+ * Create a debugger with the given `namespace`.
+ *
+ * @param {String} namespace
+ * @return {Function}
+ * @api public
+ */
+
+function debug(namespace) {
+
+ // define the `disabled` version
+ function disabled() {
+ }
+ disabled.enabled = false;
+
+ // define the `enabled` version
+ function enabled() {
+
+ var self = enabled;
+
+ // set `diff` timestamp
+ var curr = +new Date();
+ var ms = curr - (prevTime || curr);
+ self.diff = ms;
+ self.prev = prevTime;
+ self.curr = curr;
+ prevTime = curr;
+
+ // add the `color` if not set
+ if (null == self.useColors) self.useColors = exports.useColors();
+ if (null == self.color && self.useColors) self.color = selectColor();
+
+ var args = Array.prototype.slice.call(arguments);
+
+ args[0] = exports.coerce(args[0]);
+
+ if ('string' !== typeof args[0]) {
+ // anything else let's inspect with %o
+ args = ['%o'].concat(args);
+ }
+
+ // apply any `formatters` transformations
+ var index = 0;
+ args[0] = args[0].replace(/%([a-z%])/g, function(match, format) {
+ // if we encounter an escaped % then don't increase the array index
+ if (match === '%%') return match;
+ index++;
+ var formatter = exports.formatters[format];
+ if ('function' === typeof formatter) {
+ var val = args[index];
+ match = formatter.call(self, val);
+
+ // now we need to remove `args[index]` since it's inlined in the `format`
+ args.splice(index, 1);
+ index--;
+ }
+ return match;
+ });
+
+ if ('function' === typeof exports.formatArgs) {
+ args = exports.formatArgs.apply(self, args);
+ }
+ var logFn = enabled.log || exports.log || console.log.bind(console);
+ logFn.apply(self, args);
+ }
+ enabled.enabled = true;
+
+ var fn = exports.enabled(namespace) ? enabled : disabled;
+
+ fn.namespace = namespace;
+
+ return fn;
+}
+
+/**
+ * Enables a debug mode by namespaces. This can include modes
+ * separated by a colon and wildcards.
+ *
+ * @param {String} namespaces
+ * @api public
+ */
+
+function enable(namespaces) {
+ exports.save(namespaces);
+
+ var split = (namespaces || '').split(/[\s,]+/);
+ var len = split.length;
+
+ for (var i = 0; i < len; i++) {
+ if (!split[i]) continue; // ignore empty strings
+ namespaces = split[i].replace(/\*/g, '.*?');
+ if (namespaces[0] === '-') {
+ exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$'));
+ } else {
+ exports.names.push(new RegExp('^' + namespaces + '$'));
+ }
+ }
+}
+
+/**
+ * Disable debug output.
+ *
+ * @api public
+ */
+
+function disable() {
+ exports.enable('');
+}
+
+/**
+ * Returns true if the given mode name is enabled, false otherwise.
+ *
+ * @param {String} name
+ * @return {Boolean}
+ * @api public
+ */
+
+function enabled(name) {
+ var i, len;
+ for (i = 0, len = exports.skips.length; i < len; i++) {
+ if (exports.skips[i].test(name)) {
+ return false;
+ }
+ }
+ for (i = 0, len = exports.names.length; i < len; i++) {
+ if (exports.names[i].test(name)) {
+ return true;
+ }
+ }
+ return false;
+}
+
+/**
+ * Coerce `val`.
+ *
+ * @param {Mixed} val
+ * @return {Mixed}
+ * @api private
+ */
+
+function coerce(val) {
+ if (val instanceof Error) return val.stack || val.message;
+ return val;
+}
diff --git a/node_modules/express/node_modules/debug/node.js b/node_modules/express/node_modules/debug/node.js
new file mode 100644
index 00000000..1d392a81
--- /dev/null
+++ b/node_modules/express/node_modules/debug/node.js
@@ -0,0 +1,209 @@
+
+/**
+ * Module dependencies.
+ */
+
+var tty = require('tty');
+var util = require('util');
+
+/**
+ * This is the Node.js implementation of `debug()`.
+ *
+ * Expose `debug()` as the module.
+ */
+
+exports = module.exports = require('./debug');
+exports.log = log;
+exports.formatArgs = formatArgs;
+exports.save = save;
+exports.load = load;
+exports.useColors = useColors;
+
+/**
+ * Colors.
+ */
+
+exports.colors = [6, 2, 3, 4, 5, 1];
+
+/**
+ * The file descriptor to write the `debug()` calls to.
+ * Set the `DEBUG_FD` env variable to override with another value. i.e.:
+ *
+ * $ DEBUG_FD=3 node script.js 3>debug.log
+ */
+
+var fd = parseInt(process.env.DEBUG_FD, 10) || 2;
+var stream = 1 === fd ? process.stdout :
+ 2 === fd ? process.stderr :
+ createWritableStdioStream(fd);
+
+/**
+ * Is stdout a TTY? Colored output is enabled when `true`.
+ */
+
+function useColors() {
+ var debugColors = (process.env.DEBUG_COLORS || '').trim().toLowerCase();
+ if (0 === debugColors.length) {
+ return tty.isatty(fd);
+ } else {
+ return '0' !== debugColors
+ && 'no' !== debugColors
+ && 'false' !== debugColors
+ && 'disabled' !== debugColors;
+ }
+}
+
+/**
+ * Map %o to `util.inspect()`, since Node doesn't do that out of the box.
+ */
+
+var inspect = (4 === util.inspect.length ?
+ // node <= 0.8.x
+ function (v, colors) {
+ return util.inspect(v, void 0, void 0, colors);
+ } :
+ // node > 0.8.x
+ function (v, colors) {
+ return util.inspect(v, { colors: colors });
+ }
+);
+
+exports.formatters.o = function(v) {
+ return inspect(v, this.useColors)
+ .replace(/\s*\n\s*/g, ' ');
+};
+
+/**
+ * Adds ANSI color escape codes if enabled.
+ *
+ * @api public
+ */
+
+function formatArgs() {
+ var args = arguments;
+ var useColors = this.useColors;
+ var name = this.namespace;
+
+ if (useColors) {
+ var c = this.color;
+
+ args[0] = ' \u001b[3' + c + ';1m' + name + ' '
+ + '\u001b[0m'
+ + args[0] + '\u001b[3' + c + 'm'
+ + ' +' + exports.humanize(this.diff) + '\u001b[0m';
+ } else {
+ args[0] = new Date().toUTCString()
+ + ' ' + name + ' ' + args[0];
+ }
+ return args;
+}
+
+/**
+ * Invokes `console.error()` with the specified arguments.
+ */
+
+function log() {
+ return stream.write(util.format.apply(this, arguments) + '\n');
+}
+
+/**
+ * Save `namespaces`.
+ *
+ * @param {String} namespaces
+ * @api private
+ */
+
+function save(namespaces) {
+ if (null == namespaces) {
+ // If you set a process.env field to null or undefined, it gets cast to the
+ // string 'null' or 'undefined'. Just delete instead.
+ delete process.env.DEBUG;
+ } else {
+ process.env.DEBUG = namespaces;
+ }
+}
+
+/**
+ * Load `namespaces`.
+ *
+ * @return {String} returns the previously persisted debug modes
+ * @api private
+ */
+
+function load() {
+ return process.env.DEBUG;
+}
+
+/**
+ * Copied from `node/src/node.js`.
+ *
+ * XXX: It's lame that node doesn't expose this API out-of-the-box. It also
+ * relies on the undocumented `tty_wrap.guessHandleType()` which is also lame.
+ */
+
+function createWritableStdioStream (fd) {
+ var stream;
+ var tty_wrap = process.binding('tty_wrap');
+
+ // Note stream._type is used for test-module-load-list.js
+
+ switch (tty_wrap.guessHandleType(fd)) {
+ case 'TTY':
+ stream = new tty.WriteStream(fd);
+ stream._type = 'tty';
+
+ // Hack to have stream not keep the event loop alive.
+ // See https://github.com/joyent/node/issues/1726
+ if (stream._handle && stream._handle.unref) {
+ stream._handle.unref();
+ }
+ break;
+
+ case 'FILE':
+ var fs = require('fs');
+ stream = new fs.SyncWriteStream(fd, { autoClose: false });
+ stream._type = 'fs';
+ break;
+
+ case 'PIPE':
+ case 'TCP':
+ var net = require('net');
+ stream = new net.Socket({
+ fd: fd,
+ readable: false,
+ writable: true
+ });
+
+ // FIXME Should probably have an option in net.Socket to create a
+ // stream from an existing fd which is writable only. But for now
+ // we'll just add this hack and set the `readable` member to false.
+ // Test: ./node test/fixtures/echo.js < /etc/passwd
+ stream.readable = false;
+ stream.read = null;
+ stream._type = 'pipe';
+
+ // FIXME Hack to have stream not keep the event loop alive.
+ // See https://github.com/joyent/node/issues/1726
+ if (stream._handle && stream._handle.unref) {
+ stream._handle.unref();
+ }
+ break;
+
+ default:
+ // Probably an error on in uv_guess_handle()
+ throw new Error('Implement me. Unknown stream file type!');
+ }
+
+ // For supporting legacy API we put the FD here.
+ stream.fd = fd;
+
+ stream._isStdio = true;
+
+ return stream;
+}
+
+/**
+ * Enable namespaces listed in `process.env.DEBUG` initially.
+ */
+
+exports.enable(load());
diff --git a/node_modules/express/node_modules/debug/package.json b/node_modules/express/node_modules/debug/package.json
new file mode 100644
index 00000000..19ca2c35
--- /dev/null
+++ b/node_modules/express/node_modules/debug/package.json
@@ -0,0 +1,106 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "debug@~2.2.0",
+ "scope": null,
+ "escapedName": "debug",
+ "name": "debug",
+ "rawSpec": "~2.2.0",
+ "spec": ">=2.2.0 <2.3.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express"
+ ]
+ ],
+ "_from": "debug@>=2.2.0 <2.3.0",
+ "_id": "debug@2.2.0",
+ "_inCache": true,
+ "_location": "/express/debug",
+ "_nodeVersion": "0.12.2",
+ "_npmUser": {
+ "name": "tootallnate",
+ "email": "nathan@tootallnate.net"
+ },
+ "_npmVersion": "2.7.4",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "debug@~2.2.0",
+ "scope": null,
+ "escapedName": "debug",
+ "name": "debug",
+ "rawSpec": "~2.2.0",
+ "spec": ">=2.2.0 <2.3.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/express"
+ ],
+ "_resolved": "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz",
+ "_shasum": "f87057e995b1a1f6ae6a4960664137bc56f039da",
+ "_shrinkwrap": null,
+ "_spec": "debug@~2.2.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express",
+ "author": {
+ "name": "TJ Holowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ "browser": "./browser.js",
+ "bugs": {
+ "url": "https://github.com/visionmedia/debug/issues"
+ },
+ "component": {
+ "scripts": {
+ "debug/index.js": "browser.js",
+ "debug/debug.js": "debug.js"
+ }
+ },
+ "contributors": [
+ {
+ "name": "Nathan Rajlich",
+ "email": "nathan@tootallnate.net",
+ "url": "http://n8.io"
+ }
+ ],
+ "dependencies": {
+ "ms": "0.7.1"
+ },
+ "description": "small debugging utility",
+ "devDependencies": {
+ "browserify": "9.0.3",
+ "mocha": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "f87057e995b1a1f6ae6a4960664137bc56f039da",
+ "tarball": "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz"
+ },
+ "gitHead": "b38458422b5aa8aa6d286b10dfe427e8a67e2b35",
+ "homepage": "https://github.com/visionmedia/debug",
+ "keywords": [
+ "debug",
+ "log",
+ "debugger"
+ ],
+ "license": "MIT",
+ "main": "./node.js",
+ "maintainers": [
+ {
+ "name": "tjholowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ {
+ "name": "tootallnate",
+ "email": "nathan@tootallnate.net"
+ }
+ ],
+ "name": "debug",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/visionmedia/debug.git"
+ },
+ "scripts": {},
+ "version": "2.2.0"
+}
diff --git a/node_modules/express/node_modules/ms/.npmignore b/node_modules/express/node_modules/ms/.npmignore
new file mode 100644
index 00000000..d1aa0ce4
--- /dev/null
+++ b/node_modules/express/node_modules/ms/.npmignore
@@ -0,0 +1,5 @@
+node_modules
+test
+History.md
+Makefile
+component.json
diff --git a/node_modules/express/node_modules/ms/History.md b/node_modules/express/node_modules/ms/History.md
new file mode 100644
index 00000000..32fdfc17
--- /dev/null
+++ b/node_modules/express/node_modules/ms/History.md
@@ -0,0 +1,66 @@
+
+0.7.1 / 2015-04-20
+==================
+
+ * prevent extraordinary long inputs (@evilpacket)
+ * Fixed broken readme link
+
+0.7.0 / 2014-11-24
+==================
+
+ * add time abbreviations, updated tests and readme for the new units
+ * fix example in the readme.
+ * add LICENSE file
+
+0.6.2 / 2013-12-05
+==================
+
+ * Adding repository section to package.json to suppress warning from NPM.
+
+0.6.1 / 2013-05-10
+==================
+
+ * fix singularization [visionmedia]
+
+0.6.0 / 2013-03-15
+==================
+
+ * fix minutes
+
+0.5.1 / 2013-02-24
+==================
+
+ * add component namespace
+
+0.5.0 / 2012-11-09
+==================
+
+ * add short formatting as default and .long option
+ * add .license property to component.json
+ * add version to component.json
+
+0.4.0 / 2012-10-22
+==================
+
+ * add rounding to fix crazy decimals
+
+0.3.0 / 2012-09-07
+==================
+
+ * fix `ms()` [visionmedia]
+
+0.2.0 / 2012-09-03
+==================
+
+ * add component.json [visionmedia]
+ * add days support [visionmedia]
+ * add hours support [visionmedia]
+ * add minutes support [visionmedia]
+ * add seconds support [visionmedia]
+ * add ms string support [visionmedia]
+ * refactor tests to facilitate ms(number) [visionmedia]
+
+0.1.0 / 2012-03-07
+==================
+
+ * Initial release
diff --git a/node_modules/express/node_modules/ms/LICENSE b/node_modules/express/node_modules/ms/LICENSE
new file mode 100644
index 00000000..6c07561b
--- /dev/null
+++ b/node_modules/express/node_modules/ms/LICENSE
@@ -0,0 +1,20 @@
+(The MIT License)
+
+Copyright (c) 2014 Guillermo Rauch
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/express/node_modules/ms/README.md b/node_modules/express/node_modules/ms/README.md
new file mode 100644
index 00000000..9b4fd035
--- /dev/null
+++ b/node_modules/express/node_modules/ms/README.md
@@ -0,0 +1,35 @@
+# ms.js: miliseconds conversion utility
+
+```js
+ms('2 days') // 172800000
+ms('1d') // 86400000
+ms('10h') // 36000000
+ms('2.5 hrs') // 9000000
+ms('2h') // 7200000
+ms('1m') // 60000
+ms('5s') // 5000
+ms('100') // 100
+```
+
+```js
+ms(60000) // "1m"
+ms(2 * 60000) // "2m"
+ms(ms('10 hours')) // "10h"
+```
+
+```js
+ms(60000, { long: true }) // "1 minute"
+ms(2 * 60000, { long: true }) // "2 minutes"
+ms(ms('10 hours'), { long: true }) // "10 hours"
+```
+
+- Node/Browser compatible. Published as [`ms`](https://www.npmjs.org/package/ms) in [NPM](http://nodejs.org/download).
+- If a number is supplied to `ms`, a string with a unit is returned.
+- If a string that contains the number is supplied, it returns it as
+a number (e.g: it returns `100` for `'100'`).
+- If you pass a string with a number and a valid unit, the number of
+equivalent ms is returned.
+
+## License
+
+MIT
diff --git a/node_modules/express/node_modules/ms/index.js b/node_modules/express/node_modules/ms/index.js
new file mode 100644
index 00000000..4f927716
--- /dev/null
+++ b/node_modules/express/node_modules/ms/index.js
@@ -0,0 +1,125 @@
+/**
+ * Helpers.
+ */
+
+var s = 1000;
+var m = s * 60;
+var h = m * 60;
+var d = h * 24;
+var y = d * 365.25;
+
+/**
+ * Parse or format the given `val`.
+ *
+ * Options:
+ *
+ * - `long` verbose formatting [false]
+ *
+ * @param {String|Number} val
+ * @param {Object} options
+ * @return {String|Number}
+ * @api public
+ */
+
+module.exports = function(val, options){
+ options = options || {};
+ if ('string' == typeof val) return parse(val);
+ return options.long
+ ? long(val)
+ : short(val);
+};
+
+/**
+ * Parse the given `str` and return milliseconds.
+ *
+ * @param {String} str
+ * @return {Number}
+ * @api private
+ */
+
+function parse(str) {
+ str = '' + str;
+ if (str.length > 10000) return;
+ var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(str);
+ if (!match) return;
+ var n = parseFloat(match[1]);
+ var type = (match[2] || 'ms').toLowerCase();
+ switch (type) {
+ case 'years':
+ case 'year':
+ case 'yrs':
+ case 'yr':
+ case 'y':
+ return n * y;
+ case 'days':
+ case 'day':
+ case 'd':
+ return n * d;
+ case 'hours':
+ case 'hour':
+ case 'hrs':
+ case 'hr':
+ case 'h':
+ return n * h;
+ case 'minutes':
+ case 'minute':
+ case 'mins':
+ case 'min':
+ case 'm':
+ return n * m;
+ case 'seconds':
+ case 'second':
+ case 'secs':
+ case 'sec':
+ case 's':
+ return n * s;
+ case 'milliseconds':
+ case 'millisecond':
+ case 'msecs':
+ case 'msec':
+ case 'ms':
+ return n;
+ }
+}
+
+/**
+ * Short format for `ms`.
+ *
+ * @param {Number} ms
+ * @return {String}
+ * @api private
+ */
+
+function short(ms) {
+ if (ms >= d) return Math.round(ms / d) + 'd';
+ if (ms >= h) return Math.round(ms / h) + 'h';
+ if (ms >= m) return Math.round(ms / m) + 'm';
+ if (ms >= s) return Math.round(ms / s) + 's';
+ return ms + 'ms';
+}
+
+/**
+ * Long format for `ms`.
+ *
+ * @param {Number} ms
+ * @return {String}
+ * @api private
+ */
+
+function long(ms) {
+ return plural(ms, d, 'day')
+ || plural(ms, h, 'hour')
+ || plural(ms, m, 'minute')
+ || plural(ms, s, 'second')
+ || ms + ' ms';
+}
+
+/**
+ * Pluralization helper.
+ */
+
+function plural(ms, n, name) {
+ if (ms < n) return;
+ if (ms < n * 1.5) return Math.floor(ms / n) + ' ' + name;
+ return Math.ceil(ms / n) + ' ' + name + 's';
+}
diff --git a/node_modules/express/node_modules/ms/package.json b/node_modules/express/node_modules/ms/package.json
new file mode 100644
index 00000000..e95346f1
--- /dev/null
+++ b/node_modules/express/node_modules/ms/package.json
@@ -0,0 +1,82 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "ms@0.7.1",
+ "scope": null,
+ "escapedName": "ms",
+ "name": "ms",
+ "rawSpec": "0.7.1",
+ "spec": "0.7.1",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express/node_modules/debug"
+ ]
+ ],
+ "_from": "ms@0.7.1",
+ "_id": "ms@0.7.1",
+ "_inCache": true,
+ "_location": "/express/ms",
+ "_nodeVersion": "0.12.2",
+ "_npmUser": {
+ "name": "rauchg",
+ "email": "rauchg@gmail.com"
+ },
+ "_npmVersion": "2.7.5",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "ms@0.7.1",
+ "scope": null,
+ "escapedName": "ms",
+ "name": "ms",
+ "rawSpec": "0.7.1",
+ "spec": "0.7.1",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/express/debug"
+ ],
+ "_resolved": "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz",
+ "_shasum": "9cd13c03adbff25b65effde7ce864ee952017098",
+ "_shrinkwrap": null,
+ "_spec": "ms@0.7.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express/node_modules/debug",
+ "bugs": {
+ "url": "https://github.com/guille/ms.js/issues"
+ },
+ "component": {
+ "scripts": {
+ "ms/index.js": "index.js"
+ }
+ },
+ "dependencies": {},
+ "description": "Tiny ms conversion utility",
+ "devDependencies": {
+ "expect.js": "*",
+ "mocha": "*",
+ "serve": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "9cd13c03adbff25b65effde7ce864ee952017098",
+ "tarball": "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz"
+ },
+ "gitHead": "713dcf26d9e6fd9dbc95affe7eff9783b7f1b909",
+ "homepage": "https://github.com/guille/ms.js",
+ "main": "./index",
+ "maintainers": [
+ {
+ "name": "rauchg",
+ "email": "rauchg@gmail.com"
+ }
+ ],
+ "name": "ms",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/guille/ms.js.git"
+ },
+ "scripts": {},
+ "version": "0.7.1"
+}
diff --git a/node_modules/express/package.json b/node_modules/express/package.json
new file mode 100644
index 00000000..b25ce286
--- /dev/null
+++ b/node_modules/express/package.json
@@ -0,0 +1,194 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "express@^4.13.3",
+ "scope": null,
+ "escapedName": "express",
+ "name": "express",
+ "rawSpec": "^4.13.3",
+ "spec": ">=4.13.3 <5.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/webpack-dev-server"
+ ]
+ ],
+ "_from": "express@>=4.13.3 <5.0.0",
+ "_id": "express@4.14.1",
+ "_inCache": true,
+ "_location": "/express",
+ "_nodeVersion": "4.6.1",
+ "_npmOperationalInternal": {
+ "host": "packages-18-east.internal.npmjs.com",
+ "tmp": "tmp/express-4.14.1.tgz_1485642795215_0.5481494057457894"
+ },
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "2.15.9",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "express@^4.13.3",
+ "scope": null,
+ "escapedName": "express",
+ "name": "express",
+ "rawSpec": "^4.13.3",
+ "spec": ">=4.13.3 <5.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/webpack-dev-server"
+ ],
+ "_resolved": "https://registry.npmjs.org/express/-/express-4.14.1.tgz",
+ "_shasum": "646c237f766f148c2120aff073817b9e4d7e0d33",
+ "_shrinkwrap": null,
+ "_spec": "express@^4.13.3",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/webpack-dev-server",
+ "author": {
+ "name": "TJ Holowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ "bugs": {
+ "url": "https://github.com/expressjs/express/issues"
+ },
+ "contributors": [
+ {
+ "name": "Aaron Heckmann",
+ "email": "aaron.heckmann+github@gmail.com"
+ },
+ {
+ "name": "Ciaran Jessup",
+ "email": "ciaranj@gmail.com"
+ },
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ },
+ {
+ "name": "Guillermo Rauch",
+ "email": "rauchg@gmail.com"
+ },
+ {
+ "name": "Jonathan Ong",
+ "email": "me@jongleberry.com"
+ },
+ {
+ "name": "Roman Shtylman",
+ "email": "shtylman+expressjs@gmail.com"
+ },
+ {
+ "name": "Young Jae Sim",
+ "email": "hanul@hanul.me"
+ }
+ ],
+ "dependencies": {
+ "accepts": "~1.3.3",
+ "array-flatten": "1.1.1",
+ "content-disposition": "0.5.2",
+ "content-type": "~1.0.2",
+ "cookie": "0.3.1",
+ "cookie-signature": "1.0.6",
+ "debug": "~2.2.0",
+ "depd": "~1.1.0",
+ "encodeurl": "~1.0.1",
+ "escape-html": "~1.0.3",
+ "etag": "~1.7.0",
+ "finalhandler": "0.5.1",
+ "fresh": "0.3.0",
+ "merge-descriptors": "1.0.1",
+ "methods": "~1.1.2",
+ "on-finished": "~2.3.0",
+ "parseurl": "~1.3.1",
+ "path-to-regexp": "0.1.7",
+ "proxy-addr": "~1.1.3",
+ "qs": "6.2.0",
+ "range-parser": "~1.2.0",
+ "send": "0.14.2",
+ "serve-static": "~1.11.2",
+ "type-is": "~1.6.14",
+ "utils-merge": "1.0.0",
+ "vary": "~1.1.0"
+ },
+ "description": "Fast, unopinionated, minimalist web framework",
+ "devDependencies": {
+ "after": "0.8.2",
+ "body-parser": "1.16.0",
+ "connect-redis": "~2.4.1",
+ "cookie-parser": "~1.4.3",
+ "cookie-session": "~1.2.0",
+ "ejs": "2.5.5",
+ "express-session": "1.15.0",
+ "istanbul": "0.4.5",
+ "jade": "~1.11.0",
+ "marked": "0.3.6",
+ "method-override": "~2.3.6",
+ "mocha": "3.2.0",
+ "morgan": "~1.7.0",
+ "multiparty": "4.1.3",
+ "should": "11.2.0",
+ "supertest": "1.2.0",
+ "vhost": "~3.0.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "646c237f766f148c2120aff073817b9e4d7e0d33",
+ "tarball": "https://registry.npmjs.org/express/-/express-4.14.1.tgz"
+ },
+ "engines": {
+ "node": ">= 0.10.0"
+ },
+ "files": [
+ "LICENSE",
+ "History.md",
+ "Readme.md",
+ "index.js",
+ "lib/"
+ ],
+ "gitHead": "0437c513f2dbc8d1dfc5a3e35fe35182bd3a671e",
+ "homepage": "http://expressjs.com/",
+ "keywords": [
+ "express",
+ "framework",
+ "sinatra",
+ "web",
+ "rest",
+ "restful",
+ "router",
+ "app",
+ "api"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ {
+ "name": "hacksparrow",
+ "email": "captain@hacksparrow.com"
+ },
+ {
+ "name": "jasnell",
+ "email": "jasnell@gmail.com"
+ },
+ {
+ "name": "mikeal",
+ "email": "mikeal.rogers@gmail.com"
+ }
+ ],
+ "name": "express",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/expressjs/express.git"
+ },
+ "scripts": {
+ "test": "mocha --require test/support/env --reporter spec --bail --check-leaks test/ test/acceptance/",
+ "test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --require test/support/env --reporter spec --check-leaks test/ test/acceptance/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/ test/acceptance/",
+ "test-tap": "mocha --require test/support/env --reporter tap --check-leaks test/ test/acceptance/"
+ },
+ "version": "4.14.1"
+}
diff --git a/node_modules/extglob/LICENSE b/node_modules/extglob/LICENSE
new file mode 100644
index 00000000..65f90aca
--- /dev/null
+++ b/node_modules/extglob/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2015, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/extglob/README.md b/node_modules/extglob/README.md
new file mode 100644
index 00000000..66644066
--- /dev/null
+++ b/node_modules/extglob/README.md
@@ -0,0 +1,88 @@
+# extglob [](http://badge.fury.io/js/extglob) [](https://travis-ci.org/jonschlinkert/extglob)
+
+> Convert extended globs to regex-compatible strings. Add (almost) the expressive power of regular expressions to glob patterns.
+
+Install with [npm](https://www.npmjs.com/)
+
+```sh
+$ npm i extglob --save
+```
+
+Used by [micromatch](https://github.com/jonschlinkert/micromatch).
+
+**Features**
+
+* Convert an extglob string to a regex-compatible string. **Only converts extglobs**, to handle full globs use [micromatch](https://github.com/jonschlinkert/micromatch).
+* Pass `{regex: true}` to return a regex
+* Handles nested patterns
+* More complete (and correct) support than [minimatch](https://github.com/isaacs/minimatch)
+
+## Usage
+
+```js
+var extglob = require('extglob');
+
+extglob('?(z)');
+//=> '(?:z)?'
+extglob('*(z)');
+//=> '(?:z)*'
+extglob('+(z)');
+//=> '(?:z)+'
+extglob('@(z)');
+//=> '(?:z)'
+extglob('!(z)');
+//=> '(?!^(?:(?!z)[^/]*?)).*$'
+```
+
+**Optionally return regex**
+
+```js
+extglob('!(z)', {regex: true});
+//=> /(?!^(?:(?!z)[^/]*?)).*$/
+```
+
+## Extglob patterns
+
+To learn more about how extglobs work, see the docs for [Bash pattern matching](https://www.gnu.org/software/bash/manual/html_node/Pattern-Matching.html):
+
+* `?(pattern)`: Match zero or one occurrence of the given pattern.
+* `*(pattern)`: Match zero or more occurrences of the given pattern.
+* `+(pattern)`: Match one or more occurrences of the given pattern.
+* `@(pattern)`: Match one of the given pattern.
+* `!(pattern)`: Match anything except one of the given pattern.
+
+## Related
+
+* [braces](https://github.com/jonschlinkert/braces): Fastest brace expansion for node.js, with the most complete support for the Bash 4.3 braces… [more](https://github.com/jonschlinkert/braces)
+* [expand-brackets](https://github.com/jonschlinkert/expand-brackets): Expand POSIX bracket expressions (character classes) in glob patterns.
+* [expand-range](https://github.com/jonschlinkert/expand-range): Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. See… [more](https://github.com/jonschlinkert/expand-range)
+* [fill-range](https://github.com/jonschlinkert/fill-range): Fill in a range of numbers or letters, optionally passing an increment or multiplier to… [more](https://github.com/jonschlinkert/fill-range)
+* [micromatch](https://github.com/jonschlinkert/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. Just… [more](https://github.com/jonschlinkert/micromatch)
+
+## Run tests
+
+Install dev dependencies:
+
+```sh
+$ npm i -d && npm test
+```
+
+## Contributing
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/extglob/issues/new)
+
+## Author
+
+**Jon Schlinkert**
+
++ [github/jonschlinkert](https://github.com/jonschlinkert)
++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+## License
+
+Copyright © 2015 Jon Schlinkert
+Released under the MIT license.
+
+***
+
+_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on August 01, 2015._
\ No newline at end of file
diff --git a/node_modules/extglob/index.js b/node_modules/extglob/index.js
new file mode 100644
index 00000000..2e774d4a
--- /dev/null
+++ b/node_modules/extglob/index.js
@@ -0,0 +1,178 @@
+/*!
+ * extglob
+ *
+ * Copyright (c) 2015, Jon Schlinkert.
+ * Licensed under the MIT License.
+ */
+
+'use strict';
+
+/**
+ * Module dependencies
+ */
+
+var isExtglob = require('is-extglob');
+var re, cache = {};
+
+/**
+ * Expose `extglob`
+ */
+
+module.exports = extglob;
+
+/**
+ * Convert the given extglob `string` to a regex-compatible
+ * string.
+ *
+ * ```js
+ * var extglob = require('extglob');
+ * extglob('!(a?(b))');
+ * //=> '(?!a(?:b)?)[^/]*?'
+ * ```
+ *
+ * @param {String} `str` The string to convert.
+ * @param {Object} `options`
+ * @option {Boolean} [options] `esc` If `false` special characters will not be escaped. Defaults to `true`.
+ * @option {Boolean} [options] `regex` If `true` a regular expression is returned instead of a string.
+ * @return {String}
+ * @api public
+ */
+
+
+function extglob(str, opts) {
+ opts = opts || {};
+ var o = {}, i = 0;
+
+ // fix common character reversals
+ // '*!(.js)' => '*.!(js)'
+ str = str.replace(/!\(([^\w*()])/g, '$1!(');
+
+ // support file extension negation
+ str = str.replace(/([*\/])\.!\([*]\)/g, function (m, ch) {
+ if (ch === '/') {
+ return escape('\\/[^.]+');
+ }
+ return escape('[^.]+');
+ });
+
+ // create a unique key for caching by
+ // combining the string and options
+ var key = str
+ + String(!!opts.regex)
+ + String(!!opts.contains)
+ + String(!!opts.escape);
+
+ if (cache.hasOwnProperty(key)) {
+ return cache[key];
+ }
+
+ if (!(re instanceof RegExp)) {
+ re = regex();
+ }
+
+ opts.negate = false;
+ var m;
+
+ while (m = re.exec(str)) {
+ var prefix = m[1];
+ var inner = m[3];
+ if (prefix === '!') {
+ opts.negate = true;
+ }
+
+ var id = '__EXTGLOB_' + (i++) + '__';
+ // use the prefix of the _last_ (outtermost) pattern
+ o[id] = wrap(inner, prefix, opts.escape);
+ str = str.split(m[0]).join(id);
+ }
+
+ var keys = Object.keys(o);
+ var len = keys.length;
+
+ // we have to loop again to allow us to convert
+ // patterns in reverse order (starting with the
+ // innermost/last pattern first)
+ while (len--) {
+ var prop = keys[len];
+ str = str.split(prop).join(o[prop]);
+ }
+
+ var result = opts.regex
+ ? toRegex(str, opts.contains, opts.negate)
+ : str;
+
+ result = result.split('.').join('\\.');
+
+ // cache the result and return it
+ return (cache[key] = result);
+}
+
+/**
+ * Convert `string` to a regex string.
+ *
+ * @param {String} `str`
+ * @param {String} `prefix` Character that determines how to wrap the string.
+ * @param {Boolean} `esc` If `false` special characters will not be escaped. Defaults to `true`.
+ * @return {String}
+ */
+
+function wrap(inner, prefix, esc) {
+ if (esc) inner = escape(inner);
+
+ switch (prefix) {
+ case '!':
+ return '(?!' + inner + ')[^/]' + (esc ? '%%%~' : '*?');
+ case '@':
+ return '(?:' + inner + ')';
+ case '+':
+ return '(?:' + inner + ')+';
+ case '*':
+ return '(?:' + inner + ')' + (esc ? '%%' : '*')
+ case '?':
+ return '(?:' + inner + '|)';
+ default:
+ return inner;
+ }
+}
+
+function escape(str) {
+ str = str.split('*').join('[^/]%%%~');
+ str = str.split('.').join('\\.');
+ return str;
+}
+
+/**
+ * extglob regex.
+ */
+
+function regex() {
+ return /(\\?[@?!+*$]\\?)(\(([^()]*?)\))/;
+}
+
+/**
+ * Negation regex
+ */
+
+function negate(str) {
+ return '(?!^' + str + ').*$';
+}
+
+/**
+ * Create the regex to do the matching. If
+ * the leading character in the `pattern` is `!`
+ * a negation regex is returned.
+ *
+ * @param {String} `pattern`
+ * @param {Boolean} `contains` Allow loose matching.
+ * @param {Boolean} `isNegated` True if the pattern is a negation pattern.
+ */
+
+function toRegex(pattern, contains, isNegated) {
+ var prefix = contains ? '^' : '';
+ var after = contains ? '$' : '';
+ pattern = ('(?:' + pattern + ')' + after);
+ if (isNegated) {
+ pattern = prefix + negate(pattern);
+ }
+ return new RegExp(prefix + pattern);
+}
diff --git a/node_modules/extglob/package.json b/node_modules/extglob/package.json
new file mode 100644
index 00000000..dca62c48
--- /dev/null
+++ b/node_modules/extglob/package.json
@@ -0,0 +1,116 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "extglob@^0.3.1",
+ "scope": null,
+ "escapedName": "extglob",
+ "name": "extglob",
+ "rawSpec": "^0.3.1",
+ "spec": ">=0.3.1 <0.4.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/micromatch"
+ ]
+ ],
+ "_from": "extglob@>=0.3.1 <0.4.0",
+ "_id": "extglob@0.3.2",
+ "_inCache": true,
+ "_location": "/extglob",
+ "_nodeVersion": "5.3.0",
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "3.3.12",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "extglob@^0.3.1",
+ "scope": null,
+ "escapedName": "extglob",
+ "name": "extglob",
+ "rawSpec": "^0.3.1",
+ "spec": ">=0.3.1 <0.4.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/micromatch"
+ ],
+ "_resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz",
+ "_shasum": "2e18ff3d2f49ab2765cec9023f011daa8d8349a1",
+ "_shrinkwrap": null,
+ "_spec": "extglob@^0.3.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/micromatch",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/extglob/issues"
+ },
+ "dependencies": {
+ "is-extglob": "^1.0.0"
+ },
+ "description": "Convert extended globs to regex-compatible strings. Add (almost) the expressive power of regular expressions to glob patterns.",
+ "devDependencies": {
+ "ansi-green": "^0.1.1",
+ "micromatch": "^2.1.6",
+ "minimatch": "^2.0.1",
+ "minimist": "^1.1.0",
+ "mocha": "*",
+ "should": "*",
+ "success-symbol": "^0.1.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "2e18ff3d2f49ab2765cec9023f011daa8d8349a1",
+ "tarball": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "8c3f38bbd9e0afaf31a87e411c0d15532434ef41",
+ "homepage": "https://github.com/jonschlinkert/extglob",
+ "keywords": [
+ "bash",
+ "extended",
+ "extglob",
+ "glob",
+ "ksh",
+ "match",
+ "wildcard"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ }
+ ],
+ "name": "extglob",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/jonschlinkert/extglob.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "related": {
+ "list": [
+ "micromatch",
+ "expand-brackets",
+ "braces",
+ "fill-range",
+ "expand-range"
+ ]
+ }
+ },
+ "version": "0.3.2"
+}
diff --git a/node_modules/eyes/LICENSE b/node_modules/eyes/LICENSE
new file mode 100644
index 00000000..a1edd93b
--- /dev/null
+++ b/node_modules/eyes/LICENSE
@@ -0,0 +1,20 @@
+Copyright (c) 2009 cloudhead
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/eyes/Makefile b/node_modules/eyes/Makefile
new file mode 100644
index 00000000..a121deaf
--- /dev/null
+++ b/node_modules/eyes/Makefile
@@ -0,0 +1,4 @@
+test:
+ @@node test/eyes-test.js
+
+.PHONY: test
diff --git a/node_modules/eyes/README.md b/node_modules/eyes/README.md
new file mode 100644
index 00000000..c4f6f769
--- /dev/null
+++ b/node_modules/eyes/README.md
@@ -0,0 +1,73 @@
+eyes
+====
+
+a customizable value inspector for Node.js
+
+synopsis
+--------
+
+I was tired of looking at cluttered output in the console -- something needed to be done,
+`sys.inspect()` didn't display regexps correctly, and was too verbose, and I had an hour or two to spare.
+So I decided to have some fun. _eyes_ were born.
+
+
+
+_example of the output of a user-customized eyes.js inspector_
+
+*eyes* also deals with circular objects in an intelligent way, and can pretty-print object literals.
+
+usage
+-----
+
+ var inspect = require('eyes').inspector({styles: {all: 'magenta'}});
+
+ inspect(something); // inspect with the settings passed to `inspector`
+
+or
+
+ var eyes = require('eyes');
+
+ eyes.inspect(something); // inspect with the default settings
+
+you can pass a _label_ to `inspect()`, to keep track of your inspections:
+
+ eyes.inspect(something, "a random value");
+
+If you want to return the output of eyes without printing it, you can set it up this way:
+
+ var inspect = require('eyes').inspector({ stream: null });
+
+ sys.puts(inspect({ something: 42 }));
+
+customization
+-------------
+
+These are the default styles and settings used by _eyes_.
+
+ styles: { // Styles applied to stdout
+ all: 'cyan', // Overall style applied to everything
+ label: 'underline', // Inspection labels, like 'array' in `array: [1, 2, 3]`
+ other: 'inverted', // Objects which don't have a literal representation, such as functions
+ key: 'bold', // The keys in object literals, like 'a' in `{a: 1}`
+ special: 'grey', // null, undefined...
+ string: 'green',
+ number: 'magenta',
+ bool: 'blue', // true false
+ regexp: 'green', // /\d+/
+ },
+
+ pretty: true, // Indent object literals
+ hideFunctions: false, // Don't output functions at all
+ stream: process.stdout, // Stream to write to, or null
+ maxLength: 2048 // Truncate output if longer
+
+You can overwrite them with your own, by passing a similar object to `inspector()` or `inspect()`.
+
+ var inspect = require('eyes').inspector({
+ styles: {
+ all: 'magenta',
+ special: 'bold'
+ },
+ maxLength: 512
+ });
+
diff --git a/node_modules/eyes/lib/eyes.js b/node_modules/eyes/lib/eyes.js
new file mode 100644
index 00000000..10d964b9
--- /dev/null
+++ b/node_modules/eyes/lib/eyes.js
@@ -0,0 +1,236 @@
+//
+// Eyes.js - a customizable value inspector for Node.js
+//
+// usage:
+//
+// var inspect = require('eyes').inspector({styles: {all: 'magenta'}});
+// inspect(something); // inspect with the settings passed to `inspector`
+//
+// or
+//
+// var eyes = require('eyes');
+// eyes.inspect(something); // inspect with the default settings
+//
+var eyes = exports,
+ stack = [];
+
+eyes.defaults = {
+ styles: { // Styles applied to stdout
+ all: 'cyan', // Overall style applied to everything
+ label: 'underline', // Inspection labels, like 'array' in `array: [1, 2, 3]`
+ other: 'inverted', // Objects which don't have a literal representation, such as functions
+ key: 'bold', // The keys in object literals, like 'a' in `{a: 1}`
+ special: 'grey', // null, undefined...
+ string: 'green',
+ number: 'magenta',
+ bool: 'blue', // true false
+ regexp: 'green', // /\d+/
+ },
+ pretty: true, // Indent object literals
+ hideFunctions: false,
+ showHidden: false,
+ stream: process.stdout,
+ maxLength: 2048 // Truncate output if longer
+};
+
+// Return a curried inspect() function, with the `options` argument filled in.
+eyes.inspector = function (options) {
+ var that = this;
+ return function (obj, label, opts) {
+ return that.inspect.call(that, obj, label,
+ merge(options || {}, opts || {}));
+ };
+};
+
+// If we have a `stream` defined, use it to print a styled string,
+// if not, we just return the stringified object.
+eyes.inspect = function (obj, label, options) {
+ options = merge(this.defaults, options || {});
+
+ if (options.stream) {
+ return this.print(stringify(obj, options), label, options);
+ } else {
+ return stringify(obj, options) + (options.styles ? '\033[39m' : '');
+ }
+};
+
+// Output using the 'stream', and an optional label
+// Loop through `str`, and truncate it after `options.maxLength` has been reached.
+// Because escape sequences are, at this point embeded within
+// the output string, we can't measure the length of the string
+// in a useful way, without separating what is an escape sequence,
+// versus a printable character (`c`). So we resort to counting the
+// length manually.
+eyes.print = function (str, label, options) {
+ for (var c = 0, i = 0; i < str.length; i++) {
+ if (str.charAt(i) === '\033') { i += 4 } // `4` because '\033[25m'.length + 1 == 5
+ else if (c === options.maxLength) {
+ str = str.slice(0, i - 1) + '…';
+ break;
+ } else { c++ }
+ }
+ return options.stream.write.call(options.stream, (label ?
+ this.stylize(label, options.styles.label, options.styles) + ': ' : '') +
+ this.stylize(str, options.styles.all, options.styles) + '\033[0m' + "\n");
+};
+
+// Apply a style to a string, eventually,
+// I'd like this to support passing multiple
+// styles.
+eyes.stylize = function (str, style, styles) {
+ var codes = {
+ 'bold' : [1, 22],
+ 'underline' : [4, 24],
+ 'inverse' : [7, 27],
+ 'cyan' : [36, 39],
+ 'magenta' : [35, 39],
+ 'blue' : [34, 39],
+ 'yellow' : [33, 39],
+ 'green' : [32, 39],
+ 'red' : [31, 39],
+ 'grey' : [90, 39]
+ }, endCode;
+
+ if (style && codes[style]) {
+ endCode = (codes[style][1] === 39 && styles.all) ? codes[styles.all][0]
+ : codes[style][1];
+ return '\033[' + codes[style][0] + 'm' + str +
+ '\033[' + endCode + 'm';
+ } else { return str }
+};
+
+// Convert any object to a string, ready for output.
+// When an 'array' or an 'object' are encountered, they are
+// passed to specialized functions, which can then recursively call
+// stringify().
+function stringify(obj, options) {
+ var that = this, stylize = function (str, style) {
+ return eyes.stylize(str, options.styles[style], options.styles)
+ }, index, result;
+
+ if ((index = stack.indexOf(obj)) !== -1) {
+ return stylize(new(Array)(stack.length - index + 1).join('.'), 'special');
+ }
+ stack.push(obj);
+
+ result = (function (obj) {
+ switch (typeOf(obj)) {
+ case "string" : obj = stringifyString(obj.indexOf("'") === -1 ? "'" + obj + "'"
+ : '"' + obj + '"');
+ return stylize(obj, 'string');
+ case "regexp" : return stylize('/' + obj.source + '/', 'regexp');
+ case "number" : return stylize(obj + '', 'number');
+ case "function" : return options.stream ? stylize("Function", 'other') : '[Function]';
+ case "null" : return stylize("null", 'special');
+ case "undefined": return stylize("undefined", 'special');
+ case "boolean" : return stylize(obj + '', 'bool');
+ case "date" : return stylize(obj.toUTCString());
+ case "array" : return stringifyArray(obj, options, stack.length);
+ case "object" : return stringifyObject(obj, options, stack.length);
+ }
+ })(obj);
+
+ stack.pop();
+ return result;
+};
+
+// Escape invisible characters in a string
+function stringifyString (str, options) {
+ return str.replace(/\\/g, '\\\\')
+ .replace(/\n/g, '\\n')
+ .replace(/[\u0001-\u001F]/g, function (match) {
+ return '\\0' + match[0].charCodeAt(0).toString(8);
+ });
+}
+
+// Convert an array to a string, such as [1, 2, 3].
+// This function calls stringify() for each of the elements
+// in the array.
+function stringifyArray(ary, options, level) {
+ var out = [];
+ var pretty = options.pretty && (ary.length > 4 || ary.some(function (o) {
+ return (o !== null && typeof(o) === 'object' && Object.keys(o).length > 0) ||
+ (Array.isArray(o) && o.length > 0);
+ }));
+ var ws = pretty ? '\n' + new(Array)(level * 4 + 1).join(' ') : ' ';
+
+ for (var i = 0; i < ary.length; i++) {
+ out.push(stringify(ary[i], options));
+ }
+
+ if (out.length === 0) {
+ return '[]';
+ } else {
+ return '[' + ws
+ + out.join(',' + (pretty ? ws : ' '))
+ + (pretty ? ws.slice(0, -4) : ws) +
+ ']';
+ }
+};
+
+// Convert an object to a string, such as {a: 1}.
+// This function calls stringify() for each of its values,
+// and does not output functions or prototype values.
+function stringifyObject(obj, options, level) {
+ var out = [];
+ var pretty = options.pretty && (Object.keys(obj).length > 2 ||
+ Object.keys(obj).some(function (k) { return typeof(obj[k]) === 'object' }));
+ var ws = pretty ? '\n' + new(Array)(level * 4 + 1).join(' ') : ' ';
+
+ var keys = options.showHidden ? Object.keys(obj) : Object.getOwnPropertyNames(obj);
+ keys.forEach(function (k) {
+ if (Object.prototype.hasOwnProperty.call(obj, k)
+ && !(obj[k] instanceof Function && options.hideFunctions)) {
+ out.push(eyes.stylize(k, options.styles.key, options.styles) + ': ' +
+ stringify(obj[k], options));
+ }
+ });
+
+ if (out.length === 0) {
+ return '{}';
+ } else {
+ return "{" + ws
+ + out.join(',' + (pretty ? ws : ' '))
+ + (pretty ? ws.slice(0, -4) : ws) +
+ "}";
+ }
+};
+
+// A better `typeof`
+function typeOf(value) {
+ var s = typeof(value),
+ types = [Object, Array, String, RegExp, Number, Function, Boolean, Date];
+
+ if (s === 'object' || s === 'function') {
+ if (value) {
+ types.forEach(function (t) {
+ if (value instanceof t) { s = t.name.toLowerCase() }
+ });
+ } else { s = 'null' }
+ }
+ return s;
+}
+
+function merge(/* variable args */) {
+ var objs = Array.prototype.slice.call(arguments);
+ var target = {};
+
+ objs.forEach(function (o) {
+ Object.keys(o).forEach(function (k) {
+ if (k === 'styles') {
+ if (! o.styles) {
+ target.styles = false;
+ } else {
+ target.styles = {}
+ for (var s in o.styles) {
+ target.styles[s] = o.styles[s];
+ }
+ }
+ } else {
+ target[k] = o[k];
+ }
+ });
+ });
+ return target;
+}
+
diff --git a/node_modules/eyes/package.json b/node_modules/eyes/package.json
new file mode 100644
index 00000000..a44feb8c
--- /dev/null
+++ b/node_modules/eyes/package.json
@@ -0,0 +1,95 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "eyes@0.1.x",
+ "scope": null,
+ "escapedName": "eyes",
+ "name": "eyes",
+ "rawSpec": "0.1.x",
+ "spec": ">=0.1.0 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/winston"
+ ]
+ ],
+ "_from": "eyes@>=0.1.0 <0.2.0",
+ "_id": "eyes@0.1.8",
+ "_inCache": true,
+ "_location": "/eyes",
+ "_npmUser": {
+ "name": "indexzero",
+ "email": "charlie.robbins@gmail.com"
+ },
+ "_npmVersion": "1.1.53",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "eyes@0.1.x",
+ "scope": null,
+ "escapedName": "eyes",
+ "name": "eyes",
+ "rawSpec": "0.1.x",
+ "spec": ">=0.1.0 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/winston"
+ ],
+ "_resolved": "https://registry.npmjs.org/eyes/-/eyes-0.1.8.tgz",
+ "_shasum": "62cf120234c683785d902348a800ef3e0cc20bc0",
+ "_shrinkwrap": null,
+ "_spec": "eyes@0.1.x",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/winston",
+ "author": {
+ "name": "Alexis Sellier",
+ "email": "self@cloudhead.net"
+ },
+ "contributors": [
+ {
+ "name": "Charlie Robbins",
+ "email": "charlie@nodejitsu.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "a customizable value inspector",
+ "devDependencies": {},
+ "directories": {
+ "lib": "./lib",
+ "test": "./test"
+ },
+ "dist": {
+ "shasum": "62cf120234c683785d902348a800ef3e0cc20bc0",
+ "tarball": "https://registry.npmjs.org/eyes/-/eyes-0.1.8.tgz"
+ },
+ "engines": {
+ "node": "> 0.1.90"
+ },
+ "keywords": [
+ "inspector",
+ "debug",
+ "inspect",
+ "print"
+ ],
+ "licenses": [
+ "MIT"
+ ],
+ "main": "./lib/eyes",
+ "maintainers": [
+ {
+ "name": "cloudhead",
+ "email": "self@cloudhead.net"
+ },
+ {
+ "name": "indexzero",
+ "email": "charlie.robbins@gmail.com"
+ }
+ ],
+ "name": "eyes",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "scripts": {
+ "test": "node test/*-test.js"
+ },
+ "url": "http://github.com/cloudhead/eyes.js",
+ "version": "0.1.8"
+}
diff --git a/node_modules/eyes/test/eyes-test.js b/node_modules/eyes/test/eyes-test.js
new file mode 100644
index 00000000..1f9606a2
--- /dev/null
+++ b/node_modules/eyes/test/eyes-test.js
@@ -0,0 +1,56 @@
+var util = require('util');
+var eyes = require('../lib/eyes');
+
+eyes.inspect({
+ number: 42,
+ string: "John Galt",
+ regexp: /[a-z]+/,
+ array: [99, 168, 'x', {}],
+ func: function () {},
+ bool: false,
+ nil: null,
+ undef: undefined,
+ object: {attr: []}
+}, "native types");
+
+eyes.inspect({
+ number: new(Number)(42),
+ string: new(String)("John Galt"),
+ regexp: new(RegExp)(/[a-z]+/),
+ array: new(Array)(99, 168, 'x', {}),
+ bool: new(Boolean)(false),
+ object: new(Object)({attr: []}),
+ date: new(Date)
+}, "wrapped types");
+
+var obj = {};
+obj.that = { self: obj };
+obj.self = obj;
+
+eyes.inspect(obj, "circular object");
+eyes.inspect({hello: 'moto'}, "small object");
+eyes.inspect({hello: new(Array)(6) }, "big object");
+eyes.inspect(["hello 'world'", 'hello "world"'], "quotes");
+eyes.inspect({
+ recommendations: [{
+ id: 'a7a6576c2c822c8e2bd81a27e41437d8',
+ key: [ 'spree', 3.764316258020699 ],
+ value: {
+ _id: 'a7a6576c2c822c8e2bd81a27e41437d8',
+ _rev: '1-2e2d2f7fd858c4a5984bcf809d22ed98',
+ type: 'domain',
+ domain: 'spree',
+ weight: 3.764316258020699,
+ product_id: 30
+ }
+ }]
+}, 'complex');
+
+eyes.inspect([null], "null in array");
+
+var inspect = eyes.inspector({ stream: null });
+
+util.puts(inspect('something', "something"));
+util.puts(inspect("something else"));
+
+util.puts(inspect(["no color"], null, { styles: false }));
diff --git a/node_modules/faye-websocket/CHANGELOG.md b/node_modules/faye-websocket/CHANGELOG.md
new file mode 100644
index 00000000..bab808ca
--- /dev/null
+++ b/node_modules/faye-websocket/CHANGELOG.md
@@ -0,0 +1,115 @@
+### 0.10.0 / 2015-07-08
+
+* Add the standard `code` and `reason` parameters to the `close` method
+
+### 0.9.4 / 2015-03-08
+
+* Don't send input to the driver before `start()` is called
+
+### 0.9.3 / 2015-02-19
+
+* Make sure the TCP socket is not left open when closing the connection
+
+### 0.9.2 / 2014-12-21
+
+* Only emit `error` once, and don't emit it after `close`
+
+### 0.9.1 / 2014-12-18
+
+* Check that all options to the WebSocket constructor are recognized
+
+### 0.9.0 / 2014-12-13
+
+* Allow protocol extensions to be passed into websocket-extensions
+
+### 0.8.1 / 2014-11-12
+
+* Send the correct hostname when upgrading a connection to TLS
+
+### 0.8.0 / 2014-11-08
+
+* Support connections via HTTP proxies
+* Close the connection cleanly if we're still waiting for a handshake response
+
+### 0.7.3 / 2014-10-04
+
+* Allow sockets to be closed when they are in any state other than `CLOSED`
+
+### 0.7.2 / 2013-12-29
+
+* Make sure the `close` event is emitted by clients on Node v0.10
+
+### 0.7.1 / 2013-12-03
+
+* Support the `maxLength` websocket-driver option
+* Make the client emit `error` events on network errors
+
+### 0.7.0 / 2013-09-09
+
+* Allow the server to send custom headers with EventSource responses
+
+### 0.6.1 / 2013-07-05
+
+* Add `ca` option to the client for specifying certificate authorities
+* Start the server driver asynchronously so that `onopen` handlers can be added
+
+### 0.6.0 / 2013-05-12
+
+* Add support for custom headers
+
+### 0.5.0 / 2013-05-05
+
+* Extract the protocol handlers into the `websocket-driver` library
+* Support the Node streaming API
+
+### 0.4.4 / 2013-02-14
+
+* Emit the `close` event if TCP is closed before CLOSE frame is acked
+
+### 0.4.3 / 2012-07-09
+
+* Add `Connection: close` to EventSource response
+* Handle situations where `request.socket` is undefined
+
+### 0.4.2 / 2012-04-06
+
+* Add WebSocket error code `1011`.
+* Handle URLs with no path correctly by sending `GET /`
+
+### 0.4.1 / 2012-02-26
+
+* Treat anything other than a `Buffer` as a string when calling `send()`
+
+### 0.4.0 / 2012-02-13
+
+* Add `ping()` method to server-side `WebSocket` and `EventSource`
+* Buffer `send()` calls until the draft-76 handshake is complete
+* Fix HTTPS problems on Node 0.7
+
+### 0.3.1 / 2012-01-16
+
+* Call `setNoDelay(true)` on `net.Socket` objects to reduce latency
+
+### 0.3.0 / 2012-01-13
+
+* Add support for `EventSource` connections
+
+### 0.2.0 / 2011-12-21
+
+* Add support for `Sec-WebSocket-Protocol` negotiation
+* Support `hixie-76` close frames and 75/76 ignored segments
+* Improve performance of HyBi parsing/framing functions
+* Decouple parsers from TCP and reduce write volume
+
+### 0.1.2 / 2011-12-05
+
+* Detect closed sockets on the server side when TCP connection breaks
+* Make `hixie-76` sockets work through HAProxy
+
+### 0.1.1 / 2011-11-30
+
+* Fix `addEventListener()` interface methods
+
+### 0.1.0 / 2011-11-27
+
+* Initial release, based on WebSocket components from Faye
diff --git a/node_modules/faye-websocket/README.md b/node_modules/faye-websocket/README.md
new file mode 100644
index 00000000..ff251e39
--- /dev/null
+++ b/node_modules/faye-websocket/README.md
@@ -0,0 +1,336 @@
+# faye-websocket
+
+* Travis CI build: [](http://travis-ci.org/faye/faye-websocket-node)
+* Autobahn tests: [server](http://faye.jcoglan.com/autobahn/servers/),
+ [client](http://faye.jcoglan.com/autobahn/clients/)
+
+This is a general-purpose WebSocket implementation extracted from the
+[Faye](http://faye.jcoglan.com) project. It provides classes for easily building
+WebSocket servers and clients in Node. It does not provide a server itself, but
+rather makes it easy to handle WebSocket connections within an existing
+[Node](http://nodejs.org/) application. It does not provide any abstraction
+other than the standard [WebSocket API](http://dev.w3.org/html5/websockets/).
+
+It also provides an abstraction for handling
+[EventSource](http://dev.w3.org/html5/eventsource/) connections, which are
+one-way connections that allow the server to push data to the client. They are
+based on streaming HTTP responses and can be easier to access via proxies than
+WebSockets.
+
+
+## Installation
+
+```
+$ npm install faye-websocket
+```
+
+
+## Handling WebSocket connections in Node
+
+You can handle WebSockets on the server side by listening for HTTP Upgrade
+requests, and creating a new socket for the request. This socket object exposes
+the usual WebSocket methods for receiving and sending messages. For example this
+is how you'd implement an echo server:
+
+```js
+var WebSocket = require('faye-websocket'),
+ http = require('http');
+
+var server = http.createServer();
+
+server.on('upgrade', function(request, socket, body) {
+ if (WebSocket.isWebSocket(request)) {
+ var ws = new WebSocket(request, socket, body);
+
+ ws.on('message', function(event) {
+ ws.send(event.data);
+ });
+
+ ws.on('close', function(event) {
+ console.log('close', event.code, event.reason);
+ ws = null;
+ });
+ }
+});
+
+server.listen(8000);
+```
+
+`WebSocket` objects are also duplex streams, so you could replace the
+`ws.on('message', ...)` line with:
+
+```js
+ ws.pipe(ws);
+```
+
+Note that under certain circumstances (notably a draft-76 client connecting
+through an HTTP proxy), the WebSocket handshake will not be complete after you
+call `new WebSocket()` because the server will not have received the entire
+handshake from the client yet. In this case, calls to `ws.send()` will buffer
+the message in memory until the handshake is complete, at which point any
+buffered messages will be sent to the client.
+
+If you need to detect when the WebSocket handshake is complete, you can use the
+`onopen` event.
+
+If the connection's protocol version supports it, you can call `ws.ping()` to
+send a ping message and wait for the client's response. This method takes a
+message string, and an optional callback that fires when a matching pong message
+is received. It returns `true` if and only if a ping message was sent. If the
+client does not support ping/pong, this method sends no data and returns
+`false`.
+
+```js
+ws.ping('Mic check, one, two', function() {
+ // fires when pong is received
+});
+```
+
+
+## Using the WebSocket client
+
+The client supports both the plain-text `ws` protocol and the encrypted `wss`
+protocol, and has exactly the same interface as a socket you would use in a web
+browser. On the wire it identifies itself as `hybi-13`.
+
+```js
+var WebSocket = require('faye-websocket'),
+ ws = new WebSocket.Client('ws://www.example.com/');
+
+ws.on('open', function(event) {
+ console.log('open');
+ ws.send('Hello, world!');
+});
+
+ws.on('message', function(event) {
+ console.log('message', event.data);
+});
+
+ws.on('close', function(event) {
+ console.log('close', event.code, event.reason);
+ ws = null;
+});
+```
+
+The WebSocket client also lets you inspect the status and headers of the
+handshake response via its `statusCode` and `headers` properties.
+
+To connect via a proxy, set the `proxy` option to the HTTP origin of the proxy,
+including any authorization information, custom headers and TLS config you
+require. Only the `origin` setting is required.
+
+```js
+var ws = new WebSocket.Client('ws://www.example.com/', [], {
+ proxy: {
+ origin: 'http://username:password@proxy.example.com',
+ headers: {'User-Agent': 'node'},
+ tls: {cert: fs.readFileSync('client.crt')}
+ }
+});
+```
+
+The `tls` value is a Node 'TLS options' object that will be passed to
+[`tls.connect()`](http://nodejs.org/api/tls.html#tls_tls_connect_options_callback).
+
+
+## Subprotocol negotiation
+
+The WebSocket protocol allows peers to select and identify the application
+protocol to use over the connection. On the client side, you can set which
+protocols the client accepts by passing a list of protocol names when you
+construct the socket:
+
+```js
+var ws = new WebSocket.Client('ws://www.example.com/', ['irc', 'amqp']);
+```
+
+On the server side, you can likewise pass in the list of protocols the server
+supports after the other constructor arguments:
+
+```js
+var ws = new WebSocket(request, socket, body, ['irc', 'amqp']);
+```
+
+If the client and server agree on a protocol, both the client- and server-side
+socket objects expose the selected protocol through the `ws.protocol` property.
+
+
+## Protocol extensions
+
+faye-websocket is based on the
+[websocket-extensions](https://github.com/faye/websocket-extensions-node)
+framework that allows extensions to be negotiated via the
+`Sec-WebSocket-Extensions` header. To add extensions to a connection, pass an
+array of extensions to the `:extensions` option. For example, to add
+[permessage-deflate](https://github.com/faye/permessage-deflate-node):
+
+```js
+var deflate = require('permessage-deflate');
+
+var ws = new WebSocket(request, socket, body, [], {extensions: [deflate]});
+```
+
+
+## Initialization options
+
+Both the server- and client-side classes allow an options object to be passed in
+at initialization time, for example:
+
+```js
+var ws = new WebSocket(request, socket, body, protocols, options);
+var ws = new WebSocket.Client(url, protocols, options);
+```
+
+`protocols` is an array of subprotocols as described above, or `null`.
+`options` is an optional object containing any of these fields:
+
+* `extensions` - an array of
+ [websocket-extensions](https://github.com/faye/websocket-extensions-node)
+ compatible extensions, as described above
+* `headers` - an object containing key-value pairs representing HTTP headers to
+ be sent during the handshake process
+* `maxLength` - the maximum allowed size of incoming message frames, in bytes.
+ The default value is `2^26 - 1`, or 1 byte short of 64 MiB.
+* `ping` - an integer that sets how often the WebSocket should send ping frames,
+ measured in seconds
+
+The client accepts some additional options:
+
+* `proxy` - settings for a proxy as described above
+* `tls` - a Node 'TLS options' object containing TLS settings for the origin
+ server, this will be passed to
+ [`tls.connect()`](http://nodejs.org/api/tls.html#tls_tls_connect_options_callback)
+* `ca` - (legacy) a shorthand for passing `{tls: {ca: value}}`
+
+
+## WebSocket API
+
+Both server- and client-side `WebSocket` objects support the following API.
+
+* `on('open', function(event) {})` fires when the socket connection is
+ established. Event has no attributes.
+* `on('message', function(event) {})` fires when the socket receives a
+ message. Event has one attribute, `data` , which is either a `String`
+ (for text frames) or a `Buffer` (for binary frames).
+* `on('error', function(event) {})` fires when there is a protocol error
+ due to bad data sent by the other peer. This event is purely informational,
+ you do not need to implement error recover.
+* `on('close', function(event) {})` fires when either the client or the
+ server closes the connection. Event has two optional attributes, `code`
+ and `reason` , that expose the status code and message sent by the peer
+ that closed the connection.
+* `send(message)` accepts either a `String` or a `Buffer` and sends a
+ text or binary message over the connection to the other peer.
+* `ping(message, function() {})` sends a ping frame with an optional
+ message and fires the callback when a matching pong is received.
+* `close(code, reason)` closes the connection, sending the given status
+ code and reason text, both of which are optional.
+* `version` is a string containing the version of the `WebSocket`
+ protocol the connection is using.
+* `protocol` is a string (which may be empty) identifying the subprotocol
+ the socket is using.
+
+
+## Handling EventSource connections in Node
+
+EventSource connections provide a very similar interface, although because they
+only allow the server to send data to the client, there is no `onmessage` API.
+EventSource allows the server to push text messages to the client, where each
+message has an optional event-type and ID.
+
+```js
+var WebSocket = require('faye-websocket'),
+ EventSource = WebSocket.EventSource,
+ http = require('http');
+
+var server = http.createServer();
+
+server.on('request', function(request, response) {
+ if (EventSource.isEventSource(request)) {
+ var es = new EventSource(request, response);
+ console.log('open', es.url, es.lastEventId);
+
+ // Periodically send messages
+ var loop = setInterval(function() { es.send('Hello') }, 1000);
+
+ es.on('close', function() {
+ clearInterval(loop);
+ es = null;
+ });
+
+ } else {
+ // Normal HTTP request
+ response.writeHead(200, {'Content-Type': 'text/plain'});
+ response.end('Hello');
+ }
+});
+
+server.listen(8000);
+```
+
+The `send` method takes two optional parameters, `event` and `id`. The default
+event-type is `'message'` with no ID. For example, to send a `notification`
+event with ID `99`:
+
+```js
+es.send('Breaking News!', {event: 'notification', id: '99'});
+```
+
+The `EventSource` object exposes the following properties:
+
+* `url` is a string containing the URL the client used to create the
+ EventSource.
+* `lastEventId` is a string containing the last event ID received by the
+ client. You can use this when the client reconnects after a dropped connection
+ to determine which messages need resending.
+
+When you initialize an EventSource with ` new EventSource()`, you can pass
+configuration options after the `response` parameter. Available options are:
+
+* `headers` is an object containing custom headers to be set on the
+ EventSource response.
+* `retry` is a number that tells the client how long (in seconds) it
+ should wait after a dropped connection before attempting to reconnect.
+* `ping` is a number that tells the server how often (in seconds) to send
+ 'ping' packets to the client to keep the connection open, to defeat timeouts
+ set by proxies. The client will ignore these messages.
+
+For example, this creates a connection that allows access from any origin, pings
+every 15 seconds and is retryable every 10 seconds if the connection is broken:
+
+```js
+var es = new EventSource(request, response, {
+ headers: {'Access-Control-Allow-Origin': '*'},
+ ping: 15,
+ retry: 10
+});
+```
+
+You can send a ping message at any time by calling `es.ping()`. Unlike
+WebSocket, the client does not send a response to this; it is merely to send
+some data over the wire to keep the connection alive.
+
+
+## License
+
+(The MIT License)
+
+Copyright (c) 2010-2015 James Coglan
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the 'Software'), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/faye-websocket/examples/autobahn_client.js b/node_modules/faye-websocket/examples/autobahn_client.js
new file mode 100644
index 00000000..0059b219
--- /dev/null
+++ b/node_modules/faye-websocket/examples/autobahn_client.js
@@ -0,0 +1,39 @@
+var WebSocket = require('..').Client,
+ deflate = require('permessage-deflate'),
+ pace = require('pace');
+
+var host = 'ws://localhost:9001',
+ agent = encodeURIComponent('node-' + process.version),
+ cases = 0,
+ options = {extensions: [deflate]};
+
+var socket = new WebSocket(host + '/getCaseCount'),
+ url, progress;
+
+socket.onmessage = function(event) {
+ console.log('Total cases to run: ' + event.data);
+ cases = parseInt(event.data);
+ progress = pace(cases);
+};
+
+var runCase = function(n) {
+ if (n > cases) {
+ url = host + '/updateReports?agent=' + agent;
+ socket = new WebSocket(url);
+ socket.onclose = process.exit;
+ return;
+ }
+
+ url = host + '/runCase?case=' + n + '&agent=' + agent;
+ socket = new WebSocket(url, [], options);
+ socket.pipe(socket);
+
+ socket.on('close', function() {
+ progress.op();
+ runCase(n + 1);
+ });
+};
+
+socket.onclose = function() {
+ runCase(1);
+};
diff --git a/node_modules/faye-websocket/examples/client.js b/node_modules/faye-websocket/examples/client.js
new file mode 100644
index 00000000..7d12039f
--- /dev/null
+++ b/node_modules/faye-websocket/examples/client.js
@@ -0,0 +1,32 @@
+var WebSocket = require('..').Client,
+ deflate = require('permessage-deflate'),
+ fs = require('fs');
+
+var url = process.argv[2],
+ proxy = process.argv[3],
+ ca = fs.readFileSync(__dirname + '/../spec/server.crt'),
+ tls = {ca: ca};
+
+var ws = new WebSocket(url, [], {
+ proxy: {origin: proxy, headers: {'User-Agent': 'Echo'}, tls: tls},
+ tls: tls,
+ headers: {Origin: 'http://faye.jcoglan.com'},
+ extensions: [deflate]
+});
+
+ws.onopen = function() {
+ console.log('[open]', ws.headers);
+ ws.send('mic check');
+};
+
+ws.onclose = function(close) {
+ console.log('[close]', close.code, close.reason);
+};
+
+ws.onerror = function(error) {
+ console.log('[error]', error.message);
+};
+
+ws.onmessage = function(message) {
+ console.log('[message]', message.data);
+};
diff --git a/node_modules/faye-websocket/examples/haproxy.conf b/node_modules/faye-websocket/examples/haproxy.conf
new file mode 100644
index 00000000..bb7bc9d5
--- /dev/null
+++ b/node_modules/faye-websocket/examples/haproxy.conf
@@ -0,0 +1,20 @@
+defaults
+ mode http
+ timeout client 5s
+ timeout connect 5s
+ timeout server 5s
+
+frontend all 0.0.0.0:3000
+ mode http
+ timeout client 120s
+
+ option forwardfor
+ option http-server-close
+ option http-pretend-keepalive
+
+ default_backend sockets
+
+backend sockets
+ balance uri depth 2
+ timeout server 120s
+ server socket1 127.0.0.1:7000
diff --git a/node_modules/faye-websocket/examples/proxy_server.js b/node_modules/faye-websocket/examples/proxy_server.js
new file mode 100644
index 00000000..5780440b
--- /dev/null
+++ b/node_modules/faye-websocket/examples/proxy_server.js
@@ -0,0 +1,7 @@
+var ProxyServer = require('../spec/proxy_server');
+
+var port = process.argv[2],
+ secure = process.argv[3] === 'tls',
+ proxy = new ProxyServer({debug: true, tls: secure});
+
+proxy.listen(port);
diff --git a/node_modules/faye-websocket/examples/server.js b/node_modules/faye-websocket/examples/server.js
new file mode 100644
index 00000000..c2cfa325
--- /dev/null
+++ b/node_modules/faye-websocket/examples/server.js
@@ -0,0 +1,69 @@
+var WebSocket = require('..'),
+ deflate = require('permessage-deflate'),
+ fs = require('fs'),
+ http = require('http'),
+ https = require('https');
+
+var port = process.argv[2] || 7000,
+ secure = process.argv[3] === 'tls',
+ options = {extensions: [deflate], ping: 5};
+
+var upgradeHandler = function(request, socket, head) {
+ var ws = new WebSocket(request, socket, head, ['irc', 'xmpp'], options);
+ console.log('[open]', ws.url, ws.version, ws.protocol, request.headers);
+
+ ws.pipe(ws);
+
+ ws.onclose = function(event) {
+ console.log('[close]', event.code, event.reason);
+ ws = null;
+ };
+};
+
+var requestHandler = function(request, response) {
+ if (!WebSocket.EventSource.isEventSource(request))
+ return staticHandler(request, response);
+
+ var es = new WebSocket.EventSource(request, response),
+ time = parseInt(es.lastEventId, 10) || 0;
+
+ console.log('[open]', es.url, es.lastEventId);
+
+ var loop = setInterval(function() {
+ time += 1;
+ es.send('Time: ' + time);
+ setTimeout(function() {
+ if (es) es.send('Update!!', {event: 'update', id: time});
+ }, 1000);
+ }, 2000);
+
+ fs.createReadStream(__dirname + '/haproxy.conf').pipe(es, {end: false});
+
+ es.onclose = function() {
+ clearInterval(loop);
+ console.log('[close]', es.url);
+ es = null;
+ };
+};
+
+var staticHandler = function(request, response) {
+ var path = request.url;
+
+ fs.readFile(__dirname + path, function(err, content) {
+ var status = err ? 404 : 200;
+ response.writeHead(status, {'Content-Type': 'text/html'});
+ response.write(content || 'Not found');
+ response.end();
+ });
+};
+
+var server = secure
+ ? https.createServer({
+ key: fs.readFileSync(__dirname + '/../spec/server.key'),
+ cert: fs.readFileSync(__dirname + '/../spec/server.crt')
+ })
+ : http.createServer();
+
+server.on('request', requestHandler);
+server.on('upgrade', upgradeHandler);
+server.listen(port);
diff --git a/node_modules/faye-websocket/examples/sse.html b/node_modules/faye-websocket/examples/sse.html
new file mode 100644
index 00000000..e11a9114
--- /dev/null
+++ b/node_modules/faye-websocket/examples/sse.html
@@ -0,0 +1,38 @@
+
+
+
+
+ EventSource test
+
+
+
+ EventSource test
+
+
+
+
+
+
diff --git a/node_modules/faye-websocket/examples/ws.html b/node_modules/faye-websocket/examples/ws.html
new file mode 100644
index 00000000..883cdede
--- /dev/null
+++ b/node_modules/faye-websocket/examples/ws.html
@@ -0,0 +1,43 @@
+
+
+
+
+ WebSocket test
+
+
+
+ WebSocket test
+
+
+
+
+
+
diff --git a/node_modules/faye-websocket/lib/faye/eventsource.js b/node_modules/faye-websocket/lib/faye/eventsource.js
new file mode 100644
index 00000000..6e3f370d
--- /dev/null
+++ b/node_modules/faye-websocket/lib/faye/eventsource.js
@@ -0,0 +1,131 @@
+var Stream = require('stream').Stream,
+ util = require('util'),
+ driver = require('websocket-driver'),
+ Headers = require('websocket-driver/lib/websocket/driver/headers'),
+ API = require('./websocket/api'),
+ EventTarget = require('./websocket/api/event_target'),
+ Event = require('./websocket/api/event');
+
+var EventSource = function(request, response, options) {
+ this.writable = true;
+ options = options || {};
+
+ this._stream = response.socket;
+ this._ping = options.ping || this.DEFAULT_PING;
+ this._retry = options.retry || this.DEFAULT_RETRY;
+
+ var scheme = driver.isSecureRequest(request) ? 'https:' : 'http:';
+ this.url = scheme + '//' + request.headers.host + request.url;
+ this.lastEventId = request.headers['last-event-id'] || '';
+ this.readyState = API.CONNECTING;
+
+ var headers = new Headers(),
+ self = this;
+
+ if (options.headers) {
+ for (var key in options.headers) headers.set(key, options.headers[key]);
+ }
+
+ if (!this._stream || !this._stream.writable) return;
+ process.nextTick(function() { self._open() });
+
+ this._stream.setTimeout(0);
+ this._stream.setNoDelay(true);
+
+ var handshake = 'HTTP/1.1 200 OK\r\n' +
+ 'Content-Type: text/event-stream\r\n' +
+ 'Cache-Control: no-cache, no-store\r\n' +
+ 'Connection: close\r\n' +
+ headers.toString() +
+ '\r\n' +
+ 'retry: ' + Math.floor(this._retry * 1000) + '\r\n\r\n';
+
+ this._write(handshake);
+
+ this._stream.on('drain', function() { self.emit('drain') });
+
+ if (this._ping)
+ this._pingTimer = setInterval(function() { self.ping() }, this._ping * 1000);
+
+ ['error', 'end'].forEach(function(event) {
+ self._stream.on(event, function() { self.close() });
+ });
+};
+util.inherits(EventSource, Stream);
+
+EventSource.isEventSource = function(request) {
+ if (request.method !== 'GET') return false;
+ var accept = (request.headers.accept || '').split(/\s*,\s*/);
+ return accept.indexOf('text/event-stream') >= 0;
+};
+
+var instance = {
+ DEFAULT_PING: 10,
+ DEFAULT_RETRY: 5,
+
+ _write: function(chunk) {
+ if (!this.writable) return false;
+ try {
+ return this._stream.write(chunk, 'utf8');
+ } catch (e) {
+ return false;
+ }
+ },
+
+ _open: function() {
+ if (this.readyState !== API.CONNECTING) return;
+
+ this.readyState = API.OPEN;
+
+ var event = new Event('open');
+ event.initEvent('open', false, false);
+ this.dispatchEvent(event);
+ },
+
+ write: function(message) {
+ return this.send(message);
+ },
+
+ end: function(message) {
+ if (message !== undefined) this.write(message);
+ this.close();
+ },
+
+ send: function(message, options) {
+ if (this.readyState > API.OPEN) return false;
+
+ message = String(message).replace(/(\r\n|\r|\n)/g, '$1data: ');
+ options = options || {};
+
+ var frame = '';
+ if (options.event) frame += 'event: ' + options.event + '\r\n';
+ if (options.id) frame += 'id: ' + options.id + '\r\n';
+ frame += 'data: ' + message + '\r\n\r\n';
+
+ return this._write(frame);
+ },
+
+ ping: function() {
+ return this._write(':\r\n\r\n');
+ },
+
+ close: function() {
+ if (this.readyState > API.OPEN) return false;
+
+ this.readyState = API.CLOSED;
+ this.writable = false;
+ if (this._pingTimer) clearInterval(this._pingTimer);
+ if (this._stream) this._stream.end();
+
+ var event = new Event('close');
+ event.initEvent('close', false, false);
+ this.dispatchEvent(event);
+
+ return true;
+ }
+};
+
+for (var method in instance) EventSource.prototype[method] = instance[method];
+for (var key in EventTarget) EventSource.prototype[key] = EventTarget[key];
+
+module.exports = EventSource;
diff --git a/node_modules/faye-websocket/lib/faye/websocket.js b/node_modules/faye-websocket/lib/faye/websocket.js
new file mode 100644
index 00000000..bfb0ae2c
--- /dev/null
+++ b/node_modules/faye-websocket/lib/faye/websocket.js
@@ -0,0 +1,45 @@
+// API references:
+//
+// * http://dev.w3.org/html5/websockets/
+// * http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#interface-eventtarget
+// * http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#interface-event
+
+var util = require('util'),
+ driver = require('websocket-driver'),
+ API = require('./websocket/api');
+
+var WebSocket = function(request, socket, body, protocols, options) {
+ options = options || {};
+
+ this._stream = socket;
+ this._driver = driver.http(request, {maxLength: options.maxLength, protocols: protocols});
+
+ var self = this;
+ if (!this._stream || !this._stream.writable) return;
+ if (!this._stream.readable) return this._stream.end();
+
+ var catchup = function() { self._stream.removeListener('data', catchup) };
+ this._stream.on('data', catchup);
+
+ API.call(this, options);
+
+ process.nextTick(function() {
+ self._driver.start();
+ self._driver.io.write(body);
+ });
+};
+util.inherits(WebSocket, API);
+
+WebSocket.isWebSocket = function(request) {
+ return driver.isWebSocket(request);
+};
+
+WebSocket.validateOptions = function(options, validKeys) {
+ driver.validateOptions(options, validKeys);
+};
+
+WebSocket.WebSocket = WebSocket;
+WebSocket.Client = require('./websocket/client');
+WebSocket.EventSource = require('./eventsource');
+
+module.exports = WebSocket;
diff --git a/node_modules/faye-websocket/lib/faye/websocket/api.js b/node_modules/faye-websocket/lib/faye/websocket/api.js
new file mode 100644
index 00000000..40879e62
--- /dev/null
+++ b/node_modules/faye-websocket/lib/faye/websocket/api.js
@@ -0,0 +1,186 @@
+var Stream = require('stream').Stream,
+ util = require('util'),
+ driver = require('websocket-driver'),
+ EventTarget = require('./api/event_target'),
+ Event = require('./api/event');
+
+var API = function(options) {
+ options = options || {};
+ driver.validateOptions(options, ['headers', 'extensions', 'maxLength', 'ping', 'proxy', 'tls', 'ca']);
+
+ this.readable = this.writable = true;
+
+ var headers = options.headers;
+ if (headers) {
+ for (var name in headers) this._driver.setHeader(name, headers[name]);
+ }
+
+ var extensions = options.extensions;
+ if (extensions) {
+ [].concat(extensions).forEach(this._driver.addExtension, this._driver);
+ }
+
+ this._ping = options.ping;
+ this._pingId = 0;
+ this.readyState = API.CONNECTING;
+ this.bufferedAmount = 0;
+ this.protocol = '';
+ this.url = this._driver.url;
+ this.version = this._driver.version;
+
+ var self = this;
+
+ this._driver.on('open', function(e) { self._open() });
+ this._driver.on('message', function(e) { self._receiveMessage(e.data) });
+ this._driver.on('close', function(e) { self._beginClose(e.reason, e.code) });
+
+ this._driver.on('error', function(error) {
+ self._emitError(error.message);
+ });
+ this.on('error', function() {});
+
+ this._driver.messages.on('drain', function() {
+ self.emit('drain');
+ });
+
+ if (this._ping)
+ this._pingTimer = setInterval(function() {
+ self._pingId += 1;
+ self.ping(self._pingId.toString());
+ }, this._ping * 1000);
+
+ this._configureStream();
+
+ if (!this._proxy) {
+ this._stream.pipe(this._driver.io);
+ this._driver.io.pipe(this._stream);
+ }
+};
+util.inherits(API, Stream);
+
+API.CONNECTING = 0;
+API.OPEN = 1;
+API.CLOSING = 2;
+API.CLOSED = 3;
+
+var instance = {
+ write: function(data) {
+ return this.send(data);
+ },
+
+ end: function(data) {
+ if (data !== undefined) this.send(data);
+ this.close();
+ },
+
+ pause: function() {
+ return this._driver.messages.pause();
+ },
+
+ resume: function() {
+ return this._driver.messages.resume();
+ },
+
+ send: function(data) {
+ if (this.readyState > API.OPEN) return false;
+ if (!(data instanceof Buffer)) data = String(data);
+ return this._driver.messages.write(data);
+ },
+
+ ping: function(message, callback) {
+ if (this.readyState > API.OPEN) return false;
+ return this._driver.ping(message, callback);
+ },
+
+ close: function(code, reason) {
+ if (code === undefined) code = 1000;
+ if (reason === undefined) reason = '';
+
+ if (code !== 1000 && (code < 3000 || code > 4999))
+ throw new Error("Failed to execute 'close' on WebSocket: " +
+ "The code must be either 1000, or between 3000 and 4999. " +
+ code + " is neither.");
+
+ if (this.readyState !== API.CLOSED) this.readyState = API.CLOSING;
+ this._driver.close(reason, code);
+ },
+
+ _configureStream: function() {
+ var self = this;
+
+ this._stream.setTimeout(0);
+ this._stream.setNoDelay(true);
+
+ ['close', 'end'].forEach(function(event) {
+ this._stream.on(event, function() { self._finalizeClose() });
+ }, this);
+
+ this._stream.on('error', function(error) {
+ self._emitError('Network error: ' + self.url + ': ' + error.message);
+ self._finalizeClose();
+ });
+ },
+
+ _open: function() {
+ if (this.readyState !== API.CONNECTING) return;
+
+ this.readyState = API.OPEN;
+ this.protocol = this._driver.protocol || '';
+
+ var event = new Event('open');
+ event.initEvent('open', false, false);
+ this.dispatchEvent(event);
+ },
+
+ _receiveMessage: function(data) {
+ if (this.readyState > API.OPEN) return false;
+
+ if (this.readable) this.emit('data', data);
+
+ var event = new Event('message', {data: data});
+ event.initEvent('message', false, false);
+ this.dispatchEvent(event);
+ },
+
+ _emitError: function(message) {
+ if (this.readyState >= API.CLOSING) return;
+
+ var event = new Event('error', {message: message});
+ event.initEvent('error', false, false);
+ this.dispatchEvent(event);
+ },
+
+ _beginClose: function(reason, code) {
+ if (this.readyState === API.CLOSED) return;
+ this.readyState = API.CLOSING;
+ this._closeParams = [reason, code];
+
+ if (this._stream) {
+ this._stream.end();
+ if (!this._stream.readable) this._finalizeClose();
+ }
+ },
+
+ _finalizeClose: function() {
+ if (this.readyState === API.CLOSED) return;
+ this.readyState = API.CLOSED;
+
+ if (this._pingTimer) clearInterval(this._pingTimer);
+ if (this._stream) this._stream.end();
+
+ if (this.readable) this.emit('end');
+ this.readable = this.writable = false;
+
+ var reason = this._closeParams ? this._closeParams[0] : '',
+ code = this._closeParams ? this._closeParams[1] : 1006;
+
+ var event = new Event('close', {code: code, reason: reason});
+ event.initEvent('close', false, false);
+ this.dispatchEvent(event);
+ }
+};
+
+for (var method in instance) API.prototype[method] = instance[method];
+for (var key in EventTarget) API.prototype[key] = EventTarget[key];
+
+module.exports = API;
diff --git a/node_modules/faye-websocket/lib/faye/websocket/api/event.js b/node_modules/faye-websocket/lib/faye/websocket/api/event.js
new file mode 100644
index 00000000..38445809
--- /dev/null
+++ b/node_modules/faye-websocket/lib/faye/websocket/api/event.js
@@ -0,0 +1,20 @@
+var Event = function(eventType, options) {
+ this.type = eventType;
+ for (var key in options)
+ this[key] = options[key];
+};
+
+Event.prototype.initEvent = function(eventType, canBubble, cancelable) {
+ this.type = eventType;
+ this.bubbles = canBubble;
+ this.cancelable = cancelable;
+};
+
+Event.prototype.stopPropagation = function() {};
+Event.prototype.preventDefault = function() {};
+
+Event.CAPTURING_PHASE = 1;
+Event.AT_TARGET = 2;
+Event.BUBBLING_PHASE = 3;
+
+module.exports = Event;
diff --git a/node_modules/faye-websocket/lib/faye/websocket/api/event_target.js b/node_modules/faye-websocket/lib/faye/websocket/api/event_target.js
new file mode 100644
index 00000000..6c4b8697
--- /dev/null
+++ b/node_modules/faye-websocket/lib/faye/websocket/api/event_target.js
@@ -0,0 +1,28 @@
+var Event = require('./event');
+
+var EventTarget = {
+ onopen: null,
+ onmessage: null,
+ onerror: null,
+ onclose: null,
+
+ addEventListener: function(eventType, listener, useCapture) {
+ this.on(eventType, listener);
+ },
+
+ removeEventListener: function(eventType, listener, useCapture) {
+ this.removeListener(eventType, listener);
+ },
+
+ dispatchEvent: function(event) {
+ event.target = event.currentTarget = this;
+ event.eventPhase = Event.AT_TARGET;
+
+ if (this['on' + event.type])
+ this['on' + event.type](event);
+
+ this.emit(event.type, event);
+ }
+};
+
+module.exports = EventTarget;
diff --git a/node_modules/faye-websocket/lib/faye/websocket/client.js b/node_modules/faye-websocket/lib/faye/websocket/client.js
new file mode 100644
index 00000000..e32b31b0
--- /dev/null
+++ b/node_modules/faye-websocket/lib/faye/websocket/client.js
@@ -0,0 +1,83 @@
+var util = require('util'),
+ net = require('net'),
+ tls = require('tls'),
+ url = require('url'),
+ driver = require('websocket-driver'),
+ API = require('./api'),
+ Event = require('./api/event');
+
+var DEFAULT_PORTS = {'http:': 80, 'https:': 443, 'ws:':80, 'wss:': 443},
+ SECURE_PROTOCOLS = ['https:', 'wss:'];
+
+var Client = function(_url, protocols, options) {
+ options = options || {};
+
+ this.url = _url;
+ this._driver = driver.client(this.url, {maxLength: options.maxLength, protocols: protocols});
+
+ ['open', 'error'].forEach(function(event) {
+ this._driver.on(event, function() {
+ self.headers = self._driver.headers;
+ self.statusCode = self._driver.statusCode;
+ });
+ }, this);
+
+ var proxy = options.proxy || {},
+ endpoint = url.parse(proxy.origin || this.url),
+ port = endpoint.port || DEFAULT_PORTS[endpoint.protocol],
+ secure = SECURE_PROTOCOLS.indexOf(endpoint.protocol) >= 0,
+ onConnect = function() { self._onConnect() },
+ originTLS = options.tls || {},
+ socketTLS = proxy.origin ? (proxy.tls || {}) : originTLS,
+ self = this;
+
+ originTLS.ca = originTLS.ca || options.ca;
+
+ this._stream = secure
+ ? tls.connect(port, endpoint.hostname, socketTLS, onConnect)
+ : net.connect(port, endpoint.hostname, onConnect);
+
+ if (proxy.origin) this._configureProxy(proxy, originTLS);
+
+ API.call(this, options);
+};
+util.inherits(Client, API);
+
+Client.prototype._onConnect = function() {
+ var worker = this._proxy || this._driver;
+ worker.start();
+};
+
+Client.prototype._configureProxy = function(proxy, originTLS) {
+ var uri = url.parse(this.url),
+ secure = SECURE_PROTOCOLS.indexOf(uri.protocol) >= 0,
+ self = this,
+ name;
+
+ this._proxy = this._driver.proxy(proxy.origin);
+
+ if (proxy.headers) {
+ for (name in proxy.headers) this._proxy.setHeader(name, proxy.headers[name]);
+ }
+
+ this._proxy.pipe(this._stream, {end: false});
+ this._stream.pipe(this._proxy);
+
+ this._proxy.on('connect', function() {
+ if (secure) {
+ var options = {socket: self._stream, servername: uri.hostname};
+ for (name in originTLS) options[name] = originTLS[name];
+ self._stream = tls.connect(options);
+ self._configureStream();
+ }
+ self._driver.io.pipe(self._stream);
+ self._stream.pipe(self._driver.io);
+ self._driver.start();
+ });
+
+ this._proxy.on('error', function(error) {
+ self._driver.emit('error', error);
+ });
+};
+
+module.exports = Client;
diff --git a/node_modules/faye-websocket/package.json b/node_modules/faye-websocket/package.json
new file mode 100644
index 00000000..82a2530e
--- /dev/null
+++ b/node_modules/faye-websocket/package.json
@@ -0,0 +1,94 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "faye-websocket@^0.10.0",
+ "scope": null,
+ "escapedName": "faye-websocket",
+ "name": "faye-websocket",
+ "rawSpec": "^0.10.0",
+ "spec": ">=0.10.0 <0.11.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/sockjs"
+ ]
+ ],
+ "_from": "faye-websocket@>=0.10.0 <0.11.0",
+ "_id": "faye-websocket@0.10.0",
+ "_inCache": true,
+ "_location": "/faye-websocket",
+ "_nodeVersion": "0.12.6",
+ "_npmUser": {
+ "name": "jcoglan",
+ "email": "jcoglan@gmail.com"
+ },
+ "_npmVersion": "2.11.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "faye-websocket@^0.10.0",
+ "scope": null,
+ "escapedName": "faye-websocket",
+ "name": "faye-websocket",
+ "rawSpec": "^0.10.0",
+ "spec": ">=0.10.0 <0.11.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/sockjs"
+ ],
+ "_resolved": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.10.0.tgz",
+ "_shasum": "4e492f8d04dfb6f89003507f6edbf2d501e7c6f4",
+ "_shrinkwrap": null,
+ "_spec": "faye-websocket@^0.10.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/sockjs",
+ "author": {
+ "name": "James Coglan",
+ "email": "jcoglan@gmail.com",
+ "url": "http://jcoglan.com/"
+ },
+ "bugs": {
+ "url": "http://github.com/faye/faye-websocket-node/issues"
+ },
+ "dependencies": {
+ "websocket-driver": ">=0.5.1"
+ },
+ "description": "Standards-compliant WebSocket server and client",
+ "devDependencies": {
+ "jstest": "",
+ "pace": "",
+ "permessage-deflate": ""
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "4e492f8d04dfb6f89003507f6edbf2d501e7c6f4",
+ "tarball": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.10.0.tgz"
+ },
+ "engines": {
+ "node": ">=0.4.0"
+ },
+ "gitHead": "854c0a96581d95d0f07db01ce48431a4098e7c60",
+ "homepage": "http://github.com/faye/faye-websocket-node",
+ "keywords": [
+ "websocket",
+ "eventsource"
+ ],
+ "license": "MIT",
+ "main": "./lib/faye/websocket",
+ "maintainers": [
+ {
+ "name": "jcoglan",
+ "email": "jcoglan@gmail.com"
+ }
+ ],
+ "name": "faye-websocket",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/faye/faye-websocket-node.git"
+ },
+ "scripts": {
+ "test": "jstest spec/runner.js"
+ },
+ "version": "0.10.0"
+}
diff --git a/node_modules/filename-regex/README.md b/node_modules/filename-regex/README.md
new file mode 100644
index 00000000..d001e7aa
--- /dev/null
+++ b/node_modules/filename-regex/README.md
@@ -0,0 +1,51 @@
+# filename-regex [](http://badge.fury.io/js/filename-regex)
+
+> Regular expression for matching file names, with or without extension.
+
+
+## Install with [npm](npmjs.org)
+
+```bash
+npm i filename-regex --save
+```
+
+## Usage
+
+```js
+var regex = require('filename-regex');
+
+'a/b/c/d.min.js'.match(regex());
+//=> match[0] = 'd.min.js'
+
+'a/b/c/.dotfile'.match(regex());
+//=> match[0] = '.dotfile'
+```
+
+
+## Run tests
+
+Install dev dependencies:
+
+```bash
+npm i -d && npm test
+```
+
+## Contributing
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/regexps/filename-regex/issues)
+
+
+## Author
+
+**Jon Schlinkert**
+
++ [github/jonschlinkert](https://github.com/jonschlinkert)
++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+
+## License
+Copyright (c) 2015 Jon Schlinkert
+Released under the MIT license
+
+***
+
+_This file was generated by [verb](https://github.com/assemble/verb) on January 24, 2015._
diff --git a/node_modules/filename-regex/index.js b/node_modules/filename-regex/index.js
new file mode 100644
index 00000000..bb1888b4
--- /dev/null
+++ b/node_modules/filename-regex/index.js
@@ -0,0 +1,10 @@
+/*!
+ * filename-regex
+ *
+ * Copyright (c) 2014-2015, Jon Schlinkert
+ * Licensed under the MIT license.
+ */
+
+module.exports = function filenameRegex() {
+ return /([^\\\/]+)$/;
+};
diff --git a/node_modules/filename-regex/package.json b/node_modules/filename-regex/package.json
new file mode 100644
index 00000000..5a944a47
--- /dev/null
+++ b/node_modules/filename-regex/package.json
@@ -0,0 +1,100 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "filename-regex@^2.0.0",
+ "scope": null,
+ "escapedName": "filename-regex",
+ "name": "filename-regex",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/micromatch"
+ ]
+ ],
+ "_from": "filename-regex@>=2.0.0 <3.0.0",
+ "_id": "filename-regex@2.0.0",
+ "_inCache": true,
+ "_location": "/filename-regex",
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "filename-regex@^2.0.0",
+ "scope": null,
+ "escapedName": "filename-regex",
+ "name": "filename-regex",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/micromatch"
+ ],
+ "_resolved": "https://registry.npmjs.org/filename-regex/-/filename-regex-2.0.0.tgz",
+ "_shasum": "996e3e80479b98b9897f15a8a58b3d084e926775",
+ "_shrinkwrap": null,
+ "_spec": "filename-regex@^2.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/micromatch",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/regexps/filename-regex/issues"
+ },
+ "dependencies": {},
+ "description": "Regular expression for matching file names, with or without extension.",
+ "devDependencies": {},
+ "directories": {},
+ "dist": {
+ "shasum": "996e3e80479b98b9897f15a8a58b3d084e926775",
+ "tarball": "https://registry.npmjs.org/filename-regex/-/filename-regex-2.0.0.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "aa0f2933322d38cf547ff4c8ced882fbd8422866",
+ "homepage": "https://github.com/regexps/filename-regex",
+ "keywords": [
+ "basename",
+ "regular expression",
+ "file",
+ "filename",
+ "filepath",
+ "match",
+ "name",
+ "path",
+ "regex",
+ "regexp"
+ ],
+ "license": {
+ "type": "MIT",
+ "url": "https://github.com/regexps/filename-regex/blob/master/LICENSE-MIT"
+ },
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ }
+ ],
+ "name": "filename-regex",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/regexps/filename-regex.git"
+ },
+ "scripts": {
+ "test": "mocha -R spec"
+ },
+ "version": "2.0.0"
+}
diff --git a/node_modules/fill-range/LICENSE b/node_modules/fill-range/LICENSE
new file mode 100755
index 00000000..fa30c4cb
--- /dev/null
+++ b/node_modules/fill-range/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014-2015, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fill-range/README.md b/node_modules/fill-range/README.md
new file mode 100755
index 00000000..c69694a3
--- /dev/null
+++ b/node_modules/fill-range/README.md
@@ -0,0 +1,290 @@
+# fill-range [](http://badge.fury.io/js/fill-range) [](https://travis-ci.org/jonschlinkert/fill-range)
+
+> Fill in a range of numbers or letters, optionally passing an increment or multiplier to use.
+
+## Install with [npm](npmjs.org)
+
+```bash
+npm i fill-range --save
+```
+
+
+
+- [Usage](#usage)
+ * [Invalid ranges](#invalid-ranges)
+ * [Custom function](#custom-function)
+ * [Special characters](#special-characters)
+ + [plus](#plus)
+ + [pipe and tilde](#pipe-and-tilde)
+ + [angle bracket](#angle-bracket)
+ + [question mark](#question-mark)
+- [Other useful libs](#other-useful-libs)
+- [Running tests](#running-tests)
+- [Contributing](#contributing)
+- [Author](#author)
+- [License](#license)
+
+_(Table of contents generated by [verb])_
+
+
+
+## Usage
+
+```js
+var range = require('fill-range');
+
+range('a', 'e');
+//=> ['a', 'b', 'c', 'd', 'e']
+```
+
+**Params**
+
+```js
+range(start, stop, step, options, fn);
+```
+
+ - `start`: **{String|Number}** the number or letter to start with
+ - `end`: **{String|Number}** the number or letter to end with
+ - `step`: **{String|Number}** optionally pass the step to use. works for letters or numbers.
+ - `options`: **{Object}**:
+ + `makeRe`: return a regex-compatible string (still returned as an array for consistency)
+ + `step`: pass the step on the options as an alternative to passing it as an argument
+ + `silent`: `true` by default, set to false to throw errors for invalid ranges.
+ - `fn`: **{Function}** optionally [pass a function](#custom-function) to modify each character
+
+
+**Examples**
+
+```js
+range(1, 3)
+//=> ['1', '2', '3']
+
+range('1', '3')
+//=> ['1', '2', '3']
+
+range('0', '-5')
+//=> [ '0', '-1', '-2', '-3', '-4', '-5' ]
+
+range(-9, 9, 3)
+//=> [ '-9', '-6', '-3', '0', '3', '6', '9' ])
+
+range('-1', '-10', '-2')
+//=> [ '-1', '-3', '-5', '-7', '-9' ]
+
+range('1', '10', '2')
+//=> [ '1', '3', '5', '7', '9' ]
+
+range('a', 'e')
+//=> ['a', 'b', 'c', 'd', 'e']
+
+range('a', 'e', 2)
+//=> ['a', 'c', 'e']
+
+range('A', 'E', 2)
+//=> ['A', 'C', 'E']
+```
+
+### Invalid ranges
+
+When an invalid range is passed, `null` is returned.
+
+```js
+range('1.1', '2');
+//=> null
+
+range('a', '2');
+//=> null
+
+range(1, 10, 'foo');
+//=> null
+```
+
+If you want errors to be throw, pass `silent: false` on the options:
+
+
+### Custom function
+
+Optionally pass a custom function as the third or fourth argument:
+
+```js
+range('a', 'e', function (val, isNumber, pad, i) {
+ if (!isNumber) {
+ return String.fromCharCode(val) + i;
+ }
+ return val;
+});
+//=> ['a0', 'b1', 'c2', 'd3', 'e4']
+```
+
+### Special characters
+
+A special character may be passed as the third arg instead of a step increment. These characters can be pretty useful for brace expansion, creating file paths, test fixtures and similar use case.
+
+```js
+range('a', 'z', SPECIAL_CHARACTER_HERE);
+```
+
+**Supported characters**
+
+ - `+`: repeat the given string `n` times
+ - `|`: create a regex-ready string, instead of an array
+ - `>`: join values to single array element
+ - `?`: randomize the given pattern using [randomatic]
+
+#### plus
+
+Character: _(`+`)_
+
+Repeat the first argument the number of times passed on the second argument.
+
+**Examples:**
+
+```js
+range('a', 3, '+');
+//=> ['a', 'a', 'a']
+
+range('abc', 2, '+');
+//=> ['abc', 'abc']
+```
+
+#### pipe and tilde
+
+Characters: _(`|` and `~`)_
+
+Creates a regex-capable string (either a logical `or` or a character class) from the expanded arguments.
+
+**Examples:**
+
+```js
+range('a', 'c', '|');
+//=> ['(a|b|c)'
+
+range('a', 'c', '~');
+//=> ['[a-c]'
+
+range('a', 'z', '|5');
+//=> ['(a|f|k|p|u|z)'
+```
+
+**Automatic separator correction**
+
+To avoid this error:
+
+> `Range out of order in character class`
+
+Fill-range detects invalid sequences and uses the correct syntax. For example:
+
+**invalid** (regex)
+
+If you pass these:
+
+```js
+range('a', 'z', '~5');
+// which would result in this
+//=> ['[a-f-k-p-u-z]']
+
+range('10', '20', '~');
+// which would result in this
+//=> ['[10-20]']
+```
+
+**valid** (regex)
+
+fill-range corrects them to this:
+
+```js
+range('a', 'z', '~5');
+//=> ['(a|f|k|p|u|z)'
+
+range('10', '20', '~');
+//=> ['(10-20)'
+```
+
+#### angle bracket
+
+Character: _(`>`)_
+
+Joins all values in the returned array to a single value.
+
+**Examples:**
+
+```js
+range('a', 'e', '>');
+//=> ['abcde']
+
+range('5', '8', '>');
+//=> ['5678']
+
+range('2', '20', '2>');
+//=> ['2468101214161820']
+```
+
+
+#### question mark
+
+Character: _(`?`)_
+
+Uses [randomatic] to generate randomized alpha, numeric, or alpha-numeric patterns based on the provided arguments.
+
+**Examples:**
+
+_(actual results would obviously be randomized)_
+
+Generate a 5-character, uppercase, alphabetical string:
+
+```js
+range('A', 5, '?');
+//=> ['NSHAK']
+```
+
+Generate a 5-digit random number:
+
+```js
+range('0', 5, '?');
+//=> ['36583']
+```
+
+Generate a 10-character alpha-numeric string:
+
+```js
+range('A0', 10, '?');
+//=> ['5YJD60VQNN']
+```
+
+See the [randomatic] repo for all available options and or to create issues or feature requests related to randomization.
+
+## Other useful libs
+ * [micromatch](https://github.com/jonschlinkert/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. Just use `micromatch.isMatch()` instead of `minimatch()`, or use `micromatch()` instead of `multimatch()`.
+ * [expand-range](https://github.com/jonschlinkert/expand-range): Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. See the benchmarks. Used by micromatch.
+ * [braces](https://github.com/jonschlinkert/braces): Fastest brace expansion for node.js, with the most complete support for the Bash 4.3 braces specification.
+ * [is-glob](https://github.com/jonschlinkert/is-glob): Returns `true` if the given string looks like a glob pattern.
+
+## Running tests
+Install dev dependencies:
+
+```bash
+npm i -d && npm test
+```
+
+## Contributing
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/fill-range/issues)
+
+## Author
+
+**Jon Schlinkert**
+
++ [github/jonschlinkert](https://github.com/jonschlinkert)
++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+## License
+Copyright (c) 2014-2015 Jon Schlinkert
+Released under the MIT license
+
+***
+
+_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on April 07, 2015._
+
+[randomatic]: https://github.com/jonschlinkert/randomatic
+[expand-range]: https://github.com/jonschlinkert/expand-range
+[micromatch]: https://github.com/jonschlinkert/micromatch
+[braces]: https://github.com/jonschlinkert/braces
\ No newline at end of file
diff --git a/node_modules/fill-range/index.js b/node_modules/fill-range/index.js
new file mode 100644
index 00000000..5657051b
--- /dev/null
+++ b/node_modules/fill-range/index.js
@@ -0,0 +1,408 @@
+/*!
+ * fill-range
+ *
+ * Copyright (c) 2014-2015, Jon Schlinkert.
+ * Licensed under the MIT License.
+ */
+
+'use strict';
+
+var isObject = require('isobject');
+var isNumber = require('is-number');
+var randomize = require('randomatic');
+var repeatStr = require('repeat-string');
+var repeat = require('repeat-element');
+
+/**
+ * Expose `fillRange`
+ */
+
+module.exports = fillRange;
+
+/**
+ * Return a range of numbers or letters.
+ *
+ * @param {String} `a` Start of the range
+ * @param {String} `b` End of the range
+ * @param {String} `step` Increment or decrement to use.
+ * @param {Function} `fn` Custom function to modify each element in the range.
+ * @return {Array}
+ */
+
+function fillRange(a, b, step, options, fn) {
+ if (a == null || b == null) {
+ throw new Error('fill-range expects the first and second args to be strings.');
+ }
+
+ if (typeof step === 'function') {
+ fn = step; options = {}; step = null;
+ }
+
+ if (typeof options === 'function') {
+ fn = options; options = {};
+ }
+
+ if (isObject(step)) {
+ options = step; step = '';
+ }
+
+ var expand, regex = false, sep = '';
+ var opts = options || {};
+
+ if (typeof opts.silent === 'undefined') {
+ opts.silent = true;
+ }
+
+ step = step || opts.step;
+
+ // store a ref to unmodified arg
+ var origA = a, origB = b;
+
+ b = (b.toString() === '-0') ? 0 : b;
+
+ if (opts.optimize || opts.makeRe) {
+ step = step ? (step += '~') : step;
+ expand = true;
+ regex = true;
+ sep = '~';
+ }
+
+ // handle special step characters
+ if (typeof step === 'string') {
+ var match = stepRe().exec(step);
+
+ if (match) {
+ var i = match.index;
+ var m = match[0];
+
+ // repeat string
+ if (m === '+') {
+ return repeat(a, b);
+
+ // randomize a, `b` times
+ } else if (m === '?') {
+ return [randomize(a, b)];
+
+ // expand right, no regex reduction
+ } else if (m === '>') {
+ step = step.substr(0, i) + step.substr(i + 1);
+ expand = true;
+
+ // expand to an array, or if valid create a reduced
+ // string for a regex logic `or`
+ } else if (m === '|') {
+ step = step.substr(0, i) + step.substr(i + 1);
+ expand = true;
+ regex = true;
+ sep = m;
+
+ // expand to an array, or if valid create a reduced
+ // string for a regex range
+ } else if (m === '~') {
+ step = step.substr(0, i) + step.substr(i + 1);
+ expand = true;
+ regex = true;
+ sep = m;
+ }
+ } else if (!isNumber(step)) {
+ if (!opts.silent) {
+ throw new TypeError('fill-range: invalid step.');
+ }
+ return null;
+ }
+ }
+
+ if (/[.&*()[\]^%$#@!]/.test(a) || /[.&*()[\]^%$#@!]/.test(b)) {
+ if (!opts.silent) {
+ throw new RangeError('fill-range: invalid range arguments.');
+ }
+ return null;
+ }
+
+ // has neither a letter nor number, or has both letters and numbers
+ // this needs to be after the step logic
+ if (!noAlphaNum(a) || !noAlphaNum(b) || hasBoth(a) || hasBoth(b)) {
+ if (!opts.silent) {
+ throw new RangeError('fill-range: invalid range arguments.');
+ }
+ return null;
+ }
+
+ // validate arguments
+ var isNumA = isNumber(zeros(a));
+ var isNumB = isNumber(zeros(b));
+
+ if ((!isNumA && isNumB) || (isNumA && !isNumB)) {
+ if (!opts.silent) {
+ throw new TypeError('fill-range: first range argument is incompatible with second.');
+ }
+ return null;
+ }
+
+ // by this point both are the same, so we
+ // can use A to check going forward.
+ var isNum = isNumA;
+ var num = formatStep(step);
+
+ // is the range alphabetical? or numeric?
+ if (isNum) {
+ // if numeric, coerce to an integer
+ a = +a; b = +b;
+ } else {
+ // otherwise, get the charCode to expand alpha ranges
+ a = a.charCodeAt(0);
+ b = b.charCodeAt(0);
+ }
+
+ // is the pattern descending?
+ var isDescending = a > b;
+
+ // don't create a character class if the args are < 0
+ if (a < 0 || b < 0) {
+ expand = false;
+ regex = false;
+ }
+
+ // detect padding
+ var padding = isPadded(origA, origB);
+ var res, pad, arr = [];
+ var ii = 0;
+
+ // character classes, ranges and logical `or`
+ if (regex) {
+ if (shouldExpand(a, b, num, isNum, padding, opts)) {
+ // make sure the correct separator is used
+ if (sep === '|' || sep === '~') {
+ sep = detectSeparator(a, b, num, isNum, isDescending);
+ }
+ return wrap([origA, origB], sep, opts);
+ }
+ }
+
+ while (isDescending ? (a >= b) : (a <= b)) {
+ if (padding && isNum) {
+ pad = padding(a);
+ }
+
+ // custom function
+ if (typeof fn === 'function') {
+ res = fn(a, isNum, pad, ii++);
+
+ // letters
+ } else if (!isNum) {
+ if (regex && isInvalidChar(a)) {
+ res = null;
+ } else {
+ res = String.fromCharCode(a);
+ }
+
+ // numbers
+ } else {
+ res = formatPadding(a, pad);
+ }
+
+ // add result to the array, filtering any nulled values
+ if (res !== null) arr.push(res);
+
+ // increment or decrement
+ if (isDescending) {
+ a -= num;
+ } else {
+ a += num;
+ }
+ }
+
+ // now that the array is expanded, we need to handle regex
+ // character classes, ranges or logical `or` that wasn't
+ // already handled before the loop
+ if ((regex || expand) && !opts.noexpand) {
+ // make sure the correct separator is used
+ if (sep === '|' || sep === '~') {
+ sep = detectSeparator(a, b, num, isNum, isDescending);
+ }
+ if (arr.length === 1 || a < 0 || b < 0) { return arr; }
+ return wrap(arr, sep, opts);
+ }
+
+ return arr;
+}
+
+/**
+ * Wrap the string with the correct regex
+ * syntax.
+ */
+
+function wrap(arr, sep, opts) {
+ if (sep === '~') { sep = '-'; }
+ var str = arr.join(sep);
+ var pre = opts && opts.regexPrefix;
+
+ // regex logical `or`
+ if (sep === '|') {
+ str = pre ? pre + str : str;
+ str = '(' + str + ')';
+ }
+
+ // regex character class
+ if (sep === '-') {
+ str = (pre && pre === '^')
+ ? pre + str
+ : str;
+ str = '[' + str + ']';
+ }
+ return [str];
+}
+
+/**
+ * Check for invalid characters
+ */
+
+function isCharClass(a, b, step, isNum, isDescending) {
+ if (isDescending) { return false; }
+ if (isNum) { return a <= 9 && b <= 9; }
+ if (a < b) { return step === 1; }
+ return false;
+}
+
+/**
+ * Detect the correct separator to use
+ */
+
+function shouldExpand(a, b, num, isNum, padding, opts) {
+ if (isNum && (a > 9 || b > 9)) { return false; }
+ return !padding && num === 1 && a < b;
+}
+
+/**
+ * Detect the correct separator to use
+ */
+
+function detectSeparator(a, b, step, isNum, isDescending) {
+ var isChar = isCharClass(a, b, step, isNum, isDescending);
+ if (!isChar) {
+ return '|';
+ }
+ return '~';
+}
+
+/**
+ * Correctly format the step based on type
+ */
+
+function formatStep(step) {
+ return Math.abs(step >> 0) || 1;
+}
+
+/**
+ * Format padding, taking leading `-` into account
+ */
+
+function formatPadding(ch, pad) {
+ var res = pad ? pad + ch : ch;
+ if (pad && ch.toString().charAt(0) === '-') {
+ res = '-' + pad + ch.toString().substr(1);
+ }
+ return res.toString();
+}
+
+/**
+ * Check for invalid characters
+ */
+
+function isInvalidChar(str) {
+ var ch = toStr(str);
+ return ch === '\\'
+ || ch === '['
+ || ch === ']'
+ || ch === '^'
+ || ch === '('
+ || ch === ')'
+ || ch === '`';
+}
+
+/**
+ * Convert to a string from a charCode
+ */
+
+function toStr(ch) {
+ return String.fromCharCode(ch);
+}
+
+
+/**
+ * Step regex
+ */
+
+function stepRe() {
+ return /\?|>|\||\+|\~/g;
+}
+
+/**
+ * Return true if `val` has either a letter
+ * or a number
+ */
+
+function noAlphaNum(val) {
+ return /[a-z0-9]/i.test(val);
+}
+
+/**
+ * Return true if `val` has both a letter and
+ * a number (invalid)
+ */
+
+function hasBoth(val) {
+ return /[a-z][0-9]|[0-9][a-z]/i.test(val);
+}
+
+/**
+ * Normalize zeros for checks
+ */
+
+function zeros(val) {
+ if (/^-*0+$/.test(val.toString())) {
+ return '0';
+ }
+ return val;
+}
+
+/**
+ * Return true if `val` has leading zeros,
+ * or a similar valid pattern.
+ */
+
+function hasZeros(val) {
+ return /[^.]\.|^-*0+[0-9]/.test(val);
+}
+
+/**
+ * If the string is padded, returns a curried function with
+ * the a cached padding string, or `false` if no padding.
+ *
+ * @param {*} `origA` String or number.
+ * @return {String|Boolean}
+ */
+
+function isPadded(origA, origB) {
+ if (hasZeros(origA) || hasZeros(origB)) {
+ var alen = length(origA);
+ var blen = length(origB);
+
+ var len = alen >= blen
+ ? alen
+ : blen;
+
+ return function (a) {
+ return repeatStr('0', len - length(a));
+ };
+ }
+ return false;
+}
+
+/**
+ * Get the string length of `val`
+ */
+
+function length(val) {
+ return val.toString().length;
+}
diff --git a/node_modules/fill-range/package.json b/node_modules/fill-range/package.json
new file mode 100644
index 00000000..d1be0572
--- /dev/null
+++ b/node_modules/fill-range/package.json
@@ -0,0 +1,131 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "fill-range@^2.1.0",
+ "scope": null,
+ "escapedName": "fill-range",
+ "name": "fill-range",
+ "rawSpec": "^2.1.0",
+ "spec": ">=2.1.0 <3.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/expand-range"
+ ]
+ ],
+ "_from": "fill-range@>=2.1.0 <3.0.0",
+ "_id": "fill-range@2.2.3",
+ "_inCache": true,
+ "_location": "/fill-range",
+ "_nodeVersion": "5.0.0",
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "3.3.6",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "fill-range@^2.1.0",
+ "scope": null,
+ "escapedName": "fill-range",
+ "name": "fill-range",
+ "rawSpec": "^2.1.0",
+ "spec": ">=2.1.0 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/expand-range"
+ ],
+ "_resolved": "https://registry.npmjs.org/fill-range/-/fill-range-2.2.3.tgz",
+ "_shasum": "50b77dfd7e469bc7492470963699fe7a8485a723",
+ "_shrinkwrap": null,
+ "_spec": "fill-range@^2.1.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/expand-range",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/fill-range/issues"
+ },
+ "dependencies": {
+ "is-number": "^2.1.0",
+ "isobject": "^2.0.0",
+ "randomatic": "^1.1.3",
+ "repeat-element": "^1.1.2",
+ "repeat-string": "^1.5.2"
+ },
+ "description": "Fill in a range of numbers or letters, optionally passing an increment or multiplier to use.",
+ "devDependencies": {
+ "benchmarked": "^0.1.3",
+ "chalk": "^0.5.1",
+ "should": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "50b77dfd7e469bc7492470963699fe7a8485a723",
+ "tarball": "https://registry.npmjs.org/fill-range/-/fill-range-2.2.3.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "6cb50d5c679d9e6d9e8ad97bb2efd63a8c8da610",
+ "homepage": "https://github.com/jonschlinkert/fill-range",
+ "keywords": [
+ "alpha",
+ "alphabetical",
+ "bash",
+ "brace",
+ "expand",
+ "expansion",
+ "glob",
+ "match",
+ "matches",
+ "matching",
+ "number",
+ "numerical",
+ "range",
+ "ranges",
+ "sh"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ {
+ "name": "doowb",
+ "email": "brian.woodward@gmail.com"
+ },
+ {
+ "name": "es128",
+ "email": "elan.shanker+npm@gmail.com"
+ }
+ ],
+ "name": "fill-range",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonschlinkert/fill-range.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "related": {
+ "list": [
+ "micromatch",
+ "expand-range",
+ "braces",
+ "is-glob"
+ ]
+ }
+ },
+ "version": "2.2.3"
+}
diff --git a/node_modules/finalhandler/HISTORY.md b/node_modules/finalhandler/HISTORY.md
new file mode 100644
index 00000000..5070d224
--- /dev/null
+++ b/node_modules/finalhandler/HISTORY.md
@@ -0,0 +1,116 @@
+0.5.1 / 2016-11-12
+==================
+
+ * Fix exception when `err.headers` is not an object
+ * deps: statuses@~1.3.1
+ * perf: hoist regular expressions
+ * perf: remove duplicate validation path
+
+0.5.0 / 2016-06-15
+==================
+
+ * Change invalid or non-numeric status code to 500
+ * Overwrite status message to match set status code
+ * Prefer `err.statusCode` if `err.status` is invalid
+ * Set response headers from `err.headers` object
+ * Use `statuses` instead of `http` module for status messages
+ - Includes all defined status messages
+
+0.4.1 / 2015-12-02
+==================
+
+ * deps: escape-html@~1.0.3
+ - perf: enable strict mode
+ - perf: optimize string replacement
+ - perf: use faster string coercion
+
+0.4.0 / 2015-06-14
+==================
+
+ * Fix a false-positive when unpiping in Node.js 0.8
+ * Support `statusCode` property on `Error` objects
+ * Use `unpipe` module for unpiping requests
+ * deps: escape-html@1.0.2
+ * deps: on-finished@~2.3.0
+ - Add defined behavior for HTTP `CONNECT` requests
+ - Add defined behavior for HTTP `Upgrade` requests
+ - deps: ee-first@1.1.1
+ * perf: enable strict mode
+ * perf: remove argument reassignment
+
+0.3.6 / 2015-05-11
+==================
+
+ * deps: debug@~2.2.0
+ - deps: ms@0.7.1
+
+0.3.5 / 2015-04-22
+==================
+
+ * deps: on-finished@~2.2.1
+ - Fix `isFinished(req)` when data buffered
+
+0.3.4 / 2015-03-15
+==================
+
+ * deps: debug@~2.1.3
+ - Fix high intensity foreground color for bold
+ - deps: ms@0.7.0
+
+0.3.3 / 2015-01-01
+==================
+
+ * deps: debug@~2.1.1
+ * deps: on-finished@~2.2.0
+
+0.3.2 / 2014-10-22
+==================
+
+ * deps: on-finished@~2.1.1
+ - Fix handling of pipelined requests
+
+0.3.1 / 2014-10-16
+==================
+
+ * deps: debug@~2.1.0
+ - Implement `DEBUG_FD` env variable support
+
+0.3.0 / 2014-09-17
+==================
+
+ * Terminate in progress response only on error
+ * Use `on-finished` to determine request status
+
+0.2.0 / 2014-09-03
+==================
+
+ * Set `X-Content-Type-Options: nosniff` header
+ * deps: debug@~2.0.0
+
+0.1.0 / 2014-07-16
+==================
+
+ * Respond after request fully read
+ - prevents hung responses and socket hang ups
+ * deps: debug@1.0.4
+
+0.0.3 / 2014-07-11
+==================
+
+ * deps: debug@1.0.3
+ - Add support for multiple wildcards in namespaces
+
+0.0.2 / 2014-06-19
+==================
+
+ * Handle invalid status codes
+
+0.0.1 / 2014-06-05
+==================
+
+ * deps: debug@1.0.2
+
+0.0.0 / 2014-06-05
+==================
+
+ * Extracted from connect/express
diff --git a/node_modules/finalhandler/LICENSE b/node_modules/finalhandler/LICENSE
new file mode 100644
index 00000000..0fa162e9
--- /dev/null
+++ b/node_modules/finalhandler/LICENSE
@@ -0,0 +1,22 @@
+(The MIT License)
+
+Copyright (c) 2014-2016 Douglas Christopher Wilson
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/finalhandler/README.md b/node_modules/finalhandler/README.md
new file mode 100644
index 00000000..84c3d2af
--- /dev/null
+++ b/node_modules/finalhandler/README.md
@@ -0,0 +1,146 @@
+# finalhandler
+
+[![NPM Version][npm-image]][npm-url]
+[![NPM Downloads][downloads-image]][downloads-url]
+[![Node.js Version][node-image]][node-url]
+[![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
+
+Node.js function to invoke as the final step to respond to HTTP request.
+
+## Installation
+
+This is a [Node.js](https://nodejs.org/en/) module available through the
+[npm registry](https://www.npmjs.com/). Installation is done using the
+[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):
+
+```sh
+$ npm install finalhandler
+```
+
+## API
+
+```
+var finalhandler = require('finalhandler')
+```
+
+### finalhandler(req, res, [options])
+
+Returns function to be invoked as the final step for the given `req` and `res`.
+This function is to be invoked as `fn(err)`. If `err` is falsy, the handler will
+write out a 404 response to the `res`. If it is truthy, an error response will
+be written out to the `res`.
+
+When an error is written, the following information is added to the response:
+
+ * The `res.statusCode` is set from `err.status` (or `err.statusCode`). If
+ this value is outside the 4xx or 5xx range, it will be set to 500.
+ * The `res.statusMessage` is set according to the status code.
+ * The body will be the HTML of the status code message if `env` is
+ `'production'`, otherwise will be `err.stack`.
+ * Any headers specified in an `err.headers` object.
+
+The final handler will also unpipe anything from `req` when it is invoked.
+
+#### options.env
+
+By default, the environment is determined by `NODE_ENV` variable, but it can be
+overridden by this option.
+
+#### options.onerror
+
+Provide a function to be called with the `err` when it exists. Can be used for
+writing errors to a central location without excessive function generation. Called
+as `onerror(err, req, res)`.
+
+## Examples
+
+### always 404
+
+```js
+var finalhandler = require('finalhandler')
+var http = require('http')
+
+var server = http.createServer(function (req, res) {
+ var done = finalhandler(req, res)
+ done()
+})
+
+server.listen(3000)
+```
+
+### perform simple action
+
+```js
+var finalhandler = require('finalhandler')
+var fs = require('fs')
+var http = require('http')
+
+var server = http.createServer(function (req, res) {
+ var done = finalhandler(req, res)
+
+ fs.readFile('index.html', function (err, buf) {
+ if (err) return done(err)
+ res.setHeader('Content-Type', 'text/html')
+ res.end(buf)
+ })
+})
+
+server.listen(3000)
+```
+
+### use with middleware-style functions
+
+```js
+var finalhandler = require('finalhandler')
+var http = require('http')
+var serveStatic = require('serve-static')
+
+var serve = serveStatic('public')
+
+var server = http.createServer(function (req, res) {
+ var done = finalhandler(req, res)
+ serve(req, res, done)
+})
+
+server.listen(3000)
+```
+
+### keep log of all errors
+
+```js
+var finalhandler = require('finalhandler')
+var fs = require('fs')
+var http = require('http')
+
+var server = http.createServer(function (req, res) {
+ var done = finalhandler(req, res, {onerror: logerror})
+
+ fs.readFile('index.html', function (err, buf) {
+ if (err) return done(err)
+ res.setHeader('Content-Type', 'text/html')
+ res.end(buf)
+ })
+})
+
+server.listen(3000)
+
+function logerror (err) {
+ console.error(err.stack || err.toString())
+}
+```
+
+## License
+
+[MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/finalhandler.svg
+[npm-url]: https://npmjs.org/package/finalhandler
+[node-image]: https://img.shields.io/node/v/finalhandler.svg
+[node-url]: https://nodejs.org/en/download
+[travis-image]: https://img.shields.io/travis/pillarjs/finalhandler.svg
+[travis-url]: https://travis-ci.org/pillarjs/finalhandler
+[coveralls-image]: https://img.shields.io/coveralls/pillarjs/finalhandler.svg
+[coveralls-url]: https://coveralls.io/r/pillarjs/finalhandler?branch=master
+[downloads-image]: https://img.shields.io/npm/dm/finalhandler.svg
+[downloads-url]: https://npmjs.org/package/finalhandler
diff --git a/node_modules/finalhandler/index.js b/node_modules/finalhandler/index.js
new file mode 100644
index 00000000..e0719c59
--- /dev/null
+++ b/node_modules/finalhandler/index.js
@@ -0,0 +1,247 @@
+/*!
+ * finalhandler
+ * Copyright(c) 2014-2016 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict'
+
+/**
+ * Module dependencies.
+ * @private
+ */
+
+var debug = require('debug')('finalhandler')
+var escapeHtml = require('escape-html')
+var onFinished = require('on-finished')
+var statuses = require('statuses')
+var unpipe = require('unpipe')
+
+/**
+ * Module variables.
+ * @private
+ */
+
+var DOUBLE_SPACE_REGEXP = /\x20{2}/g
+var NEWLINE_REGEXP = /\n/g
+
+/* istanbul ignore next */
+var defer = typeof setImmediate === 'function'
+ ? setImmediate
+ : function (fn) { process.nextTick(fn.bind.apply(fn, arguments)) }
+var isFinished = onFinished.isFinished
+
+/**
+ * Module exports.
+ * @public
+ */
+
+module.exports = finalhandler
+
+/**
+ * Create a function to handle the final response.
+ *
+ * @param {Request} req
+ * @param {Response} res
+ * @param {Object} [options]
+ * @return {Function}
+ * @public
+ */
+
+function finalhandler (req, res, options) {
+ var opts = options || {}
+
+ // get environment
+ var env = opts.env || process.env.NODE_ENV || 'development'
+
+ // get error callback
+ var onerror = opts.onerror
+
+ return function (err) {
+ var headers
+ var status
+
+ // ignore 404 on in-flight response
+ if (!err && res._header) {
+ debug('cannot 404 after headers sent')
+ return
+ }
+
+ // unhandled error
+ if (err) {
+ // respect status code from error
+ status = getErrorStatusCode(err)
+
+ // respect headers from error
+ if (status !== undefined) {
+ headers = getErrorHeaders(err)
+ }
+
+ // fallback to status code on response
+ if (status === undefined) {
+ status = getResponseStatusCode(res)
+ }
+
+ // production gets a basic error message
+ var msg = env === 'production'
+ ? statuses[status]
+ : err.stack || err.toString()
+ msg = escapeHtml(msg)
+ .replace(NEWLINE_REGEXP, ' ')
+ .replace(DOUBLE_SPACE_REGEXP, ' ') + '\n'
+ } else {
+ status = 404
+ msg = 'Cannot ' + escapeHtml(req.method) + ' ' + escapeHtml(req.originalUrl || req.url) + '\n'
+ }
+
+ debug('default %s', status)
+
+ // schedule onerror callback
+ if (err && onerror) {
+ defer(onerror, err, req, res)
+ }
+
+ // cannot actually respond
+ if (res._header) {
+ debug('cannot %d after headers sent', status)
+ req.socket.destroy()
+ return
+ }
+
+ // send response
+ send(req, res, status, headers, msg)
+ }
+}
+
+/**
+ * Get headers from Error object.
+ *
+ * @param {Error} err
+ * @return {object}
+ * @private
+ */
+
+function getErrorHeaders (err) {
+ if (!err.headers || typeof err.headers !== 'object') {
+ return undefined
+ }
+
+ var headers = Object.create(null)
+ var keys = Object.keys(err.headers)
+
+ for (var i = 0; i < keys.length; i++) {
+ var key = keys[i]
+ headers[key] = err.headers[key]
+ }
+
+ return headers
+}
+
+/**
+ * Get status code from Error object.
+ *
+ * @param {Error} err
+ * @return {number}
+ * @private
+ */
+
+function getErrorStatusCode (err) {
+ // check err.status
+ if (typeof err.status === 'number' && err.status >= 400 && err.status < 600) {
+ return err.status
+ }
+
+ // check err.statusCode
+ if (typeof err.statusCode === 'number' && err.statusCode >= 400 && err.statusCode < 600) {
+ return err.statusCode
+ }
+
+ return undefined
+}
+
+/**
+ * Get status code from response.
+ *
+ * @param {OutgoingMessage} res
+ * @return {number}
+ * @private
+ */
+
+function getResponseStatusCode (res) {
+ var status = res.statusCode
+
+ // default status code to 500 if outside valid range
+ if (typeof status !== 'number' || status < 400 || status > 599) {
+ status = 500
+ }
+
+ return status
+}
+
+/**
+ * Send response.
+ *
+ * @param {IncomingMessage} req
+ * @param {OutgoingMessage} res
+ * @param {number} status
+ * @param {object} headers
+ * @param {string} body
+ * @private
+ */
+
+function send (req, res, status, headers, body) {
+ function write () {
+ // response status
+ res.statusCode = status
+ res.statusMessage = statuses[status]
+
+ // response headers
+ setHeaders(res, headers)
+
+ // security header for content sniffing
+ res.setHeader('X-Content-Type-Options', 'nosniff')
+
+ // standard headers
+ res.setHeader('Content-Type', 'text/html; charset=utf-8')
+ res.setHeader('Content-Length', Buffer.byteLength(body, 'utf8'))
+
+ if (req.method === 'HEAD') {
+ res.end()
+ return
+ }
+
+ res.end(body, 'utf8')
+ }
+
+ if (isFinished(req)) {
+ write()
+ return
+ }
+
+ // unpipe everything from the request
+ unpipe(req)
+
+ // flush the request
+ onFinished(req, write)
+ req.resume()
+}
+
+/**
+ * Set response headers from an object.
+ *
+ * @param {OutgoingMessage} res
+ * @param {object} headers
+ * @private
+ */
+
+function setHeaders (res, headers) {
+ if (!headers) {
+ return
+ }
+
+ var keys = Object.keys(headers)
+ for (var i = 0; i < keys.length; i++) {
+ var key = keys[i]
+ res.setHeader(key, headers[key])
+ }
+}
diff --git a/node_modules/finalhandler/node_modules/debug/.jshintrc b/node_modules/finalhandler/node_modules/debug/.jshintrc
new file mode 100644
index 00000000..299877f2
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/.jshintrc
@@ -0,0 +1,3 @@
+{
+ "laxbreak": true
+}
diff --git a/node_modules/finalhandler/node_modules/debug/.npmignore b/node_modules/finalhandler/node_modules/debug/.npmignore
new file mode 100644
index 00000000..7e6163db
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/.npmignore
@@ -0,0 +1,6 @@
+support
+test
+examples
+example
+*.sock
+dist
diff --git a/node_modules/finalhandler/node_modules/debug/History.md b/node_modules/finalhandler/node_modules/debug/History.md
new file mode 100644
index 00000000..854c9711
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/History.md
@@ -0,0 +1,195 @@
+
+2.2.0 / 2015-05-09
+==================
+
+ * package: update "ms" to v0.7.1 (#202, @dougwilson)
+ * README: add logging to file example (#193, @DanielOchoa)
+ * README: fixed a typo (#191, @amir-s)
+ * browser: expose `storage` (#190, @stephenmathieson)
+ * Makefile: add a `distclean` target (#189, @stephenmathieson)
+
+2.1.3 / 2015-03-13
+==================
+
+ * Updated stdout/stderr example (#186)
+ * Updated example/stdout.js to match debug current behaviour
+ * Renamed example/stderr.js to stdout.js
+ * Update Readme.md (#184)
+ * replace high intensity foreground color for bold (#182, #183)
+
+2.1.2 / 2015-03-01
+==================
+
+ * dist: recompile
+ * update "ms" to v0.7.0
+ * package: update "browserify" to v9.0.3
+ * component: fix "ms.js" repo location
+ * changed bower package name
+ * updated documentation about using debug in a browser
+ * fix: security error on safari (#167, #168, @yields)
+
+2.1.1 / 2014-12-29
+==================
+
+ * browser: use `typeof` to check for `console` existence
+ * browser: check for `console.log` truthiness (fix IE 8/9)
+ * browser: add support for Chrome apps
+ * Readme: added Windows usage remarks
+ * Add `bower.json` to properly support bower install
+
+2.1.0 / 2014-10-15
+==================
+
+ * node: implement `DEBUG_FD` env variable support
+ * package: update "browserify" to v6.1.0
+ * package: add "license" field to package.json (#135, @panuhorsmalahti)
+
+2.0.0 / 2014-09-01
+==================
+
+ * package: update "browserify" to v5.11.0
+ * node: use stderr rather than stdout for logging (#29, @stephenmathieson)
+
+1.0.4 / 2014-07-15
+==================
+
+ * dist: recompile
+ * example: remove `console.info()` log usage
+ * example: add "Content-Type" UTF-8 header to browser example
+ * browser: place %c marker after the space character
+ * browser: reset the "content" color via `color: inherit`
+ * browser: add colors support for Firefox >= v31
+ * debug: prefer an instance `log()` function over the global one (#119)
+ * Readme: update documentation about styled console logs for FF v31 (#116, @wryk)
+
+1.0.3 / 2014-07-09
+==================
+
+ * Add support for multiple wildcards in namespaces (#122, @seegno)
+ * browser: fix lint
+
+1.0.2 / 2014-06-10
+==================
+
+ * browser: update color palette (#113, @gscottolson)
+ * common: make console logging function configurable (#108, @timoxley)
+ * node: fix %o colors on old node <= 0.8.x
+ * Makefile: find node path using shell/which (#109, @timoxley)
+
+1.0.1 / 2014-06-06
+==================
+
+ * browser: use `removeItem()` to clear localStorage
+ * browser, node: don't set DEBUG if namespaces is undefined (#107, @leedm777)
+ * package: add "contributors" section
+ * node: fix comment typo
+ * README: list authors
+
+1.0.0 / 2014-06-04
+==================
+
+ * make ms diff be global, not be scope
+ * debug: ignore empty strings in enable()
+ * node: make DEBUG_COLORS able to disable coloring
+ * *: export the `colors` array
+ * npmignore: don't publish the `dist` dir
+ * Makefile: refactor to use browserify
+ * package: add "browserify" as a dev dependency
+ * Readme: add Web Inspector Colors section
+ * node: reset terminal color for the debug content
+ * node: map "%o" to `util.inspect()`
+ * browser: map "%j" to `JSON.stringify()`
+ * debug: add custom "formatters"
+ * debug: use "ms" module for humanizing the diff
+ * Readme: add "bash" syntax highlighting
+ * browser: add Firebug color support
+ * browser: add colors for WebKit browsers
+ * node: apply log to `console`
+ * rewrite: abstract common logic for Node & browsers
+ * add .jshintrc file
+
+0.8.1 / 2014-04-14
+==================
+
+ * package: re-add the "component" section
+
+0.8.0 / 2014-03-30
+==================
+
+ * add `enable()` method for nodejs. Closes #27
+ * change from stderr to stdout
+ * remove unnecessary index.js file
+
+0.7.4 / 2013-11-13
+==================
+
+ * remove "browserify" key from package.json (fixes something in browserify)
+
+0.7.3 / 2013-10-30
+==================
+
+ * fix: catch localStorage security error when cookies are blocked (Chrome)
+ * add debug(err) support. Closes #46
+ * add .browser prop to package.json. Closes #42
+
+0.7.2 / 2013-02-06
+==================
+
+ * fix package.json
+ * fix: Mobile Safari (private mode) is broken with debug
+ * fix: Use unicode to send escape character to shell instead of octal to work with strict mode javascript
+
+0.7.1 / 2013-02-05
+==================
+
+ * add repository URL to package.json
+ * add DEBUG_COLORED to force colored output
+ * add browserify support
+ * fix component. Closes #24
+
+0.7.0 / 2012-05-04
+==================
+
+ * Added .component to package.json
+ * Added debug.component.js build
+
+0.6.0 / 2012-03-16
+==================
+
+ * Added support for "-" prefix in DEBUG [Vinay Pulim]
+ * Added `.enabled` flag to the node version [TooTallNate]
+
+0.5.0 / 2012-02-02
+==================
+
+ * Added: humanize diffs. Closes #8
+ * Added `debug.disable()` to the CS variant
+ * Removed padding. Closes #10
+ * Fixed: persist client-side variant again. Closes #9
+
+0.4.0 / 2012-02-01
+==================
+
+ * Added browser variant support for older browsers [TooTallNate]
+ * Added `debug.enable('project:*')` to browser variant [TooTallNate]
+ * Added padding to diff (moved it to the right)
+
+0.3.0 / 2012-01-26
+==================
+
+ * Added millisecond diff when isatty, otherwise UTC string
+
+0.2.0 / 2012-01-22
+==================
+
+ * Added wildcard support
+
+0.1.0 / 2011-12-02
+==================
+
+ * Added: remove colors unless stderr isatty [TooTallNate]
+
+0.0.1 / 2010-01-03
+==================
+
+ * Initial release
diff --git a/node_modules/finalhandler/node_modules/debug/Makefile b/node_modules/finalhandler/node_modules/debug/Makefile
new file mode 100644
index 00000000..5cf4a596
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/Makefile
@@ -0,0 +1,36 @@
+
+# get Makefile directory name: http://stackoverflow.com/a/5982798/376773
+THIS_MAKEFILE_PATH:=$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
+THIS_DIR:=$(shell cd $(dir $(THIS_MAKEFILE_PATH));pwd)
+
+# BIN directory
+BIN := $(THIS_DIR)/node_modules/.bin
+
+# applications
+NODE ?= $(shell which node)
+NPM ?= $(NODE) $(shell which npm)
+BROWSERIFY ?= $(NODE) $(BIN)/browserify
+
+all: dist/debug.js
+
+install: node_modules
+
+clean:
+ @rm -rf dist
+
+dist:
+ @mkdir -p $@
+
+dist/debug.js: node_modules browser.js debug.js dist
+ @$(BROWSERIFY) \
+ --standalone debug \
+ . > $@
+
+distclean: clean
+ @rm -rf node_modules
+
+node_modules: package.json
+ @NODE_ENV= $(NPM) install
+ @touch node_modules
+
+.PHONY: all install clean distclean
diff --git a/node_modules/finalhandler/node_modules/debug/Readme.md b/node_modules/finalhandler/node_modules/debug/Readme.md
new file mode 100644
index 00000000..b4f45e3c
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/Readme.md
@@ -0,0 +1,188 @@
+# debug
+
+ tiny node.js debugging utility modelled after node core's debugging technique.
+
+## Installation
+
+```bash
+$ npm install debug
+```
+
+## Usage
+
+ With `debug` you simply invoke the exported function to generate your debug function, passing it a name which will determine if a noop function is returned, or a decorated `console.error`, so all of the `console` format string goodies you're used to work fine. A unique color is selected per-function for visibility.
+
+Example _app.js_:
+
+```js
+var debug = require('debug')('http')
+ , http = require('http')
+ , name = 'My App';
+
+// fake app
+
+debug('booting %s', name);
+
+http.createServer(function(req, res){
+ debug(req.method + ' ' + req.url);
+ res.end('hello\n');
+}).listen(3000, function(){
+ debug('listening');
+});
+
+// fake worker of some kind
+
+require('./worker');
+```
+
+Example _worker.js_:
+
+```js
+var debug = require('debug')('worker');
+
+setInterval(function(){
+ debug('doing some work');
+}, 1000);
+```
+
+ The __DEBUG__ environment variable is then used to enable these based on space or comma-delimited names. Here are some examples:
+
+ 
+
+ 
+
+#### Windows note
+
+ On Windows the environment variable is set using the `set` command.
+
+ ```cmd
+ set DEBUG=*,-not_this
+ ```
+
+Then, run the program to be debugged as usual.
+
+## Millisecond diff
+
+ When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls.
+
+ 
+
+ When stdout is not a TTY, `Date#toUTCString()` is used, making it more useful for logging the debug information as shown below:
+
+ 
+
+## Conventions
+
+ If you're using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser".
+
+## Wildcards
+
+ The `*` character may be used as a wildcard. Suppose for example your library has debuggers named "connect:bodyParser", "connect:compress", "connect:session", instead of listing all three with `DEBUG=connect:bodyParser,connect:compress,connect:session`, you may simply do `DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`.
+
+ You can also exclude specific debuggers by prefixing them with a "-" character. For example, `DEBUG=*,-connect:*` would include all debuggers except those starting with "connect:".
+
+## Browser support
+
+ Debug works in the browser as well, currently persisted by `localStorage`. Consider the situation shown below where you have `worker:a` and `worker:b`, and wish to debug both. Somewhere in the code on your page, include:
+
+```js
+window.myDebug = require("debug");
+```
+
+ ("debug" is a global object in the browser so we give this object a different name.) When your page is open in the browser, type the following in the console:
+
+```js
+myDebug.enable("worker:*")
+```
+
+ Refresh the page. Debug output will continue to be sent to the console until it is disabled by typing `myDebug.disable()` in the console.
+
+```js
+a = debug('worker:a');
+b = debug('worker:b');
+
+setInterval(function(){
+ a('doing some work');
+}, 1000);
+
+setInterval(function(){
+ b('doing some work');
+}, 1200);
+```
+
+#### Web Inspector Colors
+
+ Colors are also enabled on "Web Inspectors" that understand the `%c` formatting
+ option. These are WebKit web inspectors, Firefox ([since version
+ 31](https://hacks.mozilla.org/2014/05/editable-box-model-multiple-selection-sublime-text-keys-much-more-firefox-developer-tools-episode-31/))
+ and the Firebug plugin for Firefox (any version).
+
+ Colored output looks something like:
+
+ 
+
+### stderr vs stdout
+
+You can set an alternative logging method per-namespace by overriding the `log` method on a per-namespace or globally:
+
+Example _stdout.js_:
+
+```js
+var debug = require('debug');
+var error = debug('app:error');
+
+// by default stderr is used
+error('goes to stderr!');
+
+var log = debug('app:log');
+// set this namespace to log via console.log
+log.log = console.log.bind(console); // don't forget to bind to console!
+log('goes to stdout');
+error('still goes to stderr!');
+
+// set all output to go via console.info
+// overrides all per-namespace log settings
+debug.log = console.info.bind(console);
+error('now goes to stdout via console.info');
+log('still goes to stdout, but via console.info now');
+```
+
+### Save debug output to a file
+
+You can save all debug statements to a file by piping them.
+
+Example:
+
+```bash
+$ DEBUG_FD=3 node your-app.js 3> whatever.log
+```
+
+## Authors
+
+ - TJ Holowaychuk
+ - Nathan Rajlich
+
+## License
+
+(The MIT License)
+
+Copyright (c) 2014 TJ Holowaychuk <tj@vision-media.ca>
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/finalhandler/node_modules/debug/bower.json b/node_modules/finalhandler/node_modules/debug/bower.json
new file mode 100644
index 00000000..6af573ff
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/bower.json
@@ -0,0 +1,28 @@
+{
+ "name": "visionmedia-debug",
+ "main": "dist/debug.js",
+ "version": "2.2.0",
+ "homepage": "https://github.com/visionmedia/debug",
+ "authors": [
+ "TJ Holowaychuk "
+ ],
+ "description": "visionmedia-debug",
+ "moduleType": [
+ "amd",
+ "es6",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "visionmedia",
+ "debug"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests"
+ ]
+}
diff --git a/node_modules/finalhandler/node_modules/debug/browser.js b/node_modules/finalhandler/node_modules/debug/browser.js
new file mode 100644
index 00000000..7c764522
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/browser.js
@@ -0,0 +1,168 @@
+
+/**
+ * This is the web browser implementation of `debug()`.
+ *
+ * Expose `debug()` as the module.
+ */
+
+exports = module.exports = require('./debug');
+exports.log = log;
+exports.formatArgs = formatArgs;
+exports.save = save;
+exports.load = load;
+exports.useColors = useColors;
+exports.storage = 'undefined' != typeof chrome
+ && 'undefined' != typeof chrome.storage
+ ? chrome.storage.local
+ : localstorage();
+
+/**
+ * Colors.
+ */
+
+exports.colors = [
+ 'lightseagreen',
+ 'forestgreen',
+ 'goldenrod',
+ 'dodgerblue',
+ 'darkorchid',
+ 'crimson'
+];
+
+/**
+ * Currently only WebKit-based Web Inspectors, Firefox >= v31,
+ * and the Firebug extension (any Firefox version) are known
+ * to support "%c" CSS customizations.
+ *
+ * TODO: add a `localStorage` variable to explicitly enable/disable colors
+ */
+
+function useColors() {
+ // is webkit? http://stackoverflow.com/a/16459606/376773
+ return ('WebkitAppearance' in document.documentElement.style) ||
+ // is firebug? http://stackoverflow.com/a/398120/376773
+ (window.console && (console.firebug || (console.exception && console.table))) ||
+ // is firefox >= v31?
+ // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
+ (navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31);
+}
+
+/**
+ * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default.
+ */
+
+exports.formatters.j = function(v) {
+ return JSON.stringify(v);
+};
+
+
+/**
+ * Colorize log arguments if enabled.
+ *
+ * @api public
+ */
+
+function formatArgs() {
+ var args = arguments;
+ var useColors = this.useColors;
+
+ args[0] = (useColors ? '%c' : '')
+ + this.namespace
+ + (useColors ? ' %c' : ' ')
+ + args[0]
+ + (useColors ? '%c ' : ' ')
+ + '+' + exports.humanize(this.diff);
+
+ if (!useColors) return args;
+
+ var c = 'color: ' + this.color;
+ args = [args[0], c, 'color: inherit'].concat(Array.prototype.slice.call(args, 1));
+
+ // the final "%c" is somewhat tricky, because there could be other
+ // arguments passed either before or after the %c, so we need to
+ // figure out the correct index to insert the CSS into
+ var index = 0;
+ var lastC = 0;
+ args[0].replace(/%[a-z%]/g, function(match) {
+ if ('%%' === match) return;
+ index++;
+ if ('%c' === match) {
+ // we only are interested in the *last* %c
+ // (the user may have provided their own)
+ lastC = index;
+ }
+ });
+
+ args.splice(lastC, 0, c);
+ return args;
+}
+
+/**
+ * Invokes `console.log()` when available.
+ * No-op when `console.log` is not a "function".
+ *
+ * @api public
+ */
+
+function log() {
+ // this hackery is required for IE8/9, where
+ // the `console.log` function doesn't have 'apply'
+ return 'object' === typeof console
+ && console.log
+ && Function.prototype.apply.call(console.log, console, arguments);
+}
+
+/**
+ * Save `namespaces`.
+ *
+ * @param {String} namespaces
+ * @api private
+ */
+
+function save(namespaces) {
+ try {
+ if (null == namespaces) {
+ exports.storage.removeItem('debug');
+ } else {
+ exports.storage.debug = namespaces;
+ }
+ } catch(e) {}
+}
+
+/**
+ * Load `namespaces`.
+ *
+ * @return {String} returns the previously persisted debug modes
+ * @api private
+ */
+
+function load() {
+ var r;
+ try {
+ r = exports.storage.debug;
+ } catch(e) {}
+ return r;
+}
+
+/**
+ * Enable namespaces listed in `localStorage.debug` initially.
+ */
+
+exports.enable(load());
+
+/**
+ * Localstorage attempts to return the localstorage.
+ *
+ * This is necessary because safari throws
+ * when a user disables cookies/localstorage
+ * and you attempt to access it.
+ *
+ * @return {LocalStorage}
+ * @api private
+ */
+
+function localstorage(){
+ try {
+ return window.localStorage;
+ } catch (e) {}
+}
diff --git a/node_modules/finalhandler/node_modules/debug/component.json b/node_modules/finalhandler/node_modules/debug/component.json
new file mode 100644
index 00000000..ca106372
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/component.json
@@ -0,0 +1,19 @@
+{
+ "name": "debug",
+ "repo": "visionmedia/debug",
+ "description": "small debugging utility",
+ "version": "2.2.0",
+ "keywords": [
+ "debug",
+ "log",
+ "debugger"
+ ],
+ "main": "browser.js",
+ "scripts": [
+ "browser.js",
+ "debug.js"
+ ],
+ "dependencies": {
+ "rauchg/ms.js": "0.7.1"
+ }
+}
diff --git a/node_modules/finalhandler/node_modules/debug/debug.js b/node_modules/finalhandler/node_modules/debug/debug.js
new file mode 100644
index 00000000..7571a860
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/debug.js
@@ -0,0 +1,197 @@
+
+/**
+ * This is the common logic for both the Node.js and web browser
+ * implementations of `debug()`.
+ *
+ * Expose `debug()` as the module.
+ */
+
+exports = module.exports = debug;
+exports.coerce = coerce;
+exports.disable = disable;
+exports.enable = enable;
+exports.enabled = enabled;
+exports.humanize = require('ms');
+
+/**
+ * The currently active debug mode names, and names to skip.
+ */
+
+exports.names = [];
+exports.skips = [];
+
+/**
+ * Map of special "%n" handling functions, for the debug "format" argument.
+ *
+ * Valid key names are a single, lowercased letter, i.e. "n".
+ */
+
+exports.formatters = {};
+
+/**
+ * Previously assigned color.
+ */
+
+var prevColor = 0;
+
+/**
+ * Previous log timestamp.
+ */
+
+var prevTime;
+
+/**
+ * Select a color.
+ *
+ * @return {Number}
+ * @api private
+ */
+
+function selectColor() {
+ return exports.colors[prevColor++ % exports.colors.length];
+}
+
+/**
+ * Create a debugger with the given `namespace`.
+ *
+ * @param {String} namespace
+ * @return {Function}
+ * @api public
+ */
+
+function debug(namespace) {
+
+ // define the `disabled` version
+ function disabled() {
+ }
+ disabled.enabled = false;
+
+ // define the `enabled` version
+ function enabled() {
+
+ var self = enabled;
+
+ // set `diff` timestamp
+ var curr = +new Date();
+ var ms = curr - (prevTime || curr);
+ self.diff = ms;
+ self.prev = prevTime;
+ self.curr = curr;
+ prevTime = curr;
+
+ // add the `color` if not set
+ if (null == self.useColors) self.useColors = exports.useColors();
+ if (null == self.color && self.useColors) self.color = selectColor();
+
+ var args = Array.prototype.slice.call(arguments);
+
+ args[0] = exports.coerce(args[0]);
+
+ if ('string' !== typeof args[0]) {
+ // anything else let's inspect with %o
+ args = ['%o'].concat(args);
+ }
+
+ // apply any `formatters` transformations
+ var index = 0;
+ args[0] = args[0].replace(/%([a-z%])/g, function(match, format) {
+ // if we encounter an escaped % then don't increase the array index
+ if (match === '%%') return match;
+ index++;
+ var formatter = exports.formatters[format];
+ if ('function' === typeof formatter) {
+ var val = args[index];
+ match = formatter.call(self, val);
+
+ // now we need to remove `args[index]` since it's inlined in the `format`
+ args.splice(index, 1);
+ index--;
+ }
+ return match;
+ });
+
+ if ('function' === typeof exports.formatArgs) {
+ args = exports.formatArgs.apply(self, args);
+ }
+ var logFn = enabled.log || exports.log || console.log.bind(console);
+ logFn.apply(self, args);
+ }
+ enabled.enabled = true;
+
+ var fn = exports.enabled(namespace) ? enabled : disabled;
+
+ fn.namespace = namespace;
+
+ return fn;
+}
+
+/**
+ * Enables a debug mode by namespaces. This can include modes
+ * separated by a colon and wildcards.
+ *
+ * @param {String} namespaces
+ * @api public
+ */
+
+function enable(namespaces) {
+ exports.save(namespaces);
+
+ var split = (namespaces || '').split(/[\s,]+/);
+ var len = split.length;
+
+ for (var i = 0; i < len; i++) {
+ if (!split[i]) continue; // ignore empty strings
+ namespaces = split[i].replace(/\*/g, '.*?');
+ if (namespaces[0] === '-') {
+ exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$'));
+ } else {
+ exports.names.push(new RegExp('^' + namespaces + '$'));
+ }
+ }
+}
+
+/**
+ * Disable debug output.
+ *
+ * @api public
+ */
+
+function disable() {
+ exports.enable('');
+}
+
+/**
+ * Returns true if the given mode name is enabled, false otherwise.
+ *
+ * @param {String} name
+ * @return {Boolean}
+ * @api public
+ */
+
+function enabled(name) {
+ var i, len;
+ for (i = 0, len = exports.skips.length; i < len; i++) {
+ if (exports.skips[i].test(name)) {
+ return false;
+ }
+ }
+ for (i = 0, len = exports.names.length; i < len; i++) {
+ if (exports.names[i].test(name)) {
+ return true;
+ }
+ }
+ return false;
+}
+
+/**
+ * Coerce `val`.
+ *
+ * @param {Mixed} val
+ * @return {Mixed}
+ * @api private
+ */
+
+function coerce(val) {
+ if (val instanceof Error) return val.stack || val.message;
+ return val;
+}
diff --git a/node_modules/finalhandler/node_modules/debug/node.js b/node_modules/finalhandler/node_modules/debug/node.js
new file mode 100644
index 00000000..1d392a81
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/node.js
@@ -0,0 +1,209 @@
+
+/**
+ * Module dependencies.
+ */
+
+var tty = require('tty');
+var util = require('util');
+
+/**
+ * This is the Node.js implementation of `debug()`.
+ *
+ * Expose `debug()` as the module.
+ */
+
+exports = module.exports = require('./debug');
+exports.log = log;
+exports.formatArgs = formatArgs;
+exports.save = save;
+exports.load = load;
+exports.useColors = useColors;
+
+/**
+ * Colors.
+ */
+
+exports.colors = [6, 2, 3, 4, 5, 1];
+
+/**
+ * The file descriptor to write the `debug()` calls to.
+ * Set the `DEBUG_FD` env variable to override with another value. i.e.:
+ *
+ * $ DEBUG_FD=3 node script.js 3>debug.log
+ */
+
+var fd = parseInt(process.env.DEBUG_FD, 10) || 2;
+var stream = 1 === fd ? process.stdout :
+ 2 === fd ? process.stderr :
+ createWritableStdioStream(fd);
+
+/**
+ * Is stdout a TTY? Colored output is enabled when `true`.
+ */
+
+function useColors() {
+ var debugColors = (process.env.DEBUG_COLORS || '').trim().toLowerCase();
+ if (0 === debugColors.length) {
+ return tty.isatty(fd);
+ } else {
+ return '0' !== debugColors
+ && 'no' !== debugColors
+ && 'false' !== debugColors
+ && 'disabled' !== debugColors;
+ }
+}
+
+/**
+ * Map %o to `util.inspect()`, since Node doesn't do that out of the box.
+ */
+
+var inspect = (4 === util.inspect.length ?
+ // node <= 0.8.x
+ function (v, colors) {
+ return util.inspect(v, void 0, void 0, colors);
+ } :
+ // node > 0.8.x
+ function (v, colors) {
+ return util.inspect(v, { colors: colors });
+ }
+);
+
+exports.formatters.o = function(v) {
+ return inspect(v, this.useColors)
+ .replace(/\s*\n\s*/g, ' ');
+};
+
+/**
+ * Adds ANSI color escape codes if enabled.
+ *
+ * @api public
+ */
+
+function formatArgs() {
+ var args = arguments;
+ var useColors = this.useColors;
+ var name = this.namespace;
+
+ if (useColors) {
+ var c = this.color;
+
+ args[0] = ' \u001b[3' + c + ';1m' + name + ' '
+ + '\u001b[0m'
+ + args[0] + '\u001b[3' + c + 'm'
+ + ' +' + exports.humanize(this.diff) + '\u001b[0m';
+ } else {
+ args[0] = new Date().toUTCString()
+ + ' ' + name + ' ' + args[0];
+ }
+ return args;
+}
+
+/**
+ * Invokes `console.error()` with the specified arguments.
+ */
+
+function log() {
+ return stream.write(util.format.apply(this, arguments) + '\n');
+}
+
+/**
+ * Save `namespaces`.
+ *
+ * @param {String} namespaces
+ * @api private
+ */
+
+function save(namespaces) {
+ if (null == namespaces) {
+ // If you set a process.env field to null or undefined, it gets cast to the
+ // string 'null' or 'undefined'. Just delete instead.
+ delete process.env.DEBUG;
+ } else {
+ process.env.DEBUG = namespaces;
+ }
+}
+
+/**
+ * Load `namespaces`.
+ *
+ * @return {String} returns the previously persisted debug modes
+ * @api private
+ */
+
+function load() {
+ return process.env.DEBUG;
+}
+
+/**
+ * Copied from `node/src/node.js`.
+ *
+ * XXX: It's lame that node doesn't expose this API out-of-the-box. It also
+ * relies on the undocumented `tty_wrap.guessHandleType()` which is also lame.
+ */
+
+function createWritableStdioStream (fd) {
+ var stream;
+ var tty_wrap = process.binding('tty_wrap');
+
+ // Note stream._type is used for test-module-load-list.js
+
+ switch (tty_wrap.guessHandleType(fd)) {
+ case 'TTY':
+ stream = new tty.WriteStream(fd);
+ stream._type = 'tty';
+
+ // Hack to have stream not keep the event loop alive.
+ // See https://github.com/joyent/node/issues/1726
+ if (stream._handle && stream._handle.unref) {
+ stream._handle.unref();
+ }
+ break;
+
+ case 'FILE':
+ var fs = require('fs');
+ stream = new fs.SyncWriteStream(fd, { autoClose: false });
+ stream._type = 'fs';
+ break;
+
+ case 'PIPE':
+ case 'TCP':
+ var net = require('net');
+ stream = new net.Socket({
+ fd: fd,
+ readable: false,
+ writable: true
+ });
+
+ // FIXME Should probably have an option in net.Socket to create a
+ // stream from an existing fd which is writable only. But for now
+ // we'll just add this hack and set the `readable` member to false.
+ // Test: ./node test/fixtures/echo.js < /etc/passwd
+ stream.readable = false;
+ stream.read = null;
+ stream._type = 'pipe';
+
+ // FIXME Hack to have stream not keep the event loop alive.
+ // See https://github.com/joyent/node/issues/1726
+ if (stream._handle && stream._handle.unref) {
+ stream._handle.unref();
+ }
+ break;
+
+ default:
+ // Probably an error on in uv_guess_handle()
+ throw new Error('Implement me. Unknown stream file type!');
+ }
+
+ // For supporting legacy API we put the FD here.
+ stream.fd = fd;
+
+ stream._isStdio = true;
+
+ return stream;
+}
+
+/**
+ * Enable namespaces listed in `process.env.DEBUG` initially.
+ */
+
+exports.enable(load());
diff --git a/node_modules/finalhandler/node_modules/debug/package.json b/node_modules/finalhandler/node_modules/debug/package.json
new file mode 100644
index 00000000..e419efa0
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/debug/package.json
@@ -0,0 +1,106 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "debug@~2.2.0",
+ "scope": null,
+ "escapedName": "debug",
+ "name": "debug",
+ "rawSpec": "~2.2.0",
+ "spec": ">=2.2.0 <2.3.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/finalhandler"
+ ]
+ ],
+ "_from": "debug@>=2.2.0 <2.3.0",
+ "_id": "debug@2.2.0",
+ "_inCache": true,
+ "_location": "/finalhandler/debug",
+ "_nodeVersion": "0.12.2",
+ "_npmUser": {
+ "name": "tootallnate",
+ "email": "nathan@tootallnate.net"
+ },
+ "_npmVersion": "2.7.4",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "debug@~2.2.0",
+ "scope": null,
+ "escapedName": "debug",
+ "name": "debug",
+ "rawSpec": "~2.2.0",
+ "spec": ">=2.2.0 <2.3.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/finalhandler"
+ ],
+ "_resolved": "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz",
+ "_shasum": "f87057e995b1a1f6ae6a4960664137bc56f039da",
+ "_shrinkwrap": null,
+ "_spec": "debug@~2.2.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/finalhandler",
+ "author": {
+ "name": "TJ Holowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ "browser": "./browser.js",
+ "bugs": {
+ "url": "https://github.com/visionmedia/debug/issues"
+ },
+ "component": {
+ "scripts": {
+ "debug/index.js": "browser.js",
+ "debug/debug.js": "debug.js"
+ }
+ },
+ "contributors": [
+ {
+ "name": "Nathan Rajlich",
+ "email": "nathan@tootallnate.net",
+ "url": "http://n8.io"
+ }
+ ],
+ "dependencies": {
+ "ms": "0.7.1"
+ },
+ "description": "small debugging utility",
+ "devDependencies": {
+ "browserify": "9.0.3",
+ "mocha": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "f87057e995b1a1f6ae6a4960664137bc56f039da",
+ "tarball": "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz"
+ },
+ "gitHead": "b38458422b5aa8aa6d286b10dfe427e8a67e2b35",
+ "homepage": "https://github.com/visionmedia/debug",
+ "keywords": [
+ "debug",
+ "log",
+ "debugger"
+ ],
+ "license": "MIT",
+ "main": "./node.js",
+ "maintainers": [
+ {
+ "name": "tjholowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ {
+ "name": "tootallnate",
+ "email": "nathan@tootallnate.net"
+ }
+ ],
+ "name": "debug",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/visionmedia/debug.git"
+ },
+ "scripts": {},
+ "version": "2.2.0"
+}
diff --git a/node_modules/finalhandler/node_modules/ms/.npmignore b/node_modules/finalhandler/node_modules/ms/.npmignore
new file mode 100644
index 00000000..d1aa0ce4
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/ms/.npmignore
@@ -0,0 +1,5 @@
+node_modules
+test
+History.md
+Makefile
+component.json
diff --git a/node_modules/finalhandler/node_modules/ms/History.md b/node_modules/finalhandler/node_modules/ms/History.md
new file mode 100644
index 00000000..32fdfc17
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/ms/History.md
@@ -0,0 +1,66 @@
+
+0.7.1 / 2015-04-20
+==================
+
+ * prevent extraordinary long inputs (@evilpacket)
+ * Fixed broken readme link
+
+0.7.0 / 2014-11-24
+==================
+
+ * add time abbreviations, updated tests and readme for the new units
+ * fix example in the readme.
+ * add LICENSE file
+
+0.6.2 / 2013-12-05
+==================
+
+ * Adding repository section to package.json to suppress warning from NPM.
+
+0.6.1 / 2013-05-10
+==================
+
+ * fix singularization [visionmedia]
+
+0.6.0 / 2013-03-15
+==================
+
+ * fix minutes
+
+0.5.1 / 2013-02-24
+==================
+
+ * add component namespace
+
+0.5.0 / 2012-11-09
+==================
+
+ * add short formatting as default and .long option
+ * add .license property to component.json
+ * add version to component.json
+
+0.4.0 / 2012-10-22
+==================
+
+ * add rounding to fix crazy decimals
+
+0.3.0 / 2012-09-07
+==================
+
+ * fix `ms()` [visionmedia]
+
+0.2.0 / 2012-09-03
+==================
+
+ * add component.json [visionmedia]
+ * add days support [visionmedia]
+ * add hours support [visionmedia]
+ * add minutes support [visionmedia]
+ * add seconds support [visionmedia]
+ * add ms string support [visionmedia]
+ * refactor tests to facilitate ms(number) [visionmedia]
+
+0.1.0 / 2012-03-07
+==================
+
+ * Initial release
diff --git a/node_modules/finalhandler/node_modules/ms/LICENSE b/node_modules/finalhandler/node_modules/ms/LICENSE
new file mode 100644
index 00000000..6c07561b
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/ms/LICENSE
@@ -0,0 +1,20 @@
+(The MIT License)
+
+Copyright (c) 2014 Guillermo Rauch
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/finalhandler/node_modules/ms/README.md b/node_modules/finalhandler/node_modules/ms/README.md
new file mode 100644
index 00000000..9b4fd035
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/ms/README.md
@@ -0,0 +1,35 @@
+# ms.js: miliseconds conversion utility
+
+```js
+ms('2 days') // 172800000
+ms('1d') // 86400000
+ms('10h') // 36000000
+ms('2.5 hrs') // 9000000
+ms('2h') // 7200000
+ms('1m') // 60000
+ms('5s') // 5000
+ms('100') // 100
+```
+
+```js
+ms(60000) // "1m"
+ms(2 * 60000) // "2m"
+ms(ms('10 hours')) // "10h"
+```
+
+```js
+ms(60000, { long: true }) // "1 minute"
+ms(2 * 60000, { long: true }) // "2 minutes"
+ms(ms('10 hours'), { long: true }) // "10 hours"
+```
+
+- Node/Browser compatible. Published as [`ms`](https://www.npmjs.org/package/ms) in [NPM](http://nodejs.org/download).
+- If a number is supplied to `ms`, a string with a unit is returned.
+- If a string that contains the number is supplied, it returns it as
+a number (e.g: it returns `100` for `'100'`).
+- If you pass a string with a number and a valid unit, the number of
+equivalent ms is returned.
+
+## License
+
+MIT
diff --git a/node_modules/finalhandler/node_modules/ms/index.js b/node_modules/finalhandler/node_modules/ms/index.js
new file mode 100644
index 00000000..4f927716
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/ms/index.js
@@ -0,0 +1,125 @@
+/**
+ * Helpers.
+ */
+
+var s = 1000;
+var m = s * 60;
+var h = m * 60;
+var d = h * 24;
+var y = d * 365.25;
+
+/**
+ * Parse or format the given `val`.
+ *
+ * Options:
+ *
+ * - `long` verbose formatting [false]
+ *
+ * @param {String|Number} val
+ * @param {Object} options
+ * @return {String|Number}
+ * @api public
+ */
+
+module.exports = function(val, options){
+ options = options || {};
+ if ('string' == typeof val) return parse(val);
+ return options.long
+ ? long(val)
+ : short(val);
+};
+
+/**
+ * Parse the given `str` and return milliseconds.
+ *
+ * @param {String} str
+ * @return {Number}
+ * @api private
+ */
+
+function parse(str) {
+ str = '' + str;
+ if (str.length > 10000) return;
+ var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(str);
+ if (!match) return;
+ var n = parseFloat(match[1]);
+ var type = (match[2] || 'ms').toLowerCase();
+ switch (type) {
+ case 'years':
+ case 'year':
+ case 'yrs':
+ case 'yr':
+ case 'y':
+ return n * y;
+ case 'days':
+ case 'day':
+ case 'd':
+ return n * d;
+ case 'hours':
+ case 'hour':
+ case 'hrs':
+ case 'hr':
+ case 'h':
+ return n * h;
+ case 'minutes':
+ case 'minute':
+ case 'mins':
+ case 'min':
+ case 'm':
+ return n * m;
+ case 'seconds':
+ case 'second':
+ case 'secs':
+ case 'sec':
+ case 's':
+ return n * s;
+ case 'milliseconds':
+ case 'millisecond':
+ case 'msecs':
+ case 'msec':
+ case 'ms':
+ return n;
+ }
+}
+
+/**
+ * Short format for `ms`.
+ *
+ * @param {Number} ms
+ * @return {String}
+ * @api private
+ */
+
+function short(ms) {
+ if (ms >= d) return Math.round(ms / d) + 'd';
+ if (ms >= h) return Math.round(ms / h) + 'h';
+ if (ms >= m) return Math.round(ms / m) + 'm';
+ if (ms >= s) return Math.round(ms / s) + 's';
+ return ms + 'ms';
+}
+
+/**
+ * Long format for `ms`.
+ *
+ * @param {Number} ms
+ * @return {String}
+ * @api private
+ */
+
+function long(ms) {
+ return plural(ms, d, 'day')
+ || plural(ms, h, 'hour')
+ || plural(ms, m, 'minute')
+ || plural(ms, s, 'second')
+ || ms + ' ms';
+}
+
+/**
+ * Pluralization helper.
+ */
+
+function plural(ms, n, name) {
+ if (ms < n) return;
+ if (ms < n * 1.5) return Math.floor(ms / n) + ' ' + name;
+ return Math.ceil(ms / n) + ' ' + name + 's';
+}
diff --git a/node_modules/finalhandler/node_modules/ms/package.json b/node_modules/finalhandler/node_modules/ms/package.json
new file mode 100644
index 00000000..42e03587
--- /dev/null
+++ b/node_modules/finalhandler/node_modules/ms/package.json
@@ -0,0 +1,82 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "ms@0.7.1",
+ "scope": null,
+ "escapedName": "ms",
+ "name": "ms",
+ "rawSpec": "0.7.1",
+ "spec": "0.7.1",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/finalhandler/node_modules/debug"
+ ]
+ ],
+ "_from": "ms@0.7.1",
+ "_id": "ms@0.7.1",
+ "_inCache": true,
+ "_location": "/finalhandler/ms",
+ "_nodeVersion": "0.12.2",
+ "_npmUser": {
+ "name": "rauchg",
+ "email": "rauchg@gmail.com"
+ },
+ "_npmVersion": "2.7.5",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "ms@0.7.1",
+ "scope": null,
+ "escapedName": "ms",
+ "name": "ms",
+ "rawSpec": "0.7.1",
+ "spec": "0.7.1",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/finalhandler/debug"
+ ],
+ "_resolved": "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz",
+ "_shasum": "9cd13c03adbff25b65effde7ce864ee952017098",
+ "_shrinkwrap": null,
+ "_spec": "ms@0.7.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/finalhandler/node_modules/debug",
+ "bugs": {
+ "url": "https://github.com/guille/ms.js/issues"
+ },
+ "component": {
+ "scripts": {
+ "ms/index.js": "index.js"
+ }
+ },
+ "dependencies": {},
+ "description": "Tiny ms conversion utility",
+ "devDependencies": {
+ "expect.js": "*",
+ "mocha": "*",
+ "serve": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "9cd13c03adbff25b65effde7ce864ee952017098",
+ "tarball": "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz"
+ },
+ "gitHead": "713dcf26d9e6fd9dbc95affe7eff9783b7f1b909",
+ "homepage": "https://github.com/guille/ms.js",
+ "main": "./index",
+ "maintainers": [
+ {
+ "name": "rauchg",
+ "email": "rauchg@gmail.com"
+ }
+ ],
+ "name": "ms",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/guille/ms.js.git"
+ },
+ "scripts": {},
+ "version": "0.7.1"
+}
diff --git a/node_modules/finalhandler/package.json b/node_modules/finalhandler/package.json
new file mode 100644
index 00000000..db19f5c6
--- /dev/null
+++ b/node_modules/finalhandler/package.json
@@ -0,0 +1,109 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "finalhandler@0.5.1",
+ "scope": null,
+ "escapedName": "finalhandler",
+ "name": "finalhandler",
+ "rawSpec": "0.5.1",
+ "spec": "0.5.1",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express"
+ ]
+ ],
+ "_from": "finalhandler@0.5.1",
+ "_id": "finalhandler@0.5.1",
+ "_inCache": true,
+ "_location": "/finalhandler",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/finalhandler-0.5.1.tgz_1479018213560_0.8304649770725518"
+ },
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "finalhandler@0.5.1",
+ "scope": null,
+ "escapedName": "finalhandler",
+ "name": "finalhandler",
+ "rawSpec": "0.5.1",
+ "spec": "0.5.1",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/express"
+ ],
+ "_resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-0.5.1.tgz",
+ "_shasum": "2c400d8d4530935bc232549c5fa385ec07de6fcd",
+ "_shrinkwrap": null,
+ "_spec": "finalhandler@0.5.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express",
+ "author": {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "bugs": {
+ "url": "https://github.com/pillarjs/finalhandler/issues"
+ },
+ "dependencies": {
+ "debug": "~2.2.0",
+ "escape-html": "~1.0.3",
+ "on-finished": "~2.3.0",
+ "statuses": "~1.3.1",
+ "unpipe": "~1.0.0"
+ },
+ "description": "Node.js final http responder",
+ "devDependencies": {
+ "eslint": "3.10.0",
+ "eslint-config-standard": "6.2.1",
+ "eslint-plugin-markdown": "1.0.0-beta.3",
+ "eslint-plugin-promise": "3.3.2",
+ "eslint-plugin-standard": "2.0.1",
+ "istanbul": "0.4.5",
+ "mocha": "2.5.3",
+ "readable-stream": "2.1.2",
+ "supertest": "1.1.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "2c400d8d4530935bc232549c5fa385ec07de6fcd",
+ "tarball": "https://registry.npmjs.org/finalhandler/-/finalhandler-0.5.1.tgz"
+ },
+ "engines": {
+ "node": ">= 0.8"
+ },
+ "files": [
+ "LICENSE",
+ "HISTORY.md",
+ "index.js"
+ ],
+ "gitHead": "ae6137a81049eecb2d57341b1a9c4efed46a25da",
+ "homepage": "https://github.com/pillarjs/finalhandler",
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "finalhandler",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/pillarjs/finalhandler.git"
+ },
+ "scripts": {
+ "lint": "eslint --plugin markdown --ext js,md .",
+ "test": "mocha --reporter spec --bail --check-leaks test/",
+ "test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/"
+ },
+ "version": "0.5.1"
+}
diff --git a/node_modules/find-cache-dir/index.js b/node_modules/find-cache-dir/index.js
new file mode 100644
index 00000000..85928628
--- /dev/null
+++ b/node_modules/find-cache-dir/index.js
@@ -0,0 +1,33 @@
+'use strict';
+var path = require('path');
+var commonDir = require('commondir');
+var pkgDir = require('pkg-dir');
+var mkdirp = require('mkdirp');
+
+module.exports = function (options) {
+ var name = options.name;
+ var dir = options.cwd;
+ if (options.files) {
+ dir = commonDir(dir, options.files);
+ } else {
+ dir = dir || process.cwd();
+ }
+
+ dir = pkgDir.sync(dir);
+
+ if (dir) {
+ dir = path.join(dir, 'node_modules', '.cache', name);
+
+ if (dir && options.create) {
+ mkdirp.sync(dir);
+ }
+
+ if (options.thunk) {
+ return function () {
+ return path.join.apply(path, [dir].concat(Array.prototype.slice.call(arguments)));
+ };
+ }
+ }
+
+ return dir;
+};
diff --git a/node_modules/find-cache-dir/license b/node_modules/find-cache-dir/license
new file mode 100644
index 00000000..ad5d021e
--- /dev/null
+++ b/node_modules/find-cache-dir/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) James Talmage (github.com/jamestalmage)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/find-cache-dir/package.json b/node_modules/find-cache-dir/package.json
new file mode 100644
index 00000000..cd84b5be
--- /dev/null
+++ b/node_modules/find-cache-dir/package.json
@@ -0,0 +1,101 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "find-cache-dir@^0.1.1",
+ "scope": null,
+ "escapedName": "find-cache-dir",
+ "name": "find-cache-dir",
+ "rawSpec": "^0.1.1",
+ "spec": ">=0.1.1 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/babel-loader"
+ ]
+ ],
+ "_from": "find-cache-dir@>=0.1.1 <0.2.0",
+ "_id": "find-cache-dir@0.1.1",
+ "_inCache": true,
+ "_location": "/find-cache-dir",
+ "_nodeVersion": "5.2.0",
+ "_npmUser": {
+ "name": "jamestalmage",
+ "email": "james@talmage.io"
+ },
+ "_npmVersion": "3.5.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "find-cache-dir@^0.1.1",
+ "scope": null,
+ "escapedName": "find-cache-dir",
+ "name": "find-cache-dir",
+ "rawSpec": "^0.1.1",
+ "spec": ">=0.1.1 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/babel-loader"
+ ],
+ "_resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-0.1.1.tgz",
+ "_shasum": "c8defae57c8a52a8a784f9e31c57c742e993a0b9",
+ "_shrinkwrap": null,
+ "_spec": "find-cache-dir@^0.1.1",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/babel-loader",
+ "author": {
+ "name": "James Talmage",
+ "email": "james@talmage.io",
+ "url": "github.com/jamestalmage"
+ },
+ "bugs": {
+ "url": "https://github.com/jamestalmage/find-cache-dir/issues"
+ },
+ "dependencies": {
+ "commondir": "^1.0.1",
+ "mkdirp": "^0.5.1",
+ "pkg-dir": "^1.0.0"
+ },
+ "description": "My well-made module",
+ "devDependencies": {
+ "ava": "^0.8.0",
+ "coveralls": "^2.11.6",
+ "nyc": "^5.0.1",
+ "rimraf": "^2.5.0",
+ "xo": "^0.12.1"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "c8defae57c8a52a8a784f9e31c57c742e993a0b9",
+ "tarball": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-0.1.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "722fff2aa8fbf666d37192917d2e1fb0e1287489",
+ "homepage": "https://github.com/jamestalmage/find-cache-dir#readme",
+ "keywords": [
+ "cache",
+ "directory",
+ "dir"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "jamestalmage",
+ "email": "james@talmage.io"
+ }
+ ],
+ "name": "find-cache-dir",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jamestalmage/find-cache-dir.git"
+ },
+ "scripts": {
+ "test": "xo && nyc --reporter=lcov --reporter=text ava"
+ },
+ "version": "0.1.1"
+}
diff --git a/node_modules/find-cache-dir/readme.md b/node_modules/find-cache-dir/readme.md
new file mode 100644
index 00000000..d0b71b19
--- /dev/null
+++ b/node_modules/find-cache-dir/readme.md
@@ -0,0 +1,108 @@
+# find-cache-dir [](https://travis-ci.org/jamestalmage/find-cache-dir) [](https://coveralls.io/github/jamestalmage/find-cache-dir?branch=master)
+
+> Finds the common standard cache directory.
+
+Recently the [`nyc`](https://www.npmjs.com/package/nyc) and [`AVA`](https://www.npmjs.com/package/ava) projects decided to standardize on a common directory structure for storing cache information:
+
+```sh
+# nyc
+./node_modules/.cache/nyc
+
+# ava
+./node_modules/.cache/ava
+
+# your-module
+./node_modules/.cache/your-module
+```
+
+This module makes it easy to correctly locate the cache directory according to this shared spec. If this pattern becomes ubiquitous, clearing the cache for multiple dependencies becomes easy and consistent:
+
+```
+rm -rf ./node_modules/.cache
+```
+
+If you decide to adopt this pattern, please file a PR adding your name to the list of adopters below.
+
+
+## Install
+
+```
+$ npm install --save find-cache-dir
+```
+
+
+## Usage
+
+```js
+const findCacheDir = require('find-cache-dir');
+
+findCacheDir({name: 'unicorns'});
+//=> /user/path/node-modules/.cache/unicorns
+```
+
+
+## API
+
+### findCacheDir([options])
+
+Finds the cache dir using the supplied options. The algorithm tries to find a `package.json` file, searching every parent directory of the `cwd` specified (or implied from other options). It returns a `string` containing the absolute path to the cache directory, or `null` if `package.json` was never found.
+
+#### options
+
+##### name
+
+*Required*
+Type: `string`
+
+This should be the same as your project name in `package.json`.
+
+##### files
+
+Type: `array` of `string`
+
+An array of files that will be searched for a common parent directory. This common parent directory will be used in lieu of the `cwd` option below.
+
+##### cwd
+
+Type: `string`
+Default `process.cwd()`
+
+The directory to start searching for a `package.json` from.
+
+##### create
+
+Type: `boolean`
+Default `false`
+
+If `true`, the directory will be created synchronously before returning.
+
+##### thunk
+
+Type: `boolean`
+Default `false`
+
+If `true`, this modifies the return type to be a function that is a thunk for `path.join(theFoundCacheDirectory)`.
+
+```js
+const thunk = findCacheDir({name: 'foo', thunk: true});
+
+thunk();
+//=> /some/path/node_modules/.cache/foo
+
+thunk('bar.js')
+//=> /some/path/node_modules/.cache/foo/bar.js
+
+thunk('baz', 'quz.js')
+//=> /some/path/node_modules/.cache/foo/baz/quz.js
+```
+
+This is helpful for actually putting actual files in the cache!
+
+## Adopters
+
+- [`NYC`](https://www.npmjs.com/package/nyc)
+- [`AVA`](https://www.npmjs.com/package/ava)
+
+## License
+
+MIT © [James Talmage](http://github.com/jamestalmage)
diff --git a/node_modules/find-up/index.js b/node_modules/find-up/index.js
new file mode 100644
index 00000000..7ff0e2b7
--- /dev/null
+++ b/node_modules/find-up/index.js
@@ -0,0 +1,53 @@
+'use strict';
+var path = require('path');
+var pathExists = require('path-exists');
+var Promise = require('pinkie-promise');
+
+function splitPath(x) {
+ return path.resolve(x || '').split(path.sep);
+}
+
+function join(parts, filename) {
+ return path.resolve(parts.join(path.sep) + path.sep, filename);
+}
+
+module.exports = function (filename, opts) {
+ opts = opts || {};
+
+ var parts = splitPath(opts.cwd);
+
+ return new Promise(function (resolve) {
+ (function find() {
+ var fp = join(parts, filename);
+
+ pathExists(fp).then(function (exists) {
+ if (exists) {
+ resolve(fp);
+ } else if (parts.pop()) {
+ find();
+ } else {
+ resolve(null);
+ }
+ });
+ })();
+ });
+};
+
+module.exports.sync = function (filename, opts) {
+ opts = opts || {};
+
+ var parts = splitPath(opts.cwd);
+ var len = parts.length;
+
+ while (len--) {
+ var fp = join(parts, filename);
+
+ if (pathExists.sync(fp)) {
+ return fp;
+ }
+
+ parts.pop();
+ }
+
+ return null;
+};
diff --git a/node_modules/find-up/license b/node_modules/find-up/license
new file mode 100644
index 00000000..654d0bfe
--- /dev/null
+++ b/node_modules/find-up/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/find-up/package.json b/node_modules/find-up/package.json
new file mode 100644
index 00000000..13826d2a
--- /dev/null
+++ b/node_modules/find-up/package.json
@@ -0,0 +1,118 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "find-up@^1.0.0",
+ "scope": null,
+ "escapedName": "find-up",
+ "name": "find-up",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/pkg-dir"
+ ]
+ ],
+ "_from": "find-up@>=1.0.0 <2.0.0",
+ "_id": "find-up@1.1.2",
+ "_inCache": true,
+ "_location": "/find-up",
+ "_nodeVersion": "4.3.0",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/find-up-1.1.2.tgz_1457199955637_0.3445317060686648"
+ },
+ "_npmUser": {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ "_npmVersion": "2.14.12",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "find-up@^1.0.0",
+ "scope": null,
+ "escapedName": "find-up",
+ "name": "find-up",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/pkg-dir"
+ ],
+ "_resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz",
+ "_shasum": "6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f",
+ "_shrinkwrap": null,
+ "_spec": "find-up@^1.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/pkg-dir",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/sindresorhus/find-up/issues"
+ },
+ "dependencies": {
+ "path-exists": "^2.0.0",
+ "pinkie-promise": "^2.0.0"
+ },
+ "description": "Find a file by walking up parent directories",
+ "devDependencies": {
+ "ava": "*",
+ "tempfile": "^1.1.1",
+ "xo": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f",
+ "tarball": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "f2d7c1ff74fbac82b2cff038e311ef4b075d9184",
+ "homepage": "https://github.com/sindresorhus/find-up",
+ "keywords": [
+ "find",
+ "up",
+ "find-up",
+ "findup",
+ "look-up",
+ "look",
+ "file",
+ "search",
+ "match",
+ "package",
+ "resolve",
+ "parent",
+ "parents",
+ "folder",
+ "directory",
+ "dir",
+ "walk",
+ "walking",
+ "path"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ }
+ ],
+ "name": "find-up",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/sindresorhus/find-up.git"
+ },
+ "scripts": {
+ "test": "xo && ava"
+ },
+ "version": "1.1.2"
+}
diff --git a/node_modules/find-up/readme.md b/node_modules/find-up/readme.md
new file mode 100644
index 00000000..9ea0611c
--- /dev/null
+++ b/node_modules/find-up/readme.md
@@ -0,0 +1,72 @@
+# find-up [](https://travis-ci.org/sindresorhus/find-up)
+
+> Find a file by walking up parent directories
+
+
+## Install
+
+```
+$ npm install --save find-up
+```
+
+
+## Usage
+
+```
+/
+└── Users
+ └── sindresorhus
+ ├── unicorn.png
+ └── foo
+ └── bar
+ ├── baz
+ └── example.js
+```
+
+```js
+// example.js
+const findUp = require('find-up');
+
+findUp('unicorn.png').then(filepath => {
+ console.log(filepath);
+ //=> '/Users/sindresorhus/unicorn.png'
+});
+```
+
+
+## API
+
+### findUp(filename, [options])
+
+Returns a promise for the filepath or `null`.
+
+### findUp.sync(filename, [options])
+
+Returns a filepath or `null`.
+
+#### filename
+
+Type: `string`
+
+Filename of the file to find.
+
+#### options
+
+##### cwd
+
+Type: `string`
+Default: `process.cwd()`
+
+Directory to start from.
+
+
+## Related
+
+- [find-up-cli](https://github.com/sindresorhus/find-up-cli) - CLI for this module
+- [pkg-up](https://github.com/sindresorhus/pkg-up) - Find the closest package.json file
+- [pkg-dir](https://github.com/sindresorhus/pkg-dir) - Find the root directory of an npm package
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)
diff --git a/node_modules/for-in/LICENSE b/node_modules/for-in/LICENSE
new file mode 100644
index 00000000..39245ac1
--- /dev/null
+++ b/node_modules/for-in/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014-2016, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/for-in/README.md b/node_modules/for-in/README.md
new file mode 100644
index 00000000..85141657
--- /dev/null
+++ b/node_modules/for-in/README.md
@@ -0,0 +1,74 @@
+# for-in [](https://www.npmjs.com/package/for-in) [](https://npmjs.org/package/for-in) [](https://travis-ci.org/jonschlinkert/for-in)
+
+> Iterate over the own and inherited enumerable properties of an object, and return an object with properties that evaluate to true from the callback. Exit early by returning `false`. JavaScript/Node.js
+
+## Install
+
+Install with [npm](https://www.npmjs.com/):
+
+```sh
+$ npm install for-in --save
+```
+
+## Usage
+
+```js
+var forIn = require('for-in');
+
+var obj = {a: 'foo', b: 'bar', c: 'baz'};
+var values = [];
+var keys = [];
+
+forIn(obj, function (value, key, o) {
+ keys.push(key);
+ values.push(value);
+});
+
+console.log(keys);
+//=> ['a', 'b', 'c'];
+
+console.log(values);
+//=> ['foo', 'bar', 'baz'];
+```
+
+## Contributing
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/for-in/issues/new).
+
+## Building docs
+
+Generate readme and API documentation with [verb](https://github.com/verbose/verb):
+
+```sh
+$ npm install verb && npm run docs
+```
+
+Or, if [verb](https://github.com/verbose/verb) is installed globally:
+
+```sh
+$ verb
+```
+
+## Running tests
+
+Install dev dependencies:
+
+```sh
+$ npm install -d && npm test
+```
+
+## Author
+
+**Jon Schlinkert**
+
+* [github/jonschlinkert](https://github.com/jonschlinkert)
+* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+## License
+
+Copyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).
+Released under the [MIT license](https://github.com/jonschlinkert/for-in/blob/master/LICENSE).
+
+***
+
+_This file was generated by [verb](https://github.com/verbose/verb), v, on March 27, 2016._
diff --git a/node_modules/for-in/index.js b/node_modules/for-in/index.js
new file mode 100644
index 00000000..96575505
--- /dev/null
+++ b/node_modules/for-in/index.js
@@ -0,0 +1,16 @@
+/*!
+ * for-in
+ *
+ * Copyright (c) 2014-2016, Jon Schlinkert.
+ * Licensed under the MIT License.
+ */
+
+'use strict';
+
+module.exports = function forIn(o, fn, thisArg) {
+ for (var key in o) {
+ if (fn.call(thisArg, o[key], key, o) === false) {
+ break;
+ }
+ }
+};
diff --git a/node_modules/for-in/package.json b/node_modules/for-in/package.json
new file mode 100644
index 00000000..1017f8d8
--- /dev/null
+++ b/node_modules/for-in/package.json
@@ -0,0 +1,127 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "for-in@^0.1.5",
+ "scope": null,
+ "escapedName": "for-in",
+ "name": "for-in",
+ "rawSpec": "^0.1.5",
+ "spec": ">=0.1.5 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/for-own"
+ ]
+ ],
+ "_from": "for-in@>=0.1.5 <0.2.0",
+ "_id": "for-in@0.1.6",
+ "_inCache": true,
+ "_location": "/for-in",
+ "_nodeVersion": "6.3.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/for-in-0.1.6.tgz_1473858422358_0.2992941744159907"
+ },
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "3.10.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "for-in@^0.1.5",
+ "scope": null,
+ "escapedName": "for-in",
+ "name": "for-in",
+ "rawSpec": "^0.1.5",
+ "spec": ">=0.1.5 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/for-own"
+ ],
+ "_resolved": "https://registry.npmjs.org/for-in/-/for-in-0.1.6.tgz",
+ "_shasum": "c9f96e89bfad18a545af5ec3ed352a1d9e5b4dc8",
+ "_shrinkwrap": null,
+ "_spec": "for-in@^0.1.5",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/for-own",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/for-in/issues"
+ },
+ "dependencies": {},
+ "description": "Iterate over the own and inherited enumerable properties of an object, and return an object with properties that evaluate to true from the callback. Exit early by returning `false`. JavaScript/Node.js",
+ "devDependencies": {
+ "gulp-format-md": "^0.1.7",
+ "mocha": "^2.4.5",
+ "should": "^8.3.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "c9f96e89bfad18a545af5ec3ed352a1d9e5b4dc8",
+ "tarball": "https://registry.npmjs.org/for-in/-/for-in-0.1.6.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "c903a9c0e06747c31bed8634c7c8645c6dbf8da1",
+ "homepage": "https://github.com/jonschlinkert/for-in",
+ "keywords": [
+ "for-in",
+ "for-own",
+ "has",
+ "has-own",
+ "hasOwn",
+ "key",
+ "keys",
+ "object",
+ "own",
+ "value"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ {
+ "name": "doowb",
+ "email": "brian.woodward@gmail.com"
+ }
+ ],
+ "name": "for-in",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonschlinkert/for-in.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "run": true,
+ "toc": false,
+ "layout": "default",
+ "tasks": [
+ "readme"
+ ],
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "reflinks": [
+ "verb"
+ ],
+ "lint": {
+ "reflinks": true
+ }
+ },
+ "version": "0.1.6"
+}
diff --git a/node_modules/for-own/LICENSE b/node_modules/for-own/LICENSE
new file mode 100644
index 00000000..fa30c4cb
--- /dev/null
+++ b/node_modules/for-own/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014-2015, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/for-own/README.md b/node_modules/for-own/README.md
new file mode 100644
index 00000000..16831ab7
--- /dev/null
+++ b/node_modules/for-own/README.md
@@ -0,0 +1,52 @@
+# for-own [](http://badge.fury.io/js/for-own)
+
+> Iterate over the own and inherited enumerable properties of an object, and return an object with properties that evaluate to true from the callback. Exit early by returning `false`.
+
+## Install
+#### Install with [npm](https://www.npmjs.com/):
+
+```bash
+npm i for-own --save
+```
+
+## Run tests
+
+```bash
+npm test
+```
+
+## Usage
+
+```js
+var forOwn = require('for-own');
+
+var obj = {a: 'foo', b: 'bar', c: 'baz'};
+var values = [];
+var keys = [];
+
+forOwn(obj, function (value, key, o) {
+ keys.push(key);
+ values.push(value);
+});
+
+console.log(keys);
+//=> ['a', 'b', 'c'];
+
+console.log(values);
+//=> ['foo', 'bar', 'baz'];
+```
+
+## Author
+
+**Jon Schlinkert**
+
++ [github/jonschlinkert](https://github.com/jonschlinkert)
++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+## License
+Copyright (c) 2014 Jon Schlinkert, contributors.
+Released under the MIT license
+
+***
+
+_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on September 20, 2014._
diff --git a/node_modules/for-own/index.js b/node_modules/for-own/index.js
new file mode 100644
index 00000000..d07256c7
--- /dev/null
+++ b/node_modules/for-own/index.js
@@ -0,0 +1,19 @@
+/*!
+ * for-own
+ *
+ * Copyright (c) 2014-2016, Jon Schlinkert.
+ * Licensed under the MIT License.
+ */
+
+'use strict';
+
+var forIn = require('for-in');
+var hasOwn = Object.prototype.hasOwnProperty;
+
+module.exports = function forOwn(o, fn, thisArg) {
+ forIn(o, function(val, key) {
+ if (hasOwn.call(o, key)) {
+ return fn.call(thisArg, o[key], key, o);
+ }
+ });
+};
diff --git a/node_modules/for-own/package.json b/node_modules/for-own/package.json
new file mode 100644
index 00000000..ab442d11
--- /dev/null
+++ b/node_modules/for-own/package.json
@@ -0,0 +1,128 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "for-own@^0.1.4",
+ "scope": null,
+ "escapedName": "for-own",
+ "name": "for-own",
+ "rawSpec": "^0.1.4",
+ "spec": ">=0.1.4 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/object.omit"
+ ]
+ ],
+ "_from": "for-own@>=0.1.4 <0.2.0",
+ "_id": "for-own@0.1.4",
+ "_inCache": true,
+ "_location": "/for-own",
+ "_nodeVersion": "5.5.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/for-own-0.1.4.tgz_1459091314670_0.658134751021862"
+ },
+ "_npmUser": {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ "_npmVersion": "3.6.0",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "for-own@^0.1.4",
+ "scope": null,
+ "escapedName": "for-own",
+ "name": "for-own",
+ "rawSpec": "^0.1.4",
+ "spec": ">=0.1.4 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/object.omit"
+ ],
+ "_resolved": "https://registry.npmjs.org/for-own/-/for-own-0.1.4.tgz",
+ "_shasum": "0149b41a39088c7515f51ebe1c1386d45f935072",
+ "_shrinkwrap": null,
+ "_spec": "for-own@^0.1.4",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/object.omit",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/for-own/issues"
+ },
+ "dependencies": {
+ "for-in": "^0.1.5"
+ },
+ "description": "Iterate over the own enumerable properties of an object, and return an object with properties that evaluate to true from the callback. Exit early by returning `false`. JavaScript/Node.js.",
+ "devDependencies": {
+ "gulp-format-md": "^0.1.7",
+ "mocha": "^2.4.5"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "0149b41a39088c7515f51ebe1c1386d45f935072",
+ "tarball": "https://registry.npmjs.org/for-own/-/for-own-0.1.4.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "475607dc923dcc399c1bfdbecc0df4b957eb3779",
+ "homepage": "https://github.com/jonschlinkert/for-own",
+ "keywords": [
+ "for-in",
+ "for-own",
+ "has",
+ "has-own",
+ "hasOwn",
+ "key",
+ "keys",
+ "object",
+ "own",
+ "value"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "jonschlinkert",
+ "email": "github@sellside.com"
+ },
+ {
+ "name": "doowb",
+ "email": "brian.woodward@gmail.com"
+ }
+ ],
+ "name": "for-own",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonschlinkert/for-own.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "run": true,
+ "toc": false,
+ "layout": "default",
+ "tasks": [
+ "readme"
+ ],
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "reflinks": [
+ "verb"
+ ],
+ "lint": {
+ "reflinks": true
+ }
+ },
+ "version": "0.1.4"
+}
diff --git a/node_modules/forwarded/HISTORY.md b/node_modules/forwarded/HISTORY.md
new file mode 100644
index 00000000..97fa1d10
--- /dev/null
+++ b/node_modules/forwarded/HISTORY.md
@@ -0,0 +1,4 @@
+0.1.0 / 2014-09-21
+==================
+
+ * Initial release
diff --git a/node_modules/forwarded/LICENSE b/node_modules/forwarded/LICENSE
new file mode 100644
index 00000000..b7dce6cf
--- /dev/null
+++ b/node_modules/forwarded/LICENSE
@@ -0,0 +1,22 @@
+(The MIT License)
+
+Copyright (c) 2014 Douglas Christopher Wilson
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/forwarded/README.md b/node_modules/forwarded/README.md
new file mode 100644
index 00000000..2b4988fa
--- /dev/null
+++ b/node_modules/forwarded/README.md
@@ -0,0 +1,53 @@
+# forwarded
+
+[![NPM Version][npm-image]][npm-url]
+[![NPM Downloads][downloads-image]][downloads-url]
+[![Node.js Version][node-version-image]][node-version-url]
+[![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
+
+Parse HTTP X-Forwarded-For header
+
+## Installation
+
+```sh
+$ npm install forwarded
+```
+
+## API
+
+```js
+var forwarded = require('forwarded')
+```
+
+### forwarded(req)
+
+```js
+var addresses = forwarded(req)
+```
+
+Parse the `X-Forwarded-For` header from the request. Returns an array
+of the addresses, including the socket address for the `req`. In reverse
+order (i.e. index `0` is the socket address and the last index is the
+furthest address, typically the end-user).
+
+## Testing
+
+```sh
+$ npm test
+```
+
+## License
+
+[MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/forwarded.svg?style=flat
+[npm-url]: https://npmjs.org/package/forwarded
+[node-version-image]: https://img.shields.io/node/v/forwarded.svg?style=flat
+[node-version-url]: http://nodejs.org/download/
+[travis-image]: https://img.shields.io/travis/jshttp/forwarded.svg?style=flat
+[travis-url]: https://travis-ci.org/jshttp/forwarded
+[coveralls-image]: https://img.shields.io/coveralls/jshttp/forwarded.svg?style=flat
+[coveralls-url]: https://coveralls.io/r/jshttp/forwarded?branch=master
+[downloads-image]: https://img.shields.io/npm/dm/forwarded.svg?style=flat
+[downloads-url]: https://npmjs.org/package/forwarded
diff --git a/node_modules/forwarded/index.js b/node_modules/forwarded/index.js
new file mode 100644
index 00000000..2f5c3408
--- /dev/null
+++ b/node_modules/forwarded/index.js
@@ -0,0 +1,35 @@
+/*!
+ * forwarded
+ * Copyright(c) 2014 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+/**
+ * Module exports.
+ */
+
+module.exports = forwarded
+
+/**
+ * Get all addresses in the request, using the `X-Forwarded-For` header.
+ *
+ * @param {Object} req
+ * @api public
+ */
+
+function forwarded(req) {
+ if (!req) {
+ throw new TypeError('argument req is required')
+ }
+
+ // simple header parsing
+ var proxyAddrs = (req.headers['x-forwarded-for'] || '')
+ .split(/ *, */)
+ .filter(Boolean)
+ .reverse()
+ var socketAddr = req.connection.remoteAddress
+ var addrs = [socketAddr].concat(proxyAddrs)
+
+ // return all addresses
+ return addrs
+}
diff --git a/node_modules/forwarded/package.json b/node_modules/forwarded/package.json
new file mode 100644
index 00000000..26dfdd6a
--- /dev/null
+++ b/node_modules/forwarded/package.json
@@ -0,0 +1,99 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "forwarded@~0.1.0",
+ "scope": null,
+ "escapedName": "forwarded",
+ "name": "forwarded",
+ "rawSpec": "~0.1.0",
+ "spec": ">=0.1.0 <0.2.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/proxy-addr"
+ ]
+ ],
+ "_from": "forwarded@>=0.1.0 <0.2.0",
+ "_id": "forwarded@0.1.0",
+ "_inCache": true,
+ "_location": "/forwarded",
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "1.4.21",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "forwarded@~0.1.0",
+ "scope": null,
+ "escapedName": "forwarded",
+ "name": "forwarded",
+ "rawSpec": "~0.1.0",
+ "spec": ">=0.1.0 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/proxy-addr"
+ ],
+ "_resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.0.tgz",
+ "_shasum": "19ef9874c4ae1c297bcf078fde63a09b66a84363",
+ "_shrinkwrap": null,
+ "_spec": "forwarded@~0.1.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/proxy-addr",
+ "bugs": {
+ "url": "https://github.com/jshttp/forwarded/issues"
+ },
+ "contributors": [
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "Parse HTTP X-Forwarded-For header",
+ "devDependencies": {
+ "istanbul": "0.3.2",
+ "mocha": "~1.21.4"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "19ef9874c4ae1c297bcf078fde63a09b66a84363",
+ "tarball": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.0.tgz"
+ },
+ "engines": {
+ "node": ">= 0.6"
+ },
+ "files": [
+ "LICENSE",
+ "HISTORY.md",
+ "README.md",
+ "index.js"
+ ],
+ "gitHead": "e9a9faeb3cfaadf40eb57d144fff26bca9b818e8",
+ "homepage": "https://github.com/jshttp/forwarded",
+ "keywords": [
+ "x-forwarded-for",
+ "http",
+ "req"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ }
+ ],
+ "name": "forwarded",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jshttp/forwarded.git"
+ },
+ "scripts": {
+ "test": "mocha --reporter spec --bail --check-leaks test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
+ },
+ "version": "0.1.0"
+}
diff --git a/node_modules/fresh/HISTORY.md b/node_modules/fresh/HISTORY.md
new file mode 100644
index 00000000..3c95fbb9
--- /dev/null
+++ b/node_modules/fresh/HISTORY.md
@@ -0,0 +1,38 @@
+0.3.0 / 2015-05-12
+==================
+
+ * Add weak `ETag` matching support
+
+0.2.4 / 2014-09-07
+==================
+
+ * Support Node.js 0.6
+
+0.2.3 / 2014-09-07
+==================
+
+ * Move repository to jshttp
+
+0.2.2 / 2014-02-19
+==================
+
+ * Revert "Fix for blank page on Safari reload"
+
+0.2.1 / 2014-01-29
+==================
+
+ * Fix for blank page on Safari reload
+
+0.2.0 / 2013-08-11
+==================
+
+ * Return stale for `Cache-Control: no-cache`
+
+0.1.0 / 2012-06-15
+==================
+ * Add `If-None-Match: *` support
+
+0.0.1 / 2012-06-10
+==================
+
+ * Initial release
diff --git a/node_modules/fresh/LICENSE b/node_modules/fresh/LICENSE
new file mode 100644
index 00000000..f5273943
--- /dev/null
+++ b/node_modules/fresh/LICENSE
@@ -0,0 +1,22 @@
+(The MIT License)
+
+Copyright (c) 2012 TJ Holowaychuk
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+'Software'), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/fresh/README.md b/node_modules/fresh/README.md
new file mode 100644
index 00000000..0813e309
--- /dev/null
+++ b/node_modules/fresh/README.md
@@ -0,0 +1,58 @@
+# fresh
+
+[![NPM Version][npm-image]][npm-url]
+[![NPM Downloads][downloads-image]][downloads-url]
+[![Node.js Version][node-version-image]][node-version-url]
+[![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
+
+HTTP response freshness testing
+
+## Installation
+
+```
+$ npm install fresh
+```
+
+## API
+
+```js
+var fresh = require('fresh')
+```
+
+### fresh(req, res)
+
+ Check freshness of `req` and `res` headers.
+
+ When the cache is "fresh" __true__ is returned,
+ otherwise __false__ is returned to indicate that
+ the cache is now stale.
+
+## Example
+
+```js
+var req = { 'if-none-match': 'tobi' };
+var res = { 'etag': 'luna' };
+fresh(req, res);
+// => false
+
+var req = { 'if-none-match': 'tobi' };
+var res = { 'etag': 'tobi' };
+fresh(req, res);
+// => true
+```
+
+## License
+
+[MIT](LICENSE)
+
+[npm-image]: https://img.shields.io/npm/v/fresh.svg
+[npm-url]: https://npmjs.org/package/fresh
+[node-version-image]: https://img.shields.io/node/v/fresh.svg
+[node-version-url]: http://nodejs.org/download/
+[travis-image]: https://img.shields.io/travis/jshttp/fresh/master.svg
+[travis-url]: https://travis-ci.org/jshttp/fresh
+[coveralls-image]: https://img.shields.io/coveralls/jshttp/fresh/master.svg
+[coveralls-url]: https://coveralls.io/r/jshttp/fresh?branch=master
+[downloads-image]: https://img.shields.io/npm/dm/fresh.svg
+[downloads-url]: https://npmjs.org/package/fresh
diff --git a/node_modules/fresh/index.js b/node_modules/fresh/index.js
new file mode 100644
index 00000000..a9008736
--- /dev/null
+++ b/node_modules/fresh/index.js
@@ -0,0 +1,57 @@
+
+/**
+ * Expose `fresh()`.
+ */
+
+module.exports = fresh;
+
+/**
+ * Check freshness of `req` and `res` headers.
+ *
+ * When the cache is "fresh" __true__ is returned,
+ * otherwise __false__ is returned to indicate that
+ * the cache is now stale.
+ *
+ * @param {Object} req
+ * @param {Object} res
+ * @return {Boolean}
+ * @api public
+ */
+
+function fresh(req, res) {
+ // defaults
+ var etagMatches = true;
+ var notModified = true;
+
+ // fields
+ var modifiedSince = req['if-modified-since'];
+ var noneMatch = req['if-none-match'];
+ var lastModified = res['last-modified'];
+ var etag = res['etag'];
+ var cc = req['cache-control'];
+
+ // unconditional request
+ if (!modifiedSince && !noneMatch) return false;
+
+ // check for no-cache cache request directive
+ if (cc && cc.indexOf('no-cache') !== -1) return false;
+
+ // parse if-none-match
+ if (noneMatch) noneMatch = noneMatch.split(/ *, */);
+
+ // if-none-match
+ if (noneMatch) {
+ etagMatches = noneMatch.some(function (match) {
+ return match === '*' || match === etag || match === 'W/' + etag;
+ });
+ }
+
+ // if-modified-since
+ if (modifiedSince) {
+ modifiedSince = new Date(modifiedSince);
+ lastModified = new Date(lastModified);
+ notModified = lastModified <= modifiedSince;
+ }
+
+ return !! (etagMatches && notModified);
+}
diff --git a/node_modules/fresh/package.json b/node_modules/fresh/package.json
new file mode 100644
index 00000000..fdd9092e
--- /dev/null
+++ b/node_modules/fresh/package.json
@@ -0,0 +1,122 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "fresh@0.3.0",
+ "scope": null,
+ "escapedName": "fresh",
+ "name": "fresh",
+ "rawSpec": "0.3.0",
+ "spec": "0.3.0",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express"
+ ]
+ ],
+ "_from": "fresh@0.3.0",
+ "_id": "fresh@0.3.0",
+ "_inCache": true,
+ "_location": "/fresh",
+ "_npmUser": {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "fresh@0.3.0",
+ "scope": null,
+ "escapedName": "fresh",
+ "name": "fresh",
+ "rawSpec": "0.3.0",
+ "spec": "0.3.0",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/express",
+ "/send"
+ ],
+ "_resolved": "https://registry.npmjs.org/fresh/-/fresh-0.3.0.tgz",
+ "_shasum": "651f838e22424e7566de161d8358caa199f83d4f",
+ "_shrinkwrap": null,
+ "_spec": "fresh@0.3.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/express",
+ "author": {
+ "name": "TJ Holowaychuk",
+ "email": "tj@vision-media.ca",
+ "url": "http://tjholowaychuk.com"
+ },
+ "bugs": {
+ "url": "https://github.com/jshttp/fresh/issues"
+ },
+ "contributors": [
+ {
+ "name": "Douglas Christopher Wilson",
+ "email": "doug@somethingdoug.com"
+ },
+ {
+ "name": "Jonathan Ong",
+ "email": "me@jongleberry.com",
+ "url": "http://jongleberry.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "HTTP response freshness testing",
+ "devDependencies": {
+ "istanbul": "0.3.9",
+ "mocha": "1.21.5"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "651f838e22424e7566de161d8358caa199f83d4f",
+ "tarball": "https://registry.npmjs.org/fresh/-/fresh-0.3.0.tgz"
+ },
+ "engines": {
+ "node": ">= 0.6"
+ },
+ "files": [
+ "HISTORY.md",
+ "LICENSE",
+ "index.js"
+ ],
+ "gitHead": "14616c9748368ca08cd6a955dd88ab659b778634",
+ "homepage": "https://github.com/jshttp/fresh",
+ "keywords": [
+ "fresh",
+ "http",
+ "conditional",
+ "cache"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "tjholowaychuk",
+ "email": "tj@vision-media.ca"
+ },
+ {
+ "name": "jonathanong",
+ "email": "jonathanrichardong@gmail.com"
+ },
+ {
+ "name": "dougwilson",
+ "email": "doug@somethingdoug.com"
+ },
+ {
+ "name": "jongleberry",
+ "email": "jonathanrichardong@gmail.com"
+ }
+ ],
+ "name": "fresh",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jshttp/fresh.git"
+ },
+ "scripts": {
+ "test": "mocha --reporter spec --bail --check-leaks test/",
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
+ },
+ "version": "0.3.0"
+}
diff --git a/node_modules/fs.realpath/LICENSE b/node_modules/fs.realpath/LICENSE
new file mode 100644
index 00000000..5bd884c2
--- /dev/null
+++ b/node_modules/fs.realpath/LICENSE
@@ -0,0 +1,43 @@
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+
+----
+
+This library bundles a version of the `fs.realpath` and `fs.realpathSync`
+methods from Node.js v0.10 under the terms of the Node.js MIT license.
+
+Node's license follows, also included at the header of `old.js` which contains
+the licensed code:
+
+ Copyright Joyent, Inc. and other Node contributors.
+
+ Permission is hereby granted, free of charge, to any person obtaining a
+ copy of this software and associated documentation files (the "Software"),
+ to deal in the Software without restriction, including without limitation
+ the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ and/or sell copies of the Software, and to permit persons to whom the
+ Software is furnished to do so, subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be included in
+ all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/fs.realpath/README.md b/node_modules/fs.realpath/README.md
new file mode 100644
index 00000000..a42ceac6
--- /dev/null
+++ b/node_modules/fs.realpath/README.md
@@ -0,0 +1,33 @@
+# fs.realpath
+
+A backwards-compatible fs.realpath for Node v6 and above
+
+In Node v6, the JavaScript implementation of fs.realpath was replaced
+with a faster (but less resilient) native implementation. That raises
+new and platform-specific errors and cannot handle long or excessively
+symlink-looping paths.
+
+This module handles those cases by detecting the new errors and
+falling back to the JavaScript implementation. On versions of Node
+prior to v6, it has no effect.
+
+## USAGE
+
+```js
+var rp = require('fs.realpath')
+
+// async version
+rp.realpath(someLongAndLoopingPath, function (er, real) {
+ // the ELOOP was handled, but it was a bit slower
+})
+
+// sync version
+var real = rp.realpathSync(someLongAndLoopingPath)
+
+// monkeypatch at your own risk!
+// This replaces the fs.realpath/fs.realpathSync builtins
+rp.monkeypatch()
+
+// un-do the monkeypatching
+rp.unmonkeypatch()
+```
diff --git a/node_modules/fs.realpath/index.js b/node_modules/fs.realpath/index.js
new file mode 100644
index 00000000..b09c7c7e
--- /dev/null
+++ b/node_modules/fs.realpath/index.js
@@ -0,0 +1,66 @@
+module.exports = realpath
+realpath.realpath = realpath
+realpath.sync = realpathSync
+realpath.realpathSync = realpathSync
+realpath.monkeypatch = monkeypatch
+realpath.unmonkeypatch = unmonkeypatch
+
+var fs = require('fs')
+var origRealpath = fs.realpath
+var origRealpathSync = fs.realpathSync
+
+var version = process.version
+var ok = /^v[0-5]\./.test(version)
+var old = require('./old.js')
+
+function newError (er) {
+ return er && er.syscall === 'realpath' && (
+ er.code === 'ELOOP' ||
+ er.code === 'ENOMEM' ||
+ er.code === 'ENAMETOOLONG'
+ )
+}
+
+function realpath (p, cache, cb) {
+ if (ok) {
+ return origRealpath(p, cache, cb)
+ }
+
+ if (typeof cache === 'function') {
+ cb = cache
+ cache = null
+ }
+ origRealpath(p, cache, function (er, result) {
+ if (newError(er)) {
+ old.realpath(p, cache, cb)
+ } else {
+ cb(er, result)
+ }
+ })
+}
+
+function realpathSync (p, cache) {
+ if (ok) {
+ return origRealpathSync(p, cache)
+ }
+
+ try {
+ return origRealpathSync(p, cache)
+ } catch (er) {
+ if (newError(er)) {
+ return old.realpathSync(p, cache)
+ } else {
+ throw er
+ }
+ }
+}
+
+function monkeypatch () {
+ fs.realpath = realpath
+ fs.realpathSync = realpathSync
+}
+
+function unmonkeypatch () {
+ fs.realpath = origRealpath
+ fs.realpathSync = origRealpathSync
+}
diff --git a/node_modules/fs.realpath/old.js b/node_modules/fs.realpath/old.js
new file mode 100644
index 00000000..b40305e7
--- /dev/null
+++ b/node_modules/fs.realpath/old.js
@@ -0,0 +1,303 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+var pathModule = require('path');
+var isWindows = process.platform === 'win32';
+var fs = require('fs');
+
+// JavaScript implementation of realpath, ported from node pre-v6
+
+var DEBUG = process.env.NODE_DEBUG && /fs/.test(process.env.NODE_DEBUG);
+
+function rethrow() {
+ // Only enable in debug mode. A backtrace uses ~1000 bytes of heap space and
+ // is fairly slow to generate.
+ var callback;
+ if (DEBUG) {
+ var backtrace = new Error;
+ callback = debugCallback;
+ } else
+ callback = missingCallback;
+
+ return callback;
+
+ function debugCallback(err) {
+ if (err) {
+ backtrace.message = err.message;
+ err = backtrace;
+ missingCallback(err);
+ }
+ }
+
+ function missingCallback(err) {
+ if (err) {
+ if (process.throwDeprecation)
+ throw err; // Forgot a callback but don't know where? Use NODE_DEBUG=fs
+ else if (!process.noDeprecation) {
+ var msg = 'fs: missing callback ' + (err.stack || err.message);
+ if (process.traceDeprecation)
+ console.trace(msg);
+ else
+ console.error(msg);
+ }
+ }
+ }
+}
+
+function maybeCallback(cb) {
+ return typeof cb === 'function' ? cb : rethrow();
+}
+
+var normalize = pathModule.normalize;
+
+// Regexp that finds the next partion of a (partial) path
+// result is [base_with_slash, base], e.g. ['somedir/', 'somedir']
+if (isWindows) {
+ var nextPartRe = /(.*?)(?:[\/\\]+|$)/g;
+} else {
+ var nextPartRe = /(.*?)(?:[\/]+|$)/g;
+}
+
+// Regex to find the device root, including trailing slash. E.g. 'c:\\'.
+if (isWindows) {
+ var splitRootRe = /^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/;
+} else {
+ var splitRootRe = /^[\/]*/;
+}
+
+exports.realpathSync = function realpathSync(p, cache) {
+ // make p is absolute
+ p = pathModule.resolve(p);
+
+ if (cache && Object.prototype.hasOwnProperty.call(cache, p)) {
+ return cache[p];
+ }
+
+ var original = p,
+ seenLinks = {},
+ knownHard = {};
+
+ // current character position in p
+ var pos;
+ // the partial path so far, including a trailing slash if any
+ var current;
+ // the partial path without a trailing slash (except when pointing at a root)
+ var base;
+ // the partial path scanned in the previous round, with slash
+ var previous;
+
+ start();
+
+ function start() {
+ // Skip over roots
+ var m = splitRootRe.exec(p);
+ pos = m[0].length;
+ current = m[0];
+ base = m[0];
+ previous = '';
+
+ // On windows, check that the root exists. On unix there is no need.
+ if (isWindows && !knownHard[base]) {
+ fs.lstatSync(base);
+ knownHard[base] = true;
+ }
+ }
+
+ // walk down the path, swapping out linked pathparts for their real
+ // values
+ // NB: p.length changes.
+ while (pos < p.length) {
+ // find the next part
+ nextPartRe.lastIndex = pos;
+ var result = nextPartRe.exec(p);
+ previous = current;
+ current += result[0];
+ base = previous + result[1];
+ pos = nextPartRe.lastIndex;
+
+ // continue if not a symlink
+ if (knownHard[base] || (cache && cache[base] === base)) {
+ continue;
+ }
+
+ var resolvedLink;
+ if (cache && Object.prototype.hasOwnProperty.call(cache, base)) {
+ // some known symbolic link. no need to stat again.
+ resolvedLink = cache[base];
+ } else {
+ var stat = fs.lstatSync(base);
+ if (!stat.isSymbolicLink()) {
+ knownHard[base] = true;
+ if (cache) cache[base] = base;
+ continue;
+ }
+
+ // read the link if it wasn't read before
+ // dev/ino always return 0 on windows, so skip the check.
+ var linkTarget = null;
+ if (!isWindows) {
+ var id = stat.dev.toString(32) + ':' + stat.ino.toString(32);
+ if (seenLinks.hasOwnProperty(id)) {
+ linkTarget = seenLinks[id];
+ }
+ }
+ if (linkTarget === null) {
+ fs.statSync(base);
+ linkTarget = fs.readlinkSync(base);
+ }
+ resolvedLink = pathModule.resolve(previous, linkTarget);
+ // track this, if given a cache.
+ if (cache) cache[base] = resolvedLink;
+ if (!isWindows) seenLinks[id] = linkTarget;
+ }
+
+ // resolve the link, then start over
+ p = pathModule.resolve(resolvedLink, p.slice(pos));
+ start();
+ }
+
+ if (cache) cache[original] = p;
+
+ return p;
+};
+
+
+exports.realpath = function realpath(p, cache, cb) {
+ if (typeof cb !== 'function') {
+ cb = maybeCallback(cache);
+ cache = null;
+ }
+
+ // make p is absolute
+ p = pathModule.resolve(p);
+
+ if (cache && Object.prototype.hasOwnProperty.call(cache, p)) {
+ return process.nextTick(cb.bind(null, null, cache[p]));
+ }
+
+ var original = p,
+ seenLinks = {},
+ knownHard = {};
+
+ // current character position in p
+ var pos;
+ // the partial path so far, including a trailing slash if any
+ var current;
+ // the partial path without a trailing slash (except when pointing at a root)
+ var base;
+ // the partial path scanned in the previous round, with slash
+ var previous;
+
+ start();
+
+ function start() {
+ // Skip over roots
+ var m = splitRootRe.exec(p);
+ pos = m[0].length;
+ current = m[0];
+ base = m[0];
+ previous = '';
+
+ // On windows, check that the root exists. On unix there is no need.
+ if (isWindows && !knownHard[base]) {
+ fs.lstat(base, function(err) {
+ if (err) return cb(err);
+ knownHard[base] = true;
+ LOOP();
+ });
+ } else {
+ process.nextTick(LOOP);
+ }
+ }
+
+ // walk down the path, swapping out linked pathparts for their real
+ // values
+ function LOOP() {
+ // stop if scanned past end of path
+ if (pos >= p.length) {
+ if (cache) cache[original] = p;
+ return cb(null, p);
+ }
+
+ // find the next part
+ nextPartRe.lastIndex = pos;
+ var result = nextPartRe.exec(p);
+ previous = current;
+ current += result[0];
+ base = previous + result[1];
+ pos = nextPartRe.lastIndex;
+
+ // continue if not a symlink
+ if (knownHard[base] || (cache && cache[base] === base)) {
+ return process.nextTick(LOOP);
+ }
+
+ if (cache && Object.prototype.hasOwnProperty.call(cache, base)) {
+ // known symbolic link. no need to stat again.
+ return gotResolvedLink(cache[base]);
+ }
+
+ return fs.lstat(base, gotStat);
+ }
+
+ function gotStat(err, stat) {
+ if (err) return cb(err);
+
+ // if not a symlink, skip to the next path part
+ if (!stat.isSymbolicLink()) {
+ knownHard[base] = true;
+ if (cache) cache[base] = base;
+ return process.nextTick(LOOP);
+ }
+
+ // stat & read the link if not read before
+ // call gotTarget as soon as the link target is known
+ // dev/ino always return 0 on windows, so skip the check.
+ if (!isWindows) {
+ var id = stat.dev.toString(32) + ':' + stat.ino.toString(32);
+ if (seenLinks.hasOwnProperty(id)) {
+ return gotTarget(null, seenLinks[id], base);
+ }
+ }
+ fs.stat(base, function(err) {
+ if (err) return cb(err);
+
+ fs.readlink(base, function(err, target) {
+ if (!isWindows) seenLinks[id] = target;
+ gotTarget(err, target);
+ });
+ });
+ }
+
+ function gotTarget(err, target, base) {
+ if (err) return cb(err);
+
+ var resolvedLink = pathModule.resolve(previous, target);
+ if (cache) cache[base] = resolvedLink;
+ gotResolvedLink(resolvedLink);
+ }
+
+ function gotResolvedLink(resolvedLink) {
+ // resolve the link, then start over
+ p = pathModule.resolve(resolvedLink, p.slice(pos));
+ start();
+ }
+};
diff --git a/node_modules/fs.realpath/package.json b/node_modules/fs.realpath/package.json
new file mode 100644
index 00000000..4ad776df
--- /dev/null
+++ b/node_modules/fs.realpath/package.json
@@ -0,0 +1,94 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "fs.realpath@^1.0.0",
+ "scope": null,
+ "escapedName": "fs.realpath",
+ "name": "fs.realpath",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/glob"
+ ]
+ ],
+ "_from": "fs.realpath@>=1.0.0 <2.0.0",
+ "_id": "fs.realpath@1.0.0",
+ "_inCache": true,
+ "_location": "/fs.realpath",
+ "_nodeVersion": "4.4.4",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/fs.realpath-1.0.0.tgz_1466015941059_0.3332864767871797"
+ },
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "_npmVersion": "3.9.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "fs.realpath@^1.0.0",
+ "scope": null,
+ "escapedName": "fs.realpath",
+ "name": "fs.realpath",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/glob"
+ ],
+ "_resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
+ "_shasum": "1504ad2523158caa40db4a2787cb01411994ea4f",
+ "_shrinkwrap": null,
+ "_spec": "fs.realpath@^1.0.0",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/glob",
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me",
+ "url": "http://blog.izs.me/"
+ },
+ "bugs": {
+ "url": "https://github.com/isaacs/fs.realpath/issues"
+ },
+ "dependencies": {},
+ "description": "Use node's fs.realpath, but fall back to the JS implementation if the native one fails",
+ "devDependencies": {},
+ "directories": {},
+ "dist": {
+ "shasum": "1504ad2523158caa40db4a2787cb01411994ea4f",
+ "tarball": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz"
+ },
+ "files": [
+ "old.js",
+ "index.js"
+ ],
+ "gitHead": "03e7c884431fe185dfebbc9b771aeca339c1807a",
+ "homepage": "https://github.com/isaacs/fs.realpath#readme",
+ "keywords": [
+ "realpath",
+ "fs",
+ "polyfill"
+ ],
+ "license": "ISC",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "name": "fs.realpath",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/isaacs/fs.realpath.git"
+ },
+ "scripts": {
+ "test": "tap test/*.js --cov"
+ },
+ "version": "1.0.0"
+}
diff --git a/node_modules/fs/index.js b/node_modules/fs/index.js
new file mode 100644
index 00000000..5f292805
--- /dev/null
+++ b/node_modules/fs/index.js
@@ -0,0 +1 @@
+console.log("I'm `fs` modules");
diff --git a/node_modules/fs/package.json b/node_modules/fs/package.json
new file mode 100644
index 00000000..5a3aefcb
--- /dev/null
+++ b/node_modules/fs/package.json
@@ -0,0 +1,68 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "fs@0.0.2",
+ "scope": null,
+ "escapedName": "fs",
+ "name": "fs",
+ "rawSpec": "0.0.2",
+ "spec": "0.0.2",
+ "type": "version"
+ },
+ "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/webpack-glsl-loader"
+ ]
+ ],
+ "_from": "fs@0.0.2",
+ "_id": "fs@0.0.2",
+ "_inCache": true,
+ "_location": "/fs",
+ "_nodeVersion": "0.0.0-fake",
+ "_npmUser": {
+ "name": "npm",
+ "email": "support@npmjs.com"
+ },
+ "_npmVersion": "0.0.0-fake",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "fs@0.0.2",
+ "scope": null,
+ "escapedName": "fs",
+ "name": "fs",
+ "rawSpec": "0.0.2",
+ "spec": "0.0.2",
+ "type": "version"
+ },
+ "_requiredBy": [
+ "/webpack-glsl-loader"
+ ],
+ "_resolved": "https://registry.npmjs.org/fs/-/fs-0.0.2.tgz",
+ "_shasum": "e1f244ef3933c1b2a64bd4799136060d0f5914f8",
+ "_shrinkwrap": null,
+ "_spec": "fs@0.0.2",
+ "_where": "/Users/ericchiu/Desktop/CIS 700/HW3/Project3-LSystems/node_modules/webpack-glsl-loader",
+ "author": "",
+ "dependencies": {},
+ "description": "",
+ "devDependencies": {},
+ "directories": {},
+ "dist": {
+ "shasum": "e1f244ef3933c1b2a64bd4799136060d0f5914f8",
+ "tarball": "https://registry.npmjs.org/fs/-/fs-0.0.2.tgz"
+ },
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "npm",
+ "email": "npm@npmjs.com"
+ }
+ ],
+ "name": "fs",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "scripts": {
+ "test": "echo \"Error: no test specified\" && exit 1"
+ },
+ "version": "0.0.2"
+}
diff --git a/node_modules/fsevents/.npmignore b/node_modules/fsevents/.npmignore
new file mode 100644
index 00000000..65e3ba2e
--- /dev/null
+++ b/node_modules/fsevents/.npmignore
@@ -0,0 +1 @@
+test/
diff --git a/node_modules/fsevents/.travis.yml b/node_modules/fsevents/.travis.yml
new file mode 100644
index 00000000..afcfde0f
--- /dev/null
+++ b/node_modules/fsevents/.travis.yml
@@ -0,0 +1,103 @@
+language: objective-c
+
+env:
+ global:
+ - secure: "gve1nkeKkwFEG1VAT3i+JwYyAdF0gKXwKx0uxbkBTsmm2M+0MDusohQdFLoEIkSIFktXBIDefoa7iGpLKRfG2VsZLpwJgnvnD0HqbnuR+k+W+bu7BHt4CAaR6GTllsDCjyq9zNyhUThzSnf2WNIpOEF5kHspZlbGfawURuUJH/U="
+ - secure: "jqVpmWxxBVXu2X8+XJMpKH0cooc2EKz9xKL2znBfYdNafJORSXcFAVbjCX5mZmVDcgIMwDtm2+gIG4P73hzJ2e3S+y2Z9ROJGyXHa3AxUTvXHQsxqzH8coHHqB8vTvfr0t2O5aKfpvpICpSea39r0hzNoMv6Ie5SwBdqj1YY9K0="
+ matrix:
+ - NODE_VERSION="v7"
+ - NODE_VERSION="v6"
+ - NODE_VERSION="v5"
+ - NODE_VERSION="v4"
+ - NODE_VERSION="v0.12"
+ - NODE_VERSION="v0.10"
+ - NODE_VERSION="iojs-v3"
+ - NODE_VERSION="iojs-v2"
+ - NODE_VERSION="iojs-v1"
+
+before_install:
+
+ - echo $TRAVIS_OS_NAME
+
+ # commit
+ # ------------------------
+ # The commit message is used to determine the whether to manually
+ # invoke a binary publish
+
+ - COMMIT_MESSAGE=$(git show -s --format=%B $TRAVIS_COMMIT | tr -d '\n')
+
+ # node
+ # ------------------------
+
+ - export PATH=./node_modules/.bin/:$PATH
+ - rm -rf ~/.nvm && git clone --depth 1 https://github.com/creationix/nvm.git ~/.nvm
+ - source ~/.nvm/nvm.sh
+ - nvm install $NODE_VERSION
+ - nvm use $NODE_VERSION
+ - npm install -g npm@latest
+ - node --version
+ - npm --version
+ - nvm --version
+
+ # publish dependencies
+ # ------------------------
+
+ - npm install node-gyp -g
+ - npm install aws-sdk
+
+install:
+
+ # in the first instance we build from source to create the initial binary
+ # which can then be used to create a package
+
+ - npm install --build-from-source
+ - npm test
+
+before_script:
+
+ # Detemine if a publish is required.
+ #
+ # a) we are building a tag
+ # b) we put [publish binary] in the commit message
+
+ - PUBLISH_BINARY=false
+
+ - if [[ $TRAVIS_BRANCH == `git describe --tags --always HEAD` ]]; then PUBLISH_BINARY=true; fi; # a
+ - if test "${COMMIT_MESSAGE#*'[publish binary]'}" != "$COMMIT_MESSAGE"; then PUBLISH_BINARY=true; fi; # b
+
+ # package & publish
+ # ------------------------
+
+ - if [[ $PUBLISH_BINARY == true ]]; then node-pre-gyp package publish; fi;
+
+ # clean-up
+ # ------------------------
+
+ - node-pre-gyp clean
+ - node-gyp clean
+
+script:
+
+ # validate
+ # ------------------------
+ # Post publishing a release verify that installing will pull down latest
+ # binary from remote host
+
+ - INSTALL_RESULT=0
+ - if [[ $PUBLISH_BINARY == true ]]; then INSTALL_RESULT=$(npm install --fallback-to-build=false > /dev/null)$? || true; fi;
+
+ - node-pre-gyp clean
+
+ # failure?
+ # ------------------------
+ # if install returned non zero (errored) then we first unpublish and then
+ # call false so travis will bail at this line.
+
+ - if [[ $INSTALL_RESULT != 0 ]]; then node-pre-gyp unpublish; fi;
+ - if [[ $INSTALL_RESULT != 0 ]]; then echo "returned $INSTALL_RESULT";false; fi;
+
+after_success:
+
+ # display all published binaries
+
+ - node-pre-gyp info
diff --git a/node_modules/fsevents/ISSUE_TEMPLATE.md b/node_modules/fsevents/ISSUE_TEMPLATE.md
new file mode 100644
index 00000000..426abbb7
--- /dev/null
+++ b/node_modules/fsevents/ISSUE_TEMPLATE.md
@@ -0,0 +1,8 @@
+If you are NOT on OS X and have come here to file an issue about compatibility problems,
+please stop and go to #115 for your answer.
+
+You can look through many other similar closed issues as well if you're interested:
+https://github.com/strongloop/fsevents/search?utf8=%E2%9C%93&q=%22notsup%22+OR+%22EBADPLATFORM%22&type=Issues.
+
+If you are here to report an issue observed while using this module on OS X, please delete
+all this pre-filled text then go ahead and submit your report.
diff --git a/node_modules/fsevents/LICENSE b/node_modules/fsevents/LICENSE
new file mode 100644
index 00000000..4a49ad8d
--- /dev/null
+++ b/node_modules/fsevents/LICENSE
@@ -0,0 +1,22 @@
+MIT License
+-----------
+
+Copyright (C) 2010-2014 Philipp Dunkel
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fsevents/Readme.md b/node_modules/fsevents/Readme.md
new file mode 100644
index 00000000..03ddfa94
--- /dev/null
+++ b/node_modules/fsevents/Readme.md
@@ -0,0 +1,78 @@
+# fsevents [](https://nodei.co/npm/fsevents/)
+
+Native access to OS X FSEvents in [Node.js](http://nodejs.org/)
+
+The FSEvents API in OS X allows applications to register for notifications of
+changes to a given directory tree. It is a very fast and lightweight alternative
+to kqueue.
+
+This is a low-level library. For a cross-compatible file watching module that
+uses fsevents, check out [Chokidar](https://www.npmjs.com/package/chokidar).
+
+* [Module Site & GitHub](https://github.com/strongloop/fsevents)
+* [NPM Page](https://npmjs.org/package/fsevents)
+
+## Installation
+
+ $ npm install fsevents
+
+## Usage
+
+```js
+var fsevents = require('fsevents');
+var watcher = fsevents(__dirname);
+watcher.on('fsevent', function(path, flags, id) { }); // RAW Event as emitted by OS-X
+watcher.on('change', function(path, info) { }); // Common Event for all changes
+watcher.start() // To start observation
+watcher.stop() // To end observation
+```
+
+### Events
+
+ * *fsevent* - RAW Event as emitted by OS-X
+ * *change* - Common Event for all changes
+ * *created* - A File-System-Item has been created
+ * *deleted* - A File-System-Item has been deleted
+ * *modified* - A File-System-Item has been modified
+ * *moved-out* - A File-System-Item has been moved away from this location
+ * *moved-in* - A File-System-Item has been moved into this location
+
+All events except *fsevent* take an *info* object as the second parameter of the callback. The structure of this object is:
+
+```js
+{
+ "event": "",
+ "id": ,
+ "path": "",
+ "type": "",
+ "changes": {
+ "inode": true, // Has the iNode Meta-Information changed
+ "finder": false, // Has the Finder Meta-Data changed
+ "access": false, // Have the access permissions changed
+ "xattrs": false // Have the xAttributes changed
+ },
+ "flags":
+}
+```
+
+## MIT License
+
+Copyright (C) 2010-2014 Philipp Dunkel
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fsevents/binding.gyp b/node_modules/fsevents/binding.gyp
new file mode 100644
index 00000000..06ca003d
--- /dev/null
+++ b/node_modules/fsevents/binding.gyp
@@ -0,0 +1,29 @@
+{
+ "targets": [
+ { "target_name": "" }
+ ],
+ "conditions": [
+ ['OS=="mac"', {
+ "targets": [{
+ "target_name": "<(module_name)",
+ "sources": ["fsevents.cc"],
+ "xcode_settings": {
+ "OTHER_LDFLAGS": [
+ "-framework CoreFoundation -framework CoreServices"
+ ]
+ },
+ "include_dirs": [
+ "> $(depfile)
+# Add extra rules as in (2).
+# We remove slashes and replace spaces with new lines;
+# remove blank lines;
+# delete the first line and append a colon to the remaining lines.
+sed -e 's|\\||' -e 'y| |\n|' $(depfile).raw |\
+ grep -v '^$$' |\
+ sed -e 1d -e 's|$$|:|' \
+ >> $(depfile)
+rm $(depfile).raw
+endef
+
+# Command definitions:
+# - cmd_foo is the actual command to run;
+# - quiet_cmd_foo is the brief-output summary of the command.
+
+quiet_cmd_cc = CC($(TOOLSET)) $@
+cmd_cc = $(CC.$(TOOLSET)) $(GYP_CFLAGS) $(DEPFLAGS) $(CFLAGS.$(TOOLSET)) -c -o $@ $<
+
+quiet_cmd_cxx = CXX($(TOOLSET)) $@
+cmd_cxx = $(CXX.$(TOOLSET)) $(GYP_CXXFLAGS) $(DEPFLAGS) $(CXXFLAGS.$(TOOLSET)) -c -o $@ $<
+
+quiet_cmd_objc = CXX($(TOOLSET)) $@
+cmd_objc = $(CC.$(TOOLSET)) $(GYP_OBJCFLAGS) $(DEPFLAGS) -c -o $@ $<
+
+quiet_cmd_objcxx = CXX($(TOOLSET)) $@
+cmd_objcxx = $(CXX.$(TOOLSET)) $(GYP_OBJCXXFLAGS) $(DEPFLAGS) -c -o $@ $<
+
+# Commands for precompiled header files.
+quiet_cmd_pch_c = CXX($(TOOLSET)) $@
+cmd_pch_c = $(CC.$(TOOLSET)) $(GYP_PCH_CFLAGS) $(DEPFLAGS) $(CXXFLAGS.$(TOOLSET)) -c -o $@ $<
+quiet_cmd_pch_cc = CXX($(TOOLSET)) $@
+cmd_pch_cc = $(CC.$(TOOLSET)) $(GYP_PCH_CXXFLAGS) $(DEPFLAGS) $(CXXFLAGS.$(TOOLSET)) -c -o $@ $<
+quiet_cmd_pch_m = CXX($(TOOLSET)) $@
+cmd_pch_m = $(CC.$(TOOLSET)) $(GYP_PCH_OBJCFLAGS) $(DEPFLAGS) -c -o $@ $<
+quiet_cmd_pch_mm = CXX($(TOOLSET)) $@
+cmd_pch_mm = $(CC.$(TOOLSET)) $(GYP_PCH_OBJCXXFLAGS) $(DEPFLAGS) -c -o $@ $<
+
+# gyp-mac-tool is written next to the root Makefile by gyp.
+# Use $(4) for the command, since $(2) and $(3) are used as flag by do_cmd
+# already.
+quiet_cmd_mac_tool = MACTOOL $(4) $<
+cmd_mac_tool = ./gyp-mac-tool $(4) $< "$@"
+
+quiet_cmd_mac_package_framework = PACKAGE FRAMEWORK $@
+cmd_mac_package_framework = ./gyp-mac-tool package-framework "$@" $(4)
+
+quiet_cmd_infoplist = INFOPLIST $@
+cmd_infoplist = $(CC.$(TOOLSET)) -E -P -Wno-trigraphs -x c $(INFOPLIST_DEFINES) "$<" -o "$@"
+
+quiet_cmd_touch = TOUCH $@
+cmd_touch = touch $@
+
+quiet_cmd_copy = COPY $@
+# send stderr to /dev/null to ignore messages when linking directories.
+cmd_copy = rm -rf "$@" && cp -af "$<" "$@"
+
+quiet_cmd_alink = LIBTOOL-STATIC $@
+cmd_alink = rm -f $@ && ./gyp-mac-tool filter-libtool libtool $(GYP_LIBTOOLFLAGS) -static -o $@ $(filter %.o,$^)
+
+quiet_cmd_link = LINK($(TOOLSET)) $@
+cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o "$@" $(LD_INPUTS) $(LIBS)
+
+quiet_cmd_solink = SOLINK($(TOOLSET)) $@
+cmd_solink = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o "$@" $(LD_INPUTS) $(LIBS)
+
+quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
+cmd_solink_module = $(LINK.$(TOOLSET)) -bundle $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS)
+
+
+# Define an escape_quotes function to escape single quotes.
+# This allows us to handle quotes properly as long as we always use
+# use single quotes and escape_quotes.
+escape_quotes = $(subst ','\'',$(1))
+# This comment is here just to include a ' to unconfuse syntax highlighting.
+# Define an escape_vars function to escape '$' variable syntax.
+# This allows us to read/write command lines with shell variables (e.g.
+# $LD_LIBRARY_PATH), without triggering make substitution.
+escape_vars = $(subst $$,$$$$,$(1))
+# Helper that expands to a shell command to echo a string exactly as it is in
+# make. This uses printf instead of echo because printf's behaviour with respect
+# to escape sequences is more portable than echo's across different shells
+# (e.g., dash, bash).
+exact_echo = printf '%s\n' '$(call escape_quotes,$(1))'
+
+# Helper to compare the command we're about to run against the command
+# we logged the last time we ran the command. Produces an empty
+# string (false) when the commands match.
+# Tricky point: Make has no string-equality test function.
+# The kernel uses the following, but it seems like it would have false
+# positives, where one string reordered its arguments.
+# arg_check = $(strip $(filter-out $(cmd_$(1)), $(cmd_$@)) \
+# $(filter-out $(cmd_$@), $(cmd_$(1))))
+# We instead substitute each for the empty string into the other, and
+# say they're equal if both substitutions produce the empty string.
+# .d files contain ? instead of spaces, take that into account.
+command_changed = $(or $(subst $(cmd_$(1)),,$(cmd_$(call replace_spaces,$@))),\
+ $(subst $(cmd_$(call replace_spaces,$@)),,$(cmd_$(1))))
+
+# Helper that is non-empty when a prerequisite changes.
+# Normally make does this implicitly, but we force rules to always run
+# so we can check their command lines.
+# $? -- new prerequisites
+# $| -- order-only dependencies
+prereq_changed = $(filter-out FORCE_DO_CMD,$(filter-out $|,$?))
+
+# Helper that executes all postbuilds until one fails.
+define do_postbuilds
+ @E=0;\
+ for p in $(POSTBUILDS); do\
+ eval $$p;\
+ E=$$?;\
+ if [ $$E -ne 0 ]; then\
+ break;\
+ fi;\
+ done;\
+ if [ $$E -ne 0 ]; then\
+ rm -rf "$@";\
+ exit $$E;\
+ fi
+endef
+
+# do_cmd: run a command via the above cmd_foo names, if necessary.
+# Should always run for a given target to handle command-line changes.
+# Second argument, if non-zero, makes it do asm/C/C++ dependency munging.
+# Third argument, if non-zero, makes it do POSTBUILDS processing.
+# Note: We intentionally do NOT call dirx for depfile, since it contains ? for
+# spaces already and dirx strips the ? characters.
+define do_cmd
+$(if $(or $(command_changed),$(prereq_changed)),
+ @$(call exact_echo, $($(quiet)cmd_$(1)))
+ @mkdir -p "$(call dirx,$@)" "$(dir $(depfile))"
+ $(if $(findstring flock,$(word 2,$(cmd_$1))),
+ @$(cmd_$(1))
+ @echo " $(quiet_cmd_$(1)): Finished",
+ @$(cmd_$(1))
+ )
+ @$(call exact_echo,$(call escape_vars,cmd_$(call replace_spaces,$@) := $(cmd_$(1)))) > $(depfile)
+ @$(if $(2),$(fixup_dep))
+ $(if $(and $(3), $(POSTBUILDS)),
+ $(call do_postbuilds)
+ )
+)
+endef
+
+# Declare the "all" target first so it is the default,
+# even though we don't have the deps yet.
+.PHONY: all
+all:
+
+# make looks for ways to re-generate included makefiles, but in our case, we
+# don't have a direct way. Explicitly telling make that it has nothing to do
+# for them makes it go faster.
+%.d: ;
+
+# Use FORCE_DO_CMD to force a target to run. Should be coupled with
+# do_cmd.
+.PHONY: FORCE_DO_CMD
+FORCE_DO_CMD:
+
+TOOLSET := target
+# Suffix rules, putting all outputs into $(obj).
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.c FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.cc FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.cpp FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.cxx FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.m FORCE_DO_CMD
+ @$(call do_cmd,objc,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.mm FORCE_DO_CMD
+ @$(call do_cmd,objcxx,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.S FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+$(obj).$(TOOLSET)/%.o: $(srcdir)/%.s FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+
+# Try building from generated source, too.
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.c FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.cc FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.cpp FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.cxx FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.m FORCE_DO_CMD
+ @$(call do_cmd,objc,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.mm FORCE_DO_CMD
+ @$(call do_cmd,objcxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.S FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+$(obj).$(TOOLSET)/%.o: $(obj).$(TOOLSET)/%.s FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+
+$(obj).$(TOOLSET)/%.o: $(obj)/%.c FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.cc FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.cpp FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.cxx FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.m FORCE_DO_CMD
+ @$(call do_cmd,objc,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.mm FORCE_DO_CMD
+ @$(call do_cmd,objcxx,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.S FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+$(obj).$(TOOLSET)/%.o: $(obj)/%.s FORCE_DO_CMD
+ @$(call do_cmd,cc,1)
+
+
+ifeq ($(strip $(foreach prefix,$(NO_LOAD),\
+ $(findstring $(join ^,$(prefix)),\
+ $(join ^,.target.mk)))),)
+ include .target.mk
+endif
+ifeq ($(strip $(foreach prefix,$(NO_LOAD),\
+ $(findstring $(join ^,$(prefix)),\
+ $(join ^,action_after_build.target.mk)))),)
+ include action_after_build.target.mk
+endif
+ifeq ($(strip $(foreach prefix,$(NO_LOAD),\
+ $(findstring $(join ^,$(prefix)),\
+ $(join ^,fse.target.mk)))),)
+ include fse.target.mk
+endif
+
+quiet_cmd_regen_makefile = ACTION Regenerating $@
+cmd_regen_makefile = cd $(srcdir); /Users/eshanker/.nvm/versions/node/v5.0.0/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py -fmake --ignore-environment "--toplevel-dir=." -I/Users/eshanker/Code/fsevents/build/config.gypi -I/Users/eshanker/.nvm/versions/node/v5.0.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi -I/Users/eshanker/.node-gyp/5.0.0/include/node/common.gypi "--depth=." "-Goutput_dir=." "--generator-output=build" "-Dlibrary=shared_library" "-Dvisibility=default" "-Dnode_root_dir=/Users/eshanker/.node-gyp/5.0.0" "-Dnode_gyp_dir=/Users/eshanker/.nvm/versions/node/v5.0.0/lib/node_modules/npm/node_modules/node-gyp" "-Dnode_lib_file=node.lib" "-Dmodule_root_dir=/Users/eshanker/Code/fsevents" binding.gyp
+Makefile: $(srcdir)/../../.nvm/versions/node/v5.0.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi $(srcdir)/../../.node-gyp/5.0.0/include/node/common.gypi $(srcdir)/build/config.gypi $(srcdir)/binding.gyp
+ $(call do_cmd,regen_makefile)
+
+# "all" is a concatenation of the "all" targets from all the included
+# sub-makefiles. This is just here to clarify.
+all:
+
+# Add in dependency-tracking rules. $(all_deps) is the list of every single
+# target in our tree. Only consider the ones with .d (dependency) info:
+d_files := $(wildcard $(foreach f,$(all_deps),$(depsdir)/$(f).d))
+ifneq ($(d_files),)
+ include $(d_files)
+endif
diff --git a/node_modules/fsevents/build/action_after_build.target.mk b/node_modules/fsevents/build/action_after_build.target.mk
new file mode 100644
index 00000000..cf7a250f
--- /dev/null
+++ b/node_modules/fsevents/build/action_after_build.target.mk
@@ -0,0 +1,32 @@
+# This file is generated by gyp; do not edit.
+
+TOOLSET := target
+TARGET := action_after_build
+### Generated for copy rule.
+/Users/eshanker/Code/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node: TOOLSET := $(TOOLSET)
+/Users/eshanker/Code/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node: $(builddir)/fse.node FORCE_DO_CMD
+ $(call do_cmd,copy)
+
+all_deps += /Users/eshanker/Code/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node
+binding_gyp_action_after_build_target_copies = /Users/eshanker/Code/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node
+
+### Rules for final target.
+# Build our special outputs first.
+$(obj).target/action_after_build.stamp: | $(binding_gyp_action_after_build_target_copies)
+
+# Preserve order dependency of special output on deps.
+$(binding_gyp_action_after_build_target_copies): | $(builddir)/fse.node
+
+$(obj).target/action_after_build.stamp: TOOLSET := $(TOOLSET)
+$(obj).target/action_after_build.stamp: $(builddir)/fse.node FORCE_DO_CMD
+ $(call do_cmd,touch)
+
+all_deps += $(obj).target/action_after_build.stamp
+# Add target alias
+.PHONY: action_after_build
+action_after_build: $(obj).target/action_after_build.stamp
+
+# Add target alias to "all" target.
+.PHONY: all
+all: action_after_build
+
diff --git a/node_modules/fsevents/build/binding.Makefile b/node_modules/fsevents/build/binding.Makefile
new file mode 100644
index 00000000..f2ba1f78
--- /dev/null
+++ b/node_modules/fsevents/build/binding.Makefile
@@ -0,0 +1,6 @@
+# This file is generated by gyp; do not edit.
+
+export builddir_name ?= ./build/.
+.PHONY: all
+all:
+ $(MAKE) fse action_after_build
diff --git a/node_modules/fsevents/build/fse.target.mk b/node_modules/fsevents/build/fse.target.mk
new file mode 100644
index 00000000..b09ec0ee
--- /dev/null
+++ b/node_modules/fsevents/build/fse.target.mk
@@ -0,0 +1,169 @@
+# This file is generated by gyp; do not edit.
+
+TOOLSET := target
+TARGET := fse
+DEFS_Debug := \
+ '-DNODE_GYP_MODULE_NAME=fse' \
+ '-D_DARWIN_USE_64_BIT_INODE=1' \
+ '-D_LARGEFILE_SOURCE' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DBUILDING_NODE_EXTENSION' \
+ '-DDEBUG' \
+ '-D_DEBUG'
+
+# Flags passed to all source files.
+CFLAGS_Debug := \
+ -O0 \
+ -gdwarf-2 \
+ -mmacosx-version-min=10.5 \
+ -arch x86_64 \
+ -Wall \
+ -Wendif-labels \
+ -W \
+ -Wno-unused-parameter
+
+# Flags passed to only C files.
+CFLAGS_C_Debug := \
+ -fno-strict-aliasing
+
+# Flags passed to only C++ files.
+CFLAGS_CC_Debug := \
+ -std=gnu++0x \
+ -fno-rtti \
+ -fno-exceptions \
+ -fno-threadsafe-statics \
+ -fno-strict-aliasing
+
+# Flags passed to only ObjC files.
+CFLAGS_OBJC_Debug :=
+
+# Flags passed to only ObjC++ files.
+CFLAGS_OBJCC_Debug :=
+
+INCS_Debug := \
+ -I/Users/eshanker/.node-gyp/5.0.0/include/node \
+ -I/Users/eshanker/.node-gyp/5.0.0/src \
+ -I/Users/eshanker/.node-gyp/5.0.0/deps/uv/include \
+ -I/Users/eshanker/.node-gyp/5.0.0/deps/v8/include \
+ -I$(srcdir)/node_modules/nan
+
+DEFS_Release := \
+ '-DNODE_GYP_MODULE_NAME=fse' \
+ '-D_DARWIN_USE_64_BIT_INODE=1' \
+ '-D_LARGEFILE_SOURCE' \
+ '-D_FILE_OFFSET_BITS=64' \
+ '-DBUILDING_NODE_EXTENSION'
+
+# Flags passed to all source files.
+CFLAGS_Release := \
+ -Os \
+ -gdwarf-2 \
+ -mmacosx-version-min=10.5 \
+ -arch x86_64 \
+ -Wall \
+ -Wendif-labels \
+ -W \
+ -Wno-unused-parameter
+
+# Flags passed to only C files.
+CFLAGS_C_Release := \
+ -fno-strict-aliasing
+
+# Flags passed to only C++ files.
+CFLAGS_CC_Release := \
+ -std=gnu++0x \
+ -fno-rtti \
+ -fno-exceptions \
+ -fno-threadsafe-statics \
+ -fno-strict-aliasing
+
+# Flags passed to only ObjC files.
+CFLAGS_OBJC_Release :=
+
+# Flags passed to only ObjC++ files.
+CFLAGS_OBJCC_Release :=
+
+INCS_Release := \
+ -I/Users/eshanker/.node-gyp/5.0.0/include/node \
+ -I/Users/eshanker/.node-gyp/5.0.0/src \
+ -I/Users/eshanker/.node-gyp/5.0.0/deps/uv/include \
+ -I/Users/eshanker/.node-gyp/5.0.0/deps/v8/include \
+ -I$(srcdir)/node_modules/nan
+
+OBJS := \
+ $(obj).target/$(TARGET)/fsevents.o
+
+# Add to the list of files we specially track dependencies for.
+all_deps += $(OBJS)
+
+# CFLAGS et al overrides must be target-local.
+# See "Target-specific Variable Values" in the GNU Make manual.
+$(OBJS): TOOLSET := $(TOOLSET)
+$(OBJS): GYP_CFLAGS := $(DEFS_$(BUILDTYPE)) $(INCS_$(BUILDTYPE)) $(CFLAGS_$(BUILDTYPE)) $(CFLAGS_C_$(BUILDTYPE))
+$(OBJS): GYP_CXXFLAGS := $(DEFS_$(BUILDTYPE)) $(INCS_$(BUILDTYPE)) $(CFLAGS_$(BUILDTYPE)) $(CFLAGS_CC_$(BUILDTYPE))
+$(OBJS): GYP_OBJCFLAGS := $(DEFS_$(BUILDTYPE)) $(INCS_$(BUILDTYPE)) $(CFLAGS_$(BUILDTYPE)) $(CFLAGS_C_$(BUILDTYPE)) $(CFLAGS_OBJC_$(BUILDTYPE))
+$(OBJS): GYP_OBJCXXFLAGS := $(DEFS_$(BUILDTYPE)) $(INCS_$(BUILDTYPE)) $(CFLAGS_$(BUILDTYPE)) $(CFLAGS_CC_$(BUILDTYPE)) $(CFLAGS_OBJCC_$(BUILDTYPE))
+
+# Suffix rules, putting all outputs into $(obj).
+
+$(obj).$(TOOLSET)/$(TARGET)/%.o: $(srcdir)/%.cc FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+
+# Try building from generated source, too.
+
+$(obj).$(TOOLSET)/$(TARGET)/%.o: $(obj).$(TOOLSET)/%.cc FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+
+$(obj).$(TOOLSET)/$(TARGET)/%.o: $(obj)/%.cc FORCE_DO_CMD
+ @$(call do_cmd,cxx,1)
+
+# End of this set of suffix rules
+### Rules for final target.
+LDFLAGS_Debug := \
+ -framework CoreFoundation -framework CoreServices \
+ -undefined dynamic_lookup \
+ -Wl,-search_paths_first \
+ -mmacosx-version-min=10.5 \
+ -arch x86_64 \
+ -L$(builddir)
+
+LIBTOOLFLAGS_Debug := \
+ -framework CoreFoundation -framework CoreServices \
+ -undefined dynamic_lookup \
+ -Wl,-search_paths_first
+
+LDFLAGS_Release := \
+ -framework CoreFoundation -framework CoreServices \
+ -undefined dynamic_lookup \
+ -Wl,-search_paths_first \
+ -mmacosx-version-min=10.5 \
+ -arch x86_64 \
+ -L$(builddir)
+
+LIBTOOLFLAGS_Release := \
+ -framework CoreFoundation -framework CoreServices \
+ -undefined dynamic_lookup \
+ -Wl,-search_paths_first
+
+LIBS :=
+
+$(builddir)/fse.node: GYP_LDFLAGS := $(LDFLAGS_$(BUILDTYPE))
+$(builddir)/fse.node: LIBS := $(LIBS)
+$(builddir)/fse.node: GYP_LIBTOOLFLAGS := $(LIBTOOLFLAGS_$(BUILDTYPE))
+$(builddir)/fse.node: TOOLSET := $(TOOLSET)
+$(builddir)/fse.node: $(OBJS) FORCE_DO_CMD
+ $(call do_cmd,solink_module)
+
+all_deps += $(builddir)/fse.node
+# Add target alias
+.PHONY: fse
+fse: $(builddir)/fse.node
+
+# Short alias for building this executable.
+.PHONY: fse.node
+fse.node: $(builddir)/fse.node
+
+# Add executable to "all" target.
+.PHONY: all
+all: $(builddir)/fse.node
+
diff --git a/node_modules/fsevents/build/gyp-mac-tool b/node_modules/fsevents/build/gyp-mac-tool
new file mode 100755
index 00000000..976c5987
--- /dev/null
+++ b/node_modules/fsevents/build/gyp-mac-tool
@@ -0,0 +1,612 @@
+#!/usr/bin/env python
+# Generated by gyp. Do not edit.
+# Copyright (c) 2012 Google Inc. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+"""Utility functions to perform Xcode-style build steps.
+
+These functions are executed via gyp-mac-tool when using the Makefile generator.
+"""
+
+import fcntl
+import fnmatch
+import glob
+import json
+import os
+import plistlib
+import re
+import shutil
+import string
+import subprocess
+import sys
+import tempfile
+
+
+def main(args):
+ executor = MacTool()
+ exit_code = executor.Dispatch(args)
+ if exit_code is not None:
+ sys.exit(exit_code)
+
+
+class MacTool(object):
+ """This class performs all the Mac tooling steps. The methods can either be
+ executed directly, or dispatched from an argument list."""
+
+ def Dispatch(self, args):
+ """Dispatches a string command to a method."""
+ if len(args) < 1:
+ raise Exception("Not enough arguments")
+
+ method = "Exec%s" % self._CommandifyName(args[0])
+ return getattr(self, method)(*args[1:])
+
+ def _CommandifyName(self, name_string):
+ """Transforms a tool name like copy-info-plist to CopyInfoPlist"""
+ return name_string.title().replace('-', '')
+
+ def ExecCopyBundleResource(self, source, dest, convert_to_binary):
+ """Copies a resource file to the bundle/Resources directory, performing any
+ necessary compilation on each resource."""
+ extension = os.path.splitext(source)[1].lower()
+ if os.path.isdir(source):
+ # Copy tree.
+ # TODO(thakis): This copies file attributes like mtime, while the
+ # single-file branch below doesn't. This should probably be changed to
+ # be consistent with the single-file branch.
+ if os.path.exists(dest):
+ shutil.rmtree(dest)
+ shutil.copytree(source, dest)
+ elif extension == '.xib':
+ return self._CopyXIBFile(source, dest)
+ elif extension == '.storyboard':
+ return self._CopyXIBFile(source, dest)
+ elif extension == '.strings':
+ self._CopyStringsFile(source, dest, convert_to_binary)
+ else:
+ shutil.copy(source, dest)
+
+ def _CopyXIBFile(self, source, dest):
+ """Compiles a XIB file with ibtool into a binary plist in the bundle."""
+
+ # ibtool sometimes crashes with relative paths. See crbug.com/314728.
+ base = os.path.dirname(os.path.realpath(__file__))
+ if os.path.relpath(source):
+ source = os.path.join(base, source)
+ if os.path.relpath(dest):
+ dest = os.path.join(base, dest)
+
+ args = ['xcrun', 'ibtool', '--errors', '--warnings', '--notices',
+ '--output-format', 'human-readable-text', '--compile', dest, source]
+ ibtool_section_re = re.compile(r'/\*.*\*/')
+ ibtool_re = re.compile(r'.*note:.*is clipping its content')
+ ibtoolout = subprocess.Popen(args, stdout=subprocess.PIPE)
+ current_section_header = None
+ for line in ibtoolout.stdout:
+ if ibtool_section_re.match(line):
+ current_section_header = line
+ elif not ibtool_re.match(line):
+ if current_section_header:
+ sys.stdout.write(current_section_header)
+ current_section_header = None
+ sys.stdout.write(line)
+ return ibtoolout.returncode
+
+ def _ConvertToBinary(self, dest):
+ subprocess.check_call([
+ 'xcrun', 'plutil', '-convert', 'binary1', '-o', dest, dest])
+
+ def _CopyStringsFile(self, source, dest, convert_to_binary):
+ """Copies a .strings file using iconv to reconvert the input into UTF-16."""
+ input_code = self._DetectInputEncoding(source) or "UTF-8"
+
+ # Xcode's CpyCopyStringsFile / builtin-copyStrings seems to call
+ # CFPropertyListCreateFromXMLData() behind the scenes; at least it prints
+ # CFPropertyListCreateFromXMLData(): Old-style plist parser: missing
+ # semicolon in dictionary.
+ # on invalid files. Do the same kind of validation.
+ import CoreFoundation
+ s = open(source, 'rb').read()
+ d = CoreFoundation.CFDataCreate(None, s, len(s))
+ _, error = CoreFoundation.CFPropertyListCreateFromXMLData(None, d, 0, None)
+ if error:
+ return
+
+ fp = open(dest, 'wb')
+ fp.write(s.decode(input_code).encode('UTF-16'))
+ fp.close()
+
+ if convert_to_binary == 'True':
+ self._ConvertToBinary(dest)
+
+ def _DetectInputEncoding(self, file_name):
+ """Reads the first few bytes from file_name and tries to guess the text
+ encoding. Returns None as a guess if it can't detect it."""
+ fp = open(file_name, 'rb')
+ try:
+ header = fp.read(3)
+ except e:
+ fp.close()
+ return None
+ fp.close()
+ if header.startswith("\xFE\xFF"):
+ return "UTF-16"
+ elif header.startswith("\xFF\xFE"):
+ return "UTF-16"
+ elif header.startswith("\xEF\xBB\xBF"):
+ return "UTF-8"
+ else:
+ return None
+
+ def ExecCopyInfoPlist(self, source, dest, convert_to_binary, *keys):
+ """Copies the |source| Info.plist to the destination directory |dest|."""
+ # Read the source Info.plist into memory.
+ fd = open(source, 'r')
+ lines = fd.read()
+ fd.close()
+
+ # Insert synthesized key/value pairs (e.g. BuildMachineOSBuild).
+ plist = plistlib.readPlistFromString(lines)
+ if keys:
+ plist = dict(plist.items() + json.loads(keys[0]).items())
+ lines = plistlib.writePlistToString(plist)
+
+ # Go through all the environment variables and replace them as variables in
+ # the file.
+ IDENT_RE = re.compile(r'[/\s]')
+ for key in os.environ:
+ if key.startswith('_'):
+ continue
+ evar = '${%s}' % key
+ evalue = os.environ[key]
+ lines = string.replace(lines, evar, evalue)
+
+ # Xcode supports various suffices on environment variables, which are
+ # all undocumented. :rfc1034identifier is used in the standard project
+ # template these days, and :identifier was used earlier. They are used to
+ # convert non-url characters into things that look like valid urls --
+ # except that the replacement character for :identifier, '_' isn't valid
+ # in a URL either -- oops, hence :rfc1034identifier was born.
+ evar = '${%s:identifier}' % key
+ evalue = IDENT_RE.sub('_', os.environ[key])
+ lines = string.replace(lines, evar, evalue)
+
+ evar = '${%s:rfc1034identifier}' % key
+ evalue = IDENT_RE.sub('-', os.environ[key])
+ lines = string.replace(lines, evar, evalue)
+
+ # Remove any keys with values that haven't been replaced.
+ lines = lines.split('\n')
+ for i in range(len(lines)):
+ if lines[i].strip().startswith("${"):
+ lines[i] = None
+ lines[i - 1] = None
+ lines = '\n'.join(filter(lambda x: x is not None, lines))
+
+ # Write out the file with variables replaced.
+ fd = open(dest, 'w')
+ fd.write(lines)
+ fd.close()
+
+ # Now write out PkgInfo file now that the Info.plist file has been
+ # "compiled".
+ self._WritePkgInfo(dest)
+
+ if convert_to_binary == 'True':
+ self._ConvertToBinary(dest)
+
+ def _WritePkgInfo(self, info_plist):
+ """This writes the PkgInfo file from the data stored in Info.plist."""
+ plist = plistlib.readPlist(info_plist)
+ if not plist:
+ return
+
+ # Only create PkgInfo for executable types.
+ package_type = plist['CFBundlePackageType']
+ if package_type != 'APPL':
+ return
+
+ # The format of PkgInfo is eight characters, representing the bundle type
+ # and bundle signature, each four characters. If that is missing, four
+ # '?' characters are used instead.
+ signature_code = plist.get('CFBundleSignature', '????')
+ if len(signature_code) != 4: # Wrong length resets everything, too.
+ signature_code = '?' * 4
+
+ dest = os.path.join(os.path.dirname(info_plist), 'PkgInfo')
+ fp = open(dest, 'w')
+ fp.write('%s%s' % (package_type, signature_code))
+ fp.close()
+
+ def ExecFlock(self, lockfile, *cmd_list):
+ """Emulates the most basic behavior of Linux's flock(1)."""
+ # Rely on exception handling to report errors.
+ fd = os.open(lockfile, os.O_RDONLY|os.O_NOCTTY|os.O_CREAT, 0o666)
+ fcntl.flock(fd, fcntl.LOCK_EX)
+ return subprocess.call(cmd_list)
+
+ def ExecFilterLibtool(self, *cmd_list):
+ """Calls libtool and filters out '/path/to/libtool: file: foo.o has no
+ symbols'."""
+ libtool_re = re.compile(r'^.*libtool: file: .* has no symbols$')
+ libtool_re5 = re.compile(
+ r'^.*libtool: warning for library: ' +
+ r'.* the table of contents is empty ' +
+ r'\(no object file members in the library define global symbols\)$')
+ env = os.environ.copy()
+ # Ref:
+ # http://www.opensource.apple.com/source/cctools/cctools-809/misc/libtool.c
+ # The problem with this flag is that it resets the file mtime on the file to
+ # epoch=0, e.g. 1970-1-1 or 1969-12-31 depending on timezone.
+ env['ZERO_AR_DATE'] = '1'
+ libtoolout = subprocess.Popen(cmd_list, stderr=subprocess.PIPE, env=env)
+ _, err = libtoolout.communicate()
+ for line in err.splitlines():
+ if not libtool_re.match(line) and not libtool_re5.match(line):
+ print >>sys.stderr, line
+ # Unconditionally touch the output .a file on the command line if present
+ # and the command succeeded. A bit hacky.
+ if not libtoolout.returncode:
+ for i in range(len(cmd_list) - 1):
+ if cmd_list[i] == "-o" and cmd_list[i+1].endswith('.a'):
+ os.utime(cmd_list[i+1], None)
+ break
+ return libtoolout.returncode
+
+ def ExecPackageFramework(self, framework, version):
+ """Takes a path to Something.framework and the Current version of that and
+ sets up all the symlinks."""
+ # Find the name of the binary based on the part before the ".framework".
+ binary = os.path.basename(framework).split('.')[0]
+
+ CURRENT = 'Current'
+ RESOURCES = 'Resources'
+ VERSIONS = 'Versions'
+
+ if not os.path.exists(os.path.join(framework, VERSIONS, version, binary)):
+ # Binary-less frameworks don't seem to contain symlinks (see e.g.
+ # chromium's out/Debug/org.chromium.Chromium.manifest/ bundle).
+ return
+
+ # Move into the framework directory to set the symlinks correctly.
+ pwd = os.getcwd()
+ os.chdir(framework)
+
+ # Set up the Current version.
+ self._Relink(version, os.path.join(VERSIONS, CURRENT))
+
+ # Set up the root symlinks.
+ self._Relink(os.path.join(VERSIONS, CURRENT, binary), binary)
+ self._Relink(os.path.join(VERSIONS, CURRENT, RESOURCES), RESOURCES)
+
+ # Back to where we were before!
+ os.chdir(pwd)
+
+ def _Relink(self, dest, link):
+ """Creates a symlink to |dest| named |link|. If |link| already exists,
+ it is overwritten."""
+ if os.path.lexists(link):
+ os.remove(link)
+ os.symlink(dest, link)
+
+ def ExecCompileXcassets(self, keys, *inputs):
+ """Compiles multiple .xcassets files into a single .car file.
+
+ This invokes 'actool' to compile all the inputs .xcassets files. The
+ |keys| arguments is a json-encoded dictionary of extra arguments to
+ pass to 'actool' when the asset catalogs contains an application icon
+ or a launch image.
+
+ Note that 'actool' does not create the Assets.car file if the asset
+ catalogs does not contains imageset.
+ """
+ command_line = [
+ 'xcrun', 'actool', '--output-format', 'human-readable-text',
+ '--compress-pngs', '--notices', '--warnings', '--errors',
+ ]
+ is_iphone_target = 'IPHONEOS_DEPLOYMENT_TARGET' in os.environ
+ if is_iphone_target:
+ platform = os.environ['CONFIGURATION'].split('-')[-1]
+ if platform not in ('iphoneos', 'iphonesimulator'):
+ platform = 'iphonesimulator'
+ command_line.extend([
+ '--platform', platform, '--target-device', 'iphone',
+ '--target-device', 'ipad', '--minimum-deployment-target',
+ os.environ['IPHONEOS_DEPLOYMENT_TARGET'], '--compile',
+ os.path.abspath(os.environ['CONTENTS_FOLDER_PATH']),
+ ])
+ else:
+ command_line.extend([
+ '--platform', 'macosx', '--target-device', 'mac',
+ '--minimum-deployment-target', os.environ['MACOSX_DEPLOYMENT_TARGET'],
+ '--compile',
+ os.path.abspath(os.environ['UNLOCALIZED_RESOURCES_FOLDER_PATH']),
+ ])
+ if keys:
+ keys = json.loads(keys)
+ for key, value in keys.iteritems():
+ arg_name = '--' + key
+ if isinstance(value, bool):
+ if value:
+ command_line.append(arg_name)
+ elif isinstance(value, list):
+ for v in value:
+ command_line.append(arg_name)
+ command_line.append(str(v))
+ else:
+ command_line.append(arg_name)
+ command_line.append(str(value))
+ # Note: actool crashes if inputs path are relative, so use os.path.abspath
+ # to get absolute path name for inputs.
+ command_line.extend(map(os.path.abspath, inputs))
+ subprocess.check_call(command_line)
+
+ def ExecMergeInfoPlist(self, output, *inputs):
+ """Merge multiple .plist files into a single .plist file."""
+ merged_plist = {}
+ for path in inputs:
+ plist = self._LoadPlistMaybeBinary(path)
+ self._MergePlist(merged_plist, plist)
+ plistlib.writePlist(merged_plist, output)
+
+ def ExecCodeSignBundle(self, key, resource_rules, entitlements, provisioning):
+ """Code sign a bundle.
+
+ This function tries to code sign an iOS bundle, following the same
+ algorithm as Xcode:
+ 1. copy ResourceRules.plist from the user or the SDK into the bundle,
+ 2. pick the provisioning profile that best match the bundle identifier,
+ and copy it into the bundle as embedded.mobileprovision,
+ 3. copy Entitlements.plist from user or SDK next to the bundle,
+ 4. code sign the bundle.
+ """
+ resource_rules_path = self._InstallResourceRules(resource_rules)
+ substitutions, overrides = self._InstallProvisioningProfile(
+ provisioning, self._GetCFBundleIdentifier())
+ entitlements_path = self._InstallEntitlements(
+ entitlements, substitutions, overrides)
+ subprocess.check_call([
+ 'codesign', '--force', '--sign', key, '--resource-rules',
+ resource_rules_path, '--entitlements', entitlements_path,
+ os.path.join(
+ os.environ['TARGET_BUILD_DIR'],
+ os.environ['FULL_PRODUCT_NAME'])])
+
+ def _InstallResourceRules(self, resource_rules):
+ """Installs ResourceRules.plist from user or SDK into the bundle.
+
+ Args:
+ resource_rules: string, optional, path to the ResourceRules.plist file
+ to use, default to "${SDKROOT}/ResourceRules.plist"
+
+ Returns:
+ Path to the copy of ResourceRules.plist into the bundle.
+ """
+ source_path = resource_rules
+ target_path = os.path.join(
+ os.environ['BUILT_PRODUCTS_DIR'],
+ os.environ['CONTENTS_FOLDER_PATH'],
+ 'ResourceRules.plist')
+ if not source_path:
+ source_path = os.path.join(
+ os.environ['SDKROOT'], 'ResourceRules.plist')
+ shutil.copy2(source_path, target_path)
+ return target_path
+
+ def _InstallProvisioningProfile(self, profile, bundle_identifier):
+ """Installs embedded.mobileprovision into the bundle.
+
+ Args:
+ profile: string, optional, short name of the .mobileprovision file
+ to use, if empty or the file is missing, the best file installed
+ will be used
+ bundle_identifier: string, value of CFBundleIdentifier from Info.plist
+
+ Returns:
+ A tuple containing two dictionary: variables substitutions and values
+ to overrides when generating the entitlements file.
+ """
+ source_path, provisioning_data, team_id = self._FindProvisioningProfile(
+ profile, bundle_identifier)
+ target_path = os.path.join(
+ os.environ['BUILT_PRODUCTS_DIR'],
+ os.environ['CONTENTS_FOLDER_PATH'],
+ 'embedded.mobileprovision')
+ shutil.copy2(source_path, target_path)
+ substitutions = self._GetSubstitutions(bundle_identifier, team_id + '.')
+ return substitutions, provisioning_data['Entitlements']
+
+ def _FindProvisioningProfile(self, profile, bundle_identifier):
+ """Finds the .mobileprovision file to use for signing the bundle.
+
+ Checks all the installed provisioning profiles (or if the user specified
+ the PROVISIONING_PROFILE variable, only consult it) and select the most
+ specific that correspond to the bundle identifier.
+
+ Args:
+ profile: string, optional, short name of the .mobileprovision file
+ to use, if empty or the file is missing, the best file installed
+ will be used
+ bundle_identifier: string, value of CFBundleIdentifier from Info.plist
+
+ Returns:
+ A tuple of the path to the selected provisioning profile, the data of
+ the embedded plist in the provisioning profile and the team identifier
+ to use for code signing.
+
+ Raises:
+ SystemExit: if no .mobileprovision can be used to sign the bundle.
+ """
+ profiles_dir = os.path.join(
+ os.environ['HOME'], 'Library', 'MobileDevice', 'Provisioning Profiles')
+ if not os.path.isdir(profiles_dir):
+ print >>sys.stderr, (
+ 'cannot find mobile provisioning for %s' % bundle_identifier)
+ sys.exit(1)
+ provisioning_profiles = None
+ if profile:
+ profile_path = os.path.join(profiles_dir, profile + '.mobileprovision')
+ if os.path.exists(profile_path):
+ provisioning_profiles = [profile_path]
+ if not provisioning_profiles:
+ provisioning_profiles = glob.glob(
+ os.path.join(profiles_dir, '*.mobileprovision'))
+ valid_provisioning_profiles = {}
+ for profile_path in provisioning_profiles:
+ profile_data = self._LoadProvisioningProfile(profile_path)
+ app_id_pattern = profile_data.get(
+ 'Entitlements', {}).get('application-identifier', '')
+ for team_identifier in profile_data.get('TeamIdentifier', []):
+ app_id = '%s.%s' % (team_identifier, bundle_identifier)
+ if fnmatch.fnmatch(app_id, app_id_pattern):
+ valid_provisioning_profiles[app_id_pattern] = (
+ profile_path, profile_data, team_identifier)
+ if not valid_provisioning_profiles:
+ print >>sys.stderr, (
+ 'cannot find mobile provisioning for %s' % bundle_identifier)
+ sys.exit(1)
+ # If the user has multiple provisioning profiles installed that can be
+ # used for ${bundle_identifier}, pick the most specific one (ie. the
+ # provisioning profile whose pattern is the longest).
+ selected_key = max(valid_provisioning_profiles, key=lambda v: len(v))
+ return valid_provisioning_profiles[selected_key]
+
+ def _LoadProvisioningProfile(self, profile_path):
+ """Extracts the plist embedded in a provisioning profile.
+
+ Args:
+ profile_path: string, path to the .mobileprovision file
+
+ Returns:
+ Content of the plist embedded in the provisioning profile as a dictionary.
+ """
+ with tempfile.NamedTemporaryFile() as temp:
+ subprocess.check_call([
+ 'security', 'cms', '-D', '-i', profile_path, '-o', temp.name])
+ return self._LoadPlistMaybeBinary(temp.name)
+
+ def _MergePlist(self, merged_plist, plist):
+ """Merge |plist| into |merged_plist|."""
+ for key, value in plist.iteritems():
+ if isinstance(value, dict):
+ merged_value = merged_plist.get(key, {})
+ if isinstance(merged_value, dict):
+ self._MergePlist(merged_value, value)
+ merged_plist[key] = merged_value
+ else:
+ merged_plist[key] = value
+ else:
+ merged_plist[key] = value
+
+ def _LoadPlistMaybeBinary(self, plist_path):
+ """Loads into a memory a plist possibly encoded in binary format.
+
+ This is a wrapper around plistlib.readPlist that tries to convert the
+ plist to the XML format if it can't be parsed (assuming that it is in
+ the binary format).
+
+ Args:
+ plist_path: string, path to a plist file, in XML or binary format
+
+ Returns:
+ Content of the plist as a dictionary.
+ """
+ try:
+ # First, try to read the file using plistlib that only supports XML,
+ # and if an exception is raised, convert a temporary copy to XML and
+ # load that copy.
+ return plistlib.readPlist(plist_path)
+ except:
+ pass
+ with tempfile.NamedTemporaryFile() as temp:
+ shutil.copy2(plist_path, temp.name)
+ subprocess.check_call(['plutil', '-convert', 'xml1', temp.name])
+ return plistlib.readPlist(temp.name)
+
+ def _GetSubstitutions(self, bundle_identifier, app_identifier_prefix):
+ """Constructs a dictionary of variable substitutions for Entitlements.plist.
+
+ Args:
+ bundle_identifier: string, value of CFBundleIdentifier from Info.plist
+ app_identifier_prefix: string, value for AppIdentifierPrefix
+
+ Returns:
+ Dictionary of substitutions to apply when generating Entitlements.plist.
+ """
+ return {
+ 'CFBundleIdentifier': bundle_identifier,
+ 'AppIdentifierPrefix': app_identifier_prefix,
+ }
+
+ def _GetCFBundleIdentifier(self):
+ """Extracts CFBundleIdentifier value from Info.plist in the bundle.
+
+ Returns:
+ Value of CFBundleIdentifier in the Info.plist located in the bundle.
+ """
+ info_plist_path = os.path.join(
+ os.environ['TARGET_BUILD_DIR'],
+ os.environ['INFOPLIST_PATH'])
+ info_plist_data = self._LoadPlistMaybeBinary(info_plist_path)
+ return info_plist_data['CFBundleIdentifier']
+
+ def _InstallEntitlements(self, entitlements, substitutions, overrides):
+ """Generates and install the ${BundleName}.xcent entitlements file.
+
+ Expands variables "$(variable)" pattern in the source entitlements file,
+ add extra entitlements defined in the .mobileprovision file and the copy
+ the generated plist to "${BundlePath}.xcent".
+
+ Args:
+ entitlements: string, optional, path to the Entitlements.plist template
+ to use, defaults to "${SDKROOT}/Entitlements.plist"
+ substitutions: dictionary, variable substitutions
+ overrides: dictionary, values to add to the entitlements
+
+ Returns:
+ Path to the generated entitlements file.
+ """
+ source_path = entitlements
+ target_path = os.path.join(
+ os.environ['BUILT_PRODUCTS_DIR'],
+ os.environ['PRODUCT_NAME'] + '.xcent')
+ if not source_path:
+ source_path = os.path.join(
+ os.environ['SDKROOT'],
+ 'Entitlements.plist')
+ shutil.copy2(source_path, target_path)
+ data = self._LoadPlistMaybeBinary(target_path)
+ data = self._ExpandVariables(data, substitutions)
+ if overrides:
+ for key in overrides:
+ if key not in data:
+ data[key] = overrides[key]
+ plistlib.writePlist(data, target_path)
+ return target_path
+
+ def _ExpandVariables(self, data, substitutions):
+ """Expands variables "$(variable)" in data.
+
+ Args:
+ data: object, can be either string, list or dictionary
+ substitutions: dictionary, variable substitutions to perform
+
+ Returns:
+ Copy of data where each references to "$(variable)" has been replaced
+ by the corresponding value found in substitutions, or left intact if
+ the key was not found.
+ """
+ if isinstance(data, str):
+ for key, value in substitutions.iteritems():
+ data = data.replace('$(%s)' % key, value)
+ return data
+ if isinstance(data, list):
+ return [self._ExpandVariables(v, substitutions) for v in data]
+ if isinstance(data, dict):
+ return dict((k, self._ExpandVariables(data[k],
+ substitutions)) for k in data)
+ return data
+
+if __name__ == '__main__':
+ sys.exit(main(sys.argv[1:]))
diff --git a/node_modules/fsevents/fsevents.cc b/node_modules/fsevents/fsevents.cc
new file mode 100644
index 00000000..a347db12
--- /dev/null
+++ b/node_modules/fsevents/fsevents.cc
@@ -0,0 +1,102 @@
+/*
+** © 2014 by Philipp Dunkel
+** Licensed under MIT License.
+*/
+
+#include "nan.h"
+#include "uv.h"
+#include "v8.h"
+#include "pthread.h"
+#include "CoreFoundation/CoreFoundation.h"
+#include "CoreServices/CoreServices.h"
+#include
+#include
+
+#include "src/storage.cc"
+namespace fse {
+ class FSEvents : public node::ObjectWrap {
+ public:
+ FSEvents(const char *path, Nan::Callback *handler);
+ ~FSEvents();
+
+ // locking.cc
+ bool lockStarted;
+ pthread_mutex_t lockmutex;
+ void lockingStart();
+ void lock();
+ void unlock();
+ void lockingStop();
+
+ // async.cc
+ uv_async_t async;
+ void asyncStart();
+ void asyncTrigger();
+ void asyncStop();
+
+ // thread.cc
+ pthread_t thread;
+ CFRunLoopRef threadloop;
+ void threadStart();
+ static void *threadRun(void *ctx);
+ void threadStop();
+
+ // methods.cc - internal
+ Nan::Callback *handler;
+ void emitEvent(const char *path, UInt32 flags, UInt64 id);
+
+ // Common
+ CFArrayRef paths;
+ std::vector events;
+ static void Initialize(v8::Handle exports);
+
+ // methods.cc - exposed
+ static NAN_METHOD(New);
+ static NAN_METHOD(Stop);
+ static NAN_METHOD(Start);
+
+ };
+}
+
+using namespace fse;
+
+FSEvents::FSEvents(const char *path, Nan::Callback *handler): handler(handler) {
+ CFStringRef dirs[] = { CFStringCreateWithCString(NULL, path, kCFStringEncodingUTF8) };
+ paths = CFArrayCreate(NULL, (const void **)&dirs, 1, NULL);
+ threadloop = NULL;
+ lockingStart();
+}
+FSEvents::~FSEvents() {
+ std::cout << "YIKES" << std::endl;
+ lockingStop();
+ delete handler;
+ handler = NULL;
+
+ CFRelease(paths);
+}
+
+#ifndef kFSEventStreamEventFlagItemCreated
+#define kFSEventStreamEventFlagItemCreated 0x00000010
+#endif
+
+#include "src/locking.cc"
+#include "src/async.cc"
+#include "src/thread.cc"
+#include "src/constants.cc"
+#include "src/methods.cc"
+
+void FSEvents::Initialize(v8::Handle exports) {
+ v8::Local tpl = Nan::New(FSEvents::New);
+ tpl->SetClassName(Nan::New("FSEvents").ToLocalChecked());
+ tpl->InstanceTemplate()->SetInternalFieldCount(1);
+ tpl->PrototypeTemplate()->Set(
+ Nan::New("start").ToLocalChecked(),
+ Nan::New(FSEvents::Start));
+ tpl->PrototypeTemplate()->Set(
+ Nan::New("stop").ToLocalChecked(),
+ Nan::New(FSEvents::Stop));
+ exports->Set(Nan::New("Constants").ToLocalChecked(), Constants());
+ exports->Set(Nan::New("FSEvents").ToLocalChecked(),
+ tpl->GetFunction());
+}
+
+NODE_MODULE(fse, FSEvents::Initialize)
diff --git a/node_modules/fsevents/fsevents.js b/node_modules/fsevents/fsevents.js
new file mode 100644
index 00000000..4f36824d
--- /dev/null
+++ b/node_modules/fsevents/fsevents.js
@@ -0,0 +1,105 @@
+/*
+ ** © 2014 by Philipp Dunkel
+ ** Licensed under MIT License.
+ */
+
+/* jshint node:true */
+'use strict';
+
+var path = require('path');
+var binary = require('node-pre-gyp');
+var Native = require(binary.find(path.join(__dirname, 'package.json')));
+
+var EventEmitter = require('events').EventEmitter;
+var fs = require('fs');
+var inherits = require('util').inherits;
+
+function FSEvents(path, handler) {
+ EventEmitter.call(this);
+
+ Object.defineProperty(this, '_impl', {
+ value: new Native.FSEvents(String(path || ''), handler),
+ enumerable: false,
+ writable: false
+ });
+}
+
+inherits(FSEvents, EventEmitter);
+proxies(FSEvents, Native.FSEvents);
+
+module.exports = watch;
+module.exports.getInfo = getInfo;
+module.exports.FSEvents = Native.FSEvents;
+module.exports.Constants = Native.Constants;
+
+var defer = global.setImmediate || process.nextTick;
+
+function watch(path) {
+ var fse = new FSEvents(String(path || ''), handler);
+ EventEmitter.call(fse);
+ return fse;
+
+ function handler(path, flags, id) {
+ defer(function() {
+ fse.emit('fsevent', path, flags, id);
+ var info = getInfo(path, flags);
+ info.id = id;
+ if (info.event === 'moved') {
+ fs.stat(info.path, function(err, stat) {
+ info.event = (err || !stat) ? 'moved-out' : 'moved-in';
+ fse.emit('change', path, info);
+ fse.emit(info.event, path, info);
+ });
+ } else {
+ fse.emit('change', path, info);
+ fse.emit(info.event, path, info);
+ }
+ });
+ }
+}
+
+function proxies(ctor, target) {
+ Object.keys(target.prototype).filter(function(key) {
+ return typeof target.prototype[key] === 'function';
+ }).forEach(function(key) {
+ ctor.prototype[key] = function() {
+ this._impl[key].apply(this._impl, arguments);
+ return this;
+ }
+ });
+}
+
+function getFileType(flags) {
+ if (Native.Constants.kFSEventStreamEventFlagItemIsFile & flags) return 'file';
+ if (Native.Constants.kFSEventStreamEventFlagItemIsDir & flags) return 'directory';
+ if (Native.Constants.kFSEventStreamEventFlagItemIsSymlink & flags) return 'symlink';
+}
+
+function getEventType(flags) {
+ if (Native.Constants.kFSEventStreamEventFlagItemRemoved & flags) return 'deleted';
+ if (Native.Constants.kFSEventStreamEventFlagItemRenamed & flags) return 'moved';
+ if (Native.Constants.kFSEventStreamEventFlagItemCreated & flags) return 'created';
+ if (Native.Constants.kFSEventStreamEventFlagItemModified & flags) return 'modified';
+ if (Native.Constants.kFSEventStreamEventFlagRootChanged & flags) return 'root-changed';
+
+ return 'unknown';
+}
+
+function getFileChanges(flags) {
+ return {
+ inode: !! (Native.Constants.kFSEventStreamEventFlagItemInodeMetaMod & flags),
+ finder: !! (Native.Constants.kFSEventStreamEventFlagItemFinderInfoMod & flags),
+ access: !! (Native.Constants.kFSEventStreamEventFlagItemChangeOwner & flags),
+ xattrs: !! (Native.Constants.kFSEventStreamEventFlagItemXattrMod & flags)
+ };
+}
+
+function getInfo(path, flags) {
+ return {
+ path: path,
+ event: getEventType(flags),
+ type: getFileType(flags),
+ changes: getFileChanges(flags),
+ flags: flags
+ };
+}
diff --git a/node_modules/fsevents/lib/binding/Release/node-v11-darwin-x64/fse.node b/node_modules/fsevents/lib/binding/Release/node-v11-darwin-x64/fse.node
new file mode 100755
index 00000000..1d4e2d12
Binary files /dev/null and b/node_modules/fsevents/lib/binding/Release/node-v11-darwin-x64/fse.node differ
diff --git a/node_modules/fsevents/lib/binding/Release/node-v46-darwin-x64/fse.node b/node_modules/fsevents/lib/binding/Release/node-v46-darwin-x64/fse.node
new file mode 100755
index 00000000..ca473e6e
Binary files /dev/null and b/node_modules/fsevents/lib/binding/Release/node-v46-darwin-x64/fse.node differ
diff --git a/node_modules/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node b/node_modules/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node
new file mode 100755
index 00000000..393572ad
Binary files /dev/null and b/node_modules/fsevents/lib/binding/Release/node-v47-darwin-x64/fse.node differ
diff --git a/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node b/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node
new file mode 100755
index 00000000..23035413
Binary files /dev/null and b/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node differ
diff --git a/node_modules/fsevents/node_modules/.bin/har-validator b/node_modules/fsevents/node_modules/.bin/har-validator
new file mode 120000
index 00000000..c6ec1634
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/har-validator
@@ -0,0 +1 @@
+../har-validator/bin/har-validator
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/mkdirp b/node_modules/fsevents/node_modules/.bin/mkdirp
new file mode 120000
index 00000000..017896ce
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/mkdirp
@@ -0,0 +1 @@
+../mkdirp/bin/cmd.js
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/node-pre-gyp b/node_modules/fsevents/node_modules/.bin/node-pre-gyp
new file mode 120000
index 00000000..47a90a51
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/node-pre-gyp
@@ -0,0 +1 @@
+../node-pre-gyp/bin/node-pre-gyp
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/nopt b/node_modules/fsevents/node_modules/.bin/nopt
new file mode 120000
index 00000000..6b6566ea
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/nopt
@@ -0,0 +1 @@
+../nopt/bin/nopt.js
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/rc b/node_modules/fsevents/node_modules/.bin/rc
new file mode 120000
index 00000000..a3f6fc7f
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/rc
@@ -0,0 +1 @@
+../rc/index.js
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/rimraf b/node_modules/fsevents/node_modules/.bin/rimraf
new file mode 120000
index 00000000..4cd49a49
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/rimraf
@@ -0,0 +1 @@
+../rimraf/bin.js
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/semver b/node_modules/fsevents/node_modules/.bin/semver
new file mode 120000
index 00000000..317eb293
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/semver
@@ -0,0 +1 @@
+../semver/bin/semver
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/sshpk-conv b/node_modules/fsevents/node_modules/.bin/sshpk-conv
new file mode 120000
index 00000000..a2a295c8
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/sshpk-conv
@@ -0,0 +1 @@
+../sshpk/bin/sshpk-conv
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/sshpk-sign b/node_modules/fsevents/node_modules/.bin/sshpk-sign
new file mode 120000
index 00000000..766b9b3a
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/sshpk-sign
@@ -0,0 +1 @@
+../sshpk/bin/sshpk-sign
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/sshpk-verify b/node_modules/fsevents/node_modules/.bin/sshpk-verify
new file mode 120000
index 00000000..bfd7e3ad
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/sshpk-verify
@@ -0,0 +1 @@
+../sshpk/bin/sshpk-verify
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/strip-json-comments b/node_modules/fsevents/node_modules/.bin/strip-json-comments
new file mode 120000
index 00000000..63d549f9
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/strip-json-comments
@@ -0,0 +1 @@
+../strip-json-comments/cli.js
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/supports-color b/node_modules/fsevents/node_modules/.bin/supports-color
new file mode 120000
index 00000000..af0f05ef
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/supports-color
@@ -0,0 +1 @@
+../supports-color/cli.js
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/.bin/uuid b/node_modules/fsevents/node_modules/.bin/uuid
new file mode 120000
index 00000000..b3e45bc5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/.bin/uuid
@@ -0,0 +1 @@
+../uuid/bin/uuid
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/abbrev/LICENSE b/node_modules/fsevents/node_modules/abbrev/LICENSE
new file mode 100644
index 00000000..19129e31
--- /dev/null
+++ b/node_modules/fsevents/node_modules/abbrev/LICENSE
@@ -0,0 +1,15 @@
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/abbrev/README.md b/node_modules/fsevents/node_modules/abbrev/README.md
new file mode 100644
index 00000000..99746fe6
--- /dev/null
+++ b/node_modules/fsevents/node_modules/abbrev/README.md
@@ -0,0 +1,23 @@
+# abbrev-js
+
+Just like [ruby's Abbrev](http://apidock.com/ruby/Abbrev).
+
+Usage:
+
+ var abbrev = require("abbrev");
+ abbrev("foo", "fool", "folding", "flop");
+
+ // returns:
+ { fl: 'flop'
+ , flo: 'flop'
+ , flop: 'flop'
+ , fol: 'folding'
+ , fold: 'folding'
+ , foldi: 'folding'
+ , foldin: 'folding'
+ , folding: 'folding'
+ , foo: 'foo'
+ , fool: 'fool'
+ }
+
+This is handy for command-line scripts, or other cases where you want to be able to accept shorthands.
diff --git a/node_modules/fsevents/node_modules/abbrev/abbrev.js b/node_modules/fsevents/node_modules/abbrev/abbrev.js
new file mode 100644
index 00000000..69cfeac5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/abbrev/abbrev.js
@@ -0,0 +1,62 @@
+
+module.exports = exports = abbrev.abbrev = abbrev
+
+abbrev.monkeyPatch = monkeyPatch
+
+function monkeyPatch () {
+ Object.defineProperty(Array.prototype, 'abbrev', {
+ value: function () { return abbrev(this) },
+ enumerable: false, configurable: true, writable: true
+ })
+
+ Object.defineProperty(Object.prototype, 'abbrev', {
+ value: function () { return abbrev(Object.keys(this)) },
+ enumerable: false, configurable: true, writable: true
+ })
+}
+
+function abbrev (list) {
+ if (arguments.length !== 1 || !Array.isArray(list)) {
+ list = Array.prototype.slice.call(arguments, 0)
+ }
+ for (var i = 0, l = list.length, args = [] ; i < l ; i ++) {
+ args[i] = typeof list[i] === "string" ? list[i] : String(list[i])
+ }
+
+ // sort them lexicographically, so that they're next to their nearest kin
+ args = args.sort(lexSort)
+
+ // walk through each, seeing how much it has in common with the next and previous
+ var abbrevs = {}
+ , prev = ""
+ for (var i = 0, l = args.length ; i < l ; i ++) {
+ var current = args[i]
+ , next = args[i + 1] || ""
+ , nextMatches = true
+ , prevMatches = true
+ if (current === next) continue
+ for (var j = 0, cl = current.length ; j < cl ; j ++) {
+ var curChar = current.charAt(j)
+ nextMatches = nextMatches && curChar === next.charAt(j)
+ prevMatches = prevMatches && curChar === prev.charAt(j)
+ if (!nextMatches && !prevMatches) {
+ j ++
+ break
+ }
+ }
+ prev = current
+ if (j === cl) {
+ abbrevs[current] = current
+ continue
+ }
+ for (var a = current.substr(0, j) ; j <= cl ; j ++) {
+ abbrevs[a] = current
+ a += current.charAt(j)
+ }
+ }
+ return abbrevs
+}
+
+function lexSort (a, b) {
+ return a === b ? 0 : a > b ? 1 : -1
+}
diff --git a/node_modules/fsevents/node_modules/abbrev/package.json b/node_modules/fsevents/node_modules/abbrev/package.json
new file mode 100644
index 00000000..cc526546
--- /dev/null
+++ b/node_modules/fsevents/node_modules/abbrev/package.json
@@ -0,0 +1,89 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "abbrev@1",
+ "scope": null,
+ "escapedName": "abbrev",
+ "name": "abbrev",
+ "rawSpec": "1",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/nopt"
+ ]
+ ],
+ "_from": "abbrev@>=1.0.0 <2.0.0",
+ "_id": "abbrev@1.0.9",
+ "_inCache": true,
+ "_location": "/fsevents/abbrev",
+ "_nodeVersion": "4.4.4",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/abbrev-1.0.9.tgz_1466016055839_0.7825860097073019"
+ },
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "_npmVersion": "3.9.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "abbrev@1",
+ "scope": null,
+ "escapedName": "abbrev",
+ "name": "abbrev",
+ "rawSpec": "1",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/nopt"
+ ],
+ "_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz",
+ "_shasum": "91b4792588a7738c25f35dd6f63752a2f8776135",
+ "_shrinkwrap": null,
+ "_spec": "abbrev@1",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/nopt",
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me"
+ },
+ "bugs": {
+ "url": "https://github.com/isaacs/abbrev-js/issues"
+ },
+ "dependencies": {},
+ "description": "Like ruby's abbrev module, but in js",
+ "devDependencies": {
+ "tap": "^5.7.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "91b4792588a7738c25f35dd6f63752a2f8776135",
+ "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz"
+ },
+ "files": [
+ "abbrev.js"
+ ],
+ "gitHead": "c386cd9dbb1d8d7581718c54d4ba944cc9298d6f",
+ "homepage": "https://github.com/isaacs/abbrev-js#readme",
+ "license": "ISC",
+ "main": "abbrev.js",
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "name": "abbrev",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+ssh://git@github.com/isaacs/abbrev-js.git"
+ },
+ "scripts": {
+ "test": "tap test.js --cov"
+ },
+ "version": "1.0.9"
+}
diff --git a/node_modules/fsevents/node_modules/ansi-regex/index.js b/node_modules/fsevents/node_modules/ansi-regex/index.js
new file mode 100644
index 00000000..4906755b
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-regex/index.js
@@ -0,0 +1,4 @@
+'use strict';
+module.exports = function () {
+ return /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
+};
diff --git a/node_modules/fsevents/node_modules/ansi-regex/license b/node_modules/fsevents/node_modules/ansi-regex/license
new file mode 100644
index 00000000..654d0bfe
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-regex/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/ansi-regex/package.json b/node_modules/fsevents/node_modules/ansi-regex/package.json
new file mode 100644
index 00000000..89e01900
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-regex/package.json
@@ -0,0 +1,121 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "ansi-regex@^2.0.0",
+ "scope": null,
+ "escapedName": "ansi-regex",
+ "name": "ansi-regex",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/strip-ansi"
+ ]
+ ],
+ "_from": "ansi-regex@>=2.0.0 <3.0.0",
+ "_id": "ansi-regex@2.0.0",
+ "_inCache": true,
+ "_location": "/fsevents/ansi-regex",
+ "_nodeVersion": "0.12.5",
+ "_npmUser": {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ "_npmVersion": "2.11.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "ansi-regex@^2.0.0",
+ "scope": null,
+ "escapedName": "ansi-regex",
+ "name": "ansi-regex",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/has-ansi",
+ "/fsevents/strip-ansi"
+ ],
+ "_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.0.0.tgz",
+ "_shasum": "c5061b6e0ef8a81775e50f5d66151bf6bf371107",
+ "_shrinkwrap": null,
+ "_spec": "ansi-regex@^2.0.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/strip-ansi",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/sindresorhus/ansi-regex/issues"
+ },
+ "dependencies": {},
+ "description": "Regular expression for matching ANSI escape codes",
+ "devDependencies": {
+ "mocha": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "c5061b6e0ef8a81775e50f5d66151bf6bf371107",
+ "tarball": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.0.0.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "57c3f2941a73079fa8b081e02a522e3d29913e2f",
+ "homepage": "https://github.com/sindresorhus/ansi-regex",
+ "keywords": [
+ "ansi",
+ "styles",
+ "color",
+ "colour",
+ "colors",
+ "terminal",
+ "console",
+ "cli",
+ "string",
+ "tty",
+ "escape",
+ "formatting",
+ "rgb",
+ "256",
+ "shell",
+ "xterm",
+ "command-line",
+ "text",
+ "regex",
+ "regexp",
+ "re",
+ "match",
+ "test",
+ "find",
+ "pattern"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ {
+ "name": "jbnicolai",
+ "email": "jappelman@xebia.com"
+ }
+ ],
+ "name": "ansi-regex",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/sindresorhus/ansi-regex.git"
+ },
+ "scripts": {
+ "test": "mocha test/test.js",
+ "view-supported": "node test/viewCodes.js"
+ },
+ "version": "2.0.0"
+}
diff --git a/node_modules/fsevents/node_modules/ansi-regex/readme.md b/node_modules/fsevents/node_modules/ansi-regex/readme.md
new file mode 100644
index 00000000..1a4894ec
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-regex/readme.md
@@ -0,0 +1,31 @@
+# ansi-regex [](https://travis-ci.org/sindresorhus/ansi-regex)
+
+> Regular expression for matching [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code)
+
+
+## Install
+
+```
+$ npm install --save ansi-regex
+```
+
+
+## Usage
+
+```js
+var ansiRegex = require('ansi-regex');
+
+ansiRegex().test('\u001b[4mcake\u001b[0m');
+//=> true
+
+ansiRegex().test('cake');
+//=> false
+
+'\u001b[4mcake\u001b[0m'.match(ansiRegex());
+//=> ['\u001b[4m', '\u001b[0m']
+```
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)
diff --git a/node_modules/fsevents/node_modules/ansi-styles/index.js b/node_modules/fsevents/node_modules/ansi-styles/index.js
new file mode 100644
index 00000000..78945278
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-styles/index.js
@@ -0,0 +1,65 @@
+'use strict';
+
+function assembleStyles () {
+ var styles = {
+ modifiers: {
+ reset: [0, 0],
+ bold: [1, 22], // 21 isn't widely supported and 22 does the same thing
+ dim: [2, 22],
+ italic: [3, 23],
+ underline: [4, 24],
+ inverse: [7, 27],
+ hidden: [8, 28],
+ strikethrough: [9, 29]
+ },
+ colors: {
+ black: [30, 39],
+ red: [31, 39],
+ green: [32, 39],
+ yellow: [33, 39],
+ blue: [34, 39],
+ magenta: [35, 39],
+ cyan: [36, 39],
+ white: [37, 39],
+ gray: [90, 39]
+ },
+ bgColors: {
+ bgBlack: [40, 49],
+ bgRed: [41, 49],
+ bgGreen: [42, 49],
+ bgYellow: [43, 49],
+ bgBlue: [44, 49],
+ bgMagenta: [45, 49],
+ bgCyan: [46, 49],
+ bgWhite: [47, 49]
+ }
+ };
+
+ // fix humans
+ styles.colors.grey = styles.colors.gray;
+
+ Object.keys(styles).forEach(function (groupName) {
+ var group = styles[groupName];
+
+ Object.keys(group).forEach(function (styleName) {
+ var style = group[styleName];
+
+ styles[styleName] = group[styleName] = {
+ open: '\u001b[' + style[0] + 'm',
+ close: '\u001b[' + style[1] + 'm'
+ };
+ });
+
+ Object.defineProperty(styles, groupName, {
+ value: group,
+ enumerable: false
+ });
+ });
+
+ return styles;
+}
+
+Object.defineProperty(module, 'exports', {
+ enumerable: true,
+ get: assembleStyles
+});
diff --git a/node_modules/fsevents/node_modules/ansi-styles/license b/node_modules/fsevents/node_modules/ansi-styles/license
new file mode 100644
index 00000000..654d0bfe
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-styles/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/ansi-styles/package.json b/node_modules/fsevents/node_modules/ansi-styles/package.json
new file mode 100644
index 00000000..646cf59a
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-styles/package.json
@@ -0,0 +1,114 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "ansi-styles@^2.2.1",
+ "scope": null,
+ "escapedName": "ansi-styles",
+ "name": "ansi-styles",
+ "rawSpec": "^2.2.1",
+ "spec": ">=2.2.1 <3.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/chalk"
+ ]
+ ],
+ "_from": "ansi-styles@>=2.2.1 <3.0.0",
+ "_id": "ansi-styles@2.2.1",
+ "_inCache": true,
+ "_location": "/fsevents/ansi-styles",
+ "_nodeVersion": "4.3.0",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/ansi-styles-2.2.1.tgz_1459197317833_0.9694824463222176"
+ },
+ "_npmUser": {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ "_npmVersion": "3.8.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "ansi-styles@^2.2.1",
+ "scope": null,
+ "escapedName": "ansi-styles",
+ "name": "ansi-styles",
+ "rawSpec": "^2.2.1",
+ "spec": ">=2.2.1 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/chalk"
+ ],
+ "_resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz",
+ "_shasum": "b432dd3358b634cf75e1e4664368240533c1ddbe",
+ "_shrinkwrap": null,
+ "_spec": "ansi-styles@^2.2.1",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/chalk",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/chalk/ansi-styles/issues"
+ },
+ "dependencies": {},
+ "description": "ANSI escape codes for styling strings in the terminal",
+ "devDependencies": {
+ "mocha": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "b432dd3358b634cf75e1e4664368240533c1ddbe",
+ "tarball": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "95c59b23be760108b6530ca1c89477c21b258032",
+ "homepage": "https://github.com/chalk/ansi-styles#readme",
+ "keywords": [
+ "ansi",
+ "styles",
+ "color",
+ "colour",
+ "colors",
+ "terminal",
+ "console",
+ "cli",
+ "string",
+ "tty",
+ "escape",
+ "formatting",
+ "rgb",
+ "256",
+ "shell",
+ "xterm",
+ "log",
+ "logging",
+ "command-line",
+ "text"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ }
+ ],
+ "name": "ansi-styles",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/chalk/ansi-styles.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "version": "2.2.1"
+}
diff --git a/node_modules/fsevents/node_modules/ansi-styles/readme.md b/node_modules/fsevents/node_modules/ansi-styles/readme.md
new file mode 100644
index 00000000..3f933f61
--- /dev/null
+++ b/node_modules/fsevents/node_modules/ansi-styles/readme.md
@@ -0,0 +1,86 @@
+# ansi-styles [](https://travis-ci.org/chalk/ansi-styles)
+
+> [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) for styling strings in the terminal
+
+You probably want the higher-level [chalk](https://github.com/chalk/chalk) module for styling your strings.
+
+
+
+
+## Install
+
+```
+$ npm install --save ansi-styles
+```
+
+
+## Usage
+
+```js
+var ansi = require('ansi-styles');
+
+console.log(ansi.green.open + 'Hello world!' + ansi.green.close);
+```
+
+
+## API
+
+Each style has an `open` and `close` property.
+
+
+## Styles
+
+### Modifiers
+
+- `reset`
+- `bold`
+- `dim`
+- `italic` *(not widely supported)*
+- `underline`
+- `inverse`
+- `hidden`
+- `strikethrough` *(not widely supported)*
+
+### Colors
+
+- `black`
+- `red`
+- `green`
+- `yellow`
+- `blue`
+- `magenta`
+- `cyan`
+- `white`
+- `gray`
+
+### Background colors
+
+- `bgBlack`
+- `bgRed`
+- `bgGreen`
+- `bgYellow`
+- `bgBlue`
+- `bgMagenta`
+- `bgCyan`
+- `bgWhite`
+
+
+## Advanced usage
+
+By default you get a map of styles, but the styles are also available as groups. They are non-enumerable so they don't show up unless you access them explicitly. This makes it easier to expose only a subset in a higher-level module.
+
+- `ansi.modifiers`
+- `ansi.colors`
+- `ansi.bgColors`
+
+
+###### Example
+
+```js
+console.log(ansi.colors.green.open);
+```
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)
diff --git a/node_modules/fsevents/node_modules/aproba/LICENSE b/node_modules/fsevents/node_modules/aproba/LICENSE
new file mode 100644
index 00000000..f4be44d8
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aproba/LICENSE
@@ -0,0 +1,14 @@
+Copyright (c) 2015, Rebecca Turner
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+
diff --git a/node_modules/fsevents/node_modules/aproba/README.md b/node_modules/fsevents/node_modules/aproba/README.md
new file mode 100644
index 00000000..8246a9cc
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aproba/README.md
@@ -0,0 +1,59 @@
+aproba
+======
+
+A ridiculously light-weight function argument validator
+
+```
+var validate = require("aproba")
+
+function myfunc(a, b, c) {
+ // `a` must be a string, `b` a number, `c` a function
+ validate('SNF', arguments) // [a,b,c] is also valid
+}
+
+myfunc('test', 23, function () {}) // ok
+myfunc(123, 23, function () {}) // type error
+myfunc('test', 23) // missing arg error
+myfunc('test', 23, function () {}, true) // too many args error
+
+```
+
+Valid types are:
+
+type | description
+---- | -----------
+* | matches any type
+A | Array.isArray OR an arguments object
+S | typeof == string
+N | typeof == number
+F | typeof == function
+O | typeof == object and not type A and not type E
+B | typeof == boolean
+E | instanceof Error OR null
+
+Validation failures throw one of three exception types, distinguished by a
+`code` property of `EMISSINGARG`, `EINVALIDTYPE` or `ETOOMANYARGS`.
+
+If you pass in an invalid type then it will throw with a code of
+`EUNKNOWNTYPE`.
+
+If an error argument is found and is not null then the remaining arguments
+will not be validated.
+
+### Why this exists
+
+I wanted a very simple argument validator. It needed to do two things:
+
+1. Be more concise and easier to use than assertions
+
+2. Not encourage an infinite bikeshed of DSLs
+
+This is why types are specified by a single character and there's no such
+thing as an optional argument.
+
+This is not intended to validate user data. This is specifically about
+asserting the interface of your functions.
+
+If you need greater validation, I encourage you to write them by hand or
+look elsewhere.
+
diff --git a/node_modules/fsevents/node_modules/aproba/index.js b/node_modules/fsevents/node_modules/aproba/index.js
new file mode 100644
index 00000000..bb5ac3cd
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aproba/index.js
@@ -0,0 +1,62 @@
+'use strict'
+
+function isArguments (thingy) {
+ return typeof thingy === 'object' && thingy.hasOwnProperty('callee')
+}
+
+var types = {
+ '*': ['any', function () { return true }],
+ A: ['array', function (thingy) { return Array.isArray(thingy) || isArguments(thingy) }],
+ S: ['string', function (thingy) { return typeof thingy === 'string' }],
+ N: ['number', function (thingy) { return typeof thingy === 'number' }],
+ F: ['function', function (thingy) { return typeof thingy === 'function' }],
+ O: ['object', function (thingy) { return typeof thingy === 'object' && !types.A[1](thingy) && !types.E[1](thingy) }],
+ B: ['boolean', function (thingy) { return typeof thingy === 'boolean' }],
+ E: ['error', function (thingy) { return thingy instanceof Error }]
+}
+
+var validate = module.exports = function (schema, args) {
+ if (!schema) throw missingRequiredArg(0, 'schema')
+ if (!args) throw missingRequiredArg(1, 'args')
+ if (!types.S[1](schema)) throw invalidType(0, 'string', schema)
+ if (!types.A[1](args)) throw invalidType(1, 'array', args)
+ for (var ii = 0; ii < schema.length; ++ii) {
+ var type = schema[ii]
+ if (!types[type]) throw unknownType(ii, type)
+ var typeLabel = types[type][0]
+ var typeCheck = types[type][1]
+ if (type === 'E' && args[ii] == null) continue
+ if (args[ii] == null) throw missingRequiredArg(ii)
+ if (!typeCheck(args[ii])) throw invalidType(ii, typeLabel, args[ii])
+ if (type === 'E') return
+ }
+ if (schema.length < args.length) throw tooManyArgs(schema.length, args.length)
+}
+
+function missingRequiredArg (num) {
+ return newException('EMISSINGARG', 'Missing required argument #' + (num + 1))
+}
+
+function unknownType (num, type) {
+ return newException('EUNKNOWNTYPE', 'Unknown type ' + type + ' in argument #' + (num + 1))
+}
+
+function invalidType (num, expectedType, value) {
+ var valueType
+ Object.keys(types).forEach(function (typeCode) {
+ if (types[typeCode][1](value)) valueType = types[typeCode][0]
+ })
+ return newException('EINVALIDTYPE', 'Argument #' + (num + 1) + ': Expected ' +
+ expectedType + ' but got ' + valueType)
+}
+
+function tooManyArgs (expected, got) {
+ return newException('ETOOMANYARGS', 'Too many arguments, expected ' + expected + ' and got ' + got)
+}
+
+function newException (code, msg) {
+ var e = new Error(msg)
+ e.code = code
+ Error.captureStackTrace(e, validate)
+ return e
+}
diff --git a/node_modules/fsevents/node_modules/aproba/package.json b/node_modules/fsevents/node_modules/aproba/package.json
new file mode 100644
index 00000000..b76c481b
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aproba/package.json
@@ -0,0 +1,96 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "aproba@^1.0.3",
+ "scope": null,
+ "escapedName": "aproba",
+ "name": "aproba",
+ "rawSpec": "^1.0.3",
+ "spec": ">=1.0.3 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/gauge"
+ ]
+ ],
+ "_from": "aproba@>=1.0.3 <2.0.0",
+ "_id": "aproba@1.0.4",
+ "_inCache": true,
+ "_location": "/fsevents/aproba",
+ "_nodeVersion": "4.4.0",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/aproba-1.0.4.tgz_1466718885402_0.5348939662799239"
+ },
+ "_npmUser": {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ },
+ "_npmVersion": "3.10.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "aproba@^1.0.3",
+ "scope": null,
+ "escapedName": "aproba",
+ "name": "aproba",
+ "rawSpec": "^1.0.3",
+ "spec": ">=1.0.3 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/gauge"
+ ],
+ "_resolved": "https://registry.npmjs.org/aproba/-/aproba-1.0.4.tgz",
+ "_shasum": "2713680775e7614c8ba186c065d4e2e52d1072c0",
+ "_shrinkwrap": null,
+ "_spec": "aproba@^1.0.3",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/gauge",
+ "author": {
+ "name": "Rebecca Turner",
+ "email": "me@re-becca.org"
+ },
+ "bugs": {
+ "url": "https://github.com/iarna/aproba/issues"
+ },
+ "dependencies": {},
+ "description": "A rediculously light-weight argument validator",
+ "devDependencies": {
+ "standard": "^7.1.2",
+ "tap": "^5.7.3"
+ },
+ "directories": {
+ "test": "test"
+ },
+ "dist": {
+ "shasum": "2713680775e7614c8ba186c065d4e2e52d1072c0",
+ "tarball": "https://registry.npmjs.org/aproba/-/aproba-1.0.4.tgz"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "c6c8f82d519b9ec3816f20f23a9101083c022200",
+ "homepage": "https://github.com/iarna/aproba",
+ "keywords": [
+ "argument",
+ "validate"
+ ],
+ "license": "ISC",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ }
+ ],
+ "name": "aproba",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/iarna/aproba.git"
+ },
+ "scripts": {
+ "test": "standard && tap test/*.js"
+ },
+ "version": "1.0.4"
+}
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/.npmignore b/node_modules/fsevents/node_modules/are-we-there-yet/.npmignore
new file mode 100644
index 00000000..bc818974
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/.npmignore
@@ -0,0 +1,5 @@
+*~
+.#*
+node_modules
+coverage
+.nyc_output
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/CHANGES.md b/node_modules/fsevents/node_modules/are-we-there-yet/CHANGES.md
new file mode 100644
index 00000000..e990b86d
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/CHANGES.md
@@ -0,0 +1,19 @@
+Hi, figured we could actually use a changelog now:
+
+## 1.1.1 2016-01-29
+
+* Fix a typo in stream completion tracker
+
+## 1.1.0 2016-01-29
+
+* Rewrote completion percent computation to be low impact– no more walking a
+ tree of completion groups every time we need this info. Previously, with
+ medium sized tree of completion groups, even a relatively modest number of
+ calls to the top level `completed()` method would result in absurd numbers
+ of calls overall as it walked down the tree. We now, instead, keep track as
+ we bubble up changes, so the computation is limited to when data changes and
+ to the depth of that one branch, instead of _every_ node. (Plus, we were already
+ incurring _this_ cost, since we already bubbled out changes.)
+* Moved different tracker types out to their own files.
+* Made tests test for TOO MANY events too.
+* Standarized the source code formatting
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/LICENSE b/node_modules/fsevents/node_modules/are-we-there-yet/LICENSE
new file mode 100644
index 00000000..af458806
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/LICENSE
@@ -0,0 +1,5 @@
+Copyright (c) 2015, Rebecca Turner
+
+Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/README.md b/node_modules/fsevents/node_modules/are-we-there-yet/README.md
new file mode 100644
index 00000000..c41d3922
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/README.md
@@ -0,0 +1,194 @@
+are-we-there-yet
+----------------
+
+Track complex hiearchies of asynchronous task completion statuses. This is
+intended to give you a way of recording and reporting the progress of the big
+recursive fan-out and gather type workflows that are so common in async.
+
+What you do with this completion data is up to you, but the most common use case is to
+feed it to one of the many progress bar modules.
+
+Most progress bar modules include a rudamentary version of this, but my
+needs were more complex.
+
+Usage
+=====
+
+```javascript
+var TrackerGroup = require("are-we-there-yet").TrackerGroup
+
+var top = new TrackerGroup("program")
+
+var single = top.newItem("one thing", 100)
+single.completeWork(20)
+
+console.log(top.completed()) // 0.2
+
+fs.stat("file", function(er, stat) {
+ if (er) throw er
+ var stream = top.newStream("file", stat.size)
+ console.log(top.completed()) // now 0.1 as single is 50% of the job and is 20% complete
+ // and 50% * 20% == 10%
+ fs.createReadStream("file").pipe(stream).on("data", function (chunk) {
+ // do stuff with chunk
+ })
+ top.on("change", function (name) {
+ // called each time a chunk is read from "file"
+ // top.completed() will start at 0.1 and fill up to 0.6 as the file is read
+ })
+})
+```
+
+Shared Methods
+==============
+
+All tracker objects described below have the following methods, they, along
+with the event comprise the interface for consumers of tracker objects.
+
+* var completed = tracker.completed()
+
+Returns the ratio of completed work to work to be done. Range of 0 to 1.
+
+* tracker.finish()
+
+Marks the tracker as completed. With a TrackerGroup this marks all of its
+components as completed.
+
+Marks all of the components of this tracker as finished, which in turn means
+that `tracker.completed()` for this will now be 1.
+
+This will result in one or more `change` events being emitted.
+
+Events
+======
+
+All tracker objects emit `change` events with the following arguments:
+
+```
+function (name, completed, tracker)
+```
+
+`name` is the name of the tracker that originally emitted the event,
+or if it didn't have one, the first containing tracker group that had one.
+
+`completed` is the percent complete (as returned by `tracker.completed()` method).
+
+`tracker` is the tracker object that you are listening for events on.
+
+TrackerGroup
+============
+
+* var tracker = new TrackerGroup(**name**)
+
+ * **name** *(optional)* - The name of this tracker group, used in change
+ notifications if the component updating didn't have a name. Defaults to undefined.
+
+Creates a new empty tracker aggregation group. These are trackers whose
+completion status is determined by the completion status of other trackers.
+
+* tracker.addUnit(**otherTracker**, **weight**)
+
+ * **otherTracker** - Any of the other are-we-there-yet tracker objects
+ * **weight** *(optional)* - The weight to give the tracker, defaults to 1.
+
+Adds the **otherTracker** to this aggregation group. The weight determines
+how long you expect this tracker to take to complete in proportion to other
+units. So for instance, if you add one tracker with a weight of 1 and
+another with a weight of 2, you're saying the second will take twice as long
+to complete as the first. As such, the first will account for 33% of the
+completion of this tracker and the second will account for the other 67%.
+
+Returns **otherTracker**.
+
+* var subGroup = tracker.newGroup(**name**, **weight**)
+
+The above is exactly equivalent to:
+
+```javascript
+ var subGroup = tracker.addUnit(new TrackerGroup(name), weight)
+```
+
+* var subItem = tracker.newItem(**name**, **todo**, **weight**)
+
+The above is exactly equivalent to:
+
+```javascript
+ var subItem = tracker.addUnit(new Tracker(name, todo), weight)
+```
+
+* var subStream = tracker.newStream(**name**, **todo**, **weight**)
+
+The above is exactly equivalent to:
+
+```javascript
+ var subStream = tracker.addUnit(new TrackerStream(name, todo), weight)
+```
+
+* console.log( tracker.debug() )
+
+Returns a tree showing the completion of this tracker group and all of its
+children, including recursively entering all of the children.
+
+Tracker
+=======
+
+* var tracker = new Tracker(**name**, **todo**)
+
+ * **name** *(optional)* The name of this counter to report in change
+ events. Defaults to undefined.
+ * **todo** *(optional)* The amount of work todo (a number). Defaults to 0.
+
+Ordinarily these are constructed as a part of a tracker group (via
+`newItem`).
+
+* var completed = tracker.completed()
+
+Returns the ratio of completed work to work to be done. Range of 0 to 1. If
+total work to be done is 0 then it will return 0.
+
+* tracker.addWork(**todo**)
+
+ * **todo** A number to add to the amount of work to be done.
+
+Increases the amount of work to be done, thus decreasing the completion
+percentage. Triggers a `change` event.
+
+* tracker.completeWork(**completed**)
+
+ * **completed** A number to add to the work complete
+
+Increase the amount of work complete, thus increasing the completion percentage.
+Will never increase the work completed past the amount of work todo. That is,
+percentages > 100% are not allowed. Triggers a `change` event.
+
+* tracker.finish()
+
+Marks this tracker as finished, tracker.completed() will now be 1. Triggers
+a `change` event.
+
+TrackerStream
+=============
+
+* var tracker = new TrackerStream(**name**, **size**, **options**)
+
+ * **name** *(optional)* The name of this counter to report in change
+ events. Defaults to undefined.
+ * **size** *(optional)* The number of bytes being sent through this stream.
+ * **options** *(optional)* A hash of stream options
+
+The tracker stream object is a pass through stream that updates an internal
+tracker object each time a block passes through. It's intended to track
+downloads, file extraction and other related activities. You use it by piping
+your data source into it and then using it as your data source.
+
+If your data has a length attribute then that's used as the amount of work
+completed when the chunk is passed through. If it does not (eg, object
+streams) then each chunk counts as completing 1 unit of work, so your size
+should be the total number of objects being streamed.
+
+* tracker.addWork(**todo**)
+
+ * **todo** Increase the expected overall size by **todo** bytes.
+
+Increases the amount of work to be done, thus decreasing the completion
+percentage. Triggers a `change` event.
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/index.js b/node_modules/fsevents/node_modules/are-we-there-yet/index.js
new file mode 100644
index 00000000..57d8743f
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/index.js
@@ -0,0 +1,4 @@
+'use strict'
+exports.TrackerGroup = require('./tracker-group.js')
+exports.Tracker = require('./tracker.js')
+exports.TrackerStream = require('./tracker-stream.js')
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/package.json b/node_modules/fsevents/node_modules/are-we-there-yet/package.json
new file mode 100644
index 00000000..8128479e
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/package.json
@@ -0,0 +1,90 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "are-we-there-yet@~1.1.2",
+ "scope": null,
+ "escapedName": "are-we-there-yet",
+ "name": "are-we-there-yet",
+ "rawSpec": "~1.1.2",
+ "spec": ">=1.1.2 <1.2.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/npmlog"
+ ]
+ ],
+ "_from": "are-we-there-yet@>=1.1.2 <1.2.0",
+ "_id": "are-we-there-yet@1.1.2",
+ "_inCache": true,
+ "_location": "/fsevents/are-we-there-yet",
+ "_nodeVersion": "4.2.2",
+ "_npmOperationalInternal": {
+ "host": "packages-13-west.internal.npmjs.com",
+ "tmp": "tmp/are-we-there-yet-1.1.2.tgz_1458084397358_0.15847722673788667"
+ },
+ "_npmUser": {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ },
+ "_npmVersion": "3.8.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "are-we-there-yet@~1.1.2",
+ "scope": null,
+ "escapedName": "are-we-there-yet",
+ "name": "are-we-there-yet",
+ "rawSpec": "~1.1.2",
+ "spec": ">=1.1.2 <1.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/npmlog"
+ ],
+ "_resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.2.tgz",
+ "_shasum": "80e470e95a084794fe1899262c5667c6e88de1b3",
+ "_shrinkwrap": null,
+ "_spec": "are-we-there-yet@~1.1.2",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/npmlog",
+ "author": {
+ "name": "Rebecca Turner",
+ "url": "http://re-becca.org"
+ },
+ "bugs": {
+ "url": "https://github.com/iarna/are-we-there-yet/issues"
+ },
+ "dependencies": {
+ "delegates": "^1.0.0",
+ "readable-stream": "^2.0.0 || ^1.1.13"
+ },
+ "description": "Keep track of the overall completion of many dispirate processes",
+ "devDependencies": {
+ "standard": "^6.0.8",
+ "tap": "^5.7.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "80e470e95a084794fe1899262c5667c6e88de1b3",
+ "tarball": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.2.tgz"
+ },
+ "gitHead": "dd5706e2204cb681e78031d0ffe156ed4cc75823",
+ "homepage": "https://github.com/iarna/are-we-there-yet",
+ "license": "ISC",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ }
+ ],
+ "name": "are-we-there-yet",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/iarna/are-we-there-yet.git"
+ },
+ "scripts": {
+ "test": "standard && tap test/*.js"
+ },
+ "version": "1.1.2"
+}
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/test/lib/test-event.js b/node_modules/fsevents/node_modules/are-we-there-yet/test/lib/test-event.js
new file mode 100644
index 00000000..2aa7c05c
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/test/lib/test-event.js
@@ -0,0 +1,29 @@
+'use strict'
+var util = require('util')
+
+module.exports = function (obj, event, next) {
+ var timeout = setTimeout(gotTimeout, 10)
+ obj.once(event, gotResult)
+
+ function gotTimeout () {
+ obj.removeListener(event, gotResult)
+ next(new Error('Timeout listening for ' + event))
+ }
+ var result = []
+ function gotResult () {
+ result = Array.prototype.slice.call(arguments)
+ clearTimeout(timeout)
+ timeout = setTimeout(gotNoMoreResults, 10)
+ obj.once(event, gotTooManyResults)
+ }
+ function gotNoMoreResults () {
+ obj.removeListener(event, gotTooManyResults)
+ var args = [null].concat(result)
+ next.apply(null, args)
+ }
+ function gotTooManyResults () {
+ var secondResult = Array.prototype.slice.call(arguments)
+ clearTimeout(timeout)
+ next(new Error('Got too many results, first ' + util.inspect(result) + ' and then ' + util.inspect(secondResult)))
+ }
+}
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/test/tracker.js b/node_modules/fsevents/node_modules/are-we-there-yet/test/tracker.js
new file mode 100644
index 00000000..374c7739
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/test/tracker.js
@@ -0,0 +1,57 @@
+'use strict'
+var test = require('tap').test
+var Tracker = require('../index.js').Tracker
+
+var testEvent = require('./lib/test-event.js')
+
+var name = 'test'
+
+test('initialization', function (t) {
+ var simple = new Tracker(name)
+
+ t.is(simple.completed(), 0, 'Nothing todo is 0 completion')
+ t.done()
+})
+
+var track
+var todo = 100
+test('completion', function (t) {
+ track = new Tracker(name, todo)
+ t.is(track.completed(), 0, 'Nothing done is 0 completion')
+
+ testEvent(track, 'change', afterCompleteWork)
+
+ track.completeWork(todo)
+ t.is(track.completed(), 1, 'completeWork: 100% completed')
+
+ function afterCompleteWork (er, onChangeName) {
+ t.is(er, null, 'completeWork: on change event fired')
+ t.is(onChangeName, name, 'completeWork: on change emits the correct name')
+ t.done()
+ }
+})
+
+test('add more work', function (t) {
+ testEvent(track, 'change', afterAddWork)
+ track.addWork(todo)
+ t.is(track.completed(), 0.5, 'addWork: 50% completed')
+ function afterAddWork (er, onChangeName) {
+ t.is(er, null, 'addWork: on change event fired')
+ t.is(onChangeName, name, 'addWork: on change emits the correct name')
+ t.done()
+ }
+})
+
+test('complete more work', function (t) {
+ track.completeWork(200)
+ t.is(track.completed(), 1, 'completeWork: Over completion is still only 100% complete')
+ t.done()
+})
+
+test('finish is always 100%', function (t) {
+ var finishtest = new Tracker(name, todo)
+ finishtest.completeWork(50)
+ finishtest.finish()
+ t.is(finishtest.completed(), 1, 'finish: Explicitly finishing moves to 100%')
+ t.done()
+})
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/test/trackergroup.js b/node_modules/fsevents/node_modules/are-we-there-yet/test/trackergroup.js
new file mode 100644
index 00000000..799a7670
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/test/trackergroup.js
@@ -0,0 +1,96 @@
+'use strict'
+var test = require('tap').test
+var TrackerGroup = require('../index.js').TrackerGroup
+var testEvent = require('./lib/test-event.js')
+
+test('TrackerGroup', function (t) {
+ var name = 'test'
+
+ var track = new TrackerGroup(name)
+ t.is(track.completed(), 0, 'Nothing todo is 0 completion')
+ testEvent(track, 'change', afterFinishEmpty)
+ track.finish()
+ var a, b
+ function afterFinishEmpty (er, onChangeName, completion) {
+ t.is(er, null, 'finishEmpty: on change event fired')
+ t.is(onChangeName, name, 'finishEmpty: on change emits the correct name')
+ t.is(completion, 1, 'finishEmpty: passed through completion was correct')
+ t.is(track.completed(), 1, 'finishEmpty: Finishing an empty group actually finishes it')
+
+ track = new TrackerGroup(name)
+ a = track.newItem('a', 10, 1)
+ b = track.newItem('b', 10, 1)
+ t.is(track.completed(), 0, 'Initially empty')
+ testEvent(track, 'change', afterCompleteWork)
+ a.completeWork(5)
+ }
+ function afterCompleteWork (er, onChangeName, completion) {
+ t.is(er, null, 'on change event fired')
+ t.is(onChangeName, 'a', 'on change emits the correct name')
+ t.is(completion, 0.25, 'Complete half of one is a quarter overall')
+ t.is(track.completed(), 0.25, 'Complete half of one is a quarter overall')
+ testEvent(track, 'change', afterFinishAll)
+ track.finish()
+ }
+ function afterFinishAll (er, onChangeName, completion) {
+ t.is(er, null, 'finishAll: on change event fired')
+ t.is(onChangeName, name, 'finishAll: on change emits the correct name')
+ t.is(completion, 1, 'Finishing everything ')
+ t.is(track.completed(), 1, 'Finishing everything ')
+
+ track = new TrackerGroup(name)
+ a = track.newItem('a', 10, 2)
+ b = track.newItem('b', 10, 1)
+ t.is(track.completed(), 0, 'weighted: Initially empty')
+ testEvent(track, 'change', afterWeightedCompleteWork)
+ a.completeWork(5)
+ }
+ function afterWeightedCompleteWork (er, onChangeName, completion) {
+ t.is(er, null, 'weighted: on change event fired')
+ t.is(onChangeName, 'a', 'weighted: on change emits the correct name')
+ t.is(Math.floor(completion * 100), 33, 'weighted: Complete half of double weighted')
+ t.is(Math.floor(track.completed() * 100), 33, 'weighted: Complete half of double weighted')
+ testEvent(track, 'change', afterWeightedFinishAll)
+ track.finish()
+ }
+ function afterWeightedFinishAll (er, onChangeName, completion) {
+ t.is(er, null, 'weightedFinishAll: on change event fired')
+ t.is(onChangeName, name, 'weightedFinishAll: on change emits the correct name')
+ t.is(completion, 1, 'weightedFinishaAll: Finishing everything ')
+ t.is(track.completed(), 1, 'weightedFinishaAll: Finishing everything ')
+
+ track = new TrackerGroup(name)
+ a = track.newGroup('a', 10)
+ b = track.newGroup('b', 10)
+ var a1 = a.newItem('a.1', 10)
+ a1.completeWork(5)
+ t.is(track.completed(), 0.25, 'nested: Initially quarter done')
+ testEvent(track, 'change', afterNestedComplete)
+ b.finish()
+ }
+ function afterNestedComplete (er, onChangeName, completion) {
+ t.is(er, null, 'nestedComplete: on change event fired')
+ t.is(onChangeName, 'b', 'nestedComplete: on change emits the correct name')
+ t.is(completion, 0.75, 'nestedComplete: Finishing everything ')
+ t.is(track.completed(), 0.75, 'nestedComplete: Finishing everything ')
+ t.end()
+ }
+})
+
+test('cycles', function (t) {
+ var track = new TrackerGroup('top')
+ testCycle(track, track)
+ var layer1 = track.newGroup('layer1')
+ testCycle(layer1, track)
+ t.end()
+
+ function testCycle (addTo, toAdd) {
+ try {
+ addTo.addUnit(toAdd)
+ t.fail(toAdd.name)
+ } catch (ex) {
+ console.log(ex)
+ t.pass(toAdd.name)
+ }
+ }
+})
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/test/trackerstream.js b/node_modules/fsevents/node_modules/are-we-there-yet/test/trackerstream.js
new file mode 100644
index 00000000..65f04b03
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/test/trackerstream.js
@@ -0,0 +1,51 @@
+'use strict'
+var test = require('tap').test
+var util = require('util')
+var stream = require('readable-stream')
+var TrackerStream = require('../index.js').TrackerStream
+var testEvent = require('./lib/test-event.js')
+
+var Sink = function () {
+ stream.Writable.apply(this, arguments)
+}
+util.inherits(Sink, stream.Writable)
+Sink.prototype._write = function (data, encoding, cb) {
+ cb()
+}
+
+test('TrackerStream', function (t) {
+ t.plan(9)
+
+ var name = 'test'
+ var track = new TrackerStream(name)
+
+ t.is(track.completed(), 0, 'Nothing todo is 0 completion')
+
+ var todo = 10
+ track = new TrackerStream(name, todo)
+ t.is(track.completed(), 0, 'Nothing done is 0 completion')
+
+ track.pipe(new Sink())
+
+ testEvent(track, 'change', afterCompleteWork)
+ track.write('0123456789')
+ function afterCompleteWork (er, onChangeName) {
+ t.is(er, null, 'write: on change event fired')
+ t.is(onChangeName, name, 'write: on change emits the correct name')
+ t.is(track.completed(), 1, 'write: 100% completed')
+
+ testEvent(track, 'change', afterAddWork)
+ track.addWork(10)
+ }
+ function afterAddWork (er, onChangeName) {
+ t.is(er, null, 'addWork: on change event fired')
+ t.is(track.completed(), 0.5, 'addWork: 50% completed')
+
+ testEvent(track, 'change', afterAllWork)
+ track.write('ABCDEFGHIJKLMNOPQRST')
+ }
+ function afterAllWork (er) {
+ t.is(er, null, 'allWork: on change event fired')
+ t.is(track.completed(), 1, 'allWork: 100% completed')
+ }
+})
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/tracker-base.js b/node_modules/fsevents/node_modules/are-we-there-yet/tracker-base.js
new file mode 100644
index 00000000..6f436875
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/tracker-base.js
@@ -0,0 +1,11 @@
+'use strict'
+var EventEmitter = require('events').EventEmitter
+var util = require('util')
+
+var trackerId = 0
+var TrackerBase = module.exports = function (name) {
+ EventEmitter.call(this)
+ this.id = ++trackerId
+ this.name = name
+}
+util.inherits(TrackerBase, EventEmitter)
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/tracker-group.js b/node_modules/fsevents/node_modules/are-we-there-yet/tracker-group.js
new file mode 100644
index 00000000..9759e122
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/tracker-group.js
@@ -0,0 +1,107 @@
+'use strict'
+var util = require('util')
+var TrackerBase = require('./tracker-base.js')
+var Tracker = require('./tracker.js')
+var TrackerStream = require('./tracker-stream.js')
+
+var TrackerGroup = module.exports = function (name) {
+ TrackerBase.call(this, name)
+ this.parentGroup = null
+ this.trackers = []
+ this.completion = {}
+ this.weight = {}
+ this.totalWeight = 0
+ this.finished = false
+ this.bubbleChange = bubbleChange(this)
+}
+util.inherits(TrackerGroup, TrackerBase)
+
+function bubbleChange (trackerGroup) {
+ return function (name, completed, tracker) {
+ trackerGroup.completion[tracker.id] = completed
+ if (trackerGroup.finished) return
+ trackerGroup.emit('change', name || trackerGroup.name, trackerGroup.completed(), trackerGroup)
+ }
+}
+
+TrackerGroup.prototype.nameInTree = function () {
+ var names = []
+ var from = this
+ while (from) {
+ names.unshift(from.name)
+ from = from.parentGroup
+ }
+ return names.join('/')
+}
+
+TrackerGroup.prototype.addUnit = function (unit, weight) {
+ if (unit.addUnit) {
+ var toTest = this
+ while (toTest) {
+ if (unit === toTest) {
+ throw new Error(
+ 'Attempted to add tracker group ' +
+ unit.name + ' to tree that already includes it ' +
+ this.nameInTree(this))
+ }
+ toTest = toTest.parentGroup
+ }
+ unit.parentGroup = this
+ }
+ this.weight[unit.id] = weight || 1
+ this.totalWeight += this.weight[unit.id]
+ this.trackers.push(unit)
+ this.completion[unit.id] = unit.completed()
+ unit.on('change', this.bubbleChange)
+ if (!this.finished) this.emit('change', unit.name, this.completion[unit.id], unit)
+ return unit
+}
+
+TrackerGroup.prototype.completed = function () {
+ if (this.trackers.length === 0) return 0
+ var valPerWeight = 1 / this.totalWeight
+ var completed = 0
+ for (var ii = 0; ii < this.trackers.length; ii++) {
+ var trackerId = this.trackers[ii].id
+ completed += valPerWeight * this.weight[trackerId] * this.completion[trackerId]
+ }
+ return completed
+}
+
+TrackerGroup.prototype.newGroup = function (name, weight) {
+ return this.addUnit(new TrackerGroup(name), weight)
+}
+
+TrackerGroup.prototype.newItem = function (name, todo, weight) {
+ return this.addUnit(new Tracker(name, todo), weight)
+}
+
+TrackerGroup.prototype.newStream = function (name, todo, weight) {
+ return this.addUnit(new TrackerStream(name, todo), weight)
+}
+
+TrackerGroup.prototype.finish = function () {
+ this.finished = true
+ if (!this.trackers.length) this.addUnit(new Tracker(), 1, true)
+ for (var ii = 0; ii < this.trackers.length; ii++) {
+ var tracker = this.trackers[ii]
+ tracker.finish()
+ tracker.removeListener('change', this.bubbleChange)
+ }
+ this.emit('change', this.name, 1, this)
+}
+
+var buffer = ' '
+TrackerGroup.prototype.debug = function (depth) {
+ depth = depth || 0
+ var indent = depth ? buffer.substr(0, depth) : ''
+ var output = indent + (this.name || 'top') + ': ' + this.completed() + '\n'
+ this.trackers.forEach(function (tracker) {
+ if (tracker instanceof TrackerGroup) {
+ output += tracker.debug(depth + 1)
+ } else {
+ output += indent + ' ' + tracker.name + ': ' + tracker.completed() + '\n'
+ }
+ })
+ return output
+}
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/tracker-stream.js b/node_modules/fsevents/node_modules/are-we-there-yet/tracker-stream.js
new file mode 100644
index 00000000..fb9598ed
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/tracker-stream.js
@@ -0,0 +1,35 @@
+'use strict'
+var util = require('util')
+var stream = require('readable-stream')
+var delegate = require('delegates')
+var Tracker = require('./tracker.js')
+
+var TrackerStream = module.exports = function (name, size, options) {
+ stream.Transform.call(this, options)
+ this.tracker = new Tracker(name, size)
+ this.name = name
+ this.id = this.tracker.id
+ this.tracker.on('change', delegateChange(this))
+}
+util.inherits(TrackerStream, stream.Transform)
+
+function delegateChange (trackerStream) {
+ return function (name, completion, tracker) {
+ trackerStream.emit('change', name, completion, trackerStream)
+ }
+}
+
+TrackerStream.prototype._transform = function (data, encoding, cb) {
+ this.tracker.completeWork(data.length ? data.length : 1)
+ this.push(data)
+ cb()
+}
+
+TrackerStream.prototype._flush = function (cb) {
+ this.tracker.finish()
+ cb()
+}
+
+delegate(TrackerStream.prototype, 'tracker')
+ .method('completed')
+ .method('addWork')
diff --git a/node_modules/fsevents/node_modules/are-we-there-yet/tracker.js b/node_modules/fsevents/node_modules/are-we-there-yet/tracker.js
new file mode 100644
index 00000000..68c2339b
--- /dev/null
+++ b/node_modules/fsevents/node_modules/are-we-there-yet/tracker.js
@@ -0,0 +1,30 @@
+'use strict'
+var util = require('util')
+var TrackerBase = require('./tracker-base.js')
+
+var Tracker = module.exports = function (name, todo) {
+ TrackerBase.call(this, name)
+ this.workDone = 0
+ this.workTodo = todo || 0
+}
+util.inherits(Tracker, TrackerBase)
+
+Tracker.prototype.completed = function () {
+ return this.workTodo === 0 ? 0 : this.workDone / this.workTodo
+}
+
+Tracker.prototype.addWork = function (work) {
+ this.workTodo += work
+ this.emit('change', this.name, this.completed(), this)
+}
+
+Tracker.prototype.completeWork = function (work) {
+ this.workDone += work
+ if (this.workDone > this.workTodo) this.workDone = this.workTodo
+ this.emit('change', this.name, this.completed(), this)
+}
+
+Tracker.prototype.finish = function () {
+ this.workTodo = this.workDone = 1
+ this.emit('change', this.name, 1, this)
+}
diff --git a/node_modules/fsevents/node_modules/asn1/.npmignore b/node_modules/fsevents/node_modules/asn1/.npmignore
new file mode 100644
index 00000000..eb03e3e1
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/.npmignore
@@ -0,0 +1,2 @@
+node_modules
+*.log
diff --git a/node_modules/fsevents/node_modules/asn1/.travis.yml b/node_modules/fsevents/node_modules/asn1/.travis.yml
new file mode 100644
index 00000000..09d3ef37
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/.travis.yml
@@ -0,0 +1,4 @@
+language: node_js
+node_js:
+ - 0.8
+ - 0.10
diff --git a/node_modules/fsevents/node_modules/asn1/LICENSE b/node_modules/fsevents/node_modules/asn1/LICENSE
new file mode 100644
index 00000000..9b5dcdb7
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2011 Mark Cavage, All rights reserved.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE
diff --git a/node_modules/fsevents/node_modules/asn1/README.md b/node_modules/fsevents/node_modules/asn1/README.md
new file mode 100644
index 00000000..7cebf7a2
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/README.md
@@ -0,0 +1,50 @@
+node-asn1 is a library for encoding and decoding ASN.1 datatypes in pure JS.
+Currently BER encoding is supported; at some point I'll likely have to do DER.
+
+## Usage
+
+Mostly, if you're *actually* needing to read and write ASN.1, you probably don't
+need this readme to explain what and why. If you have no idea what ASN.1 is,
+see this: ftp://ftp.rsa.com/pub/pkcs/ascii/layman.asc
+
+The source is pretty much self-explanatory, and has read/write methods for the
+common types out there.
+
+### Decoding
+
+The following reads an ASN.1 sequence with a boolean.
+
+ var Ber = require('asn1').Ber;
+
+ var reader = new Ber.Reader(new Buffer([0x30, 0x03, 0x01, 0x01, 0xff]));
+
+ reader.readSequence();
+ console.log('Sequence len: ' + reader.length);
+ if (reader.peek() === Ber.Boolean)
+ console.log(reader.readBoolean());
+
+### Encoding
+
+The following generates the same payload as above.
+
+ var Ber = require('asn1').Ber;
+
+ var writer = new Ber.Writer();
+
+ writer.startSequence();
+ writer.writeBoolean(true);
+ writer.endSequence();
+
+ console.log(writer.buffer);
+
+## Installation
+
+ npm install asn1
+
+## License
+
+MIT.
+
+## Bugs
+
+See .
diff --git a/node_modules/fsevents/node_modules/asn1/lib/ber/errors.js b/node_modules/fsevents/node_modules/asn1/lib/ber/errors.js
new file mode 100644
index 00000000..ff21d4fa
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/lib/ber/errors.js
@@ -0,0 +1,13 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+
+module.exports = {
+
+ newInvalidAsn1Error: function(msg) {
+ var e = new Error();
+ e.name = 'InvalidAsn1Error';
+ e.message = msg || '';
+ return e;
+ }
+
+};
diff --git a/node_modules/fsevents/node_modules/asn1/lib/ber/index.js b/node_modules/fsevents/node_modules/asn1/lib/ber/index.js
new file mode 100644
index 00000000..4fb90aea
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/lib/ber/index.js
@@ -0,0 +1,27 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+var errors = require('./errors');
+var types = require('./types');
+
+var Reader = require('./reader');
+var Writer = require('./writer');
+
+
+///--- Exports
+
+module.exports = {
+
+ Reader: Reader,
+
+ Writer: Writer
+
+};
+
+for (var t in types) {
+ if (types.hasOwnProperty(t))
+ module.exports[t] = types[t];
+}
+for (var e in errors) {
+ if (errors.hasOwnProperty(e))
+ module.exports[e] = errors[e];
+}
diff --git a/node_modules/fsevents/node_modules/asn1/lib/ber/reader.js b/node_modules/fsevents/node_modules/asn1/lib/ber/reader.js
new file mode 100644
index 00000000..0a00e98e
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/lib/ber/reader.js
@@ -0,0 +1,261 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+var assert = require('assert');
+
+var ASN1 = require('./types');
+var errors = require('./errors');
+
+
+///--- Globals
+
+var newInvalidAsn1Error = errors.newInvalidAsn1Error;
+
+
+
+///--- API
+
+function Reader(data) {
+ if (!data || !Buffer.isBuffer(data))
+ throw new TypeError('data must be a node Buffer');
+
+ this._buf = data;
+ this._size = data.length;
+
+ // These hold the "current" state
+ this._len = 0;
+ this._offset = 0;
+}
+
+Object.defineProperty(Reader.prototype, 'length', {
+ enumerable: true,
+ get: function () { return (this._len); }
+});
+
+Object.defineProperty(Reader.prototype, 'offset', {
+ enumerable: true,
+ get: function () { return (this._offset); }
+});
+
+Object.defineProperty(Reader.prototype, 'remain', {
+ get: function () { return (this._size - this._offset); }
+});
+
+Object.defineProperty(Reader.prototype, 'buffer', {
+ get: function () { return (this._buf.slice(this._offset)); }
+});
+
+
+/**
+ * Reads a single byte and advances offset; you can pass in `true` to make this
+ * a "peek" operation (i.e., get the byte, but don't advance the offset).
+ *
+ * @param {Boolean} peek true means don't move offset.
+ * @return {Number} the next byte, null if not enough data.
+ */
+Reader.prototype.readByte = function(peek) {
+ if (this._size - this._offset < 1)
+ return null;
+
+ var b = this._buf[this._offset] & 0xff;
+
+ if (!peek)
+ this._offset += 1;
+
+ return b;
+};
+
+
+Reader.prototype.peek = function() {
+ return this.readByte(true);
+};
+
+
+/**
+ * Reads a (potentially) variable length off the BER buffer. This call is
+ * not really meant to be called directly, as callers have to manipulate
+ * the internal buffer afterwards.
+ *
+ * As a result of this call, you can call `Reader.length`, until the
+ * next thing called that does a readLength.
+ *
+ * @return {Number} the amount of offset to advance the buffer.
+ * @throws {InvalidAsn1Error} on bad ASN.1
+ */
+Reader.prototype.readLength = function(offset) {
+ if (offset === undefined)
+ offset = this._offset;
+
+ if (offset >= this._size)
+ return null;
+
+ var lenB = this._buf[offset++] & 0xff;
+ if (lenB === null)
+ return null;
+
+ if ((lenB & 0x80) == 0x80) {
+ lenB &= 0x7f;
+
+ if (lenB == 0)
+ throw newInvalidAsn1Error('Indefinite length not supported');
+
+ if (lenB > 4)
+ throw newInvalidAsn1Error('encoding too long');
+
+ if (this._size - offset < lenB)
+ return null;
+
+ this._len = 0;
+ for (var i = 0; i < lenB; i++)
+ this._len = (this._len << 8) + (this._buf[offset++] & 0xff);
+
+ } else {
+ // Wasn't a variable length
+ this._len = lenB;
+ }
+
+ return offset;
+};
+
+
+/**
+ * Parses the next sequence in this BER buffer.
+ *
+ * To get the length of the sequence, call `Reader.length`.
+ *
+ * @return {Number} the sequence's tag.
+ */
+Reader.prototype.readSequence = function(tag) {
+ var seq = this.peek();
+ if (seq === null)
+ return null;
+ if (tag !== undefined && tag !== seq)
+ throw newInvalidAsn1Error('Expected 0x' + tag.toString(16) +
+ ': got 0x' + seq.toString(16));
+
+ var o = this.readLength(this._offset + 1); // stored in `length`
+ if (o === null)
+ return null;
+
+ this._offset = o;
+ return seq;
+};
+
+
+Reader.prototype.readInt = function() {
+ return this._readTag(ASN1.Integer);
+};
+
+
+Reader.prototype.readBoolean = function() {
+ return (this._readTag(ASN1.Boolean) === 0 ? false : true);
+};
+
+
+Reader.prototype.readEnumeration = function() {
+ return this._readTag(ASN1.Enumeration);
+};
+
+
+Reader.prototype.readString = function(tag, retbuf) {
+ if (!tag)
+ tag = ASN1.OctetString;
+
+ var b = this.peek();
+ if (b === null)
+ return null;
+
+ if (b !== tag)
+ throw newInvalidAsn1Error('Expected 0x' + tag.toString(16) +
+ ': got 0x' + b.toString(16));
+
+ var o = this.readLength(this._offset + 1); // stored in `length`
+
+ if (o === null)
+ return null;
+
+ if (this.length > this._size - o)
+ return null;
+
+ this._offset = o;
+
+ if (this.length === 0)
+ return retbuf ? new Buffer(0) : '';
+
+ var str = this._buf.slice(this._offset, this._offset + this.length);
+ this._offset += this.length;
+
+ return retbuf ? str : str.toString('utf8');
+};
+
+Reader.prototype.readOID = function(tag) {
+ if (!tag)
+ tag = ASN1.OID;
+
+ var b = this.readString(tag, true);
+ if (b === null)
+ return null;
+
+ var values = [];
+ var value = 0;
+
+ for (var i = 0; i < b.length; i++) {
+ var byte = b[i] & 0xff;
+
+ value <<= 7;
+ value += byte & 0x7f;
+ if ((byte & 0x80) == 0) {
+ values.push(value);
+ value = 0;
+ }
+ }
+
+ value = values.shift();
+ values.unshift(value % 40);
+ values.unshift((value / 40) >> 0);
+
+ return values.join('.');
+};
+
+
+Reader.prototype._readTag = function(tag) {
+ assert.ok(tag !== undefined);
+
+ var b = this.peek();
+
+ if (b === null)
+ return null;
+
+ if (b !== tag)
+ throw newInvalidAsn1Error('Expected 0x' + tag.toString(16) +
+ ': got 0x' + b.toString(16));
+
+ var o = this.readLength(this._offset + 1); // stored in `length`
+ if (o === null)
+ return null;
+
+ if (this.length > 4)
+ throw newInvalidAsn1Error('Integer too long: ' + this.length);
+
+ if (this.length > this._size - o)
+ return null;
+ this._offset = o;
+
+ var fb = this._buf[this._offset];
+ var value = 0;
+
+ for (var i = 0; i < this.length; i++) {
+ value <<= 8;
+ value |= (this._buf[this._offset++] & 0xff);
+ }
+
+ if ((fb & 0x80) == 0x80 && i !== 4)
+ value -= (1 << (i * 8));
+
+ return value >> 0;
+};
+
+
+
+///--- Exported API
+
+module.exports = Reader;
diff --git a/node_modules/fsevents/node_modules/asn1/lib/ber/types.js b/node_modules/fsevents/node_modules/asn1/lib/ber/types.js
new file mode 100644
index 00000000..8aea0001
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/lib/ber/types.js
@@ -0,0 +1,36 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+
+module.exports = {
+ EOC: 0,
+ Boolean: 1,
+ Integer: 2,
+ BitString: 3,
+ OctetString: 4,
+ Null: 5,
+ OID: 6,
+ ObjectDescriptor: 7,
+ External: 8,
+ Real: 9, // float
+ Enumeration: 10,
+ PDV: 11,
+ Utf8String: 12,
+ RelativeOID: 13,
+ Sequence: 16,
+ Set: 17,
+ NumericString: 18,
+ PrintableString: 19,
+ T61String: 20,
+ VideotexString: 21,
+ IA5String: 22,
+ UTCTime: 23,
+ GeneralizedTime: 24,
+ GraphicString: 25,
+ VisibleString: 26,
+ GeneralString: 28,
+ UniversalString: 29,
+ CharacterString: 30,
+ BMPString: 31,
+ Constructor: 32,
+ Context: 128
+};
diff --git a/node_modules/fsevents/node_modules/asn1/lib/ber/writer.js b/node_modules/fsevents/node_modules/asn1/lib/ber/writer.js
new file mode 100644
index 00000000..d9d99af6
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/lib/ber/writer.js
@@ -0,0 +1,316 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+var assert = require('assert');
+var ASN1 = require('./types');
+var errors = require('./errors');
+
+
+///--- Globals
+
+var newInvalidAsn1Error = errors.newInvalidAsn1Error;
+
+var DEFAULT_OPTS = {
+ size: 1024,
+ growthFactor: 8
+};
+
+
+///--- Helpers
+
+function merge(from, to) {
+ assert.ok(from);
+ assert.equal(typeof(from), 'object');
+ assert.ok(to);
+ assert.equal(typeof(to), 'object');
+
+ var keys = Object.getOwnPropertyNames(from);
+ keys.forEach(function(key) {
+ if (to[key])
+ return;
+
+ var value = Object.getOwnPropertyDescriptor(from, key);
+ Object.defineProperty(to, key, value);
+ });
+
+ return to;
+}
+
+
+
+///--- API
+
+function Writer(options) {
+ options = merge(DEFAULT_OPTS, options || {});
+
+ this._buf = new Buffer(options.size || 1024);
+ this._size = this._buf.length;
+ this._offset = 0;
+ this._options = options;
+
+ // A list of offsets in the buffer where we need to insert
+ // sequence tag/len pairs.
+ this._seq = [];
+}
+
+Object.defineProperty(Writer.prototype, 'buffer', {
+ get: function () {
+ if (this._seq.length)
+ throw new InvalidAsn1Error(this._seq.length + ' unended sequence(s)');
+
+ return (this._buf.slice(0, this._offset));
+ }
+});
+
+Writer.prototype.writeByte = function(b) {
+ if (typeof(b) !== 'number')
+ throw new TypeError('argument must be a Number');
+
+ this._ensure(1);
+ this._buf[this._offset++] = b;
+};
+
+
+Writer.prototype.writeInt = function(i, tag) {
+ if (typeof(i) !== 'number')
+ throw new TypeError('argument must be a Number');
+ if (typeof(tag) !== 'number')
+ tag = ASN1.Integer;
+
+ var sz = 4;
+
+ while ((((i & 0xff800000) === 0) || ((i & 0xff800000) === 0xff800000 >> 0)) &&
+ (sz > 1)) {
+ sz--;
+ i <<= 8;
+ }
+
+ if (sz > 4)
+ throw new InvalidAsn1Error('BER ints cannot be > 0xffffffff');
+
+ this._ensure(2 + sz);
+ this._buf[this._offset++] = tag;
+ this._buf[this._offset++] = sz;
+
+ while (sz-- > 0) {
+ this._buf[this._offset++] = ((i & 0xff000000) >>> 24);
+ i <<= 8;
+ }
+
+};
+
+
+Writer.prototype.writeNull = function() {
+ this.writeByte(ASN1.Null);
+ this.writeByte(0x00);
+};
+
+
+Writer.prototype.writeEnumeration = function(i, tag) {
+ if (typeof(i) !== 'number')
+ throw new TypeError('argument must be a Number');
+ if (typeof(tag) !== 'number')
+ tag = ASN1.Enumeration;
+
+ return this.writeInt(i, tag);
+};
+
+
+Writer.prototype.writeBoolean = function(b, tag) {
+ if (typeof(b) !== 'boolean')
+ throw new TypeError('argument must be a Boolean');
+ if (typeof(tag) !== 'number')
+ tag = ASN1.Boolean;
+
+ this._ensure(3);
+ this._buf[this._offset++] = tag;
+ this._buf[this._offset++] = 0x01;
+ this._buf[this._offset++] = b ? 0xff : 0x00;
+};
+
+
+Writer.prototype.writeString = function(s, tag) {
+ if (typeof(s) !== 'string')
+ throw new TypeError('argument must be a string (was: ' + typeof(s) + ')');
+ if (typeof(tag) !== 'number')
+ tag = ASN1.OctetString;
+
+ var len = Buffer.byteLength(s);
+ this.writeByte(tag);
+ this.writeLength(len);
+ if (len) {
+ this._ensure(len);
+ this._buf.write(s, this._offset);
+ this._offset += len;
+ }
+};
+
+
+Writer.prototype.writeBuffer = function(buf, tag) {
+ if (typeof(tag) !== 'number')
+ throw new TypeError('tag must be a number');
+ if (!Buffer.isBuffer(buf))
+ throw new TypeError('argument must be a buffer');
+
+ this.writeByte(tag);
+ this.writeLength(buf.length);
+ this._ensure(buf.length);
+ buf.copy(this._buf, this._offset, 0, buf.length);
+ this._offset += buf.length;
+};
+
+
+Writer.prototype.writeStringArray = function(strings) {
+ if ((!strings instanceof Array))
+ throw new TypeError('argument must be an Array[String]');
+
+ var self = this;
+ strings.forEach(function(s) {
+ self.writeString(s);
+ });
+};
+
+// This is really to solve DER cases, but whatever for now
+Writer.prototype.writeOID = function(s, tag) {
+ if (typeof(s) !== 'string')
+ throw new TypeError('argument must be a string');
+ if (typeof(tag) !== 'number')
+ tag = ASN1.OID;
+
+ if (!/^([0-9]+\.){3,}[0-9]+$/.test(s))
+ throw new Error('argument is not a valid OID string');
+
+ function encodeOctet(bytes, octet) {
+ if (octet < 128) {
+ bytes.push(octet);
+ } else if (octet < 16384) {
+ bytes.push((octet >>> 7) | 0x80);
+ bytes.push(octet & 0x7F);
+ } else if (octet < 2097152) {
+ bytes.push((octet >>> 14) | 0x80);
+ bytes.push(((octet >>> 7) | 0x80) & 0xFF);
+ bytes.push(octet & 0x7F);
+ } else if (octet < 268435456) {
+ bytes.push((octet >>> 21) | 0x80);
+ bytes.push(((octet >>> 14) | 0x80) & 0xFF);
+ bytes.push(((octet >>> 7) | 0x80) & 0xFF);
+ bytes.push(octet & 0x7F);
+ } else {
+ bytes.push(((octet >>> 28) | 0x80) & 0xFF);
+ bytes.push(((octet >>> 21) | 0x80) & 0xFF);
+ bytes.push(((octet >>> 14) | 0x80) & 0xFF);
+ bytes.push(((octet >>> 7) | 0x80) & 0xFF);
+ bytes.push(octet & 0x7F);
+ }
+ }
+
+ var tmp = s.split('.');
+ var bytes = [];
+ bytes.push(parseInt(tmp[0], 10) * 40 + parseInt(tmp[1], 10));
+ tmp.slice(2).forEach(function(b) {
+ encodeOctet(bytes, parseInt(b, 10));
+ });
+
+ var self = this;
+ this._ensure(2 + bytes.length);
+ this.writeByte(tag);
+ this.writeLength(bytes.length);
+ bytes.forEach(function(b) {
+ self.writeByte(b);
+ });
+};
+
+
+Writer.prototype.writeLength = function(len) {
+ if (typeof(len) !== 'number')
+ throw new TypeError('argument must be a Number');
+
+ this._ensure(4);
+
+ if (len <= 0x7f) {
+ this._buf[this._offset++] = len;
+ } else if (len <= 0xff) {
+ this._buf[this._offset++] = 0x81;
+ this._buf[this._offset++] = len;
+ } else if (len <= 0xffff) {
+ this._buf[this._offset++] = 0x82;
+ this._buf[this._offset++] = len >> 8;
+ this._buf[this._offset++] = len;
+ } else if (len <= 0xffffff) {
+ this._buf[this._offset++] = 0x83;
+ this._buf[this._offset++] = len >> 16;
+ this._buf[this._offset++] = len >> 8;
+ this._buf[this._offset++] = len;
+ } else {
+ throw new InvalidAsn1ERror('Length too long (> 4 bytes)');
+ }
+};
+
+Writer.prototype.startSequence = function(tag) {
+ if (typeof(tag) !== 'number')
+ tag = ASN1.Sequence | ASN1.Constructor;
+
+ this.writeByte(tag);
+ this._seq.push(this._offset);
+ this._ensure(3);
+ this._offset += 3;
+};
+
+
+Writer.prototype.endSequence = function() {
+ var seq = this._seq.pop();
+ var start = seq + 3;
+ var len = this._offset - start;
+
+ if (len <= 0x7f) {
+ this._shift(start, len, -2);
+ this._buf[seq] = len;
+ } else if (len <= 0xff) {
+ this._shift(start, len, -1);
+ this._buf[seq] = 0x81;
+ this._buf[seq + 1] = len;
+ } else if (len <= 0xffff) {
+ this._buf[seq] = 0x82;
+ this._buf[seq + 1] = len >> 8;
+ this._buf[seq + 2] = len;
+ } else if (len <= 0xffffff) {
+ this._shift(start, len, 1);
+ this._buf[seq] = 0x83;
+ this._buf[seq + 1] = len >> 16;
+ this._buf[seq + 2] = len >> 8;
+ this._buf[seq + 3] = len;
+ } else {
+ throw new InvalidAsn1Error('Sequence too long');
+ }
+};
+
+
+Writer.prototype._shift = function(start, len, shift) {
+ assert.ok(start !== undefined);
+ assert.ok(len !== undefined);
+ assert.ok(shift);
+
+ this._buf.copy(this._buf, start + shift, start, start + len);
+ this._offset += shift;
+};
+
+Writer.prototype._ensure = function(len) {
+ assert.ok(len);
+
+ if (this._size - this._offset < len) {
+ var sz = this._size * this._options.growthFactor;
+ if (sz - this._offset < len)
+ sz += len;
+
+ var buf = new Buffer(sz);
+
+ this._buf.copy(buf, 0, 0, this._offset);
+ this._buf = buf;
+ this._size = sz;
+ }
+};
+
+
+
+///--- Exported API
+
+module.exports = Writer;
diff --git a/node_modules/fsevents/node_modules/asn1/lib/index.js b/node_modules/fsevents/node_modules/asn1/lib/index.js
new file mode 100644
index 00000000..d1766e7a
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/lib/index.js
@@ -0,0 +1,20 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+// If you have no idea what ASN.1 or BER is, see this:
+// ftp://ftp.rsa.com/pub/pkcs/ascii/layman.asc
+
+var Ber = require('./ber/index');
+
+
+
+///--- Exported API
+
+module.exports = {
+
+ Ber: Ber,
+
+ BerReader: Ber.Reader,
+
+ BerWriter: Ber.Writer
+
+};
diff --git a/node_modules/fsevents/node_modules/asn1/package.json b/node_modules/fsevents/node_modules/asn1/package.json
new file mode 100644
index 00000000..a4d9a3e9
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/package.json
@@ -0,0 +1,98 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "asn1@~0.2.3",
+ "scope": null,
+ "escapedName": "asn1",
+ "name": "asn1",
+ "rawSpec": "~0.2.3",
+ "spec": ">=0.2.3 <0.3.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/sshpk"
+ ]
+ ],
+ "_from": "asn1@>=0.2.3 <0.3.0",
+ "_id": "asn1@0.2.3",
+ "_inCache": true,
+ "_location": "/fsevents/asn1",
+ "_npmUser": {
+ "name": "pfmooney",
+ "email": "patrick.f.mooney@gmail.com"
+ },
+ "_npmVersion": "1.4.28",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "asn1@~0.2.3",
+ "scope": null,
+ "escapedName": "asn1",
+ "name": "asn1",
+ "rawSpec": "~0.2.3",
+ "spec": ">=0.2.3 <0.3.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/sshpk"
+ ],
+ "_resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.3.tgz",
+ "_shasum": "dac8787713c9966849fc8180777ebe9c1ddf3b86",
+ "_shrinkwrap": null,
+ "_spec": "asn1@~0.2.3",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/sshpk",
+ "author": {
+ "name": "Mark Cavage",
+ "email": "mcavage@gmail.com"
+ },
+ "bugs": {
+ "url": "https://github.com/mcavage/node-asn1/issues"
+ },
+ "contributors": [
+ {
+ "name": "David Gwynne",
+ "email": "loki@animata.net"
+ },
+ {
+ "name": "Yunong Xiao",
+ "email": "yunong@joyent.com"
+ },
+ {
+ "name": "Alex Wilson",
+ "email": "alex.wilson@joyent.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "Contains parsers and serializers for ASN.1 (currently BER only)",
+ "devDependencies": {
+ "tap": "0.4.8"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "dac8787713c9966849fc8180777ebe9c1ddf3b86",
+ "tarball": "https://registry.npmjs.org/asn1/-/asn1-0.2.3.tgz"
+ },
+ "homepage": "https://github.com/mcavage/node-asn1",
+ "license": "MIT",
+ "main": "lib/index.js",
+ "maintainers": [
+ {
+ "name": "mcavage",
+ "email": "mcavage@gmail.com"
+ },
+ {
+ "name": "pfmooney",
+ "email": "patrick.f.mooney@gmail.com"
+ }
+ ],
+ "name": "asn1",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/mcavage/node-asn1.git"
+ },
+ "scripts": {
+ "test": "tap ./tst"
+ },
+ "version": "0.2.3"
+}
diff --git a/node_modules/fsevents/node_modules/asn1/tst/ber/reader.test.js b/node_modules/fsevents/node_modules/asn1/tst/ber/reader.test.js
new file mode 100644
index 00000000..062fd7ee
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/tst/ber/reader.test.js
@@ -0,0 +1,208 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+var test = require('tap').test;
+
+
+
+///--- Globals
+
+var BerReader;
+
+
+
+///--- Tests
+
+test('load library', function(t) {
+ BerReader = require('../../lib/index').BerReader;
+ t.ok(BerReader);
+ try {
+ new BerReader();
+ t.fail('Should have thrown');
+ } catch (e) {
+ t.ok(e instanceof TypeError, 'Should have been a type error');
+ }
+ t.end();
+});
+
+
+test('read byte', function(t) {
+ var reader = new BerReader(new Buffer([0xde]));
+ t.ok(reader);
+ t.equal(reader.readByte(), 0xde, 'wrong value');
+ t.end();
+});
+
+
+test('read 1 byte int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x01, 0x03]));
+ t.ok(reader);
+ t.equal(reader.readInt(), 0x03, 'wrong value');
+ t.equal(reader.length, 0x01, 'wrong length');
+ t.end();
+});
+
+
+test('read 2 byte int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x02, 0x7e, 0xde]));
+ t.ok(reader);
+ t.equal(reader.readInt(), 0x7ede, 'wrong value');
+ t.equal(reader.length, 0x02, 'wrong length');
+ t.end();
+});
+
+
+test('read 3 byte int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x03, 0x7e, 0xde, 0x03]));
+ t.ok(reader);
+ t.equal(reader.readInt(), 0x7ede03, 'wrong value');
+ t.equal(reader.length, 0x03, 'wrong length');
+ t.end();
+});
+
+
+test('read 4 byte int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x04, 0x7e, 0xde, 0x03, 0x01]));
+ t.ok(reader);
+ t.equal(reader.readInt(), 0x7ede0301, 'wrong value');
+ t.equal(reader.length, 0x04, 'wrong length');
+ t.end();
+});
+
+
+test('read 1 byte negative int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x01, 0xdc]));
+ t.ok(reader);
+ t.equal(reader.readInt(), -36, 'wrong value');
+ t.equal(reader.length, 0x01, 'wrong length');
+ t.end();
+});
+
+
+test('read 2 byte negative int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x02, 0xc0, 0x4e]));
+ t.ok(reader);
+ t.equal(reader.readInt(), -16306, 'wrong value');
+ t.equal(reader.length, 0x02, 'wrong length');
+ t.end();
+});
+
+
+test('read 3 byte negative int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x03, 0xff, 0x00, 0x19]));
+ t.ok(reader);
+ t.equal(reader.readInt(), -65511, 'wrong value');
+ t.equal(reader.length, 0x03, 'wrong length');
+ t.end();
+});
+
+
+test('read 4 byte negative int', function(t) {
+ var reader = new BerReader(new Buffer([0x02, 0x04, 0x91, 0x7c, 0x22, 0x1f]));
+ t.ok(reader);
+ t.equal(reader.readInt(), -1854135777, 'wrong value');
+ t.equal(reader.length, 0x04, 'wrong length');
+ t.end();
+});
+
+
+test('read boolean true', function(t) {
+ var reader = new BerReader(new Buffer([0x01, 0x01, 0xff]));
+ t.ok(reader);
+ t.equal(reader.readBoolean(), true, 'wrong value');
+ t.equal(reader.length, 0x01, 'wrong length');
+ t.end();
+});
+
+
+test('read boolean false', function(t) {
+ var reader = new BerReader(new Buffer([0x01, 0x01, 0x00]));
+ t.ok(reader);
+ t.equal(reader.readBoolean(), false, 'wrong value');
+ t.equal(reader.length, 0x01, 'wrong length');
+ t.end();
+});
+
+
+test('read enumeration', function(t) {
+ var reader = new BerReader(new Buffer([0x0a, 0x01, 0x20]));
+ t.ok(reader);
+ t.equal(reader.readEnumeration(), 0x20, 'wrong value');
+ t.equal(reader.length, 0x01, 'wrong length');
+ t.end();
+});
+
+
+test('read string', function(t) {
+ var dn = 'cn=foo,ou=unit,o=test';
+ var buf = new Buffer(dn.length + 2);
+ buf[0] = 0x04;
+ buf[1] = Buffer.byteLength(dn);
+ buf.write(dn, 2);
+ var reader = new BerReader(buf);
+ t.ok(reader);
+ t.equal(reader.readString(), dn, 'wrong value');
+ t.equal(reader.length, dn.length, 'wrong length');
+ t.end();
+});
+
+
+test('read sequence', function(t) {
+ var reader = new BerReader(new Buffer([0x30, 0x03, 0x01, 0x01, 0xff]));
+ t.ok(reader);
+ t.equal(reader.readSequence(), 0x30, 'wrong value');
+ t.equal(reader.length, 0x03, 'wrong length');
+ t.equal(reader.readBoolean(), true, 'wrong value');
+ t.equal(reader.length, 0x01, 'wrong length');
+ t.end();
+});
+
+
+test('anonymous LDAPv3 bind', function(t) {
+ var BIND = new Buffer(14);
+ BIND[0] = 0x30; // Sequence
+ BIND[1] = 12; // len
+ BIND[2] = 0x02; // ASN.1 Integer
+ BIND[3] = 1; // len
+ BIND[4] = 0x04; // msgid (make up 4)
+ BIND[5] = 0x60; // Bind Request
+ BIND[6] = 7; // len
+ BIND[7] = 0x02; // ASN.1 Integer
+ BIND[8] = 1; // len
+ BIND[9] = 0x03; // v3
+ BIND[10] = 0x04; // String (bind dn)
+ BIND[11] = 0; // len
+ BIND[12] = 0x80; // ContextSpecific (choice)
+ BIND[13] = 0; // simple bind
+
+ // Start testing ^^
+ var ber = new BerReader(BIND);
+ t.equal(ber.readSequence(), 48, 'Not an ASN.1 Sequence');
+ t.equal(ber.length, 12, 'Message length should be 12');
+ t.equal(ber.readInt(), 4, 'Message id should have been 4');
+ t.equal(ber.readSequence(), 96, 'Bind Request should have been 96');
+ t.equal(ber.length, 7, 'Bind length should have been 7');
+ t.equal(ber.readInt(), 3, 'LDAP version should have been 3');
+ t.equal(ber.readString(), '', 'Bind DN should have been empty');
+ t.equal(ber.length, 0, 'string length should have been 0');
+ t.equal(ber.readByte(), 0x80, 'Should have been ContextSpecific (choice)');
+ t.equal(ber.readByte(), 0, 'Should have been simple bind');
+ t.equal(null, ber.readByte(), 'Should be out of data');
+ t.end();
+});
+
+
+test('long string', function(t) {
+ var buf = new Buffer(256);
+ var o;
+ var s =
+ '2;649;CN=Red Hat CS 71GA Demo,O=Red Hat CS 71GA Demo,C=US;' +
+ 'CN=RHCS Agent - admin01,UID=admin01,O=redhat,C=US [1] This is ' +
+ 'Teena Vradmin\'s description.';
+ buf[0] = 0x04;
+ buf[1] = 0x81;
+ buf[2] = 0x94;
+ buf.write(s, 3);
+ var ber = new BerReader(buf.slice(0, 3 + s.length));
+ t.equal(ber.readString(), s);
+ t.end();
+});
diff --git a/node_modules/fsevents/node_modules/asn1/tst/ber/writer.test.js b/node_modules/fsevents/node_modules/asn1/tst/ber/writer.test.js
new file mode 100644
index 00000000..d87cb7bc
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asn1/tst/ber/writer.test.js
@@ -0,0 +1,370 @@
+// Copyright 2011 Mark Cavage All rights reserved.
+
+var test = require('tap').test;
+var sys = require('sys');
+
+///--- Globals
+
+var BerWriter;
+
+var BerReader;
+
+
+///--- Tests
+
+test('load library', function(t) {
+ BerWriter = require('../../lib/index').BerWriter;
+ t.ok(BerWriter);
+ t.ok(new BerWriter());
+ t.end();
+});
+
+
+test('write byte', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeByte(0xC2);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 1, 'Wrong length');
+ t.equal(ber[0], 0xC2, 'value wrong');
+
+ t.end();
+});
+
+
+test('write 1 byte int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(0x7f);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 3, 'Wrong length for an int: ' + ber.length);
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong (2) -> ' + ber[0]);
+ t.equal(ber[1], 0x01, 'length wrong(1) -> ' + ber[1]);
+ t.equal(ber[2], 0x7f, 'value wrong(3) -> ' + ber[2]);
+
+ t.end();
+});
+
+
+test('write 2 byte int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(0x7ffe);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 4, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x02, 'length wrong');
+ t.equal(ber[2], 0x7f, 'value wrong (byte 1)');
+ t.equal(ber[3], 0xfe, 'value wrong (byte 2)');
+
+ t.end();
+});
+
+
+test('write 3 byte int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(0x7ffffe);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 5, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x03, 'length wrong');
+ t.equal(ber[2], 0x7f, 'value wrong (byte 1)');
+ t.equal(ber[3], 0xff, 'value wrong (byte 2)');
+ t.equal(ber[4], 0xfe, 'value wrong (byte 3)');
+
+ t.end();
+});
+
+
+test('write 4 byte int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(0x7ffffffe);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+
+ t.equal(ber.length, 6, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x04, 'length wrong');
+ t.equal(ber[2], 0x7f, 'value wrong (byte 1)');
+ t.equal(ber[3], 0xff, 'value wrong (byte 2)');
+ t.equal(ber[4], 0xff, 'value wrong (byte 3)');
+ t.equal(ber[5], 0xfe, 'value wrong (byte 4)');
+
+ t.end();
+});
+
+
+test('write 1 byte negative int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(-128);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+
+ t.equal(ber.length, 3, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x01, 'length wrong');
+ t.equal(ber[2], 0x80, 'value wrong (byte 1)');
+
+ t.end();
+});
+
+
+test('write 2 byte negative int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(-22400);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+
+ t.equal(ber.length, 4, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x02, 'length wrong');
+ t.equal(ber[2], 0xa8, 'value wrong (byte 1)');
+ t.equal(ber[3], 0x80, 'value wrong (byte 2)');
+
+ t.end();
+});
+
+
+test('write 3 byte negative int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(-481653);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+
+ t.equal(ber.length, 5, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x03, 'length wrong');
+ t.equal(ber[2], 0xf8, 'value wrong (byte 1)');
+ t.equal(ber[3], 0xa6, 'value wrong (byte 2)');
+ t.equal(ber[4], 0x8b, 'value wrong (byte 3)');
+
+ t.end();
+});
+
+
+test('write 4 byte negative int', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeInt(-1522904131);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+
+ t.equal(ber.length, 6, 'Wrong length for an int');
+ t.equal(ber[0], 0x02, 'ASN.1 tag wrong');
+ t.equal(ber[1], 0x04, 'length wrong');
+ t.equal(ber[2], 0xa5, 'value wrong (byte 1)');
+ t.equal(ber[3], 0x3a, 'value wrong (byte 2)');
+ t.equal(ber[4], 0x53, 'value wrong (byte 3)');
+ t.equal(ber[5], 0xbd, 'value wrong (byte 4)');
+
+ t.end();
+});
+
+
+test('write boolean', function(t) {
+ var writer = new BerWriter();
+
+ writer.writeBoolean(true);
+ writer.writeBoolean(false);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 6, 'Wrong length');
+ t.equal(ber[0], 0x01, 'tag wrong');
+ t.equal(ber[1], 0x01, 'length wrong');
+ t.equal(ber[2], 0xff, 'value wrong');
+ t.equal(ber[3], 0x01, 'tag wrong');
+ t.equal(ber[4], 0x01, 'length wrong');
+ t.equal(ber[5], 0x00, 'value wrong');
+
+ t.end();
+});
+
+
+test('write string', function(t) {
+ var writer = new BerWriter();
+ writer.writeString('hello world');
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 13, 'wrong length');
+ t.equal(ber[0], 0x04, 'wrong tag');
+ t.equal(ber[1], 11, 'wrong length');
+ t.equal(ber.slice(2).toString('utf8'), 'hello world', 'wrong value');
+
+ t.end();
+});
+
+test('write buffer', function(t) {
+ var writer = new BerWriter();
+ // write some stuff to start with
+ writer.writeString('hello world');
+ var ber = writer.buffer;
+ var buf = new Buffer([0x04, 0x0b, 0x30, 0x09, 0x02, 0x01, 0x0f, 0x01, 0x01,
+ 0xff, 0x01, 0x01, 0xff]);
+ writer.writeBuffer(buf.slice(2, buf.length), 0x04);
+ ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 26, 'wrong length');
+ t.equal(ber[0], 0x04, 'wrong tag');
+ t.equal(ber[1], 11, 'wrong length');
+ t.equal(ber.slice(2, 13).toString('utf8'), 'hello world', 'wrong value');
+ t.equal(ber[13], buf[0], 'wrong tag');
+ t.equal(ber[14], buf[1], 'wrong length');
+ for (var i = 13, j = 0; i < ber.length && j < buf.length; i++, j++) {
+ t.equal(ber[i], buf[j], 'buffer contents not identical');
+ }
+ t.end();
+});
+
+test('write string array', function(t) {
+ var writer = new BerWriter();
+ writer.writeStringArray(['hello world', 'fubar!']);
+ var ber = writer.buffer;
+
+ t.ok(ber);
+
+ t.equal(ber.length, 21, 'wrong length');
+ t.equal(ber[0], 0x04, 'wrong tag');
+ t.equal(ber[1], 11, 'wrong length');
+ t.equal(ber.slice(2, 13).toString('utf8'), 'hello world', 'wrong value');
+
+ t.equal(ber[13], 0x04, 'wrong tag');
+ t.equal(ber[14], 6, 'wrong length');
+ t.equal(ber.slice(15).toString('utf8'), 'fubar!', 'wrong value');
+
+ t.end();
+});
+
+
+test('resize internal buffer', function(t) {
+ var writer = new BerWriter({size: 2});
+ writer.writeString('hello world');
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 13, 'wrong length');
+ t.equal(ber[0], 0x04, 'wrong tag');
+ t.equal(ber[1], 11, 'wrong length');
+ t.equal(ber.slice(2).toString('utf8'), 'hello world', 'wrong value');
+
+ t.end();
+});
+
+
+test('sequence', function(t) {
+ var writer = new BerWriter({size: 25});
+ writer.startSequence();
+ writer.writeString('hello world');
+ writer.endSequence();
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ console.log(ber);
+ t.equal(ber.length, 15, 'wrong length');
+ t.equal(ber[0], 0x30, 'wrong tag');
+ t.equal(ber[1], 13, 'wrong length');
+ t.equal(ber[2], 0x04, 'wrong tag');
+ t.equal(ber[3], 11, 'wrong length');
+ t.equal(ber.slice(4).toString('utf8'), 'hello world', 'wrong value');
+
+ t.end();
+});
+
+
+test('nested sequence', function(t) {
+ var writer = new BerWriter({size: 25});
+ writer.startSequence();
+ writer.writeString('hello world');
+ writer.startSequence();
+ writer.writeString('hello world');
+ writer.endSequence();
+ writer.endSequence();
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 30, 'wrong length');
+ t.equal(ber[0], 0x30, 'wrong tag');
+ t.equal(ber[1], 28, 'wrong length');
+ t.equal(ber[2], 0x04, 'wrong tag');
+ t.equal(ber[3], 11, 'wrong length');
+ t.equal(ber.slice(4, 15).toString('utf8'), 'hello world', 'wrong value');
+ t.equal(ber[15], 0x30, 'wrong tag');
+ t.equal(ber[16], 13, 'wrong length');
+ t.equal(ber[17], 0x04, 'wrong tag');
+ t.equal(ber[18], 11, 'wrong length');
+ t.equal(ber.slice(19, 30).toString('utf8'), 'hello world', 'wrong value');
+
+ t.end();
+});
+
+
+test('LDAP bind message', function(t) {
+ var dn = 'cn=foo,ou=unit,o=test';
+ var writer = new BerWriter();
+ writer.startSequence();
+ writer.writeInt(3); // msgid = 3
+ writer.startSequence(0x60); // ldap bind
+ writer.writeInt(3); // ldap v3
+ writer.writeString(dn);
+ writer.writeByte(0x80);
+ writer.writeByte(0x00);
+ writer.endSequence();
+ writer.endSequence();
+ var ber = writer.buffer;
+
+ t.ok(ber);
+ t.equal(ber.length, 35, 'wrong length (buffer)');
+ t.equal(ber[0], 0x30, 'wrong tag');
+ t.equal(ber[1], 33, 'wrong length');
+ t.equal(ber[2], 0x02, 'wrong tag');
+ t.equal(ber[3], 1, 'wrong length');
+ t.equal(ber[4], 0x03, 'wrong value');
+ t.equal(ber[5], 0x60, 'wrong tag');
+ t.equal(ber[6], 28, 'wrong length');
+ t.equal(ber[7], 0x02, 'wrong tag');
+ t.equal(ber[8], 1, 'wrong length');
+ t.equal(ber[9], 0x03, 'wrong value');
+ t.equal(ber[10], 0x04, 'wrong tag');
+ t.equal(ber[11], dn.length, 'wrong length');
+ t.equal(ber.slice(12, 33).toString('utf8'), dn, 'wrong value');
+ t.equal(ber[33], 0x80, 'wrong tag');
+ t.equal(ber[34], 0x00, 'wrong len');
+
+ t.end();
+});
+
+
+test('Write OID', function(t) {
+ var oid = '1.2.840.113549.1.1.1';
+ var writer = new BerWriter();
+ writer.writeOID(oid);
+
+ var ber = writer.buffer;
+ t.ok(ber);
+ console.log(require('util').inspect(ber));
+ console.log(require('util').inspect(new Buffer([0x06, 0x09, 0x2a, 0x86,
+ 0x48, 0x86, 0xf7, 0x0d,
+ 0x01, 0x01, 0x01])));
+
+ t.end();
+});
diff --git a/node_modules/fsevents/node_modules/assert-plus/AUTHORS b/node_modules/fsevents/node_modules/assert-plus/AUTHORS
new file mode 100644
index 00000000..1923524f
--- /dev/null
+++ b/node_modules/fsevents/node_modules/assert-plus/AUTHORS
@@ -0,0 +1,6 @@
+Dave Eddy
+Fred Kuo
+Lars-Magnus Skog
+Mark Cavage
+Patrick Mooney
+Rob Gulewich
diff --git a/node_modules/fsevents/node_modules/assert-plus/CHANGES.md b/node_modules/fsevents/node_modules/assert-plus/CHANGES.md
new file mode 100644
index 00000000..d249d9b2
--- /dev/null
+++ b/node_modules/fsevents/node_modules/assert-plus/CHANGES.md
@@ -0,0 +1,8 @@
+# assert-plus Changelog
+
+## 0.2.0
+
+- Fix `assert.object(null)` so it throws
+- Fix optional/arrayOf exports for non-type-of asserts
+- Add optiona/arrayOf exports for Stream/Date/Regex/uuid
+- Add basic unit test coverage
diff --git a/node_modules/fsevents/node_modules/assert-plus/README.md b/node_modules/fsevents/node_modules/assert-plus/README.md
new file mode 100644
index 00000000..0b39593c
--- /dev/null
+++ b/node_modules/fsevents/node_modules/assert-plus/README.md
@@ -0,0 +1,155 @@
+# assert-plus
+
+This library is a super small wrapper over node's assert module that has two
+things: (1) the ability to disable assertions with the environment variable
+NODE\_NDEBUG, and (2) some API wrappers for argument testing. Like
+`assert.string(myArg, 'myArg')`. As a simple example, most of my code looks
+like this:
+
+```javascript
+ var assert = require('assert-plus');
+
+ function fooAccount(options, callback) {
+ assert.object(options, 'options');
+ assert.number(options.id, 'options.id');
+ assert.bool(options.isManager, 'options.isManager');
+ assert.string(options.name, 'options.name');
+ assert.arrayOfString(options.email, 'options.email');
+ assert.func(callback, 'callback');
+
+ // Do stuff
+ callback(null, {});
+ }
+```
+
+# API
+
+All methods that *aren't* part of node's core assert API are simply assumed to
+take an argument, and then a string 'name' that's not a message; `AssertionError`
+will be thrown if the assertion fails with a message like:
+
+ AssertionError: foo (string) is required
+ at test (/home/mark/work/foo/foo.js:3:9)
+ at Object. (/home/mark/work/foo/foo.js:15:1)
+ at Module._compile (module.js:446:26)
+ at Object..js (module.js:464:10)
+ at Module.load (module.js:353:31)
+ at Function._load (module.js:311:12)
+ at Array.0 (module.js:484:10)
+ at EventEmitter._tickCallback (node.js:190:38)
+
+from:
+
+```javascript
+ function test(foo) {
+ assert.string(foo, 'foo');
+ }
+```
+
+There you go. You can check that arrays are of a homogeneous type with `Arrayof$Type`:
+
+```javascript
+ function test(foo) {
+ assert.arrayOfString(foo, 'foo');
+ }
+```
+
+You can assert IFF an argument is not `undefined` (i.e., an optional arg):
+
+```javascript
+ assert.optionalString(foo, 'foo');
+```
+
+Lastly, you can opt-out of assertion checking altogether by setting the
+environment variable `NODE_NDEBUG=1`. This is pseudo-useful if you have
+lots of assertions, and don't want to pay `typeof ()` taxes to v8 in
+production. Be advised: The standard functions re-exported from `assert` are
+also disabled in assert-plus if NDEBUG is specified. Using them directly from
+the `assert` module avoids this behavior.
+
+The complete list of APIs is:
+
+* assert.array
+* assert.bool
+* assert.buffer
+* assert.func
+* assert.number
+* assert.object
+* assert.string
+* assert.stream
+* assert.date
+* assert.regex
+* assert.uuid
+* assert.arrayOfArray
+* assert.arrayOfBool
+* assert.arrayOfBuffer
+* assert.arrayOfFunc
+* assert.arrayOfNumber
+* assert.arrayOfObject
+* assert.arrayOfString
+* assert.arrayOfStream
+* assert.arrayOfDate
+* assert.arrayOfUuid
+* assert.optionalArray
+* assert.optionalBool
+* assert.optionalBuffer
+* assert.optionalFunc
+* assert.optionalNumber
+* assert.optionalObject
+* assert.optionalString
+* assert.optionalStream
+* assert.optionalDate
+* assert.optionalUuid
+* assert.optionalArrayOfArray
+* assert.optionalArrayOfBool
+* assert.optionalArrayOfBuffer
+* assert.optionalArrayOfFunc
+* assert.optionalArrayOfNumber
+* assert.optionalArrayOfObject
+* assert.optionalArrayOfString
+* assert.optionalArrayOfStream
+* assert.optionalArrayOfDate
+* assert.optionalArrayOfUuid
+* assert.AssertionError
+* assert.fail
+* assert.ok
+* assert.equal
+* assert.notEqual
+* assert.deepEqual
+* assert.notDeepEqual
+* assert.strictEqual
+* assert.notStrictEqual
+* assert.throws
+* assert.doesNotThrow
+* assert.ifError
+
+# Installation
+
+ npm install assert-plus
+
+## License
+
+The MIT License (MIT)
+Copyright (c) 2012 Mark Cavage
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+
+## Bugs
+
+See .
diff --git a/node_modules/fsevents/node_modules/assert-plus/assert.js b/node_modules/fsevents/node_modules/assert-plus/assert.js
new file mode 100644
index 00000000..6bce4d8c
--- /dev/null
+++ b/node_modules/fsevents/node_modules/assert-plus/assert.js
@@ -0,0 +1,206 @@
+// Copyright (c) 2012, Mark Cavage. All rights reserved.
+// Copyright 2015 Joyent, Inc.
+
+var assert = require('assert');
+var Stream = require('stream').Stream;
+var util = require('util');
+
+
+///--- Globals
+
+/* JSSTYLED */
+var UUID_REGEXP = /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
+
+
+///--- Internal
+
+function _capitalize(str) {
+ return (str.charAt(0).toUpperCase() + str.slice(1));
+}
+
+function _toss(name, expected, oper, arg, actual) {
+ throw new assert.AssertionError({
+ message: util.format('%s (%s) is required', name, expected),
+ actual: (actual === undefined) ? typeof (arg) : actual(arg),
+ expected: expected,
+ operator: oper || '===',
+ stackStartFunction: _toss.caller
+ });
+}
+
+function _getClass(arg) {
+ return (Object.prototype.toString.call(arg).slice(8, -1));
+}
+
+function noop() {
+ // Why even bother with asserts?
+}
+
+
+///--- Exports
+
+var types = {
+ bool: {
+ check: function (arg) { return typeof (arg) === 'boolean'; }
+ },
+ func: {
+ check: function (arg) { return typeof (arg) === 'function'; }
+ },
+ string: {
+ check: function (arg) { return typeof (arg) === 'string'; }
+ },
+ object: {
+ check: function (arg) {
+ return typeof (arg) === 'object' && arg !== null;
+ }
+ },
+ number: {
+ check: function (arg) {
+ return typeof (arg) === 'number' && !isNaN(arg) && isFinite(arg);
+ }
+ },
+ buffer: {
+ check: function (arg) { return Buffer.isBuffer(arg); },
+ operator: 'Buffer.isBuffer'
+ },
+ array: {
+ check: function (arg) { return Array.isArray(arg); },
+ operator: 'Array.isArray'
+ },
+ stream: {
+ check: function (arg) { return arg instanceof Stream; },
+ operator: 'instanceof',
+ actual: _getClass
+ },
+ date: {
+ check: function (arg) { return arg instanceof Date; },
+ operator: 'instanceof',
+ actual: _getClass
+ },
+ regexp: {
+ check: function (arg) { return arg instanceof RegExp; },
+ operator: 'instanceof',
+ actual: _getClass
+ },
+ uuid: {
+ check: function (arg) {
+ return typeof (arg) === 'string' && UUID_REGEXP.test(arg);
+ },
+ operator: 'isUUID'
+ }
+};
+
+function _setExports(ndebug) {
+ var keys = Object.keys(types);
+ var out;
+
+ /* re-export standard assert */
+ if (process.env.NODE_NDEBUG) {
+ out = noop;
+ } else {
+ out = function (arg, msg) {
+ if (!arg) {
+ _toss(msg, 'true', arg);
+ }
+ };
+ }
+
+ /* standard checks */
+ keys.forEach(function (k) {
+ if (ndebug) {
+ out[k] = noop;
+ return;
+ }
+ var type = types[k];
+ out[k] = function (arg, msg) {
+ if (!type.check(arg)) {
+ _toss(msg, k, type.operator, arg, type.actual);
+ }
+ };
+ });
+
+ /* optional checks */
+ keys.forEach(function (k) {
+ var name = 'optional' + _capitalize(k);
+ if (ndebug) {
+ out[name] = noop;
+ return;
+ }
+ var type = types[k];
+ out[name] = function (arg, msg) {
+ if (arg === undefined || arg === null) {
+ return;
+ }
+ if (!type.check(arg)) {
+ _toss(msg, k, type.operator, arg, type.actual);
+ }
+ };
+ });
+
+ /* arrayOf checks */
+ keys.forEach(function (k) {
+ var name = 'arrayOf' + _capitalize(k);
+ if (ndebug) {
+ out[name] = noop;
+ return;
+ }
+ var type = types[k];
+ var expected = '[' + k + ']';
+ out[name] = function (arg, msg) {
+ if (!Array.isArray(arg)) {
+ _toss(msg, expected, type.operator, arg, type.actual);
+ }
+ var i;
+ for (i = 0; i < arg.length; i++) {
+ if (!type.check(arg[i])) {
+ _toss(msg, expected, type.operator, arg, type.actual);
+ }
+ }
+ };
+ });
+
+ /* optionalArrayOf checks */
+ keys.forEach(function (k) {
+ var name = 'optionalArrayOf' + _capitalize(k);
+ if (ndebug) {
+ out[name] = noop;
+ return;
+ }
+ var type = types[k];
+ var expected = '[' + k + ']';
+ out[name] = function (arg, msg) {
+ if (arg === undefined || arg === null) {
+ return;
+ }
+ if (!Array.isArray(arg)) {
+ _toss(msg, expected, type.operator, arg, type.actual);
+ }
+ var i;
+ for (i = 0; i < arg.length; i++) {
+ if (!type.check(arg[i])) {
+ _toss(msg, expected, type.operator, arg, type.actual);
+ }
+ }
+ };
+ });
+
+ /* re-export built-in assertions */
+ Object.keys(assert).forEach(function (k) {
+ if (k === 'AssertionError') {
+ out[k] = assert[k];
+ return;
+ }
+ if (ndebug) {
+ out[k] = noop;
+ return;
+ }
+ out[k] = assert[k];
+ });
+
+ /* export ourselves (for unit tests _only_) */
+ out._setExports = _setExports;
+
+ return out;
+}
+
+module.exports = _setExports(process.env.NODE_NDEBUG);
diff --git a/node_modules/fsevents/node_modules/assert-plus/package.json b/node_modules/fsevents/node_modules/assert-plus/package.json
new file mode 100644
index 00000000..0200b198
--- /dev/null
+++ b/node_modules/fsevents/node_modules/assert-plus/package.json
@@ -0,0 +1,115 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "assert-plus@^0.2.0",
+ "scope": null,
+ "escapedName": "assert-plus",
+ "name": "assert-plus",
+ "rawSpec": "^0.2.0",
+ "spec": ">=0.2.0 <0.3.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/http-signature"
+ ]
+ ],
+ "_from": "assert-plus@>=0.2.0 <0.3.0",
+ "_id": "assert-plus@0.2.0",
+ "_inCache": true,
+ "_location": "/fsevents/assert-plus",
+ "_nodeVersion": "0.10.36",
+ "_npmUser": {
+ "name": "pfmooney",
+ "email": "patrick.f.mooney@gmail.com"
+ },
+ "_npmVersion": "3.3.8",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "assert-plus@^0.2.0",
+ "scope": null,
+ "escapedName": "assert-plus",
+ "name": "assert-plus",
+ "rawSpec": "^0.2.0",
+ "spec": ">=0.2.0 <0.3.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/http-signature"
+ ],
+ "_resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-0.2.0.tgz",
+ "_shasum": "d74e1b87e7affc0db8aadb7021f3fe48101ab234",
+ "_shrinkwrap": null,
+ "_spec": "assert-plus@^0.2.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/http-signature",
+ "author": {
+ "name": "Mark Cavage",
+ "email": "mcavage@gmail.com"
+ },
+ "bugs": {
+ "url": "https://github.com/mcavage/node-assert-plus/issues"
+ },
+ "contributors": [
+ {
+ "name": "Dave Eddy",
+ "email": "dave@daveeddy.com"
+ },
+ {
+ "name": "Fred Kuo",
+ "email": "fred.kuo@joyent.com"
+ },
+ {
+ "name": "Lars-Magnus Skog",
+ "email": "ralphtheninja@riseup.net"
+ },
+ {
+ "name": "Mark Cavage",
+ "email": "mcavage@gmail.com"
+ },
+ {
+ "name": "Patrick Mooney",
+ "email": "pmooney@pfmooney.com"
+ },
+ {
+ "name": "Rob Gulewich",
+ "email": "robert.gulewich@joyent.com"
+ }
+ ],
+ "dependencies": {},
+ "description": "Extra assertions on top of node's assert module",
+ "devDependencies": {
+ "faucet": "0.0.1",
+ "tape": "4.2.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "d74e1b87e7affc0db8aadb7021f3fe48101ab234",
+ "tarball": "https://registry.npmjs.org/assert-plus/-/assert-plus-0.2.0.tgz"
+ },
+ "engines": {
+ "node": ">=0.8"
+ },
+ "homepage": "https://github.com/mcavage/node-assert-plus#readme",
+ "license": "MIT",
+ "main": "./assert.js",
+ "maintainers": [
+ {
+ "name": "mcavage",
+ "email": "mcavage@gmail.com"
+ },
+ {
+ "name": "pfmooney",
+ "email": "patrick.f.mooney@gmail.com"
+ }
+ ],
+ "name": "assert-plus",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/mcavage/node-assert-plus.git"
+ },
+ "scripts": {
+ "test": "tape tests/*.js | ./node_modules/.bin/faucet"
+ },
+ "version": "0.2.0"
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/LICENSE b/node_modules/fsevents/node_modules/asynckit/LICENSE
new file mode 100644
index 00000000..c9eca5dd
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2016 Alex Indigo
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/asynckit/README.md b/node_modules/fsevents/node_modules/asynckit/README.md
new file mode 100644
index 00000000..ddcc7e6b
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/README.md
@@ -0,0 +1,233 @@
+# asynckit [](https://www.npmjs.com/package/asynckit)
+
+Minimal async jobs utility library, with streams support.
+
+[](https://travis-ci.org/alexindigo/asynckit)
+[](https://travis-ci.org/alexindigo/asynckit)
+[](https://ci.appveyor.com/project/alexindigo/asynckit)
+
+[](https://coveralls.io/github/alexindigo/asynckit?branch=master)
+[](https://david-dm.org/alexindigo/asynckit)
+[](https://www.bithound.io/github/alexindigo/asynckit)
+
+
+
+AsyncKit provides harness for `parallel` and `serial` iterators over list of items represented by arrays or objects.
+Optionally it accepts abort function (should be synchronously return by iterator for each item), and terminates left over jobs upon an error event. For specific iteration order built-in (`ascending` and `descending`) and custom sort helpers also supported, via `asynckit.serialOrdered` method.
+
+It ensures async operations to keep behavior more stable and prevent `Maximum call stack size exceeded` errors, from sync iterators.
+
+| compression | size |
+| :----------------- | -------: |
+| asynckit.js | 12.34 kB |
+| asynckit.min.js | 4.11 kB |
+| asynckit.min.js.gz | 1.47 kB |
+
+
+## Install
+
+```sh
+$ npm install --save asynckit
+```
+
+## Examples
+
+### Parallel Jobs
+
+Runs iterator over provided array in parallel. Stores output in the `result` array,
+on the matching positions. In unlikely event of an error from one of the jobs,
+will terminate rest of the active jobs (if abort function is provided)
+and return error along with salvaged data to the main callback function.
+
+#### Input Array
+
+```javascript
+var parallel = require('asynckit').parallel
+ , assert = require('assert')
+ ;
+
+var source = [ 1, 1, 4, 16, 64, 32, 8, 2 ]
+ , expectedResult = [ 2, 2, 8, 32, 128, 64, 16, 4 ]
+ , expectedTarget = [ 1, 1, 2, 4, 8, 16, 32, 64 ]
+ , target = []
+ ;
+
+parallel(source, asyncJob, function(err, result)
+{
+ assert.deepEqual(result, expectedResult);
+ assert.deepEqual(target, expectedTarget);
+});
+
+// async job accepts one element from the array
+// and a callback function
+function asyncJob(item, cb)
+{
+ // different delays (in ms) per item
+ var delay = item * 25;
+
+ // pretend different jobs take different time to finish
+ // and not in consequential order
+ var timeoutId = setTimeout(function() {
+ target.push(item);
+ cb(null, item * 2);
+ }, delay);
+
+ // allow to cancel "leftover" jobs upon error
+ // return function, invoking of which will abort this job
+ return clearTimeout.bind(null, timeoutId);
+}
+```
+
+More examples could be found in [test/test-parallel-array.js](test/test-parallel-array.js).
+
+#### Input Object
+
+Also it supports named jobs, listed via object.
+
+```javascript
+var parallel = require('asynckit/parallel')
+ , assert = require('assert')
+ ;
+
+var source = { first: 1, one: 1, four: 4, sixteen: 16, sixtyFour: 64, thirtyTwo: 32, eight: 8, two: 2 }
+ , expectedResult = { first: 2, one: 2, four: 8, sixteen: 32, sixtyFour: 128, thirtyTwo: 64, eight: 16, two: 4 }
+ , expectedTarget = [ 1, 1, 2, 4, 8, 16, 32, 64 ]
+ , expectedKeys = [ 'first', 'one', 'two', 'four', 'eight', 'sixteen', 'thirtyTwo', 'sixtyFour' ]
+ , target = []
+ , keys = []
+ ;
+
+parallel(source, asyncJob, function(err, result)
+{
+ assert.deepEqual(result, expectedResult);
+ assert.deepEqual(target, expectedTarget);
+ assert.deepEqual(keys, expectedKeys);
+});
+
+// supports full value, key, callback (shortcut) interface
+function asyncJob(item, key, cb)
+{
+ // different delays (in ms) per item
+ var delay = item * 25;
+
+ // pretend different jobs take different time to finish
+ // and not in consequential order
+ var timeoutId = setTimeout(function() {
+ keys.push(key);
+ target.push(item);
+ cb(null, item * 2);
+ }, delay);
+
+ // allow to cancel "leftover" jobs upon error
+ // return function, invoking of which will abort this job
+ return clearTimeout.bind(null, timeoutId);
+}
+```
+
+More examples could be found in [test/test-parallel-object.js](test/test-parallel-object.js).
+
+### Serial Jobs
+
+Runs iterator over provided array sequentially. Stores output in the `result` array,
+on the matching positions. In unlikely event of an error from one of the jobs,
+will not proceed to the rest of the items in the list
+and return error along with salvaged data to the main callback function.
+
+#### Input Array
+
+```javascript
+var serial = require('asynckit/serial')
+ , assert = require('assert')
+ ;
+
+var source = [ 1, 1, 4, 16, 64, 32, 8, 2 ]
+ , expectedResult = [ 2, 2, 8, 32, 128, 64, 16, 4 ]
+ , expectedTarget = [ 0, 1, 2, 3, 4, 5, 6, 7 ]
+ , target = []
+ ;
+
+serial(source, asyncJob, function(err, result)
+{
+ assert.deepEqual(result, expectedResult);
+ assert.deepEqual(target, expectedTarget);
+});
+
+// extended interface (item, key, callback)
+// also supported for arrays
+function asyncJob(item, key, cb)
+{
+ target.push(key);
+
+ // it will be automatically made async
+ // even it iterator "returns" in the same event loop
+ cb(null, item * 2);
+}
+```
+
+More examples could be found in [test/test-serial-array.js](test/test-serial-array.js).
+
+#### Input Object
+
+Also it supports named jobs, listed via object.
+
+```javascript
+var serial = require('asynckit').serial
+ , assert = require('assert')
+ ;
+
+var source = [ 1, 1, 4, 16, 64, 32, 8, 2 ]
+ , expectedResult = [ 2, 2, 8, 32, 128, 64, 16, 4 ]
+ , expectedTarget = [ 0, 1, 2, 3, 4, 5, 6, 7 ]
+ , target = []
+ ;
+
+var source = { first: 1, one: 1, four: 4, sixteen: 16, sixtyFour: 64, thirtyTwo: 32, eight: 8, two: 2 }
+ , expectedResult = { first: 2, one: 2, four: 8, sixteen: 32, sixtyFour: 128, thirtyTwo: 64, eight: 16, two: 4 }
+ , expectedTarget = [ 1, 1, 4, 16, 64, 32, 8, 2 ]
+ , target = []
+ ;
+
+
+serial(source, asyncJob, function(err, result)
+{
+ assert.deepEqual(result, expectedResult);
+ assert.deepEqual(target, expectedTarget);
+});
+
+// shortcut interface (item, callback)
+// works for object as well as for the arrays
+function asyncJob(item, cb)
+{
+ target.push(item);
+
+ // it will be automatically made async
+ // even it iterator "returns" in the same event loop
+ cb(null, item * 2);
+}
+```
+
+More examples could be found in [test/test-serial-object.js](test/test-serial-object.js).
+
+_Note: Since _object_ is an _unordered_ collection of properties,
+it may produce unexpected results with sequential iterations.
+Whenever order of the jobs' execution is important please use `serialOrdered` method._
+
+### Ordered Serial Iterations
+
+TBD
+
+For example [compare-property](compare-property) package.
+
+### Streaming interface
+
+TBD
+
+## Want to Know More?
+
+More examples can be found in [test folder](test/).
+
+Or open an [issue](https://github.com/alexindigo/asynckit/issues) with questions and/or suggestions.
+
+## License
+
+AsyncKit is licensed under the MIT license.
diff --git a/node_modules/fsevents/node_modules/asynckit/bench.js b/node_modules/fsevents/node_modules/asynckit/bench.js
new file mode 100644
index 00000000..c612f1a5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/bench.js
@@ -0,0 +1,76 @@
+/* eslint no-console: "off" */
+
+var asynckit = require('./')
+ , async = require('async')
+ , assert = require('assert')
+ , expected = 0
+ ;
+
+var Benchmark = require('benchmark');
+var suite = new Benchmark.Suite;
+
+var source = [];
+for (var z = 1; z < 100; z++)
+{
+ source.push(z);
+ expected += z;
+}
+
+suite
+// add tests
+
+.add('async.map', function(deferred)
+{
+ var total = 0;
+
+ async.map(source,
+ function(i, cb)
+ {
+ setImmediate(function()
+ {
+ total += i;
+ cb(null, total);
+ });
+ },
+ function(err, result)
+ {
+ assert.ifError(err);
+ assert.equal(result[result.length - 1], expected);
+ deferred.resolve();
+ });
+}, {'defer': true})
+
+
+.add('asynckit.parallel', function(deferred)
+{
+ var total = 0;
+
+ asynckit.parallel(source,
+ function(i, cb)
+ {
+ setImmediate(function()
+ {
+ total += i;
+ cb(null, total);
+ });
+ },
+ function(err, result)
+ {
+ assert.ifError(err);
+ assert.equal(result[result.length - 1], expected);
+ deferred.resolve();
+ });
+}, {'defer': true})
+
+
+// add listeners
+.on('cycle', function(ev)
+{
+ console.log(String(ev.target));
+})
+.on('complete', function()
+{
+ console.log('Fastest is ' + this.filter('fastest').map('name'));
+})
+// run async
+.run({ 'async': true });
diff --git a/node_modules/fsevents/node_modules/asynckit/index.js b/node_modules/fsevents/node_modules/asynckit/index.js
new file mode 100644
index 00000000..455f9454
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/index.js
@@ -0,0 +1,6 @@
+module.exports =
+{
+ parallel : require('./parallel.js'),
+ serial : require('./serial.js'),
+ serialOrdered : require('./serialOrdered.js')
+};
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/abort.js b/node_modules/fsevents/node_modules/asynckit/lib/abort.js
new file mode 100644
index 00000000..114367e5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/abort.js
@@ -0,0 +1,29 @@
+// API
+module.exports = abort;
+
+/**
+ * Aborts leftover active jobs
+ *
+ * @param {object} state - current state object
+ */
+function abort(state)
+{
+ Object.keys(state.jobs).forEach(clean.bind(state));
+
+ // reset leftover jobs
+ state.jobs = {};
+}
+
+/**
+ * Cleans up leftover job by invoking abort function for the provided job id
+ *
+ * @this state
+ * @param {string|number} key - job id to abort
+ */
+function clean(key)
+{
+ if (typeof this.jobs[key] == 'function')
+ {
+ this.jobs[key]();
+ }
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/async.js b/node_modules/fsevents/node_modules/asynckit/lib/async.js
new file mode 100644
index 00000000..7f1288a4
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/async.js
@@ -0,0 +1,34 @@
+var defer = require('./defer.js');
+
+// API
+module.exports = async;
+
+/**
+ * Runs provided callback asynchronously
+ * even if callback itself is not
+ *
+ * @param {function} callback - callback to invoke
+ * @returns {function} - augmented callback
+ */
+function async(callback)
+{
+ var isAsync = false;
+
+ // check if async happened
+ defer(function() { isAsync = true; });
+
+ return function async_callback(err, result)
+ {
+ if (isAsync)
+ {
+ callback(err, result);
+ }
+ else
+ {
+ defer(function nextTick_callback()
+ {
+ callback(err, result);
+ });
+ }
+ };
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/defer.js b/node_modules/fsevents/node_modules/asynckit/lib/defer.js
new file mode 100644
index 00000000..b67110c7
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/defer.js
@@ -0,0 +1,26 @@
+module.exports = defer;
+
+/**
+ * Runs provided function on next iteration of the event loop
+ *
+ * @param {function} fn - function to run
+ */
+function defer(fn)
+{
+ var nextTick = typeof setImmediate == 'function'
+ ? setImmediate
+ : (
+ typeof process == 'object' && typeof process.nextTick == 'function'
+ ? process.nextTick
+ : null
+ );
+
+ if (nextTick)
+ {
+ nextTick(fn);
+ }
+ else
+ {
+ setTimeout(fn, 0);
+ }
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/iterate.js b/node_modules/fsevents/node_modules/asynckit/lib/iterate.js
new file mode 100644
index 00000000..5d2839a5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/iterate.js
@@ -0,0 +1,75 @@
+var async = require('./async.js')
+ , abort = require('./abort.js')
+ ;
+
+// API
+module.exports = iterate;
+
+/**
+ * Iterates over each job object
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {object} state - current job status
+ * @param {function} callback - invoked when all elements processed
+ */
+function iterate(list, iterator, state, callback)
+{
+ // store current index
+ var key = state['keyedList'] ? state['keyedList'][state.index] : state.index;
+
+ state.jobs[key] = runJob(iterator, key, list[key], function(error, output)
+ {
+ // don't repeat yourself
+ // skip secondary callbacks
+ if (!(key in state.jobs))
+ {
+ return;
+ }
+
+ // clean up jobs
+ delete state.jobs[key];
+
+ if (error)
+ {
+ // don't process rest of the results
+ // stop still active jobs
+ // and reset the list
+ abort(state);
+ }
+ else
+ {
+ state.results[key] = output;
+ }
+
+ // return salvaged results
+ callback(error, state.results);
+ });
+}
+
+/**
+ * Runs iterator over provided job element
+ *
+ * @param {function} iterator - iterator to invoke
+ * @param {string|number} key - key/index of the element in the list of jobs
+ * @param {mixed} item - job description
+ * @param {function} callback - invoked after iterator is done with the job
+ * @returns {function|mixed} - job abort function or something else
+ */
+function runJob(iterator, key, item, callback)
+{
+ var aborter;
+
+ // allow shortcut if iterator expects only two arguments
+ if (iterator.length == 2)
+ {
+ aborter = iterator(item, async(callback));
+ }
+ // otherwise go with full three arguments
+ else
+ {
+ aborter = iterator(item, key, async(callback));
+ }
+
+ return aborter;
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/readable_asynckit.js b/node_modules/fsevents/node_modules/asynckit/lib/readable_asynckit.js
new file mode 100644
index 00000000..78ad240f
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/readable_asynckit.js
@@ -0,0 +1,91 @@
+var streamify = require('./streamify.js')
+ , defer = require('./defer.js')
+ ;
+
+// API
+module.exports = ReadableAsyncKit;
+
+/**
+ * Base constructor for all streams
+ * used to hold properties/methods
+ */
+function ReadableAsyncKit()
+{
+ ReadableAsyncKit.super_.apply(this, arguments);
+
+ // list of active jobs
+ this.jobs = {};
+
+ // add stream methods
+ this.destroy = destroy;
+ this._start = _start;
+ this._read = _read;
+}
+
+/**
+ * Destroys readable stream,
+ * by aborting outstanding jobs
+ *
+ * @returns {void}
+ */
+function destroy()
+{
+ if (this.destroyed)
+ {
+ return;
+ }
+
+ this.destroyed = true;
+
+ if (typeof this.terminator == 'function')
+ {
+ this.terminator();
+ }
+}
+
+/**
+ * Starts provided jobs in async manner
+ *
+ * @private
+ */
+function _start()
+{
+ // first argument – runner function
+ var runner = arguments[0]
+ // take away first argument
+ , args = Array.prototype.slice.call(arguments, 1)
+ // second argument - input data
+ , input = args[0]
+ // last argument - result callback
+ , endCb = streamify.callback.call(this, args[args.length - 1])
+ ;
+
+ args[args.length - 1] = endCb;
+ // third argument - iterator
+ args[1] = streamify.iterator.call(this, args[1]);
+
+ // allow time for proper setup
+ defer(function()
+ {
+ if (!this.destroyed)
+ {
+ this.terminator = runner.apply(null, args);
+ }
+ else
+ {
+ endCb(null, Array.isArray(input) ? [] : {});
+ }
+ }.bind(this));
+}
+
+
+/**
+ * Implement _read to comply with Readable streams
+ * Doesn't really make sense for flowing object mode
+ *
+ * @private
+ */
+function _read()
+{
+
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/readable_parallel.js b/node_modules/fsevents/node_modules/asynckit/lib/readable_parallel.js
new file mode 100644
index 00000000..5d2929f7
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/readable_parallel.js
@@ -0,0 +1,25 @@
+var parallel = require('../parallel.js');
+
+// API
+module.exports = ReadableParallel;
+
+/**
+ * Streaming wrapper to `asynckit.parallel`
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {function} callback - invoked when all elements processed
+ * @returns {stream.Readable#}
+ */
+function ReadableParallel(list, iterator, callback)
+{
+ if (!(this instanceof ReadableParallel))
+ {
+ return new ReadableParallel(list, iterator, callback);
+ }
+
+ // turn on object mode
+ ReadableParallel.super_.call(this, {objectMode: true});
+
+ this._start(parallel, list, iterator, callback);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/readable_serial.js b/node_modules/fsevents/node_modules/asynckit/lib/readable_serial.js
new file mode 100644
index 00000000..78226982
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/readable_serial.js
@@ -0,0 +1,25 @@
+var serial = require('../serial.js');
+
+// API
+module.exports = ReadableSerial;
+
+/**
+ * Streaming wrapper to `asynckit.serial`
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {function} callback - invoked when all elements processed
+ * @returns {stream.Readable#}
+ */
+function ReadableSerial(list, iterator, callback)
+{
+ if (!(this instanceof ReadableSerial))
+ {
+ return new ReadableSerial(list, iterator, callback);
+ }
+
+ // turn on object mode
+ ReadableSerial.super_.call(this, {objectMode: true});
+
+ this._start(serial, list, iterator, callback);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/readable_serial_ordered.js b/node_modules/fsevents/node_modules/asynckit/lib/readable_serial_ordered.js
new file mode 100644
index 00000000..3de89c47
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/readable_serial_ordered.js
@@ -0,0 +1,29 @@
+var serialOrdered = require('../serialOrdered.js');
+
+// API
+module.exports = ReadableSerialOrdered;
+// expose sort helpers
+module.exports.ascending = serialOrdered.ascending;
+module.exports.descending = serialOrdered.descending;
+
+/**
+ * Streaming wrapper to `asynckit.serialOrdered`
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {function} sortMethod - custom sort function
+ * @param {function} callback - invoked when all elements processed
+ * @returns {stream.Readable#}
+ */
+function ReadableSerialOrdered(list, iterator, sortMethod, callback)
+{
+ if (!(this instanceof ReadableSerialOrdered))
+ {
+ return new ReadableSerialOrdered(list, iterator, sortMethod, callback);
+ }
+
+ // turn on object mode
+ ReadableSerialOrdered.super_.call(this, {objectMode: true});
+
+ this._start(serialOrdered, list, iterator, sortMethod, callback);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/state.js b/node_modules/fsevents/node_modules/asynckit/lib/state.js
new file mode 100644
index 00000000..cbea7ad8
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/state.js
@@ -0,0 +1,37 @@
+// API
+module.exports = state;
+
+/**
+ * Creates initial state object
+ * for iteration over list
+ *
+ * @param {array|object} list - list to iterate over
+ * @param {function|null} sortMethod - function to use for keys sort,
+ * or `null` to keep them as is
+ * @returns {object} - initial state object
+ */
+function state(list, sortMethod)
+{
+ var isNamedList = !Array.isArray(list)
+ , initState =
+ {
+ index : 0,
+ keyedList: isNamedList || sortMethod ? Object.keys(list) : null,
+ jobs : {},
+ results : isNamedList ? {} : [],
+ size : isNamedList ? Object.keys(list).length : list.length
+ }
+ ;
+
+ if (sortMethod)
+ {
+ // sort array keys based on it's values
+ // sort object's keys just on own merit
+ initState.keyedList.sort(isNamedList ? sortMethod : function(a, b)
+ {
+ return sortMethod(list[a], list[b]);
+ });
+ }
+
+ return initState;
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/streamify.js b/node_modules/fsevents/node_modules/asynckit/lib/streamify.js
new file mode 100644
index 00000000..f56a1c92
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/streamify.js
@@ -0,0 +1,141 @@
+var async = require('./async.js');
+
+// API
+module.exports = {
+ iterator: wrapIterator,
+ callback: wrapCallback
+};
+
+/**
+ * Wraps iterators with long signature
+ *
+ * @this ReadableAsyncKit#
+ * @param {function} iterator - function to wrap
+ * @returns {function} - wrapped function
+ */
+function wrapIterator(iterator)
+{
+ var stream = this;
+
+ return function(item, key, cb)
+ {
+ var aborter
+ , wrappedCb = async(wrapIteratorCallback.call(stream, cb, key))
+ ;
+
+ stream.jobs[key] = wrappedCb;
+
+ // it's either shortcut (item, cb)
+ if (iterator.length == 2)
+ {
+ aborter = iterator(item, wrappedCb);
+ }
+ // or long format (item, key, cb)
+ else
+ {
+ aborter = iterator(item, key, wrappedCb);
+ }
+
+ return aborter;
+ };
+}
+
+/**
+ * Wraps provided callback function
+ * allowing to execute snitch function before
+ * real callback
+ *
+ * @this ReadableAsyncKit#
+ * @param {function} callback - function to wrap
+ * @returns {function} - wrapped function
+ */
+function wrapCallback(callback)
+{
+ var stream = this;
+
+ var wrapped = function(error, result)
+ {
+ return finisher.call(stream, error, result, callback);
+ };
+
+ return wrapped;
+}
+
+/**
+ * Wraps provided iterator callback function
+ * makes sure snitch only called once,
+ * but passes secondary calls to the original callback
+ *
+ * @this ReadableAsyncKit#
+ * @param {function} callback - callback to wrap
+ * @param {number|string} key - iteration key
+ * @returns {function} wrapped callback
+ */
+function wrapIteratorCallback(callback, key)
+{
+ var stream = this;
+
+ return function(error, output)
+ {
+ // don't repeat yourself
+ if (!(key in stream.jobs))
+ {
+ callback(error, output);
+ return;
+ }
+
+ // clean up jobs
+ delete stream.jobs[key];
+
+ return streamer.call(stream, error, {key: key, value: output}, callback);
+ };
+}
+
+/**
+ * Stream wrapper for iterator callback
+ *
+ * @this ReadableAsyncKit#
+ * @param {mixed} error - error response
+ * @param {mixed} output - iterator output
+ * @param {function} callback - callback that expects iterator results
+ */
+function streamer(error, output, callback)
+{
+ if (error && !this.error)
+ {
+ this.error = error;
+ this.pause();
+ this.emit('error', error);
+ // send back value only, as expected
+ callback(error, output && output.value);
+ return;
+ }
+
+ // stream stuff
+ this.push(output);
+
+ // back to original track
+ // send back value only, as expected
+ callback(error, output && output.value);
+}
+
+/**
+ * Stream wrapper for finishing callback
+ *
+ * @this ReadableAsyncKit#
+ * @param {mixed} error - error response
+ * @param {mixed} output - iterator output
+ * @param {function} callback - callback that expects final results
+ */
+function finisher(error, output, callback)
+{
+ // signal end of the stream
+ // only for successfully finished streams
+ if (!error)
+ {
+ this.push(null);
+ }
+
+ // back to original track
+ callback(error, output);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/lib/terminator.js b/node_modules/fsevents/node_modules/asynckit/lib/terminator.js
new file mode 100644
index 00000000..d6eb9921
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/lib/terminator.js
@@ -0,0 +1,29 @@
+var abort = require('./abort.js')
+ , async = require('./async.js')
+ ;
+
+// API
+module.exports = terminator;
+
+/**
+ * Terminates jobs in the attached state context
+ *
+ * @this AsyncKitState#
+ * @param {function} callback - final callback to invoke after termination
+ */
+function terminator(callback)
+{
+ if (!Object.keys(this.jobs).length)
+ {
+ return;
+ }
+
+ // fast forward iteration index
+ this.index = this.size;
+
+ // abort jobs
+ abort(this);
+
+ // send back results we have so far
+ async(callback)(null, this.results);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/package.json b/node_modules/fsevents/node_modules/asynckit/package.json
new file mode 100644
index 00000000..ddf472a8
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/package.json
@@ -0,0 +1,126 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "asynckit@^0.4.0",
+ "scope": null,
+ "escapedName": "asynckit",
+ "name": "asynckit",
+ "rawSpec": "^0.4.0",
+ "spec": ">=0.4.0 <0.5.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/form-data"
+ ]
+ ],
+ "_from": "asynckit@>=0.4.0 <0.5.0",
+ "_id": "asynckit@0.4.0",
+ "_inCache": true,
+ "_location": "/fsevents/asynckit",
+ "_nodeVersion": "0.12.11",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/asynckit-0.4.0.tgz_1465928940169_0.8008207362145185"
+ },
+ "_npmUser": {
+ "name": "alexindigo",
+ "email": "iam@alexindigo.com"
+ },
+ "_npmVersion": "2.15.6",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "asynckit@^0.4.0",
+ "scope": null,
+ "escapedName": "asynckit",
+ "name": "asynckit",
+ "rawSpec": "^0.4.0",
+ "spec": ">=0.4.0 <0.5.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/form-data"
+ ],
+ "_resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
+ "_shasum": "c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79",
+ "_shrinkwrap": null,
+ "_spec": "asynckit@^0.4.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/form-data",
+ "author": {
+ "name": "Alex Indigo",
+ "email": "iam@alexindigo.com"
+ },
+ "bugs": {
+ "url": "https://github.com/alexindigo/asynckit/issues"
+ },
+ "dependencies": {},
+ "description": "Minimal async jobs utility library, with streams support",
+ "devDependencies": {
+ "browserify": "^13.0.0",
+ "browserify-istanbul": "^2.0.0",
+ "coveralls": "^2.11.9",
+ "eslint": "^2.9.0",
+ "istanbul": "^0.4.3",
+ "obake": "^0.1.2",
+ "phantomjs-prebuilt": "^2.1.7",
+ "pre-commit": "^1.1.3",
+ "reamde": "^1.1.0",
+ "rimraf": "^2.5.2",
+ "size-table": "^0.2.0",
+ "tap-spec": "^4.1.1",
+ "tape": "^4.5.1"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79",
+ "tarball": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz"
+ },
+ "gitHead": "583a75ed4fe41761b66416bb6e703ebb1f8963bf",
+ "homepage": "https://github.com/alexindigo/asynckit#readme",
+ "keywords": [
+ "async",
+ "jobs",
+ "parallel",
+ "serial",
+ "iterator",
+ "array",
+ "object",
+ "stream",
+ "destroy",
+ "terminate",
+ "abort"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "alexindigo",
+ "email": "iam@alexindigo.com"
+ }
+ ],
+ "name": "asynckit",
+ "optionalDependencies": {},
+ "pre-commit": [
+ "clean",
+ "lint",
+ "test",
+ "browser",
+ "report",
+ "size"
+ ],
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/alexindigo/asynckit.git"
+ },
+ "scripts": {
+ "browser": "browserify -t browserify-istanbul test/lib/browserify_adjustment.js test/test-*.js | obake --coverage | tap-spec",
+ "clean": "rimraf coverage",
+ "debug": "tape test/test-*.js",
+ "lint": "eslint *.js lib/*.js test/*.js",
+ "report": "istanbul report",
+ "size": "browserify index.js | size-table asynckit",
+ "test": "istanbul cover --reporter=json tape -- 'test/test-*.js' | tap-spec",
+ "win-test": "tape test/test-*.js"
+ },
+ "version": "0.4.0"
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/parallel.js b/node_modules/fsevents/node_modules/asynckit/parallel.js
new file mode 100644
index 00000000..3c50344d
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/parallel.js
@@ -0,0 +1,43 @@
+var iterate = require('./lib/iterate.js')
+ , initState = require('./lib/state.js')
+ , terminator = require('./lib/terminator.js')
+ ;
+
+// Public API
+module.exports = parallel;
+
+/**
+ * Runs iterator over provided array elements in parallel
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {function} callback - invoked when all elements processed
+ * @returns {function} - jobs terminator
+ */
+function parallel(list, iterator, callback)
+{
+ var state = initState(list);
+
+ while (state.index < (state['keyedList'] || list).length)
+ {
+ iterate(list, iterator, state, function(error, result)
+ {
+ if (error)
+ {
+ callback(error, result);
+ return;
+ }
+
+ // looks like it's the last one
+ if (Object.keys(state.jobs).length === 0)
+ {
+ callback(null, state.results);
+ return;
+ }
+ });
+
+ state.index++;
+ }
+
+ return terminator.bind(state, callback);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/serial.js b/node_modules/fsevents/node_modules/asynckit/serial.js
new file mode 100644
index 00000000..6cd949a6
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/serial.js
@@ -0,0 +1,17 @@
+var serialOrdered = require('./serialOrdered.js');
+
+// Public API
+module.exports = serial;
+
+/**
+ * Runs iterator over provided array elements in series
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {function} callback - invoked when all elements processed
+ * @returns {function} - jobs terminator
+ */
+function serial(list, iterator, callback)
+{
+ return serialOrdered(list, iterator, null, callback);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/serialOrdered.js b/node_modules/fsevents/node_modules/asynckit/serialOrdered.js
new file mode 100644
index 00000000..607eafea
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/serialOrdered.js
@@ -0,0 +1,75 @@
+var iterate = require('./lib/iterate.js')
+ , initState = require('./lib/state.js')
+ , terminator = require('./lib/terminator.js')
+ ;
+
+// Public API
+module.exports = serialOrdered;
+// sorting helpers
+module.exports.ascending = ascending;
+module.exports.descending = descending;
+
+/**
+ * Runs iterator over provided sorted array elements in series
+ *
+ * @param {array|object} list - array or object (named list) to iterate over
+ * @param {function} iterator - iterator to run
+ * @param {function} sortMethod - custom sort function
+ * @param {function} callback - invoked when all elements processed
+ * @returns {function} - jobs terminator
+ */
+function serialOrdered(list, iterator, sortMethod, callback)
+{
+ var state = initState(list, sortMethod);
+
+ iterate(list, iterator, state, function iteratorHandler(error, result)
+ {
+ if (error)
+ {
+ callback(error, result);
+ return;
+ }
+
+ state.index++;
+
+ // are we there yet?
+ if (state.index < (state['keyedList'] || list).length)
+ {
+ iterate(list, iterator, state, iteratorHandler);
+ return;
+ }
+
+ // done here
+ callback(null, state.results);
+ });
+
+ return terminator.bind(state, callback);
+}
+
+/*
+ * -- Sort methods
+ */
+
+/**
+ * sort helper to sort array elements in ascending order
+ *
+ * @param {mixed} a - an item to compare
+ * @param {mixed} b - an item to compare
+ * @returns {number} - comparison result
+ */
+function ascending(a, b)
+{
+ return a < b ? -1 : a > b ? 1 : 0;
+}
+
+/**
+ * sort helper to sort array elements in descending order
+ *
+ * @param {mixed} a - an item to compare
+ * @param {mixed} b - an item to compare
+ * @returns {number} - comparison result
+ */
+function descending(a, b)
+{
+ return -1 * ascending(a, b);
+}
diff --git a/node_modules/fsevents/node_modules/asynckit/stream.js b/node_modules/fsevents/node_modules/asynckit/stream.js
new file mode 100644
index 00000000..d43465f9
--- /dev/null
+++ b/node_modules/fsevents/node_modules/asynckit/stream.js
@@ -0,0 +1,21 @@
+var inherits = require('util').inherits
+ , Readable = require('stream').Readable
+ , ReadableAsyncKit = require('./lib/readable_asynckit.js')
+ , ReadableParallel = require('./lib/readable_parallel.js')
+ , ReadableSerial = require('./lib/readable_serial.js')
+ , ReadableSerialOrdered = require('./lib/readable_serial_ordered.js')
+ ;
+
+// API
+module.exports =
+{
+ parallel : ReadableParallel,
+ serial : ReadableSerial,
+ serialOrdered : ReadableSerialOrdered,
+};
+
+inherits(ReadableAsyncKit, Readable);
+
+inherits(ReadableParallel, ReadableAsyncKit);
+inherits(ReadableSerial, ReadableAsyncKit);
+inherits(ReadableSerialOrdered, ReadableAsyncKit);
diff --git a/node_modules/fsevents/node_modules/aws-sign2/LICENSE b/node_modules/fsevents/node_modules/aws-sign2/LICENSE
new file mode 100644
index 00000000..a4a9aee0
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws-sign2/LICENSE
@@ -0,0 +1,55 @@
+Apache License
+
+Version 2.0, January 2004
+
+http://www.apache.org/licenses/
+
+TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+1. Definitions.
+
+"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
+
+"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
+
+"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
+
+"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
+
+"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
+
+"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
+
+"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
+
+"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
+
+"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
+
+"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
+
+2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
+
+3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
+
+4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
+
+You must give any other recipients of the Work or Derivative Works a copy of this License; and
+
+You must cause any modified files to carry prominent notices stating that You changed the files; and
+
+You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
+
+If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
+
+5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
+
+6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
+
+7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
+
+8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
+
+9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
+
+END OF TERMS AND CONDITIONS
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/aws-sign2/README.md b/node_modules/fsevents/node_modules/aws-sign2/README.md
new file mode 100644
index 00000000..763564e0
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws-sign2/README.md
@@ -0,0 +1,4 @@
+aws-sign
+========
+
+AWS signing. Originally pulled from LearnBoost/knox, maintained as vendor in request, now a standalone module.
diff --git a/node_modules/fsevents/node_modules/aws-sign2/index.js b/node_modules/fsevents/node_modules/aws-sign2/index.js
new file mode 100644
index 00000000..ac720930
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws-sign2/index.js
@@ -0,0 +1,212 @@
+
+/*!
+ * Copyright 2010 LearnBoost
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * Module dependencies.
+ */
+
+var crypto = require('crypto')
+ , parse = require('url').parse
+ ;
+
+/**
+ * Valid keys.
+ */
+
+var keys =
+ [ 'acl'
+ , 'location'
+ , 'logging'
+ , 'notification'
+ , 'partNumber'
+ , 'policy'
+ , 'requestPayment'
+ , 'torrent'
+ , 'uploadId'
+ , 'uploads'
+ , 'versionId'
+ , 'versioning'
+ , 'versions'
+ , 'website'
+ ]
+
+/**
+ * Return an "Authorization" header value with the given `options`
+ * in the form of "AWS :"
+ *
+ * @param {Object} options
+ * @return {String}
+ * @api private
+ */
+
+function authorization (options) {
+ return 'AWS ' + options.key + ':' + sign(options)
+}
+
+module.exports = authorization
+module.exports.authorization = authorization
+
+/**
+ * Simple HMAC-SHA1 Wrapper
+ *
+ * @param {Object} options
+ * @return {String}
+ * @api private
+ */
+
+function hmacSha1 (options) {
+ return crypto.createHmac('sha1', options.secret).update(options.message).digest('base64')
+}
+
+module.exports.hmacSha1 = hmacSha1
+
+/**
+ * Create a base64 sha1 HMAC for `options`.
+ *
+ * @param {Object} options
+ * @return {String}
+ * @api private
+ */
+
+function sign (options) {
+ options.message = stringToSign(options)
+ return hmacSha1(options)
+}
+module.exports.sign = sign
+
+/**
+ * Create a base64 sha1 HMAC for `options`.
+ *
+ * Specifically to be used with S3 presigned URLs
+ *
+ * @param {Object} options
+ * @return {String}
+ * @api private
+ */
+
+function signQuery (options) {
+ options.message = queryStringToSign(options)
+ return hmacSha1(options)
+}
+module.exports.signQuery= signQuery
+
+/**
+ * Return a string for sign() with the given `options`.
+ *
+ * Spec:
+ *
+ * \n
+ * \n
+ * \n
+ * \n
+ * [headers\n]
+ *
+ *
+ * @param {Object} options
+ * @return {String}
+ * @api private
+ */
+
+function stringToSign (options) {
+ var headers = options.amazonHeaders || ''
+ if (headers) headers += '\n'
+ var r =
+ [ options.verb
+ , options.md5
+ , options.contentType
+ , options.date ? options.date.toUTCString() : ''
+ , headers + options.resource
+ ]
+ return r.join('\n')
+}
+module.exports.queryStringToSign = stringToSign
+
+/**
+ * Return a string for sign() with the given `options`, but is meant exclusively
+ * for S3 presigned URLs
+ *
+ * Spec:
+ *
+ * \n
+ *
+ *
+ * @param {Object} options
+ * @return {String}
+ * @api private
+ */
+
+function queryStringToSign (options){
+ return 'GET\n\n\n' + options.date + '\n' + options.resource
+}
+module.exports.queryStringToSign = queryStringToSign
+
+/**
+ * Perform the following:
+ *
+ * - ignore non-amazon headers
+ * - lowercase fields
+ * - sort lexicographically
+ * - trim whitespace between ":"
+ * - join with newline
+ *
+ * @param {Object} headers
+ * @return {String}
+ * @api private
+ */
+
+function canonicalizeHeaders (headers) {
+ var buf = []
+ , fields = Object.keys(headers)
+ ;
+ for (var i = 0, len = fields.length; i < len; ++i) {
+ var field = fields[i]
+ , val = headers[field]
+ , field = field.toLowerCase()
+ ;
+ if (0 !== field.indexOf('x-amz')) continue
+ buf.push(field + ':' + val)
+ }
+ return buf.sort().join('\n')
+}
+module.exports.canonicalizeHeaders = canonicalizeHeaders
+
+/**
+ * Perform the following:
+ *
+ * - ignore non sub-resources
+ * - sort lexicographically
+ *
+ * @param {String} resource
+ * @return {String}
+ * @api private
+ */
+
+function canonicalizeResource (resource) {
+ var url = parse(resource, true)
+ , path = url.pathname
+ , buf = []
+ ;
+
+ Object.keys(url.query).forEach(function(key){
+ if (!~keys.indexOf(key)) return
+ var val = '' == url.query[key] ? '' : '=' + encodeURIComponent(url.query[key])
+ buf.push(key + val)
+ })
+
+ return path + (buf.length ? '?' + buf.sort().join('&') : '')
+}
+module.exports.canonicalizeResource = canonicalizeResource
diff --git a/node_modules/fsevents/node_modules/aws-sign2/package.json b/node_modules/fsevents/node_modules/aws-sign2/package.json
new file mode 100644
index 00000000..8ce47ff6
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws-sign2/package.json
@@ -0,0 +1,81 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "aws-sign2@~0.6.0",
+ "scope": null,
+ "escapedName": "aws-sign2",
+ "name": "aws-sign2",
+ "rawSpec": "~0.6.0",
+ "spec": ">=0.6.0 <0.7.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/request"
+ ]
+ ],
+ "_from": "aws-sign2@>=0.6.0 <0.7.0",
+ "_id": "aws-sign2@0.6.0",
+ "_inCache": true,
+ "_location": "/fsevents/aws-sign2",
+ "_nodeVersion": "4.1.2",
+ "_npmUser": {
+ "name": "mikeal",
+ "email": "mikeal.rogers@gmail.com"
+ },
+ "_npmVersion": "2.14.4",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "aws-sign2@~0.6.0",
+ "scope": null,
+ "escapedName": "aws-sign2",
+ "name": "aws-sign2",
+ "rawSpec": "~0.6.0",
+ "spec": ">=0.6.0 <0.7.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/request"
+ ],
+ "_resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.6.0.tgz",
+ "_shasum": "14342dd38dbcc94d0e5b87d763cd63612c0e794f",
+ "_shrinkwrap": null,
+ "_spec": "aws-sign2@~0.6.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/request",
+ "author": {
+ "name": "Mikeal Rogers",
+ "email": "mikeal.rogers@gmail.com",
+ "url": "http://www.futurealoof.com"
+ },
+ "bugs": {
+ "url": "https://github.com/mikeal/aws-sign/issues"
+ },
+ "dependencies": {},
+ "description": "AWS signing. Originally pulled from LearnBoost/knox, maintained as vendor in request, now a standalone module.",
+ "devDependencies": {},
+ "directories": {},
+ "dist": {
+ "shasum": "14342dd38dbcc94d0e5b87d763cd63612c0e794f",
+ "tarball": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.6.0.tgz"
+ },
+ "engines": {
+ "node": "*"
+ },
+ "gitHead": "8554bdb41268fa295eb1ee300f4adaa9f7f07fec",
+ "homepage": "https://github.com/mikeal/aws-sign#readme",
+ "license": "Apache-2.0",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "mikeal",
+ "email": "mikeal.rogers@gmail.com"
+ }
+ ],
+ "name": "aws-sign2",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "url": "git+https://github.com/mikeal/aws-sign.git"
+ },
+ "scripts": {},
+ "version": "0.6.0"
+}
diff --git a/node_modules/fsevents/node_modules/aws4/.npmignore b/node_modules/fsevents/node_modules/aws4/.npmignore
new file mode 100644
index 00000000..6c6ade6f
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/.npmignore
@@ -0,0 +1,4 @@
+test
+examples
+example.js
+browser
diff --git a/node_modules/fsevents/node_modules/aws4/.tern-port b/node_modules/fsevents/node_modules/aws4/.tern-port
new file mode 100644
index 00000000..7fd1b522
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/.tern-port
@@ -0,0 +1 @@
+62638
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/aws4/.travis.yml b/node_modules/fsevents/node_modules/aws4/.travis.yml
new file mode 100644
index 00000000..61d06340
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/.travis.yml
@@ -0,0 +1,5 @@
+language: node_js
+node_js:
+ - "0.10"
+ - "0.12"
+ - "4.2"
diff --git a/node_modules/fsevents/node_modules/aws4/LICENSE b/node_modules/fsevents/node_modules/aws4/LICENSE
new file mode 100644
index 00000000..4f321e59
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/LICENSE
@@ -0,0 +1,19 @@
+Copyright 2013 Michael Hart (michael.hart.au@gmail.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+of the Software, and to permit persons to whom the Software is furnished to do
+so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/aws4/README.md b/node_modules/fsevents/node_modules/aws4/README.md
new file mode 100644
index 00000000..6b002d02
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/README.md
@@ -0,0 +1,523 @@
+aws4
+----
+
+[](http://travis-ci.org/mhart/aws4)
+
+A small utility to sign vanilla node.js http(s) request options using Amazon's
+[AWS Signature Version 4](http://docs.amazonwebservices.com/general/latest/gr/signature-version-4.html).
+
+Can also be used [in the browser](./browser).
+
+This signature is supported by nearly all Amazon services, including
+[S3](http://docs.aws.amazon.com/AmazonS3/latest/API/),
+[EC2](http://docs.aws.amazon.com/AWSEC2/latest/APIReference/),
+[DynamoDB](http://docs.aws.amazon.com/amazondynamodb/latest/developerguide/API.html),
+[Kinesis](http://docs.aws.amazon.com/kinesis/latest/APIReference/),
+[Lambda](http://docs.aws.amazon.com/lambda/latest/dg/API_Reference.html),
+[SQS](http://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/),
+[SNS](http://docs.aws.amazon.com/sns/latest/api/),
+[IAM](http://docs.aws.amazon.com/IAM/latest/APIReference/),
+[STS](http://docs.aws.amazon.com/STS/latest/APIReference/),
+[RDS](http://docs.aws.amazon.com/AmazonRDS/latest/APIReference/),
+[CloudWatch](http://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/),
+[CloudWatch Logs](http://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/),
+[CodeDeploy](http://docs.aws.amazon.com/codedeploy/latest/APIReference/),
+[CloudFront](http://docs.aws.amazon.com/AmazonCloudFront/latest/APIReference/),
+[CloudTrail](http://docs.aws.amazon.com/awscloudtrail/latest/APIReference/),
+[ElastiCache](http://docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/),
+[EMR](http://docs.aws.amazon.com/ElasticMapReduce/latest/API/),
+[Glacier](http://docs.aws.amazon.com/amazonglacier/latest/dev/amazon-glacier-api.html),
+[CloudSearch](http://docs.aws.amazon.com/cloudsearch/latest/developerguide/APIReq.html),
+[Elastic Load Balancing](http://docs.aws.amazon.com/ElasticLoadBalancing/latest/APIReference/),
+[Elastic Transcoder](http://docs.aws.amazon.com/elastictranscoder/latest/developerguide/api-reference.html),
+[CloudFormation](http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/),
+[Elastic Beanstalk](http://docs.aws.amazon.com/elasticbeanstalk/latest/api/),
+[Storage Gateway](http://docs.aws.amazon.com/storagegateway/latest/userguide/AWSStorageGatewayAPI.html),
+[Data Pipeline](http://docs.aws.amazon.com/datapipeline/latest/APIReference/),
+[Direct Connect](http://docs.aws.amazon.com/directconnect/latest/APIReference/),
+[Redshift](http://docs.aws.amazon.com/redshift/latest/APIReference/),
+[OpsWorks](http://docs.aws.amazon.com/opsworks/latest/APIReference/),
+[SES](http://docs.aws.amazon.com/ses/latest/APIReference/),
+[SWF](http://docs.aws.amazon.com/amazonswf/latest/apireference/),
+[AutoScaling](http://docs.aws.amazon.com/AutoScaling/latest/APIReference/),
+[Mobile Analytics](http://docs.aws.amazon.com/mobileanalytics/latest/ug/server-reference.html),
+[Cognito Identity](http://docs.aws.amazon.com/cognitoidentity/latest/APIReference/),
+[Cognito Sync](http://docs.aws.amazon.com/cognitosync/latest/APIReference/),
+[Container Service](http://docs.aws.amazon.com/AmazonECS/latest/APIReference/),
+[AppStream](http://docs.aws.amazon.com/appstream/latest/developerguide/appstream-api-rest.html),
+[Key Management Service](http://docs.aws.amazon.com/kms/latest/APIReference/),
+[Config](http://docs.aws.amazon.com/config/latest/APIReference/),
+[CloudHSM](http://docs.aws.amazon.com/cloudhsm/latest/dg/api-ref.html),
+[Route53](http://docs.aws.amazon.com/Route53/latest/APIReference/requests-rest.html) and
+[Route53 Domains](http://docs.aws.amazon.com/Route53/latest/APIReference/requests-rpc.html).
+
+Indeed, the only AWS services that *don't* support v4 as of 2014-12-30 are
+[Import/Export](http://docs.aws.amazon.com/AWSImportExport/latest/DG/api-reference.html) and
+[SimpleDB](http://docs.aws.amazon.com/AmazonSimpleDB/latest/DeveloperGuide/SDB_API.html)
+(they only support [AWS Signature Version 2](https://github.com/mhart/aws2)).
+
+It also provides defaults for a number of core AWS headers and
+request parameters, making it very easy to query AWS services, or
+build out a fully-featured AWS library.
+
+Example
+-------
+
+```javascript
+var http = require('http'),
+ https = require('https'),
+ aws4 = require('aws4')
+
+// given an options object you could pass to http.request
+var opts = {host: 'sqs.us-east-1.amazonaws.com', path: '/?Action=ListQueues'}
+
+// alternatively (as aws4 can infer the host):
+opts = {service: 'sqs', region: 'us-east-1', path: '/?Action=ListQueues'}
+
+// alternatively (as us-east-1 is default):
+opts = {service: 'sqs', path: '/?Action=ListQueues'}
+
+aws4.sign(opts) // assumes AWS credentials are available in process.env
+
+console.log(opts)
+/*
+{
+ host: 'sqs.us-east-1.amazonaws.com',
+ path: '/?Action=ListQueues',
+ headers: {
+ Host: 'sqs.us-east-1.amazonaws.com',
+ 'X-Amz-Date': '20121226T061030Z',
+ Authorization: 'AWS4-HMAC-SHA256 Credential=ABCDEF/20121226/us-east-1/sqs/aws4_request, ...'
+ }
+}
+*/
+
+// we can now use this to query AWS using the standard node.js http API
+http.request(opts, function(res) { res.pipe(process.stdout) }).end()
+/*
+
+
+...
+*/
+```
+
+More options
+------------
+
+```javascript
+// you can also pass AWS credentials in explicitly (otherwise taken from process.env)
+aws4.sign(opts, {accessKeyId: '', secretAccessKey: ''})
+
+// can also add the signature to query strings
+aws4.sign({service: 's3', path: '/my-bucket?X-Amz-Expires=12345', signQuery: true})
+
+// create a utility function to pipe to stdout (with https this time)
+function request(o) { https.request(o, function(res) { res.pipe(process.stdout) }).end(o.body || '') }
+
+// aws4 can infer the HTTP method if a body is passed in
+// method will be POST and Content-Type: 'application/x-www-form-urlencoded; charset=utf-8'
+request(aws4.sign({service: 'iam', body: 'Action=ListGroups&Version=2010-05-08'}))
+/*
+
+...
+*/
+
+// can specify any custom option or header as per usual
+request(aws4.sign({
+ service: 'dynamodb',
+ region: 'ap-southeast-2',
+ method: 'POST',
+ path: '/',
+ headers: {
+ 'Content-Type': 'application/x-amz-json-1.0',
+ 'X-Amz-Target': 'DynamoDB_20120810.ListTables'
+ },
+ body: '{}'
+}))
+/*
+{"TableNames":[]}
+...
+*/
+
+// works with all other services that support Signature Version 4
+
+request(aws4.sign({service: 's3', path: '/', signQuery: true}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'ec2', path: '/?Action=DescribeRegions&Version=2014-06-15'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'sns', path: '/?Action=ListTopics&Version=2010-03-31'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'sts', path: '/?Action=GetSessionToken&Version=2011-06-15'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'cloudsearch', path: '/?Action=ListDomainNames&Version=2013-01-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'ses', path: '/?Action=ListIdentities&Version=2010-12-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'autoscaling', path: '/?Action=DescribeAutoScalingInstances&Version=2011-01-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'elasticloadbalancing', path: '/?Action=DescribeLoadBalancers&Version=2012-06-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'cloudformation', path: '/?Action=ListStacks&Version=2010-05-15'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'elasticbeanstalk', path: '/?Action=ListAvailableSolutionStacks&Version=2010-12-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'rds', path: '/?Action=DescribeDBInstances&Version=2012-09-17'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'monitoring', path: '/?Action=ListMetrics&Version=2010-08-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'redshift', path: '/?Action=DescribeClusters&Version=2012-12-01'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'cloudfront', path: '/2014-05-31/distribution'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'elasticache', path: '/?Action=DescribeCacheClusters&Version=2014-07-15'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'elasticmapreduce', path: '/?Action=DescribeJobFlows&Version=2009-03-31'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'route53', path: '/2013-04-01/hostedzone'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'appstream', path: '/applications'}))
+/*
+{"_links":{"curie":[{"href":"http://docs.aws.amazon.com/appstream/latest/...
+...
+*/
+
+request(aws4.sign({service: 'cognito-sync', path: '/identitypools'}))
+/*
+{"Count":0,"IdentityPoolUsages":[],"MaxResults":16,"NextToken":null}
+...
+*/
+
+request(aws4.sign({service: 'elastictranscoder', path: '/2012-09-25/pipelines'}))
+/*
+{"NextPageToken":null,"Pipelines":[]}
+...
+*/
+
+request(aws4.sign({service: 'lambda', path: '/2014-11-13/functions/'}))
+/*
+{"Functions":[],"NextMarker":null}
+...
+*/
+
+request(aws4.sign({service: 'ecs', path: '/?Action=ListClusters&Version=2014-11-13'}))
+/*
+
+...
+*/
+
+request(aws4.sign({service: 'glacier', path: '/-/vaults', headers: {'X-Amz-Glacier-Version': '2012-06-01'}}))
+/*
+{"Marker":null,"VaultList":[]}
+...
+*/
+
+request(aws4.sign({service: 'storagegateway', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'StorageGateway_20120630.ListGateways'
+}}))
+/*
+{"Gateways":[]}
+...
+*/
+
+request(aws4.sign({service: 'datapipeline', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'DataPipeline.ListPipelines'
+}}))
+/*
+{"hasMoreResults":false,"pipelineIdList":[]}
+...
+*/
+
+request(aws4.sign({service: 'opsworks', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'OpsWorks_20130218.DescribeStacks'
+}}))
+/*
+{"Stacks":[]}
+...
+*/
+
+request(aws4.sign({service: 'route53domains', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'Route53Domains_v20140515.ListDomains'
+}}))
+/*
+{"Domains":[]}
+...
+*/
+
+request(aws4.sign({service: 'kinesis', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'Kinesis_20131202.ListStreams'
+}}))
+/*
+{"HasMoreStreams":false,"StreamNames":[]}
+...
+*/
+
+request(aws4.sign({service: 'cloudtrail', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'CloudTrail_20131101.DescribeTrails'
+}}))
+/*
+{"trailList":[]}
+...
+*/
+
+request(aws4.sign({service: 'logs', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'Logs_20140328.DescribeLogGroups'
+}}))
+/*
+{"logGroups":[]}
+...
+*/
+
+request(aws4.sign({service: 'codedeploy', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'CodeDeploy_20141006.ListApplications'
+}}))
+/*
+{"applications":[]}
+...
+*/
+
+request(aws4.sign({service: 'directconnect', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'OvertureService.DescribeConnections'
+}}))
+/*
+{"connections":[]}
+...
+*/
+
+request(aws4.sign({service: 'kms', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'TrentService.ListKeys'
+}}))
+/*
+{"Keys":[],"Truncated":false}
+...
+*/
+
+request(aws4.sign({service: 'config', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'StarlingDoveService.DescribeDeliveryChannels'
+}}))
+/*
+{"DeliveryChannels":[]}
+...
+*/
+
+request(aws4.sign({service: 'cloudhsm', body: '{}', headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'CloudHsmFrontendService.ListAvailableZones'
+}}))
+/*
+{"AZList":["us-east-1a","us-east-1b","us-east-1c"]}
+...
+*/
+
+request(aws4.sign({
+ service: 'swf',
+ body: '{"registrationStatus":"REGISTERED"}',
+ headers: {
+ 'Content-Type': 'application/x-amz-json-1.0',
+ 'X-Amz-Target': 'SimpleWorkflowService.ListDomains'
+ }
+}))
+/*
+{"domainInfos":[]}
+...
+*/
+
+request(aws4.sign({
+ service: 'cognito-identity',
+ body: '{"MaxResults": 1}',
+ headers: {
+ 'Content-Type': 'application/x-amz-json-1.1',
+ 'X-Amz-Target': 'AWSCognitoIdentityService.ListIdentityPools'
+ }
+}))
+/*
+{"IdentityPools":[]}
+...
+*/
+
+request(aws4.sign({
+ service: 'mobileanalytics',
+ path: '/2014-06-05/events',
+ body: JSON.stringify({events:[{
+ eventType: 'a',
+ timestamp: new Date().toISOString(),
+ session: {},
+ }]}),
+ headers: {
+ 'Content-Type': 'application/json',
+ 'X-Amz-Client-Context': JSON.stringify({
+ client: {client_id: 'a', app_title: 'a'},
+ custom: {},
+ env: {platform: 'a'},
+ services: {},
+ }),
+ }
+}))
+/*
+(HTTP 202, empty response)
+*/
+
+// Generate CodeCommit Git access password
+var signer = new aws4.RequestSigner({
+ service: 'codecommit',
+ host: 'git-codecommit.us-east-1.amazonaws.com',
+ method: 'GIT',
+ path: '/v1/repos/MyAwesomeRepo',
+})
+var password = signer.getDateTime() + 'Z' + signer.signature()
+```
+
+API
+---
+
+### aws4.sign(requestOptions, [credentials])
+
+This calculates and populates the `Authorization` header of
+`requestOptions`, and any other necessary AWS headers and/or request
+options. Returns `requestOptions` as a convenience for chaining.
+
+`requestOptions` is an object holding the same options that the node.js
+[http.request](http://nodejs.org/docs/latest/api/http.html#http_http_request_options_callback)
+function takes.
+
+The following properties of `requestOptions` are used in the signing or
+populated if they don't already exist:
+
+- `hostname` or `host` (will be determined from `service` and `region` if not given)
+- `method` (will use `'GET'` if not given or `'POST'` if there is a `body`)
+- `path` (will use `'/'` if not given)
+- `body` (will use `''` if not given)
+- `service` (will be calculated from `hostname` or `host` if not given)
+- `region` (will be calculated from `hostname` or `host` or use `'us-east-1'` if not given)
+- `headers['Host']` (will use `hostname` or `host` or be calculated if not given)
+- `headers['Content-Type']` (will use `'application/x-www-form-urlencoded; charset=utf-8'`
+ if not given and there is a `body`)
+- `headers['Date']` (used to calculate the signature date if given, otherwise `new Date` is used)
+
+Your AWS credentials (which can be found in your
+[AWS console](https://portal.aws.amazon.com/gp/aws/securityCredentials))
+can be specified in one of two ways:
+
+- As the second argument, like this:
+
+```javascript
+aws4.sign(requestOptions, {
+ secretAccessKey: "",
+ accessKeyId: "",
+ sessionToken: ""
+})
+```
+
+- From `process.env`, such as this:
+
+```
+export AWS_SECRET_ACCESS_KEY=""
+export AWS_ACCESS_KEY_ID=""
+export AWS_SESSION_TOKEN=""
+```
+
+(will also use `AWS_ACCESS_KEY` and `AWS_SECRET_KEY` if available)
+
+The `sessionToken` property and `AWS_SESSION_TOKEN` environment variable are optional for signing
+with [IAM STS temporary credentials](http://docs.aws.amazon.com/STS/latest/UsingSTS/using-temp-creds.html).
+
+Installation
+------------
+
+With [npm](http://npmjs.org/) do:
+
+```
+npm install aws4
+```
+
+Can also be used [in the browser](./browser).
+
+Thanks
+------
+
+Thanks to [@jed](https://github.com/jed) for his
+[dynamo-client](https://github.com/jed/dynamo-client) lib where I first
+committed and subsequently extracted this code.
+
+Also thanks to the
+[official node.js AWS SDK](https://github.com/aws/aws-sdk-js) for giving
+me a start on implementing the v4 signature.
+
diff --git a/node_modules/fsevents/node_modules/aws4/aws4.js b/node_modules/fsevents/node_modules/aws4/aws4.js
new file mode 100644
index 00000000..a5431806
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/aws4.js
@@ -0,0 +1,323 @@
+var aws4 = exports,
+ url = require('url'),
+ querystring = require('querystring'),
+ crypto = require('crypto'),
+ lru = require('./lru'),
+ credentialsCache = lru(1000)
+
+// http://docs.amazonwebservices.com/general/latest/gr/signature-version-4.html
+
+function hmac(key, string, encoding) {
+ return crypto.createHmac('sha256', key).update(string, 'utf8').digest(encoding)
+}
+
+function hash(string, encoding) {
+ return crypto.createHash('sha256').update(string, 'utf8').digest(encoding)
+}
+
+// This function assumes the string has already been percent encoded
+function encodeRfc3986(urlEncodedString) {
+ return urlEncodedString.replace(/[!'()*]/g, function(c) {
+ return '%' + c.charCodeAt(0).toString(16).toUpperCase()
+ })
+}
+
+// request: { path | body, [host], [method], [headers], [service], [region] }
+// credentials: { accessKeyId, secretAccessKey, [sessionToken] }
+function RequestSigner(request, credentials) {
+
+ if (typeof request === 'string') request = url.parse(request)
+
+ var headers = request.headers = (request.headers || {}),
+ hostParts = this.matchHost(request.hostname || request.host || headers.Host || headers.host)
+
+ this.request = request
+ this.credentials = credentials || this.defaultCredentials()
+
+ this.service = request.service || hostParts[0] || ''
+ this.region = request.region || hostParts[1] || 'us-east-1'
+
+ // SES uses a different domain from the service name
+ if (this.service === 'email') this.service = 'ses'
+
+ if (!request.method && request.body)
+ request.method = 'POST'
+
+ if (!headers.Host && !headers.host) {
+ headers.Host = request.hostname || request.host || this.createHost()
+
+ // If a port is specified explicitly, use it as is
+ if (request.port)
+ headers.Host += ':' + request.port
+ }
+ if (!request.hostname && !request.host)
+ request.hostname = headers.Host || headers.host
+
+ this.isCodeCommitGit = this.service === 'codecommit' && request.method === 'GIT'
+}
+
+RequestSigner.prototype.matchHost = function(host) {
+ var match = (host || '').match(/([^\.]+)\.(?:([^\.]*)\.)?amazonaws\.com$/)
+ var hostParts = (match || []).slice(1, 3)
+
+ // ES's hostParts are sometimes the other way round, if the value that is expected
+ // to be region equals ‘es’ switch them back
+ // e.g. search-cluster-name-aaaa00aaaa0aaa0aaaaaaa0aaa.us-east-1.es.amazonaws.com
+ if (hostParts[1] === 'es')
+ hostParts = hostParts.reverse()
+
+ return hostParts
+}
+
+// http://docs.aws.amazon.com/general/latest/gr/rande.html
+RequestSigner.prototype.isSingleRegion = function() {
+ // Special case for S3 and SimpleDB in us-east-1
+ if (['s3', 'sdb'].indexOf(this.service) >= 0 && this.region === 'us-east-1') return true
+
+ return ['cloudfront', 'ls', 'route53', 'iam', 'importexport', 'sts']
+ .indexOf(this.service) >= 0
+}
+
+RequestSigner.prototype.createHost = function() {
+ var region = this.isSingleRegion() ? '' :
+ (this.service === 's3' && this.region !== 'us-east-1' ? '-' : '.') + this.region,
+ service = this.service === 'ses' ? 'email' : this.service
+ return service + region + '.amazonaws.com'
+}
+
+RequestSigner.prototype.prepareRequest = function() {
+ this.parsePath()
+
+ var request = this.request, headers = request.headers, query
+
+ if (request.signQuery) {
+
+ this.parsedPath.query = query = this.parsedPath.query || {}
+
+ if (this.credentials.sessionToken)
+ query['X-Amz-Security-Token'] = this.credentials.sessionToken
+
+ if (this.service === 's3' && !query['X-Amz-Expires'])
+ query['X-Amz-Expires'] = 86400
+
+ if (query['X-Amz-Date'])
+ this.datetime = query['X-Amz-Date']
+ else
+ query['X-Amz-Date'] = this.getDateTime()
+
+ query['X-Amz-Algorithm'] = 'AWS4-HMAC-SHA256'
+ query['X-Amz-Credential'] = this.credentials.accessKeyId + '/' + this.credentialString()
+ query['X-Amz-SignedHeaders'] = this.signedHeaders()
+
+ } else {
+
+ if (!request.doNotModifyHeaders && !this.isCodeCommitGit) {
+ if (request.body && !headers['Content-Type'] && !headers['content-type'])
+ headers['Content-Type'] = 'application/x-www-form-urlencoded; charset=utf-8'
+
+ if (request.body && !headers['Content-Length'] && !headers['content-length'])
+ headers['Content-Length'] = Buffer.byteLength(request.body)
+
+ if (this.credentials.sessionToken)
+ headers['X-Amz-Security-Token'] = this.credentials.sessionToken
+
+ if (this.service === 's3')
+ headers['X-Amz-Content-Sha256'] = hash(this.request.body || '', 'hex')
+
+ if (headers['X-Amz-Date'])
+ this.datetime = headers['X-Amz-Date']
+ else
+ headers['X-Amz-Date'] = this.getDateTime()
+ }
+
+ delete headers.Authorization
+ delete headers.authorization
+ }
+}
+
+RequestSigner.prototype.sign = function() {
+ if (!this.parsedPath) this.prepareRequest()
+
+ if (this.request.signQuery) {
+ this.parsedPath.query['X-Amz-Signature'] = this.signature()
+ } else {
+ this.request.headers.Authorization = this.authHeader()
+ }
+
+ this.request.path = this.formatPath()
+
+ return this.request
+}
+
+RequestSigner.prototype.getDateTime = function() {
+ if (!this.datetime) {
+ var headers = this.request.headers,
+ date = new Date(headers.Date || headers.date || new Date)
+
+ this.datetime = date.toISOString().replace(/[:\-]|\.\d{3}/g, '')
+
+ // Remove the trailing 'Z' on the timestamp string for CodeCommit git access
+ if (this.isCodeCommitGit) this.datetime = this.datetime.slice(0, -1)
+ }
+ return this.datetime
+}
+
+RequestSigner.prototype.getDate = function() {
+ return this.getDateTime().substr(0, 8)
+}
+
+RequestSigner.prototype.authHeader = function() {
+ return [
+ 'AWS4-HMAC-SHA256 Credential=' + this.credentials.accessKeyId + '/' + this.credentialString(),
+ 'SignedHeaders=' + this.signedHeaders(),
+ 'Signature=' + this.signature(),
+ ].join(', ')
+}
+
+RequestSigner.prototype.signature = function() {
+ var date = this.getDate(),
+ cacheKey = [this.credentials.secretAccessKey, date, this.region, this.service].join(),
+ kDate, kRegion, kService, kCredentials = credentialsCache.get(cacheKey)
+ if (!kCredentials) {
+ kDate = hmac('AWS4' + this.credentials.secretAccessKey, date)
+ kRegion = hmac(kDate, this.region)
+ kService = hmac(kRegion, this.service)
+ kCredentials = hmac(kService, 'aws4_request')
+ credentialsCache.set(cacheKey, kCredentials)
+ }
+ return hmac(kCredentials, this.stringToSign(), 'hex')
+}
+
+RequestSigner.prototype.stringToSign = function() {
+ return [
+ 'AWS4-HMAC-SHA256',
+ this.getDateTime(),
+ this.credentialString(),
+ hash(this.canonicalString(), 'hex'),
+ ].join('\n')
+}
+
+RequestSigner.prototype.canonicalString = function() {
+ if (!this.parsedPath) this.prepareRequest()
+
+ var pathStr = this.parsedPath.path,
+ query = this.parsedPath.query,
+ queryStr = '',
+ normalizePath = this.service !== 's3',
+ decodePath = this.service === 's3' || this.request.doNotEncodePath,
+ decodeSlashesInPath = this.service === 's3',
+ firstValOnly = this.service === 's3',
+ bodyHash = this.service === 's3' && this.request.signQuery ? 'UNSIGNED-PAYLOAD' :
+ (this.isCodeCommitGit ? '' : hash(this.request.body || '', 'hex'))
+
+ if (query) {
+ queryStr = encodeRfc3986(querystring.stringify(Object.keys(query).sort().reduce(function(obj, key) {
+ if (!key) return obj
+ obj[key] = !Array.isArray(query[key]) ? query[key] :
+ (firstValOnly ? query[key][0] : query[key].slice().sort())
+ return obj
+ }, {})))
+ }
+ if (pathStr !== '/') {
+ if (normalizePath) pathStr = pathStr.replace(/\/{2,}/g, '/')
+ pathStr = pathStr.split('/').reduce(function(path, piece) {
+ if (normalizePath && piece === '..') {
+ path.pop()
+ } else if (!normalizePath || piece !== '.') {
+ if (decodePath) piece = querystring.unescape(piece)
+ path.push(encodeRfc3986(querystring.escape(piece)))
+ }
+ return path
+ }, []).join('/')
+ if (pathStr[0] !== '/') pathStr = '/' + pathStr
+ if (decodeSlashesInPath) pathStr = pathStr.replace(/%2F/g, '/')
+ }
+
+ return [
+ this.request.method || 'GET',
+ pathStr,
+ queryStr,
+ this.canonicalHeaders() + '\n',
+ this.signedHeaders(),
+ bodyHash,
+ ].join('\n')
+}
+
+RequestSigner.prototype.canonicalHeaders = function() {
+ var headers = this.request.headers
+ function trimAll(header) {
+ return header.toString().trim().replace(/\s+/g, ' ')
+ }
+ return Object.keys(headers)
+ .sort(function(a, b) { return a.toLowerCase() < b.toLowerCase() ? -1 : 1 })
+ .map(function(key) { return key.toLowerCase() + ':' + trimAll(headers[key]) })
+ .join('\n')
+}
+
+RequestSigner.prototype.signedHeaders = function() {
+ return Object.keys(this.request.headers)
+ .map(function(key) { return key.toLowerCase() })
+ .sort()
+ .join(';')
+}
+
+RequestSigner.prototype.credentialString = function() {
+ return [
+ this.getDate(),
+ this.region,
+ this.service,
+ 'aws4_request',
+ ].join('/')
+}
+
+RequestSigner.prototype.defaultCredentials = function() {
+ var env = process.env
+ return {
+ accessKeyId: env.AWS_ACCESS_KEY_ID || env.AWS_ACCESS_KEY,
+ secretAccessKey: env.AWS_SECRET_ACCESS_KEY || env.AWS_SECRET_KEY,
+ sessionToken: env.AWS_SESSION_TOKEN,
+ }
+}
+
+RequestSigner.prototype.parsePath = function() {
+ var path = this.request.path || '/',
+ queryIx = path.indexOf('?'),
+ query = null
+
+ if (queryIx >= 0) {
+ query = querystring.parse(path.slice(queryIx + 1))
+ path = path.slice(0, queryIx)
+ }
+
+ // S3 doesn't always encode characters > 127 correctly and
+ // all services don't encode characters > 255 correctly
+ // So if there are non-reserved chars (and it's not already all % encoded), just encode them all
+ if (/[^0-9A-Za-z!'()*\-._~%/]/.test(path)) {
+ path = path.split('/').map(function(piece) {
+ return querystring.escape(querystring.unescape(piece))
+ }).join('/')
+ }
+
+ this.parsedPath = {
+ path: path,
+ query: query,
+ }
+}
+
+RequestSigner.prototype.formatPath = function() {
+ var path = this.parsedPath.path,
+ query = this.parsedPath.query
+
+ if (!query) return path
+
+ // Services don't support empty query string keys
+ if (query[''] != null) delete query['']
+
+ return path + '?' + encodeRfc3986(querystring.stringify(query))
+}
+
+aws4.RequestSigner = RequestSigner
+
+aws4.sign = function(request, credentials) {
+ return new RequestSigner(request, credentials).sign()
+}
diff --git a/node_modules/fsevents/node_modules/aws4/lru.js b/node_modules/fsevents/node_modules/aws4/lru.js
new file mode 100644
index 00000000..333f66a4
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/lru.js
@@ -0,0 +1,96 @@
+module.exports = function(size) {
+ return new LruCache(size)
+}
+
+function LruCache(size) {
+ this.capacity = size | 0
+ this.map = Object.create(null)
+ this.list = new DoublyLinkedList()
+}
+
+LruCache.prototype.get = function(key) {
+ var node = this.map[key]
+ if (node == null) return undefined
+ this.used(node)
+ return node.val
+}
+
+LruCache.prototype.set = function(key, val) {
+ var node = this.map[key]
+ if (node != null) {
+ node.val = val
+ } else {
+ if (!this.capacity) this.prune()
+ if (!this.capacity) return false
+ node = new DoublyLinkedNode(key, val)
+ this.map[key] = node
+ this.capacity--
+ }
+ this.used(node)
+ return true
+}
+
+LruCache.prototype.used = function(node) {
+ this.list.moveToFront(node)
+}
+
+LruCache.prototype.prune = function() {
+ var node = this.list.pop()
+ if (node != null) {
+ delete this.map[node.key]
+ this.capacity++
+ }
+}
+
+
+function DoublyLinkedList() {
+ this.firstNode = null
+ this.lastNode = null
+}
+
+DoublyLinkedList.prototype.moveToFront = function(node) {
+ if (this.firstNode == node) return
+
+ this.remove(node)
+
+ if (this.firstNode == null) {
+ this.firstNode = node
+ this.lastNode = node
+ node.prev = null
+ node.next = null
+ } else {
+ node.prev = null
+ node.next = this.firstNode
+ node.next.prev = node
+ this.firstNode = node
+ }
+}
+
+DoublyLinkedList.prototype.pop = function() {
+ var lastNode = this.lastNode
+ if (lastNode != null) {
+ this.remove(lastNode)
+ }
+ return lastNode
+}
+
+DoublyLinkedList.prototype.remove = function(node) {
+ if (this.firstNode == node) {
+ this.firstNode = node.next
+ } else if (node.prev != null) {
+ node.prev.next = node.next
+ }
+ if (this.lastNode == node) {
+ this.lastNode = node.prev
+ } else if (node.next != null) {
+ node.next.prev = node.prev
+ }
+}
+
+
+function DoublyLinkedNode(key, val) {
+ this.key = key
+ this.val = val
+ this.prev = null
+ this.next = null
+}
diff --git a/node_modules/fsevents/node_modules/aws4/package.json b/node_modules/fsevents/node_modules/aws4/package.json
new file mode 100644
index 00000000..02c6f779
--- /dev/null
+++ b/node_modules/fsevents/node_modules/aws4/package.json
@@ -0,0 +1,140 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "aws4@^1.2.1",
+ "scope": null,
+ "escapedName": "aws4",
+ "name": "aws4",
+ "rawSpec": "^1.2.1",
+ "spec": ">=1.2.1 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/request"
+ ]
+ ],
+ "_from": "aws4@>=1.2.1 <2.0.0",
+ "_id": "aws4@1.5.0",
+ "_inCache": true,
+ "_location": "/fsevents/aws4",
+ "_nodeVersion": "4.5.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/aws4-1.5.0.tgz_1476226259635_0.2796843808609992"
+ },
+ "_npmUser": {
+ "name": "hichaelmart",
+ "email": "michael.hart.au@gmail.com"
+ },
+ "_npmVersion": "2.15.11",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "aws4@^1.2.1",
+ "scope": null,
+ "escapedName": "aws4",
+ "name": "aws4",
+ "rawSpec": "^1.2.1",
+ "spec": ">=1.2.1 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/request"
+ ],
+ "_resolved": "https://registry.npmjs.org/aws4/-/aws4-1.5.0.tgz",
+ "_shasum": "0a29ffb79c31c9e712eeb087e8e7a64b4a56d755",
+ "_shrinkwrap": null,
+ "_spec": "aws4@^1.2.1",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/request",
+ "author": {
+ "name": "Michael Hart",
+ "email": "michael.hart.au@gmail.com",
+ "url": "http://github.com/mhart"
+ },
+ "bugs": {
+ "url": "https://github.com/mhart/aws4/issues"
+ },
+ "dependencies": {},
+ "description": "Signs and prepares requests using AWS Signature Version 4",
+ "devDependencies": {
+ "mocha": "^2.4.5",
+ "should": "^8.2.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "0a29ffb79c31c9e712eeb087e8e7a64b4a56d755",
+ "tarball": "https://registry.npmjs.org/aws4/-/aws4-1.5.0.tgz"
+ },
+ "gitHead": "ba136334ee08884c6042c8578a22e376233eef34",
+ "homepage": "https://github.com/mhart/aws4#readme",
+ "keywords": [
+ "amazon",
+ "aws",
+ "signature",
+ "s3",
+ "ec2",
+ "autoscaling",
+ "cloudformation",
+ "elasticloadbalancing",
+ "elb",
+ "elasticbeanstalk",
+ "cloudsearch",
+ "dynamodb",
+ "kinesis",
+ "lambda",
+ "glacier",
+ "sqs",
+ "sns",
+ "iam",
+ "sts",
+ "ses",
+ "swf",
+ "storagegateway",
+ "datapipeline",
+ "directconnect",
+ "redshift",
+ "opsworks",
+ "rds",
+ "monitoring",
+ "cloudtrail",
+ "cloudfront",
+ "codedeploy",
+ "elasticache",
+ "elasticmapreduce",
+ "elastictranscoder",
+ "emr",
+ "cloudwatch",
+ "mobileanalytics",
+ "cognitoidentity",
+ "cognitosync",
+ "cognito",
+ "containerservice",
+ "ecs",
+ "appstream",
+ "keymanagementservice",
+ "kms",
+ "config",
+ "cloudhsm",
+ "route53",
+ "route53domains",
+ "logs"
+ ],
+ "license": "MIT",
+ "main": "aws4.js",
+ "maintainers": [
+ {
+ "name": "hichaelmart",
+ "email": "michael.hart.au@gmail.com"
+ }
+ ],
+ "name": "aws4",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/mhart/aws4.git"
+ },
+ "scripts": {
+ "test": "mocha ./test/fast.js ./test/slow.js -b -t 100s -R list"
+ },
+ "version": "1.5.0"
+}
diff --git a/node_modules/fsevents/node_modules/balanced-match/.npmignore b/node_modules/fsevents/node_modules/balanced-match/.npmignore
new file mode 100644
index 00000000..ae5d8c36
--- /dev/null
+++ b/node_modules/fsevents/node_modules/balanced-match/.npmignore
@@ -0,0 +1,5 @@
+test
+.gitignore
+.travis.yml
+Makefile
+example.js
diff --git a/node_modules/fsevents/node_modules/balanced-match/LICENSE.md b/node_modules/fsevents/node_modules/balanced-match/LICENSE.md
new file mode 100644
index 00000000..2cdc8e41
--- /dev/null
+++ b/node_modules/fsevents/node_modules/balanced-match/LICENSE.md
@@ -0,0 +1,21 @@
+(MIT)
+
+Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+of the Software, and to permit persons to whom the Software is furnished to do
+so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/balanced-match/README.md b/node_modules/fsevents/node_modules/balanced-match/README.md
new file mode 100644
index 00000000..08e918c0
--- /dev/null
+++ b/node_modules/fsevents/node_modules/balanced-match/README.md
@@ -0,0 +1,91 @@
+# balanced-match
+
+Match balanced string pairs, like `{` and `}` or `` and ` `. Supports regular expressions as well!
+
+[](http://travis-ci.org/juliangruber/balanced-match)
+[](https://www.npmjs.org/package/balanced-match)
+
+[](https://ci.testling.com/juliangruber/balanced-match)
+
+## Example
+
+Get the first matching pair of braces:
+
+```js
+var balanced = require('balanced-match');
+
+console.log(balanced('{', '}', 'pre{in{nested}}post'));
+console.log(balanced('{', '}', 'pre{first}between{second}post'));
+console.log(balanced(/\s+\{\s+/, /\s+\}\s+/, 'pre { in{nest} } post'));
+```
+
+The matches are:
+
+```bash
+$ node example.js
+{ start: 3, end: 14, pre: 'pre', body: 'in{nested}', post: 'post' }
+{ start: 3,
+ end: 9,
+ pre: 'pre',
+ body: 'first',
+ post: 'between{second}post' }
+{ start: 3, end: 17, pre: 'pre', body: 'in{nest}', post: 'post' }
+```
+
+## API
+
+### var m = balanced(a, b, str)
+
+For the first non-nested matching pair of `a` and `b` in `str`, return an
+object with those keys:
+
+* **start** the index of the first match of `a`
+* **end** the index of the matching `b`
+* **pre** the preamble, `a` and `b` not included
+* **body** the match, `a` and `b` not included
+* **post** the postscript, `a` and `b` not included
+
+If there's no match, `undefined` will be returned.
+
+If the `str` contains more `a` than `b` / there are unmatched pairs, the first match that was closed will be used. For example, `{{a}` will match `['{', 'a', '']` and `{a}}` will match `['', 'a', '}']`.
+
+### var r = balanced.range(a, b, str)
+
+For the first non-nested matching pair of `a` and `b` in `str`, return an
+array with indexes: `[ , ]`.
+
+If there's no match, `undefined` will be returned.
+
+If the `str` contains more `a` than `b` / there are unmatched pairs, the first match that was closed will be used. For example, `{{a}` will match `[ 1, 3 ]` and `{a}}` will match `[0, 2]`.
+
+## Installation
+
+With [npm](https://npmjs.org) do:
+
+```bash
+npm install balanced-match
+```
+
+## License
+
+(MIT)
+
+Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+of the Software, and to permit persons to whom the Software is furnished to do
+so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/balanced-match/index.js b/node_modules/fsevents/node_modules/balanced-match/index.js
new file mode 100644
index 00000000..e8d85870
--- /dev/null
+++ b/node_modules/fsevents/node_modules/balanced-match/index.js
@@ -0,0 +1,58 @@
+module.exports = balanced;
+function balanced(a, b, str) {
+ if (a instanceof RegExp) a = maybeMatch(a, str);
+ if (b instanceof RegExp) b = maybeMatch(b, str);
+
+ var r = range(a, b, str);
+
+ return r && {
+ start: r[0],
+ end: r[1],
+ pre: str.slice(0, r[0]),
+ body: str.slice(r[0] + a.length, r[1]),
+ post: str.slice(r[1] + b.length)
+ };
+}
+
+function maybeMatch(reg, str) {
+ var m = str.match(reg);
+ return m ? m[0] : null;
+}
+
+balanced.range = range;
+function range(a, b, str) {
+ var begs, beg, left, right, result;
+ var ai = str.indexOf(a);
+ var bi = str.indexOf(b, ai + 1);
+ var i = ai;
+
+ if (ai >= 0 && bi > 0) {
+ begs = [];
+ left = str.length;
+
+ while (i >= 0 && !result) {
+ if (i == ai) {
+ begs.push(i);
+ ai = str.indexOf(a, i + 1);
+ } else if (begs.length == 1) {
+ result = [ begs.pop(), bi ];
+ } else {
+ beg = begs.pop();
+ if (beg < left) {
+ left = beg;
+ right = bi;
+ }
+
+ bi = str.indexOf(b, i + 1);
+ }
+
+ i = ai < bi && ai >= 0 ? ai : bi;
+ }
+
+ if (begs.length) {
+ result = [ left, right ];
+ }
+ }
+
+ return result;
+}
diff --git a/node_modules/fsevents/node_modules/balanced-match/package.json b/node_modules/fsevents/node_modules/balanced-match/package.json
new file mode 100644
index 00000000..5d362231
--- /dev/null
+++ b/node_modules/fsevents/node_modules/balanced-match/package.json
@@ -0,0 +1,110 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "balanced-match@^0.4.1",
+ "scope": null,
+ "escapedName": "balanced-match",
+ "name": "balanced-match",
+ "rawSpec": "^0.4.1",
+ "spec": ">=0.4.1 <0.5.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/brace-expansion"
+ ]
+ ],
+ "_from": "balanced-match@>=0.4.1 <0.5.0",
+ "_id": "balanced-match@0.4.2",
+ "_inCache": true,
+ "_location": "/fsevents/balanced-match",
+ "_nodeVersion": "4.4.7",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/balanced-match-0.4.2.tgz_1468834991581_0.6590619895141572"
+ },
+ "_npmUser": {
+ "name": "juliangruber",
+ "email": "julian@juliangruber.com"
+ },
+ "_npmVersion": "2.15.8",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "balanced-match@^0.4.1",
+ "scope": null,
+ "escapedName": "balanced-match",
+ "name": "balanced-match",
+ "rawSpec": "^0.4.1",
+ "spec": ">=0.4.1 <0.5.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/brace-expansion"
+ ],
+ "_resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-0.4.2.tgz",
+ "_shasum": "cb3f3e3c732dc0f01ee70b403f302e61d7709838",
+ "_shrinkwrap": null,
+ "_spec": "balanced-match@^0.4.1",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/brace-expansion",
+ "author": {
+ "name": "Julian Gruber",
+ "email": "mail@juliangruber.com",
+ "url": "http://juliangruber.com"
+ },
+ "bugs": {
+ "url": "https://github.com/juliangruber/balanced-match/issues"
+ },
+ "dependencies": {},
+ "description": "Match balanced character pairs, like \"{\" and \"}\"",
+ "devDependencies": {
+ "tape": "^4.6.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "cb3f3e3c732dc0f01ee70b403f302e61d7709838",
+ "tarball": "https://registry.npmjs.org/balanced-match/-/balanced-match-0.4.2.tgz"
+ },
+ "gitHead": "57c2ea29d89a2844ae3bdcc637c6e2cbb73725e2",
+ "homepage": "https://github.com/juliangruber/balanced-match",
+ "keywords": [
+ "match",
+ "regexp",
+ "test",
+ "balanced",
+ "parse"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "juliangruber",
+ "email": "julian@juliangruber.com"
+ }
+ ],
+ "name": "balanced-match",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/juliangruber/balanced-match.git"
+ },
+ "scripts": {
+ "test": "make test"
+ },
+ "testling": {
+ "files": "test/*.js",
+ "browsers": [
+ "ie/8..latest",
+ "firefox/20..latest",
+ "firefox/nightly",
+ "chrome/25..latest",
+ "chrome/canary",
+ "opera/12..latest",
+ "opera/next",
+ "safari/5.1..latest",
+ "ipad/6.0..latest",
+ "iphone/6.0..latest",
+ "android-browser/4.2..latest"
+ ]
+ },
+ "version": "0.4.2"
+}
diff --git a/node_modules/fsevents/node_modules/bcrypt-pbkdf/README.md b/node_modules/fsevents/node_modules/bcrypt-pbkdf/README.md
new file mode 100644
index 00000000..12018090
--- /dev/null
+++ b/node_modules/fsevents/node_modules/bcrypt-pbkdf/README.md
@@ -0,0 +1,39 @@
+Port of the OpenBSD `bcrypt_pbkdf` function to pure Javascript. `npm`-ified
+version of [Devi Mandiri's port]
+(https://github.com/devi/tmp/blob/master/js/bcrypt_pbkdf.js),
+with some minor performance improvements. The code is copied verbatim (and
+un-styled) from Devi's work.
+
+This product includes software developed by Niels Provos.
+
+## API
+
+### `bcrypt_pbkdf.pbkdf(pass, passlen, salt, saltlen, key, keylen, rounds)`
+
+Derive a cryptographic key of arbitrary length from a given password and salt,
+using the OpenBSD `bcrypt_pbkdf` function. This is a combination of Blowfish and
+SHA-512.
+
+See [this article](http://www.tedunangst.com/flak/post/bcrypt-pbkdf) for
+further information.
+
+Parameters:
+
+ * `pass`, a Uint8Array of length `passlen`
+ * `passlen`, an integer Number
+ * `salt`, a Uint8Array of length `saltlen`
+ * `saltlen`, an integer Number
+ * `key`, a Uint8Array of length `keylen`, will be filled with output
+ * `keylen`, an integer Number
+ * `rounds`, an integer Number, number of rounds of the PBKDF to run
+
+### `bcrypt_pbkdf.hash(sha2pass, sha2salt, out)`
+
+Calculate a Blowfish hash, given SHA2-512 output of a password and salt. Used as
+part of the inner round function in the PBKDF.
+
+Parameters:
+
+ * `sha2pass`, a Uint8Array of length 64
+ * `sha2salt`, a Uint8Array of length 64
+ * `out`, a Uint8Array of length 32, will be filled with output
diff --git a/node_modules/fsevents/node_modules/bcrypt-pbkdf/index.js b/node_modules/fsevents/node_modules/bcrypt-pbkdf/index.js
new file mode 100644
index 00000000..ea29aa96
--- /dev/null
+++ b/node_modules/fsevents/node_modules/bcrypt-pbkdf/index.js
@@ -0,0 +1,559 @@
+'use strict';
+
+var crypto_hash_sha512 = require('tweetnacl').lowlevel.crypto_hash;
+
+/*
+ * This file is a 1:1 port from the OpenBSD blowfish.c and bcrypt_pbkdf.c. As a
+ * result, it retains the original copyright and license. The two files are
+ * under slightly different (but compatible) licenses, and are here combined in
+ * one file.
+ *
+ * Credit for the actual porting work goes to:
+ * Devi Mandiri
+ */
+
+/*
+ * The Blowfish portions are under the following license:
+ *
+ * Blowfish block cipher for OpenBSD
+ * Copyright 1997 Niels Provos
+ * All rights reserved.
+ *
+ * Implementation advice by David Mazieres .
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * This product includes software developed by Niels Provos.
+ * 4. The name of the author may not be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * The bcrypt_pbkdf portions are under the following license:
+ *
+ * Copyright (c) 2013 Ted Unangst
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+/*
+ * Performance improvements (Javascript-specific):
+ *
+ * Copyright 2016, Joyent Inc
+ * Author: Alex Wilson
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+// Ported from OpenBSD bcrypt_pbkdf.c v1.9
+
+var BLF_J = 0;
+
+var Blowfish = function() {
+ this.S = [
+ new Uint32Array([
+ 0xd1310ba6, 0x98dfb5ac, 0x2ffd72db, 0xd01adfb7,
+ 0xb8e1afed, 0x6a267e96, 0xba7c9045, 0xf12c7f99,
+ 0x24a19947, 0xb3916cf7, 0x0801f2e2, 0x858efc16,
+ 0x636920d8, 0x71574e69, 0xa458fea3, 0xf4933d7e,
+ 0x0d95748f, 0x728eb658, 0x718bcd58, 0x82154aee,
+ 0x7b54a41d, 0xc25a59b5, 0x9c30d539, 0x2af26013,
+ 0xc5d1b023, 0x286085f0, 0xca417918, 0xb8db38ef,
+ 0x8e79dcb0, 0x603a180e, 0x6c9e0e8b, 0xb01e8a3e,
+ 0xd71577c1, 0xbd314b27, 0x78af2fda, 0x55605c60,
+ 0xe65525f3, 0xaa55ab94, 0x57489862, 0x63e81440,
+ 0x55ca396a, 0x2aab10b6, 0xb4cc5c34, 0x1141e8ce,
+ 0xa15486af, 0x7c72e993, 0xb3ee1411, 0x636fbc2a,
+ 0x2ba9c55d, 0x741831f6, 0xce5c3e16, 0x9b87931e,
+ 0xafd6ba33, 0x6c24cf5c, 0x7a325381, 0x28958677,
+ 0x3b8f4898, 0x6b4bb9af, 0xc4bfe81b, 0x66282193,
+ 0x61d809cc, 0xfb21a991, 0x487cac60, 0x5dec8032,
+ 0xef845d5d, 0xe98575b1, 0xdc262302, 0xeb651b88,
+ 0x23893e81, 0xd396acc5, 0x0f6d6ff3, 0x83f44239,
+ 0x2e0b4482, 0xa4842004, 0x69c8f04a, 0x9e1f9b5e,
+ 0x21c66842, 0xf6e96c9a, 0x670c9c61, 0xabd388f0,
+ 0x6a51a0d2, 0xd8542f68, 0x960fa728, 0xab5133a3,
+ 0x6eef0b6c, 0x137a3be4, 0xba3bf050, 0x7efb2a98,
+ 0xa1f1651d, 0x39af0176, 0x66ca593e, 0x82430e88,
+ 0x8cee8619, 0x456f9fb4, 0x7d84a5c3, 0x3b8b5ebe,
+ 0xe06f75d8, 0x85c12073, 0x401a449f, 0x56c16aa6,
+ 0x4ed3aa62, 0x363f7706, 0x1bfedf72, 0x429b023d,
+ 0x37d0d724, 0xd00a1248, 0xdb0fead3, 0x49f1c09b,
+ 0x075372c9, 0x80991b7b, 0x25d479d8, 0xf6e8def7,
+ 0xe3fe501a, 0xb6794c3b, 0x976ce0bd, 0x04c006ba,
+ 0xc1a94fb6, 0x409f60c4, 0x5e5c9ec2, 0x196a2463,
+ 0x68fb6faf, 0x3e6c53b5, 0x1339b2eb, 0x3b52ec6f,
+ 0x6dfc511f, 0x9b30952c, 0xcc814544, 0xaf5ebd09,
+ 0xbee3d004, 0xde334afd, 0x660f2807, 0x192e4bb3,
+ 0xc0cba857, 0x45c8740f, 0xd20b5f39, 0xb9d3fbdb,
+ 0x5579c0bd, 0x1a60320a, 0xd6a100c6, 0x402c7279,
+ 0x679f25fe, 0xfb1fa3cc, 0x8ea5e9f8, 0xdb3222f8,
+ 0x3c7516df, 0xfd616b15, 0x2f501ec8, 0xad0552ab,
+ 0x323db5fa, 0xfd238760, 0x53317b48, 0x3e00df82,
+ 0x9e5c57bb, 0xca6f8ca0, 0x1a87562e, 0xdf1769db,
+ 0xd542a8f6, 0x287effc3, 0xac6732c6, 0x8c4f5573,
+ 0x695b27b0, 0xbbca58c8, 0xe1ffa35d, 0xb8f011a0,
+ 0x10fa3d98, 0xfd2183b8, 0x4afcb56c, 0x2dd1d35b,
+ 0x9a53e479, 0xb6f84565, 0xd28e49bc, 0x4bfb9790,
+ 0xe1ddf2da, 0xa4cb7e33, 0x62fb1341, 0xcee4c6e8,
+ 0xef20cada, 0x36774c01, 0xd07e9efe, 0x2bf11fb4,
+ 0x95dbda4d, 0xae909198, 0xeaad8e71, 0x6b93d5a0,
+ 0xd08ed1d0, 0xafc725e0, 0x8e3c5b2f, 0x8e7594b7,
+ 0x8ff6e2fb, 0xf2122b64, 0x8888b812, 0x900df01c,
+ 0x4fad5ea0, 0x688fc31c, 0xd1cff191, 0xb3a8c1ad,
+ 0x2f2f2218, 0xbe0e1777, 0xea752dfe, 0x8b021fa1,
+ 0xe5a0cc0f, 0xb56f74e8, 0x18acf3d6, 0xce89e299,
+ 0xb4a84fe0, 0xfd13e0b7, 0x7cc43b81, 0xd2ada8d9,
+ 0x165fa266, 0x80957705, 0x93cc7314, 0x211a1477,
+ 0xe6ad2065, 0x77b5fa86, 0xc75442f5, 0xfb9d35cf,
+ 0xebcdaf0c, 0x7b3e89a0, 0xd6411bd3, 0xae1e7e49,
+ 0x00250e2d, 0x2071b35e, 0x226800bb, 0x57b8e0af,
+ 0x2464369b, 0xf009b91e, 0x5563911d, 0x59dfa6aa,
+ 0x78c14389, 0xd95a537f, 0x207d5ba2, 0x02e5b9c5,
+ 0x83260376, 0x6295cfa9, 0x11c81968, 0x4e734a41,
+ 0xb3472dca, 0x7b14a94a, 0x1b510052, 0x9a532915,
+ 0xd60f573f, 0xbc9bc6e4, 0x2b60a476, 0x81e67400,
+ 0x08ba6fb5, 0x571be91f, 0xf296ec6b, 0x2a0dd915,
+ 0xb6636521, 0xe7b9f9b6, 0xff34052e, 0xc5855664,
+ 0x53b02d5d, 0xa99f8fa1, 0x08ba4799, 0x6e85076a]),
+ new Uint32Array([
+ 0x4b7a70e9, 0xb5b32944, 0xdb75092e, 0xc4192623,
+ 0xad6ea6b0, 0x49a7df7d, 0x9cee60b8, 0x8fedb266,
+ 0xecaa8c71, 0x699a17ff, 0x5664526c, 0xc2b19ee1,
+ 0x193602a5, 0x75094c29, 0xa0591340, 0xe4183a3e,
+ 0x3f54989a, 0x5b429d65, 0x6b8fe4d6, 0x99f73fd6,
+ 0xa1d29c07, 0xefe830f5, 0x4d2d38e6, 0xf0255dc1,
+ 0x4cdd2086, 0x8470eb26, 0x6382e9c6, 0x021ecc5e,
+ 0x09686b3f, 0x3ebaefc9, 0x3c971814, 0x6b6a70a1,
+ 0x687f3584, 0x52a0e286, 0xb79c5305, 0xaa500737,
+ 0x3e07841c, 0x7fdeae5c, 0x8e7d44ec, 0x5716f2b8,
+ 0xb03ada37, 0xf0500c0d, 0xf01c1f04, 0x0200b3ff,
+ 0xae0cf51a, 0x3cb574b2, 0x25837a58, 0xdc0921bd,
+ 0xd19113f9, 0x7ca92ff6, 0x94324773, 0x22f54701,
+ 0x3ae5e581, 0x37c2dadc, 0xc8b57634, 0x9af3dda7,
+ 0xa9446146, 0x0fd0030e, 0xecc8c73e, 0xa4751e41,
+ 0xe238cd99, 0x3bea0e2f, 0x3280bba1, 0x183eb331,
+ 0x4e548b38, 0x4f6db908, 0x6f420d03, 0xf60a04bf,
+ 0x2cb81290, 0x24977c79, 0x5679b072, 0xbcaf89af,
+ 0xde9a771f, 0xd9930810, 0xb38bae12, 0xdccf3f2e,
+ 0x5512721f, 0x2e6b7124, 0x501adde6, 0x9f84cd87,
+ 0x7a584718, 0x7408da17, 0xbc9f9abc, 0xe94b7d8c,
+ 0xec7aec3a, 0xdb851dfa, 0x63094366, 0xc464c3d2,
+ 0xef1c1847, 0x3215d908, 0xdd433b37, 0x24c2ba16,
+ 0x12a14d43, 0x2a65c451, 0x50940002, 0x133ae4dd,
+ 0x71dff89e, 0x10314e55, 0x81ac77d6, 0x5f11199b,
+ 0x043556f1, 0xd7a3c76b, 0x3c11183b, 0x5924a509,
+ 0xf28fe6ed, 0x97f1fbfa, 0x9ebabf2c, 0x1e153c6e,
+ 0x86e34570, 0xeae96fb1, 0x860e5e0a, 0x5a3e2ab3,
+ 0x771fe71c, 0x4e3d06fa, 0x2965dcb9, 0x99e71d0f,
+ 0x803e89d6, 0x5266c825, 0x2e4cc978, 0x9c10b36a,
+ 0xc6150eba, 0x94e2ea78, 0xa5fc3c53, 0x1e0a2df4,
+ 0xf2f74ea7, 0x361d2b3d, 0x1939260f, 0x19c27960,
+ 0x5223a708, 0xf71312b6, 0xebadfe6e, 0xeac31f66,
+ 0xe3bc4595, 0xa67bc883, 0xb17f37d1, 0x018cff28,
+ 0xc332ddef, 0xbe6c5aa5, 0x65582185, 0x68ab9802,
+ 0xeecea50f, 0xdb2f953b, 0x2aef7dad, 0x5b6e2f84,
+ 0x1521b628, 0x29076170, 0xecdd4775, 0x619f1510,
+ 0x13cca830, 0xeb61bd96, 0x0334fe1e, 0xaa0363cf,
+ 0xb5735c90, 0x4c70a239, 0xd59e9e0b, 0xcbaade14,
+ 0xeecc86bc, 0x60622ca7, 0x9cab5cab, 0xb2f3846e,
+ 0x648b1eaf, 0x19bdf0ca, 0xa02369b9, 0x655abb50,
+ 0x40685a32, 0x3c2ab4b3, 0x319ee9d5, 0xc021b8f7,
+ 0x9b540b19, 0x875fa099, 0x95f7997e, 0x623d7da8,
+ 0xf837889a, 0x97e32d77, 0x11ed935f, 0x16681281,
+ 0x0e358829, 0xc7e61fd6, 0x96dedfa1, 0x7858ba99,
+ 0x57f584a5, 0x1b227263, 0x9b83c3ff, 0x1ac24696,
+ 0xcdb30aeb, 0x532e3054, 0x8fd948e4, 0x6dbc3128,
+ 0x58ebf2ef, 0x34c6ffea, 0xfe28ed61, 0xee7c3c73,
+ 0x5d4a14d9, 0xe864b7e3, 0x42105d14, 0x203e13e0,
+ 0x45eee2b6, 0xa3aaabea, 0xdb6c4f15, 0xfacb4fd0,
+ 0xc742f442, 0xef6abbb5, 0x654f3b1d, 0x41cd2105,
+ 0xd81e799e, 0x86854dc7, 0xe44b476a, 0x3d816250,
+ 0xcf62a1f2, 0x5b8d2646, 0xfc8883a0, 0xc1c7b6a3,
+ 0x7f1524c3, 0x69cb7492, 0x47848a0b, 0x5692b285,
+ 0x095bbf00, 0xad19489d, 0x1462b174, 0x23820e00,
+ 0x58428d2a, 0x0c55f5ea, 0x1dadf43e, 0x233f7061,
+ 0x3372f092, 0x8d937e41, 0xd65fecf1, 0x6c223bdb,
+ 0x7cde3759, 0xcbee7460, 0x4085f2a7, 0xce77326e,
+ 0xa6078084, 0x19f8509e, 0xe8efd855, 0x61d99735,
+ 0xa969a7aa, 0xc50c06c2, 0x5a04abfc, 0x800bcadc,
+ 0x9e447a2e, 0xc3453484, 0xfdd56705, 0x0e1e9ec9,
+ 0xdb73dbd3, 0x105588cd, 0x675fda79, 0xe3674340,
+ 0xc5c43465, 0x713e38d8, 0x3d28f89e, 0xf16dff20,
+ 0x153e21e7, 0x8fb03d4a, 0xe6e39f2b, 0xdb83adf7]),
+ new Uint32Array([
+ 0xe93d5a68, 0x948140f7, 0xf64c261c, 0x94692934,
+ 0x411520f7, 0x7602d4f7, 0xbcf46b2e, 0xd4a20068,
+ 0xd4082471, 0x3320f46a, 0x43b7d4b7, 0x500061af,
+ 0x1e39f62e, 0x97244546, 0x14214f74, 0xbf8b8840,
+ 0x4d95fc1d, 0x96b591af, 0x70f4ddd3, 0x66a02f45,
+ 0xbfbc09ec, 0x03bd9785, 0x7fac6dd0, 0x31cb8504,
+ 0x96eb27b3, 0x55fd3941, 0xda2547e6, 0xabca0a9a,
+ 0x28507825, 0x530429f4, 0x0a2c86da, 0xe9b66dfb,
+ 0x68dc1462, 0xd7486900, 0x680ec0a4, 0x27a18dee,
+ 0x4f3ffea2, 0xe887ad8c, 0xb58ce006, 0x7af4d6b6,
+ 0xaace1e7c, 0xd3375fec, 0xce78a399, 0x406b2a42,
+ 0x20fe9e35, 0xd9f385b9, 0xee39d7ab, 0x3b124e8b,
+ 0x1dc9faf7, 0x4b6d1856, 0x26a36631, 0xeae397b2,
+ 0x3a6efa74, 0xdd5b4332, 0x6841e7f7, 0xca7820fb,
+ 0xfb0af54e, 0xd8feb397, 0x454056ac, 0xba489527,
+ 0x55533a3a, 0x20838d87, 0xfe6ba9b7, 0xd096954b,
+ 0x55a867bc, 0xa1159a58, 0xcca92963, 0x99e1db33,
+ 0xa62a4a56, 0x3f3125f9, 0x5ef47e1c, 0x9029317c,
+ 0xfdf8e802, 0x04272f70, 0x80bb155c, 0x05282ce3,
+ 0x95c11548, 0xe4c66d22, 0x48c1133f, 0xc70f86dc,
+ 0x07f9c9ee, 0x41041f0f, 0x404779a4, 0x5d886e17,
+ 0x325f51eb, 0xd59bc0d1, 0xf2bcc18f, 0x41113564,
+ 0x257b7834, 0x602a9c60, 0xdff8e8a3, 0x1f636c1b,
+ 0x0e12b4c2, 0x02e1329e, 0xaf664fd1, 0xcad18115,
+ 0x6b2395e0, 0x333e92e1, 0x3b240b62, 0xeebeb922,
+ 0x85b2a20e, 0xe6ba0d99, 0xde720c8c, 0x2da2f728,
+ 0xd0127845, 0x95b794fd, 0x647d0862, 0xe7ccf5f0,
+ 0x5449a36f, 0x877d48fa, 0xc39dfd27, 0xf33e8d1e,
+ 0x0a476341, 0x992eff74, 0x3a6f6eab, 0xf4f8fd37,
+ 0xa812dc60, 0xa1ebddf8, 0x991be14c, 0xdb6e6b0d,
+ 0xc67b5510, 0x6d672c37, 0x2765d43b, 0xdcd0e804,
+ 0xf1290dc7, 0xcc00ffa3, 0xb5390f92, 0x690fed0b,
+ 0x667b9ffb, 0xcedb7d9c, 0xa091cf0b, 0xd9155ea3,
+ 0xbb132f88, 0x515bad24, 0x7b9479bf, 0x763bd6eb,
+ 0x37392eb3, 0xcc115979, 0x8026e297, 0xf42e312d,
+ 0x6842ada7, 0xc66a2b3b, 0x12754ccc, 0x782ef11c,
+ 0x6a124237, 0xb79251e7, 0x06a1bbe6, 0x4bfb6350,
+ 0x1a6b1018, 0x11caedfa, 0x3d25bdd8, 0xe2e1c3c9,
+ 0x44421659, 0x0a121386, 0xd90cec6e, 0xd5abea2a,
+ 0x64af674e, 0xda86a85f, 0xbebfe988, 0x64e4c3fe,
+ 0x9dbc8057, 0xf0f7c086, 0x60787bf8, 0x6003604d,
+ 0xd1fd8346, 0xf6381fb0, 0x7745ae04, 0xd736fccc,
+ 0x83426b33, 0xf01eab71, 0xb0804187, 0x3c005e5f,
+ 0x77a057be, 0xbde8ae24, 0x55464299, 0xbf582e61,
+ 0x4e58f48f, 0xf2ddfda2, 0xf474ef38, 0x8789bdc2,
+ 0x5366f9c3, 0xc8b38e74, 0xb475f255, 0x46fcd9b9,
+ 0x7aeb2661, 0x8b1ddf84, 0x846a0e79, 0x915f95e2,
+ 0x466e598e, 0x20b45770, 0x8cd55591, 0xc902de4c,
+ 0xb90bace1, 0xbb8205d0, 0x11a86248, 0x7574a99e,
+ 0xb77f19b6, 0xe0a9dc09, 0x662d09a1, 0xc4324633,
+ 0xe85a1f02, 0x09f0be8c, 0x4a99a025, 0x1d6efe10,
+ 0x1ab93d1d, 0x0ba5a4df, 0xa186f20f, 0x2868f169,
+ 0xdcb7da83, 0x573906fe, 0xa1e2ce9b, 0x4fcd7f52,
+ 0x50115e01, 0xa70683fa, 0xa002b5c4, 0x0de6d027,
+ 0x9af88c27, 0x773f8641, 0xc3604c06, 0x61a806b5,
+ 0xf0177a28, 0xc0f586e0, 0x006058aa, 0x30dc7d62,
+ 0x11e69ed7, 0x2338ea63, 0x53c2dd94, 0xc2c21634,
+ 0xbbcbee56, 0x90bcb6de, 0xebfc7da1, 0xce591d76,
+ 0x6f05e409, 0x4b7c0188, 0x39720a3d, 0x7c927c24,
+ 0x86e3725f, 0x724d9db9, 0x1ac15bb4, 0xd39eb8fc,
+ 0xed545578, 0x08fca5b5, 0xd83d7cd3, 0x4dad0fc4,
+ 0x1e50ef5e, 0xb161e6f8, 0xa28514d9, 0x6c51133c,
+ 0x6fd5c7e7, 0x56e14ec4, 0x362abfce, 0xddc6c837,
+ 0xd79a3234, 0x92638212, 0x670efa8e, 0x406000e0]),
+ new Uint32Array([
+ 0x3a39ce37, 0xd3faf5cf, 0xabc27737, 0x5ac52d1b,
+ 0x5cb0679e, 0x4fa33742, 0xd3822740, 0x99bc9bbe,
+ 0xd5118e9d, 0xbf0f7315, 0xd62d1c7e, 0xc700c47b,
+ 0xb78c1b6b, 0x21a19045, 0xb26eb1be, 0x6a366eb4,
+ 0x5748ab2f, 0xbc946e79, 0xc6a376d2, 0x6549c2c8,
+ 0x530ff8ee, 0x468dde7d, 0xd5730a1d, 0x4cd04dc6,
+ 0x2939bbdb, 0xa9ba4650, 0xac9526e8, 0xbe5ee304,
+ 0xa1fad5f0, 0x6a2d519a, 0x63ef8ce2, 0x9a86ee22,
+ 0xc089c2b8, 0x43242ef6, 0xa51e03aa, 0x9cf2d0a4,
+ 0x83c061ba, 0x9be96a4d, 0x8fe51550, 0xba645bd6,
+ 0x2826a2f9, 0xa73a3ae1, 0x4ba99586, 0xef5562e9,
+ 0xc72fefd3, 0xf752f7da, 0x3f046f69, 0x77fa0a59,
+ 0x80e4a915, 0x87b08601, 0x9b09e6ad, 0x3b3ee593,
+ 0xe990fd5a, 0x9e34d797, 0x2cf0b7d9, 0x022b8b51,
+ 0x96d5ac3a, 0x017da67d, 0xd1cf3ed6, 0x7c7d2d28,
+ 0x1f9f25cf, 0xadf2b89b, 0x5ad6b472, 0x5a88f54c,
+ 0xe029ac71, 0xe019a5e6, 0x47b0acfd, 0xed93fa9b,
+ 0xe8d3c48d, 0x283b57cc, 0xf8d56629, 0x79132e28,
+ 0x785f0191, 0xed756055, 0xf7960e44, 0xe3d35e8c,
+ 0x15056dd4, 0x88f46dba, 0x03a16125, 0x0564f0bd,
+ 0xc3eb9e15, 0x3c9057a2, 0x97271aec, 0xa93a072a,
+ 0x1b3f6d9b, 0x1e6321f5, 0xf59c66fb, 0x26dcf319,
+ 0x7533d928, 0xb155fdf5, 0x03563482, 0x8aba3cbb,
+ 0x28517711, 0xc20ad9f8, 0xabcc5167, 0xccad925f,
+ 0x4de81751, 0x3830dc8e, 0x379d5862, 0x9320f991,
+ 0xea7a90c2, 0xfb3e7bce, 0x5121ce64, 0x774fbe32,
+ 0xa8b6e37e, 0xc3293d46, 0x48de5369, 0x6413e680,
+ 0xa2ae0810, 0xdd6db224, 0x69852dfd, 0x09072166,
+ 0xb39a460a, 0x6445c0dd, 0x586cdecf, 0x1c20c8ae,
+ 0x5bbef7dd, 0x1b588d40, 0xccd2017f, 0x6bb4e3bb,
+ 0xdda26a7e, 0x3a59ff45, 0x3e350a44, 0xbcb4cdd5,
+ 0x72eacea8, 0xfa6484bb, 0x8d6612ae, 0xbf3c6f47,
+ 0xd29be463, 0x542f5d9e, 0xaec2771b, 0xf64e6370,
+ 0x740e0d8d, 0xe75b1357, 0xf8721671, 0xaf537d5d,
+ 0x4040cb08, 0x4eb4e2cc, 0x34d2466a, 0x0115af84,
+ 0xe1b00428, 0x95983a1d, 0x06b89fb4, 0xce6ea048,
+ 0x6f3f3b82, 0x3520ab82, 0x011a1d4b, 0x277227f8,
+ 0x611560b1, 0xe7933fdc, 0xbb3a792b, 0x344525bd,
+ 0xa08839e1, 0x51ce794b, 0x2f32c9b7, 0xa01fbac9,
+ 0xe01cc87e, 0xbcc7d1f6, 0xcf0111c3, 0xa1e8aac7,
+ 0x1a908749, 0xd44fbd9a, 0xd0dadecb, 0xd50ada38,
+ 0x0339c32a, 0xc6913667, 0x8df9317c, 0xe0b12b4f,
+ 0xf79e59b7, 0x43f5bb3a, 0xf2d519ff, 0x27d9459c,
+ 0xbf97222c, 0x15e6fc2a, 0x0f91fc71, 0x9b941525,
+ 0xfae59361, 0xceb69ceb, 0xc2a86459, 0x12baa8d1,
+ 0xb6c1075e, 0xe3056a0c, 0x10d25065, 0xcb03a442,
+ 0xe0ec6e0e, 0x1698db3b, 0x4c98a0be, 0x3278e964,
+ 0x9f1f9532, 0xe0d392df, 0xd3a0342b, 0x8971f21e,
+ 0x1b0a7441, 0x4ba3348c, 0xc5be7120, 0xc37632d8,
+ 0xdf359f8d, 0x9b992f2e, 0xe60b6f47, 0x0fe3f11d,
+ 0xe54cda54, 0x1edad891, 0xce6279cf, 0xcd3e7e6f,
+ 0x1618b166, 0xfd2c1d05, 0x848fd2c5, 0xf6fb2299,
+ 0xf523f357, 0xa6327623, 0x93a83531, 0x56cccd02,
+ 0xacf08162, 0x5a75ebb5, 0x6e163697, 0x88d273cc,
+ 0xde966292, 0x81b949d0, 0x4c50901b, 0x71c65614,
+ 0xe6c6c7bd, 0x327a140a, 0x45e1d006, 0xc3f27b9a,
+ 0xc9aa53fd, 0x62a80f00, 0xbb25bfe2, 0x35bdd2f6,
+ 0x71126905, 0xb2040222, 0xb6cbcf7c, 0xcd769c2b,
+ 0x53113ec0, 0x1640e3d3, 0x38abbd60, 0x2547adf0,
+ 0xba38209c, 0xf746ce76, 0x77afa1c5, 0x20756060,
+ 0x85cbfe4e, 0x8ae88dd8, 0x7aaaf9b0, 0x4cf9aa7e,
+ 0x1948c25c, 0x02fb8a8c, 0x01c36ae4, 0xd6ebe1f9,
+ 0x90d4f869, 0xa65cdea0, 0x3f09252d, 0xc208e69f,
+ 0xb74e6132, 0xce77e25b, 0x578fdfe3, 0x3ac372e6])
+ ];
+ this.P = new Uint32Array([
+ 0x243f6a88, 0x85a308d3, 0x13198a2e, 0x03707344,
+ 0xa4093822, 0x299f31d0, 0x082efa98, 0xec4e6c89,
+ 0x452821e6, 0x38d01377, 0xbe5466cf, 0x34e90c6c,
+ 0xc0ac29b7, 0xc97c50dd, 0x3f84d5b5, 0xb5470917,
+ 0x9216d5d9, 0x8979fb1b]);
+};
+
+function F(S, x8, i) {
+ return (((S[0][x8[i+3]] +
+ S[1][x8[i+2]]) ^
+ S[2][x8[i+1]]) +
+ S[3][x8[i]]);
+};
+
+Blowfish.prototype.encipher = function(x, x8) {
+ if (x8 === undefined) {
+ x8 = new Uint8Array(x.buffer);
+ if (x.byteOffset !== 0)
+ x8 = x8.subarray(x.byteOffset);
+ }
+ x[0] ^= this.P[0];
+ for (var i = 1; i < 16; i += 2) {
+ x[1] ^= F(this.S, x8, 0) ^ this.P[i];
+ x[0] ^= F(this.S, x8, 4) ^ this.P[i+1];
+ }
+ var t = x[0];
+ x[0] = x[1] ^ this.P[17];
+ x[1] = t;
+};
+
+Blowfish.prototype.decipher = function(x) {
+ var x8 = new Uint8Array(x.buffer);
+ if (x.byteOffset !== 0)
+ x8 = x8.subarray(x.byteOffset);
+ x[0] ^= this.P[17];
+ for (var i = 16; i > 0; i -= 2) {
+ x[1] ^= F(this.S, x8, 0) ^ this.P[i];
+ x[0] ^= F(this.S, x8, 4) ^ this.P[i-1];
+ }
+ var t = x[0];
+ x[0] = x[1] ^ this.P[0];
+ x[1] = t;
+};
+
+function stream2word(data, databytes){
+ var i, temp = 0;
+ for (i = 0; i < 4; i++, BLF_J++) {
+ if (BLF_J >= databytes) BLF_J = 0;
+ temp = (temp << 8) | data[BLF_J];
+ }
+ return temp;
+};
+
+Blowfish.prototype.expand0state = function(key, keybytes) {
+ var d = new Uint32Array(2), i, k;
+ var d8 = new Uint8Array(d.buffer);
+
+ for (i = 0, BLF_J = 0; i < 18; i++) {
+ this.P[i] ^= stream2word(key, keybytes);
+ }
+ BLF_J = 0;
+
+ for (i = 0; i < 18; i += 2) {
+ this.encipher(d, d8);
+ this.P[i] = d[0];
+ this.P[i+1] = d[1];
+ }
+
+ for (i = 0; i < 4; i++) {
+ for (k = 0; k < 256; k += 2) {
+ this.encipher(d, d8);
+ this.S[i][k] = d[0];
+ this.S[i][k+1] = d[1];
+ }
+ }
+};
+
+Blowfish.prototype.expandstate = function(data, databytes, key, keybytes) {
+ var d = new Uint32Array(2), i, k;
+
+ for (i = 0, BLF_J = 0; i < 18; i++) {
+ this.P[i] ^= stream2word(key, keybytes);
+ }
+
+ for (i = 0, BLF_J = 0; i < 18; i += 2) {
+ d[0] ^= stream2word(data, databytes);
+ d[1] ^= stream2word(data, databytes);
+ this.encipher(d);
+ this.P[i] = d[0];
+ this.P[i+1] = d[1];
+ }
+
+ for (i = 0; i < 4; i++) {
+ for (k = 0; k < 256; k += 2) {
+ d[0] ^= stream2word(data, databytes);
+ d[1] ^= stream2word(data, databytes);
+ this.encipher(d);
+ this.S[i][k] = d[0];
+ this.S[i][k+1] = d[1];
+ }
+ }
+ BLF_J = 0;
+};
+
+Blowfish.prototype.enc = function(data, blocks) {
+ for (var i = 0; i < blocks; i++) {
+ this.encipher(data.subarray(i*2));
+ }
+};
+
+Blowfish.prototype.dec = function(data, blocks) {
+ for (var i = 0; i < blocks; i++) {
+ this.decipher(data.subarray(i*2));
+ }
+};
+
+var BCRYPT_BLOCKS = 8,
+ BCRYPT_HASHSIZE = 32;
+
+function bcrypt_hash(sha2pass, sha2salt, out) {
+ var state = new Blowfish(),
+ cdata = new Uint32Array(BCRYPT_BLOCKS), i,
+ ciphertext = new Uint8Array([79,120,121,99,104,114,111,109,97,116,105,
+ 99,66,108,111,119,102,105,115,104,83,119,97,116,68,121,110,97,109,
+ 105,116,101]); //"OxychromaticBlowfishSwatDynamite"
+
+ state.expandstate(sha2salt, 64, sha2pass, 64);
+ for (i = 0; i < 64; i++) {
+ state.expand0state(sha2salt, 64);
+ state.expand0state(sha2pass, 64);
+ }
+
+ for (i = 0; i < BCRYPT_BLOCKS; i++)
+ cdata[i] = stream2word(ciphertext, ciphertext.byteLength);
+ for (i = 0; i < 64; i++)
+ state.enc(cdata, cdata.byteLength / 8);
+
+ for (i = 0; i < BCRYPT_BLOCKS; i++) {
+ out[4*i+3] = cdata[i] >>> 24;
+ out[4*i+2] = cdata[i] >>> 16;
+ out[4*i+1] = cdata[i] >>> 8;
+ out[4*i+0] = cdata[i];
+ }
+};
+
+function bcrypt_pbkdf(pass, passlen, salt, saltlen, key, keylen, rounds) {
+ var sha2pass = new Uint8Array(64),
+ sha2salt = new Uint8Array(64),
+ out = new Uint8Array(BCRYPT_HASHSIZE),
+ tmpout = new Uint8Array(BCRYPT_HASHSIZE),
+ countsalt = new Uint8Array(saltlen+4),
+ i, j, amt, stride, dest, count,
+ origkeylen = keylen;
+
+ if (rounds < 1)
+ return -1;
+ if (passlen === 0 || saltlen === 0 || keylen === 0 ||
+ keylen > (out.byteLength * out.byteLength) || saltlen > (1<<20))
+ return -1;
+
+ stride = Math.floor((keylen + out.byteLength - 1) / out.byteLength);
+ amt = Math.floor((keylen + stride - 1) / stride);
+
+ for (i = 0; i < saltlen; i++)
+ countsalt[i] = salt[i];
+
+ crypto_hash_sha512(sha2pass, pass, passlen);
+
+ for (count = 1; keylen > 0; count++) {
+ countsalt[saltlen+0] = count >>> 24;
+ countsalt[saltlen+1] = count >>> 16;
+ countsalt[saltlen+2] = count >>> 8;
+ countsalt[saltlen+3] = count;
+
+ crypto_hash_sha512(sha2salt, countsalt, saltlen + 4);
+ bcrypt_hash(sha2pass, sha2salt, tmpout);
+ for (i = out.byteLength; i--;)
+ out[i] = tmpout[i];
+
+ for (i = 1; i < rounds; i++) {
+ crypto_hash_sha512(sha2salt, tmpout, tmpout.byteLength);
+ bcrypt_hash(sha2pass, sha2salt, tmpout);
+ for (j = 0; j < out.byteLength; j++)
+ out[j] ^= tmpout[j];
+ }
+
+ amt = Math.min(amt, keylen);
+ for (i = 0; i < amt; i++) {
+ dest = i * stride + (count - 1);
+ if (dest >= origkeylen)
+ break;
+ key[dest] = out[i];
+ }
+ keylen -= i;
+ }
+
+ return 0;
+};
+
+module.exports = {
+ BLOCKS: BCRYPT_BLOCKS,
+ HASHSIZE: BCRYPT_HASHSIZE,
+ hash: bcrypt_hash,
+ pbkdf: bcrypt_pbkdf
+};
diff --git a/node_modules/fsevents/node_modules/bcrypt-pbkdf/package.json b/node_modules/fsevents/node_modules/bcrypt-pbkdf/package.json
new file mode 100644
index 00000000..e33727e6
--- /dev/null
+++ b/node_modules/fsevents/node_modules/bcrypt-pbkdf/package.json
@@ -0,0 +1,72 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "bcrypt-pbkdf@^1.0.0",
+ "scope": null,
+ "escapedName": "bcrypt-pbkdf",
+ "name": "bcrypt-pbkdf",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/sshpk"
+ ]
+ ],
+ "_from": "bcrypt-pbkdf@>=1.0.0 <2.0.0",
+ "_id": "bcrypt-pbkdf@1.0.0",
+ "_inCache": true,
+ "_location": "/fsevents/bcrypt-pbkdf",
+ "_nodeVersion": "0.12.15",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/bcrypt-pbkdf-1.0.0.tgz_1471381825814_0.06877309852279723"
+ },
+ "_npmUser": {
+ "name": "arekinath",
+ "email": "alex@cooperi.net"
+ },
+ "_npmVersion": "3.10.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "bcrypt-pbkdf@^1.0.0",
+ "scope": null,
+ "escapedName": "bcrypt-pbkdf",
+ "name": "bcrypt-pbkdf",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/sshpk"
+ ],
+ "_resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.0.tgz",
+ "_shasum": "3ca76b85241c7170bf7d9703e7b9aa74630040d4",
+ "_shrinkwrap": null,
+ "_spec": "bcrypt-pbkdf@^1.0.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/sshpk",
+ "dependencies": {
+ "tweetnacl": "^0.14.3"
+ },
+ "description": "Port of the OpenBSD bcrypt_pbkdf function to pure JS",
+ "devDependencies": {},
+ "directories": {},
+ "dist": {
+ "shasum": "3ca76b85241c7170bf7d9703e7b9aa74630040d4",
+ "tarball": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.0.tgz"
+ },
+ "gitHead": "e88be37d3cd25395b4aa496ac468b33671368be6",
+ "license": "BSD-4-Clause",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "arekinath",
+ "email": "alex@cooperi.net"
+ }
+ ],
+ "name": "bcrypt-pbkdf",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "scripts": {},
+ "version": "1.0.0"
+}
diff --git a/node_modules/fsevents/node_modules/block-stream/LICENCE b/node_modules/fsevents/node_modules/block-stream/LICENCE
new file mode 100644
index 00000000..74489e2e
--- /dev/null
+++ b/node_modules/fsevents/node_modules/block-stream/LICENCE
@@ -0,0 +1,25 @@
+Copyright (c) Isaac Z. Schlueter
+All rights reserved.
+
+The BSD License
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
diff --git a/node_modules/fsevents/node_modules/block-stream/LICENSE b/node_modules/fsevents/node_modules/block-stream/LICENSE
new file mode 100644
index 00000000..19129e31
--- /dev/null
+++ b/node_modules/fsevents/node_modules/block-stream/LICENSE
@@ -0,0 +1,15 @@
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/block-stream/README.md b/node_modules/fsevents/node_modules/block-stream/README.md
new file mode 100644
index 00000000..c16e9c46
--- /dev/null
+++ b/node_modules/fsevents/node_modules/block-stream/README.md
@@ -0,0 +1,14 @@
+# block-stream
+
+A stream of blocks.
+
+Write data into it, and it'll output data in buffer blocks the size you
+specify, padding with zeroes if necessary.
+
+```javascript
+var block = new BlockStream(512)
+fs.createReadStream("some-file").pipe(block)
+block.pipe(fs.createWriteStream("block-file"))
+```
+
+When `.end()` or `.flush()` is called, it'll pad the block with zeroes.
diff --git a/node_modules/fsevents/node_modules/block-stream/block-stream.js b/node_modules/fsevents/node_modules/block-stream/block-stream.js
new file mode 100644
index 00000000..008de035
--- /dev/null
+++ b/node_modules/fsevents/node_modules/block-stream/block-stream.js
@@ -0,0 +1,209 @@
+// write data to it, and it'll emit data in 512 byte blocks.
+// if you .end() or .flush(), it'll emit whatever it's got,
+// padded with nulls to 512 bytes.
+
+module.exports = BlockStream
+
+var Stream = require("stream").Stream
+ , inherits = require("inherits")
+ , assert = require("assert").ok
+ , debug = process.env.DEBUG ? console.error : function () {}
+
+function BlockStream (size, opt) {
+ this.writable = this.readable = true
+ this._opt = opt || {}
+ this._chunkSize = size || 512
+ this._offset = 0
+ this._buffer = []
+ this._bufferLength = 0
+ if (this._opt.nopad) this._zeroes = false
+ else {
+ this._zeroes = new Buffer(this._chunkSize)
+ for (var i = 0; i < this._chunkSize; i ++) {
+ this._zeroes[i] = 0
+ }
+ }
+}
+
+inherits(BlockStream, Stream)
+
+BlockStream.prototype.write = function (c) {
+ // debug(" BS write", c)
+ if (this._ended) throw new Error("BlockStream: write after end")
+ if (c && !Buffer.isBuffer(c)) c = new Buffer(c + "")
+ if (c.length) {
+ this._buffer.push(c)
+ this._bufferLength += c.length
+ }
+ // debug("pushed onto buffer", this._bufferLength)
+ if (this._bufferLength >= this._chunkSize) {
+ if (this._paused) {
+ // debug(" BS paused, return false, need drain")
+ this._needDrain = true
+ return false
+ }
+ this._emitChunk()
+ }
+ return true
+}
+
+BlockStream.prototype.pause = function () {
+ // debug(" BS pausing")
+ this._paused = true
+}
+
+BlockStream.prototype.resume = function () {
+ // debug(" BS resume")
+ this._paused = false
+ return this._emitChunk()
+}
+
+BlockStream.prototype.end = function (chunk) {
+ // debug("end", chunk)
+ if (typeof chunk === "function") cb = chunk, chunk = null
+ if (chunk) this.write(chunk)
+ this._ended = true
+ this.flush()
+}
+
+BlockStream.prototype.flush = function () {
+ this._emitChunk(true)
+}
+
+BlockStream.prototype._emitChunk = function (flush) {
+ // debug("emitChunk flush=%j emitting=%j paused=%j", flush, this._emitting, this._paused)
+
+ // emit a chunk
+ if (flush && this._zeroes) {
+ // debug(" BS push zeroes", this._bufferLength)
+ // push a chunk of zeroes
+ var padBytes = (this._bufferLength % this._chunkSize)
+ if (padBytes !== 0) padBytes = this._chunkSize - padBytes
+ if (padBytes > 0) {
+ // debug("padBytes", padBytes, this._zeroes.slice(0, padBytes))
+ this._buffer.push(this._zeroes.slice(0, padBytes))
+ this._bufferLength += padBytes
+ // debug(this._buffer[this._buffer.length - 1].length, this._bufferLength)
+ }
+ }
+
+ if (this._emitting || this._paused) return
+ this._emitting = true
+
+ // debug(" BS entering loops")
+ var bufferIndex = 0
+ while (this._bufferLength >= this._chunkSize &&
+ (flush || !this._paused)) {
+ // debug(" BS data emission loop", this._bufferLength)
+
+ var out
+ , outOffset = 0
+ , outHas = this._chunkSize
+
+ while (outHas > 0 && (flush || !this._paused) ) {
+ // debug(" BS data inner emit loop", this._bufferLength)
+ var cur = this._buffer[bufferIndex]
+ , curHas = cur.length - this._offset
+ // debug("cur=", cur)
+ // debug("curHas=%j", curHas)
+ // If it's not big enough to fill the whole thing, then we'll need
+ // to copy multiple buffers into one. However, if it is big enough,
+ // then just slice out the part we want, to save unnecessary copying.
+ // Also, need to copy if we've already done some copying, since buffers
+ // can't be joined like cons strings.
+ if (out || curHas < outHas) {
+ out = out || new Buffer(this._chunkSize)
+ cur.copy(out, outOffset,
+ this._offset, this._offset + Math.min(curHas, outHas))
+ } else if (cur.length === outHas && this._offset === 0) {
+ // shortcut -- cur is exactly long enough, and no offset.
+ out = cur
+ } else {
+ // slice out the piece of cur that we need.
+ out = cur.slice(this._offset, this._offset + outHas)
+ }
+
+ if (curHas > outHas) {
+ // means that the current buffer couldn't be completely output
+ // update this._offset to reflect how much WAS written
+ this._offset += outHas
+ outHas = 0
+ } else {
+ // output the entire current chunk.
+ // toss it away
+ outHas -= curHas
+ outOffset += curHas
+ bufferIndex ++
+ this._offset = 0
+ }
+ }
+
+ this._bufferLength -= this._chunkSize
+ assert(out.length === this._chunkSize)
+ // debug("emitting data", out)
+ // debug(" BS emitting, paused=%j", this._paused, this._bufferLength)
+ this.emit("data", out)
+ out = null
+ }
+ // debug(" BS out of loops", this._bufferLength)
+
+ // whatever is left, it's not enough to fill up a block, or we're paused
+ this._buffer = this._buffer.slice(bufferIndex)
+ if (this._paused) {
+ // debug(" BS paused, leaving", this._bufferLength)
+ this._needsDrain = true
+ this._emitting = false
+ return
+ }
+
+ // if flushing, and not using null-padding, then need to emit the last
+ // chunk(s) sitting in the queue. We know that it's not enough to
+ // fill up a whole block, because otherwise it would have been emitted
+ // above, but there may be some offset.
+ var l = this._buffer.length
+ if (flush && !this._zeroes && l) {
+ if (l === 1) {
+ if (this._offset) {
+ this.emit("data", this._buffer[0].slice(this._offset))
+ } else {
+ this.emit("data", this._buffer[0])
+ }
+ } else {
+ var outHas = this._bufferLength
+ , out = new Buffer(outHas)
+ , outOffset = 0
+ for (var i = 0; i < l; i ++) {
+ var cur = this._buffer[i]
+ , curHas = cur.length - this._offset
+ cur.copy(out, outOffset, this._offset)
+ this._offset = 0
+ outOffset += curHas
+ this._bufferLength -= curHas
+ }
+ this.emit("data", out)
+ }
+ // truncate
+ this._buffer.length = 0
+ this._bufferLength = 0
+ this._offset = 0
+ }
+
+ // now either drained or ended
+ // debug("either draining, or ended", this._bufferLength, this._ended)
+ // means that we've flushed out all that we can so far.
+ if (this._needDrain) {
+ // debug("emitting drain", this._bufferLength)
+ this._needDrain = false
+ this.emit("drain")
+ }
+
+ if ((this._bufferLength === 0) && this._ended && !this._endEmitted) {
+ // debug("emitting end", this._bufferLength)
+ this._endEmitted = true
+ this.emit("end")
+ }
+
+ this._emitting = false
+
+ // debug(" BS no longer emitting", flush, this._paused, this._emitting, this._bufferLength, this._chunkSize)
+}
diff --git a/node_modules/fsevents/node_modules/block-stream/package.json b/node_modules/fsevents/node_modules/block-stream/package.json
new file mode 100644
index 00000000..7b34c476
--- /dev/null
+++ b/node_modules/fsevents/node_modules/block-stream/package.json
@@ -0,0 +1,95 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "block-stream@*",
+ "scope": null,
+ "escapedName": "block-stream",
+ "name": "block-stream",
+ "rawSpec": "*",
+ "spec": "*",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/tar"
+ ]
+ ],
+ "_from": "block-stream@*",
+ "_id": "block-stream@0.0.9",
+ "_inCache": true,
+ "_location": "/fsevents/block-stream",
+ "_nodeVersion": "5.6.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/block-stream-0.0.9.tgz_1462149852620_0.6890447810292244"
+ },
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "_npmVersion": "3.8.5",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "block-stream@*",
+ "scope": null,
+ "escapedName": "block-stream",
+ "name": "block-stream",
+ "rawSpec": "*",
+ "spec": "*",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/tar"
+ ],
+ "_resolved": "https://registry.npmjs.org/block-stream/-/block-stream-0.0.9.tgz",
+ "_shasum": "13ebfe778a03205cfe03751481ebb4b3300c126a",
+ "_shrinkwrap": null,
+ "_spec": "block-stream@*",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/tar",
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me",
+ "url": "http://blog.izs.me/"
+ },
+ "bugs": {
+ "url": "https://github.com/isaacs/block-stream/issues"
+ },
+ "dependencies": {
+ "inherits": "~2.0.0"
+ },
+ "description": "a stream of blocks",
+ "devDependencies": {
+ "tap": "^5.7.1"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "13ebfe778a03205cfe03751481ebb4b3300c126a",
+ "tarball": "https://registry.npmjs.org/block-stream/-/block-stream-0.0.9.tgz"
+ },
+ "engines": {
+ "node": "0.4 || >=0.5.8"
+ },
+ "files": [
+ "block-stream.js"
+ ],
+ "gitHead": "321cf242ef6d130bb2e59c0565a61ded5dd2673f",
+ "homepage": "https://github.com/isaacs/block-stream#readme",
+ "license": "ISC",
+ "main": "block-stream.js",
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "name": "block-stream",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/isaacs/block-stream.git"
+ },
+ "scripts": {
+ "test": "tap test/*.js --cov"
+ },
+ "version": "0.0.9"
+}
diff --git a/node_modules/fsevents/node_modules/boom/.npmignore b/node_modules/fsevents/node_modules/boom/.npmignore
new file mode 100644
index 00000000..77ba16cb
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/.npmignore
@@ -0,0 +1,18 @@
+.idea
+*.iml
+npm-debug.log
+dump.rdb
+node_modules
+results.tap
+results.xml
+npm-shrinkwrap.json
+config.json
+.DS_Store
+*/.DS_Store
+*/*/.DS_Store
+._*
+*/._*
+*/*/._*
+coverage.*
+lib-cov
+
diff --git a/node_modules/fsevents/node_modules/boom/.travis.yml b/node_modules/fsevents/node_modules/boom/.travis.yml
new file mode 100755
index 00000000..dd1b24f1
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/.travis.yml
@@ -0,0 +1,8 @@
+language: node_js
+
+node_js:
+ - 0.10
+ - 4.0
+
+sudo: false
+
diff --git a/node_modules/fsevents/node_modules/boom/CONTRIBUTING.md b/node_modules/fsevents/node_modules/boom/CONTRIBUTING.md
new file mode 100644
index 00000000..89283615
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/CONTRIBUTING.md
@@ -0,0 +1 @@
+Please view our [hapijs contributing guide](https://github.com/hapijs/hapi/blob/master/CONTRIBUTING.md).
diff --git a/node_modules/fsevents/node_modules/boom/LICENSE b/node_modules/fsevents/node_modules/boom/LICENSE
new file mode 100755
index 00000000..39468893
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/LICENSE
@@ -0,0 +1,28 @@
+Copyright (c) 2012-2014, Walmart and other contributors.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ * The names of any contributors may not be used to endorse or promote
+ products derived from this software without specific prior written
+ permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS AND CONTRIBUTORS BE LIABLE FOR ANY
+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+ * * *
+
+The complete list of contributors can be found at: https://github.com/hapijs/boom/graphs/contributors
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/boom/README.md b/node_modules/fsevents/node_modules/boom/README.md
new file mode 100755
index 00000000..cbd91c93
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/README.md
@@ -0,0 +1,652 @@
+
+
+HTTP-friendly error objects
+
+[](http://travis-ci.org/hapijs/boom)
+[](https://www.npmjs.com/package/boom)
+
+Lead Maintainer: [Adam Bretz](https://github.com/arb)
+
+**boom** provides a set of utilities for returning HTTP errors. Each utility returns a `Boom` error response
+object (instance of `Error`) which includes the following properties:
+- `isBoom` - if `true`, indicates this is a `Boom` object instance.
+- `isServer` - convenience bool indicating status code >= 500.
+- `message` - the error message.
+- `output` - the formatted response. Can be directly manipulated after object construction to return a custom
+ error response. Allowed root keys:
+ - `statusCode` - the HTTP status code (typically 4xx or 5xx).
+ - `headers` - an object containing any HTTP headers where each key is a header name and value is the header content.
+ - `payload` - the formatted object used as the response payload (stringified). Can be directly manipulated but any
+ changes will be lost
+ if `reformat()` is called. Any content allowed and by default includes the following content:
+ - `statusCode` - the HTTP status code, derived from `error.output.statusCode`.
+ - `error` - the HTTP status message (e.g. 'Bad Request', 'Internal Server Error') derived from `statusCode`.
+ - `message` - the error message derived from `error.message`.
+- inherited `Error` properties.
+
+The `Boom` object also supports the following method:
+- `reformat()` - rebuilds `error.output` using the other object properties.
+
+## Overview
+
+- Helper methods
+ - [`wrap(error, [statusCode], [message])`](#wraperror-statuscode-message)
+ - [`create(statusCode, [message], [data])`](#createstatuscode-message-data)
+- HTTP 4xx Errors
+ - 400: [`Boom.badRequest([message], [data])`](#boombadrequestmessage-data)
+ - 401: [`Boom.unauthorized([message], [scheme], [attributes])`](#boomunauthorizedmessage-scheme-attributes)
+ - 403: [`Boom.forbidden([message], [data])`](#boomforbiddenmessage-data)
+ - 404: [`Boom.notFound([message], [data])`](#boomnotfoundmessage-data)
+ - 405: [`Boom.methodNotAllowed([message], [data])`](#boommethodnotallowedmessage-data)
+ - 406: [`Boom.notAcceptable([message], [data])`](#boomnotacceptablemessage-data)
+ - 407: [`Boom.proxyAuthRequired([message], [data])`](#boomproxyauthrequiredmessage-data)
+ - 408: [`Boom.clientTimeout([message], [data])`](#boomclienttimeoutmessage-data)
+ - 409: [`Boom.conflict([message], [data])`](#boomconflictmessage-data)
+ - 410: [`Boom.resourceGone([message], [data])`](#boomresourcegonemessage-data)
+ - 411: [`Boom.lengthRequired([message], [data])`](#boomlengthrequiredmessage-data)
+ - 412: [`Boom.preconditionFailed([message], [data])`](#boompreconditionfailedmessage-data)
+ - 413: [`Boom.entityTooLarge([message], [data])`](#boomentitytoolargemessage-data)
+ - 414: [`Boom.uriTooLong([message], [data])`](#boomuritoolongmessage-data)
+ - 415: [`Boom.unsupportedMediaType([message], [data])`](#boomunsupportedmediatypemessage-data)
+ - 416: [`Boom.rangeNotSatisfiable([message], [data])`](#boomrangenotsatisfiablemessage-data)
+ - 417: [`Boom.expectationFailed([message], [data])`](#boomexpectationfailedmessage-data)
+ - 422: [`Boom.badData([message], [data])`](#boombaddatamessage-data)
+ - 428: [`Boom.preconditionRequired([message], [data])`](#boompreconditionrequiredmessage-data)
+ - 429: [`Boom.tooManyRequests([message], [data])`](#boomtoomanyrequestsmessage-data)
+- HTTP 5xx Errors
+ - 500: [`Boom.badImplementation([message], [data])`](#boombadimplementationmessage-data)
+ - 501: [`Boom.notImplemented([message], [data])`](#boomnotimplementedmessage-data)
+ - 502: [`Boom.badGateway([message], [data])`](#boombadgatewaymessage-data)
+ - 503: [`Boom.serverTimeout([message], [data])`](#boomservertimeoutmessage-data)
+ - 504: [`Boom.gatewayTimeout([message], [data])`](#boomgatewaytimeoutmessage-data)
+- [FAQ](#faq)
+
+
+## Helper Methods
+
+### `wrap(error, [statusCode], [message])`
+
+Decorates an error with the **boom** properties where:
+- `error` - the error object to wrap. If `error` is already a **boom** object, returns back the same object.
+- `statusCode` - optional HTTP status code. Defaults to `500`.
+- `message` - optional message string. If the error already has a message, it adds the message as a prefix.
+ Defaults to no message.
+
+```js
+var error = new Error('Unexpected input');
+Boom.wrap(error, 400);
+```
+
+### `create(statusCode, [message], [data])`
+
+Generates an `Error` object with the **boom** decorations where:
+- `statusCode` - an HTTP error code number. Must be greater or equal 400.
+- `message` - optional message string.
+- `data` - additional error data set to `error.data` property.
+
+```js
+var error = Boom.create(400, 'Bad request', { timestamp: Date.now() });
+```
+
+## HTTP 4xx Errors
+
+### `Boom.badRequest([message], [data])`
+
+Returns a 400 Bad Request error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.badRequest('invalid query');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 400,
+ "error": "Bad Request",
+ "message": "invalid query"
+}
+```
+
+### `Boom.unauthorized([message], [scheme], [attributes])`
+
+Returns a 401 Unauthorized error where:
+- `message` - optional message.
+- `scheme` can be one of the following:
+ - an authentication scheme name
+ - an array of string values. These values will be separated by ', ' and set to the 'WWW-Authenticate' header.
+- `attributes` - an object of values to use while setting the 'WWW-Authenticate' header. This value is only used
+ when `schema` is a string, otherwise it is ignored. Every key/value pair will be included in the
+ 'WWW-Authenticate' in the format of 'key="value"' as well as in the response payload under the `attributes` key.
+ `null` and `undefined` will be replaced with an empty string. If `attributes` is set, `message` will be used as
+ the 'error' segment of the 'WWW-Authenticate' header. If `message` is unset, the 'error' segment of the header
+ will not be present and `isMissing` will be true on the error object.
+
+If either `scheme` or `attributes` are set, the resultant `Boom` object will have the 'WWW-Authenticate' header set for the response.
+
+```js
+Boom.unauthorized('invalid password');
+```
+
+Generates the following response:
+
+```json
+"payload": {
+ "statusCode": 401,
+ "error": "Unauthorized",
+ "message": "invalid password"
+},
+"headers" {}
+```
+
+```js
+Boom.unauthorized('invalid password', 'sample');
+```
+
+Generates the following response:
+
+```json
+"payload": {
+ "statusCode": 401,
+ "error": "Unauthorized",
+ "message": "invalid password",
+ "attributes": {
+ "error": "invalid password"
+ }
+},
+"headers" {
+ "WWW-Authenticate": "sample error=\"invalid password\""
+}
+```
+
+```js
+Boom.unauthorized('invalid password', 'sample', { ttl: 0, cache: null, foo: 'bar' });
+```
+
+Generates the following response:
+
+```json
+"payload": {
+ "statusCode": 401,
+ "error": "Unauthorized",
+ "message": "invalid password",
+ "attributes": {
+ "error": "invalid password",
+ "ttl": 0,
+ "cache": "",
+ "foo": "bar"
+ }
+},
+"headers" {
+ "WWW-Authenticate": "sample ttl=\"0\", cache=\"\", foo=\"bar\", error=\"invalid password\""
+}
+```
+
+### `Boom.forbidden([message], [data])`
+
+Returns a 403 Forbidden error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.forbidden('try again some time');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 403,
+ "error": "Forbidden",
+ "message": "try again some time"
+}
+```
+
+### `Boom.notFound([message], [data])`
+
+Returns a 404 Not Found error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.notFound('missing');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 404,
+ "error": "Not Found",
+ "message": "missing"
+}
+```
+
+### `Boom.methodNotAllowed([message], [data])`
+
+Returns a 405 Method Not Allowed error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.methodNotAllowed('that method is not allowed');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 405,
+ "error": "Method Not Allowed",
+ "message": "that method is not allowed"
+}
+```
+
+### `Boom.notAcceptable([message], [data])`
+
+Returns a 406 Not Acceptable error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.notAcceptable('unacceptable');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 406,
+ "error": "Not Acceptable",
+ "message": "unacceptable"
+}
+```
+
+### `Boom.proxyAuthRequired([message], [data])`
+
+Returns a 407 Proxy Authentication Required error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.proxyAuthRequired('auth missing');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 407,
+ "error": "Proxy Authentication Required",
+ "message": "auth missing"
+}
+```
+
+### `Boom.clientTimeout([message], [data])`
+
+Returns a 408 Request Time-out error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.clientTimeout('timed out');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 408,
+ "error": "Request Time-out",
+ "message": "timed out"
+}
+```
+
+### `Boom.conflict([message], [data])`
+
+Returns a 409 Conflict error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.conflict('there was a conflict');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 409,
+ "error": "Conflict",
+ "message": "there was a conflict"
+}
+```
+
+### `Boom.resourceGone([message], [data])`
+
+Returns a 410 Gone error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.resourceGone('it is gone');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 410,
+ "error": "Gone",
+ "message": "it is gone"
+}
+```
+
+### `Boom.lengthRequired([message], [data])`
+
+Returns a 411 Length Required error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.lengthRequired('length needed');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 411,
+ "error": "Length Required",
+ "message": "length needed"
+}
+```
+
+### `Boom.preconditionFailed([message], [data])`
+
+Returns a 412 Precondition Failed error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.preconditionFailed();
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 412,
+ "error": "Precondition Failed"
+}
+```
+
+### `Boom.entityTooLarge([message], [data])`
+
+Returns a 413 Request Entity Too Large error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.entityTooLarge('too big');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 413,
+ "error": "Request Entity Too Large",
+ "message": "too big"
+}
+```
+
+### `Boom.uriTooLong([message], [data])`
+
+Returns a 414 Request-URI Too Large error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.uriTooLong('uri is too long');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 414,
+ "error": "Request-URI Too Large",
+ "message": "uri is too long"
+}
+```
+
+### `Boom.unsupportedMediaType([message], [data])`
+
+Returns a 415 Unsupported Media Type error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.unsupportedMediaType('that media is not supported');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 415,
+ "error": "Unsupported Media Type",
+ "message": "that media is not supported"
+}
+```
+
+### `Boom.rangeNotSatisfiable([message], [data])`
+
+Returns a 416 Requested Range Not Satisfiable error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.rangeNotSatisfiable();
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 416,
+ "error": "Requested Range Not Satisfiable"
+}
+```
+
+### `Boom.expectationFailed([message], [data])`
+
+Returns a 417 Expectation Failed error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.expectationFailed('expected this to work');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 417,
+ "error": "Expectation Failed",
+ "message": "expected this to work"
+}
+```
+
+### `Boom.badData([message], [data])`
+
+Returns a 422 Unprocessable Entity error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.badData('your data is bad and you should feel bad');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 422,
+ "error": "Unprocessable Entity",
+ "message": "your data is bad and you should feel bad"
+}
+```
+
+### `Boom.preconditionRequired([message], [data])`
+
+Returns a 428 Precondition Required error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.preconditionRequired('you must supply an If-Match header');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 428,
+ "error": "Precondition Required",
+ "message": "you must supply an If-Match header"
+}
+```
+
+### `Boom.tooManyRequests([message], [data])`
+
+Returns a 429 Too Many Requests error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.tooManyRequests('you have exceeded your request limit');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 429,
+ "error": "Too Many Requests",
+ "message": "you have exceeded your request limit"
+}
+```
+
+## HTTP 5xx Errors
+
+All 500 errors hide your message from the end user. Your message is recorded in the server log.
+
+### `Boom.badImplementation([message], [data])`
+
+Returns a 500 Internal Server Error error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.badImplementation('terrible implementation');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 500,
+ "error": "Internal Server Error",
+ "message": "An internal server error occurred"
+}
+```
+
+### `Boom.notImplemented([message], [data])`
+
+Returns a 501 Not Implemented error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.notImplemented('method not implemented');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 501,
+ "error": "Not Implemented",
+ "message": "method not implemented"
+}
+```
+
+### `Boom.badGateway([message], [data])`
+
+Returns a 502 Bad Gateway error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.badGateway('that is a bad gateway');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 502,
+ "error": "Bad Gateway",
+ "message": "that is a bad gateway"
+}
+```
+
+### `Boom.serverTimeout([message], [data])`
+
+Returns a 503 Service Unavailable error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.serverTimeout('unavailable');
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 503,
+ "error": "Service Unavailable",
+ "message": "unavailable"
+}
+```
+
+### `Boom.gatewayTimeout([message], [data])`
+
+Returns a 504 Gateway Time-out error where:
+- `message` - optional message.
+- `data` - optional additional error data.
+
+```js
+Boom.gatewayTimeout();
+```
+
+Generates the following response payload:
+
+```json
+{
+ "statusCode": 504,
+ "error": "Gateway Time-out"
+}
+```
+
+## F.A.Q.
+
+###### How do I include extra information in my responses? `output.payload` is missing `data`, what gives?
+
+There is a reason the values passed back in the response payloads are pretty locked down. It's mostly for security and to not leak any important information back to the client. This means you will need to put in a little more effort to include extra information about your custom error. Check out the ["Error transformation"](https://github.com/hapijs/hapi/blob/master/API.md#error-transformation) section in the hapi documentation.
diff --git a/node_modules/fsevents/node_modules/boom/images/boom.png b/node_modules/fsevents/node_modules/boom/images/boom.png
new file mode 100755
index 00000000..373bc134
Binary files /dev/null and b/node_modules/fsevents/node_modules/boom/images/boom.png differ
diff --git a/node_modules/fsevents/node_modules/boom/lib/index.js b/node_modules/fsevents/node_modules/boom/lib/index.js
new file mode 100755
index 00000000..6bdea693
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/lib/index.js
@@ -0,0 +1,318 @@
+// Load modules
+
+var Http = require('http');
+var Hoek = require('hoek');
+
+
+// Declare internals
+
+var internals = {};
+
+exports.wrap = function (error, statusCode, message) {
+
+ Hoek.assert(error instanceof Error, 'Cannot wrap non-Error object');
+ return (error.isBoom ? error : internals.initialize(error, statusCode || 500, message));
+};
+
+
+exports.create = function (statusCode, message, data) {
+
+ return internals.create(statusCode, message, data, exports.create);
+};
+
+internals.create = function (statusCode, message, data, ctor) {
+
+ var error = new Error(message ? message : undefined); // Avoids settings null message
+ Error.captureStackTrace(error, ctor); // Filter the stack to our external API
+ error.data = data || null;
+ internals.initialize(error, statusCode);
+ return error;
+};
+
+internals.initialize = function (error, statusCode, message) {
+
+ var numberCode = parseInt(statusCode, 10);
+ Hoek.assert(!isNaN(numberCode) && numberCode >= 400, 'First argument must be a number (400+):', statusCode);
+
+ error.isBoom = true;
+ error.isServer = numberCode >= 500;
+
+ if (!error.hasOwnProperty('data')) {
+ error.data = null;
+ }
+
+ error.output = {
+ statusCode: numberCode,
+ payload: {},
+ headers: {}
+ };
+
+ error.reformat = internals.reformat;
+ error.reformat();
+
+ if (!message &&
+ !error.message) {
+
+ message = error.output.payload.error;
+ }
+
+ if (message) {
+ error.message = (message + (error.message ? ': ' + error.message : ''));
+ }
+
+ return error;
+};
+
+
+internals.reformat = function () {
+
+ this.output.payload.statusCode = this.output.statusCode;
+ this.output.payload.error = Http.STATUS_CODES[this.output.statusCode] || 'Unknown';
+
+ if (this.output.statusCode === 500) {
+ this.output.payload.message = 'An internal server error occurred'; // Hide actual error from user
+ }
+ else if (this.message) {
+ this.output.payload.message = this.message;
+ }
+};
+
+
+// 4xx Client Errors
+
+exports.badRequest = function (message, data) {
+
+ return internals.create(400, message, data, exports.badRequest);
+};
+
+
+exports.unauthorized = function (message, scheme, attributes) { // Or function (message, wwwAuthenticate[])
+
+ var err = internals.create(401, message, undefined, exports.unauthorized);
+
+ if (!scheme) {
+ return err;
+ }
+
+ var wwwAuthenticate = '';
+ var i = 0;
+ var il = 0;
+
+ if (typeof scheme === 'string') {
+
+ // function (message, scheme, attributes)
+
+ wwwAuthenticate = scheme;
+
+ if (attributes || message) {
+ err.output.payload.attributes = {};
+ }
+
+ if (attributes) {
+ var names = Object.keys(attributes);
+ for (i = 0, il = names.length; i < il; ++i) {
+ var name = names[i];
+ if (i) {
+ wwwAuthenticate += ',';
+ }
+
+ var value = attributes[name];
+ if (value === null ||
+ value === undefined) { // Value can be zero
+
+ value = '';
+ }
+ wwwAuthenticate += ' ' + name + '="' + Hoek.escapeHeaderAttribute(value.toString()) + '"';
+ err.output.payload.attributes[name] = value;
+ }
+ }
+
+ if (message) {
+ if (attributes) {
+ wwwAuthenticate += ',';
+ }
+ wwwAuthenticate += ' error="' + Hoek.escapeHeaderAttribute(message) + '"';
+ err.output.payload.attributes.error = message;
+ }
+ else {
+ err.isMissing = true;
+ }
+ }
+ else {
+
+ // function (message, wwwAuthenticate[])
+
+ var wwwArray = scheme;
+ for (i = 0, il = wwwArray.length; i < il; ++i) {
+ if (i) {
+ wwwAuthenticate += ', ';
+ }
+
+ wwwAuthenticate += wwwArray[i];
+ }
+ }
+
+ err.output.headers['WWW-Authenticate'] = wwwAuthenticate;
+
+ return err;
+};
+
+
+exports.forbidden = function (message, data) {
+
+ return internals.create(403, message, data, exports.forbidden);
+};
+
+
+exports.notFound = function (message, data) {
+
+ return internals.create(404, message, data, exports.notFound);
+};
+
+
+exports.methodNotAllowed = function (message, data) {
+
+ return internals.create(405, message, data, exports.methodNotAllowed);
+};
+
+
+exports.notAcceptable = function (message, data) {
+
+ return internals.create(406, message, data, exports.notAcceptable);
+};
+
+
+exports.proxyAuthRequired = function (message, data) {
+
+ return internals.create(407, message, data, exports.proxyAuthRequired);
+};
+
+
+exports.clientTimeout = function (message, data) {
+
+ return internals.create(408, message, data, exports.clientTimeout);
+};
+
+
+exports.conflict = function (message, data) {
+
+ return internals.create(409, message, data, exports.conflict);
+};
+
+
+exports.resourceGone = function (message, data) {
+
+ return internals.create(410, message, data, exports.resourceGone);
+};
+
+
+exports.lengthRequired = function (message, data) {
+
+ return internals.create(411, message, data, exports.lengthRequired);
+};
+
+
+exports.preconditionFailed = function (message, data) {
+
+ return internals.create(412, message, data, exports.preconditionFailed);
+};
+
+
+exports.entityTooLarge = function (message, data) {
+
+ return internals.create(413, message, data, exports.entityTooLarge);
+};
+
+
+exports.uriTooLong = function (message, data) {
+
+ return internals.create(414, message, data, exports.uriTooLong);
+};
+
+
+exports.unsupportedMediaType = function (message, data) {
+
+ return internals.create(415, message, data, exports.unsupportedMediaType);
+};
+
+
+exports.rangeNotSatisfiable = function (message, data) {
+
+ return internals.create(416, message, data, exports.rangeNotSatisfiable);
+};
+
+
+exports.expectationFailed = function (message, data) {
+
+ return internals.create(417, message, data, exports.expectationFailed);
+};
+
+exports.badData = function (message, data) {
+
+ return internals.create(422, message, data, exports.badData);
+};
+
+
+exports.preconditionRequired = function (message, data) {
+
+ return internals.create(428, message, data, exports.preconditionRequired);
+};
+
+
+exports.tooManyRequests = function (message, data) {
+
+ return internals.create(429, message, data, exports.tooManyRequests);
+};
+
+
+// 5xx Server Errors
+
+exports.internal = function (message, data, statusCode) {
+
+ return internals.serverError(message, data, statusCode, exports.internal);
+};
+
+internals.serverError = function (message, data, statusCode, ctor) {
+
+ var error;
+ if (data instanceof Error) {
+ error = exports.wrap(data, statusCode, message);
+ } else {
+ error = internals.create(statusCode || 500, message, undefined, ctor);
+ error.data = data;
+ }
+
+ return error;
+};
+
+
+exports.notImplemented = function (message, data) {
+
+ return internals.serverError(message, data, 501, exports.notImplemented);
+};
+
+
+exports.badGateway = function (message, data) {
+
+ return internals.serverError(message, data, 502, exports.badGateway);
+};
+
+
+exports.serverTimeout = function (message, data) {
+
+ return internals.serverError(message, data, 503, exports.serverTimeout);
+};
+
+
+exports.gatewayTimeout = function (message, data) {
+
+ return internals.serverError(message, data, 504, exports.gatewayTimeout);
+};
+
+
+exports.badImplementation = function (message, data) {
+
+ var err = internals.serverError(message, data, 500, exports.badImplementation);
+ err.isDeveloperError = true;
+ return err;
+};
diff --git a/node_modules/fsevents/node_modules/boom/package.json b/node_modules/fsevents/node_modules/boom/package.json
new file mode 100644
index 00000000..84039cb5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/package.json
@@ -0,0 +1,98 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "boom@2.x.x",
+ "scope": null,
+ "escapedName": "boom",
+ "name": "boom",
+ "rawSpec": "2.x.x",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/hawk"
+ ]
+ ],
+ "_from": "boom@>=2.0.0 <3.0.0",
+ "_id": "boom@2.10.1",
+ "_inCache": true,
+ "_location": "/fsevents/boom",
+ "_nodeVersion": "0.10.40",
+ "_npmUser": {
+ "name": "arb",
+ "email": "arbretz@gmail.com"
+ },
+ "_npmVersion": "2.11.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "boom@2.x.x",
+ "scope": null,
+ "escapedName": "boom",
+ "name": "boom",
+ "rawSpec": "2.x.x",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/cryptiles",
+ "/fsevents/hawk"
+ ],
+ "_resolved": "https://registry.npmjs.org/boom/-/boom-2.10.1.tgz",
+ "_shasum": "39c8918ceff5799f83f9492a848f625add0c766f",
+ "_shrinkwrap": null,
+ "_spec": "boom@2.x.x",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/hawk",
+ "bugs": {
+ "url": "https://github.com/hapijs/boom/issues"
+ },
+ "dependencies": {
+ "hoek": "2.x.x"
+ },
+ "description": "HTTP-friendly error objects",
+ "devDependencies": {
+ "code": "1.x.x",
+ "lab": "7.x.x"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "39c8918ceff5799f83f9492a848f625add0c766f",
+ "tarball": "https://registry.npmjs.org/boom/-/boom-2.10.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.40"
+ },
+ "gitHead": "ff1a662a86b39426cdd18f4441b112d307a34a6f",
+ "homepage": "https://github.com/hapijs/boom#readme",
+ "keywords": [
+ "error",
+ "http"
+ ],
+ "license": "BSD-3-Clause",
+ "main": "lib/index.js",
+ "maintainers": [
+ {
+ "name": "hueniverse",
+ "email": "eran@hueniverse.com"
+ },
+ {
+ "name": "wyatt",
+ "email": "wpreul@gmail.com"
+ },
+ {
+ "name": "arb",
+ "email": "arbretz@gmail.com"
+ }
+ ],
+ "name": "boom",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/hapijs/boom.git"
+ },
+ "scripts": {
+ "test": "lab -a code -t 100 -L",
+ "test-cov-html": "lab -a code -r html -o coverage.html -L"
+ },
+ "version": "2.10.1"
+}
diff --git a/node_modules/fsevents/node_modules/boom/test/index.js b/node_modules/fsevents/node_modules/boom/test/index.js
new file mode 100755
index 00000000..79a59e9f
--- /dev/null
+++ b/node_modules/fsevents/node_modules/boom/test/index.js
@@ -0,0 +1,654 @@
+// Load modules
+
+var Code = require('code');
+var Boom = require('../lib');
+var Lab = require('lab');
+
+
+// Declare internals
+
+var internals = {};
+
+
+// Test shortcuts
+
+var lab = exports.lab = Lab.script();
+var describe = lab.describe;
+var it = lab.it;
+var expect = Code.expect;
+
+
+it('returns the same object when already boom', function (done) {
+
+ var error = Boom.badRequest();
+ var wrapped = Boom.wrap(error);
+ expect(error).to.equal(wrapped);
+ done();
+});
+
+it('returns an error with info when constructed using another error', function (done) {
+
+ var error = new Error('ka-boom');
+ error.xyz = 123;
+ var err = Boom.wrap(error);
+ expect(err.xyz).to.equal(123);
+ expect(err.message).to.equal('ka-boom');
+ expect(err.output).to.deep.equal({
+ statusCode: 500,
+ payload: {
+ statusCode: 500,
+ error: 'Internal Server Error',
+ message: 'An internal server error occurred'
+ },
+ headers: {}
+ });
+ expect(err.data).to.equal(null);
+ done();
+});
+
+it('does not override data when constructed using another error', function (done) {
+
+ var error = new Error('ka-boom');
+ error.data = { useful: 'data' };
+ var err = Boom.wrap(error);
+ expect(err.data).to.equal(error.data);
+ done();
+});
+
+it('sets new message when none exists', function (done) {
+
+ var error = new Error();
+ var wrapped = Boom.wrap(error, 400, 'something bad');
+ expect(wrapped.message).to.equal('something bad');
+ done();
+});
+
+it('throws when statusCode is not a number', function (done) {
+
+ expect(function () {
+
+ Boom.create('x');
+ }).to.throw('First argument must be a number (400+): x');
+ done();
+});
+
+it('will cast a number-string to an integer', function (done) {
+
+ var codes = [
+ { input: '404', result: 404 },
+ { input: '404.1', result: 404 },
+ { input: 400, result: 400 },
+ { input: 400.123, result: 400 }];
+ for (var i = 0, il = codes.length; i < il; ++i) {
+ var code = codes[i];
+ var err = Boom.create(code.input);
+ expect(err.output.statusCode).to.equal(code.result);
+ }
+
+ done();
+});
+
+it('throws when statusCode is not finite', function (done) {
+
+ expect(function () {
+
+ Boom.create(1 / 0);
+ }).to.throw('First argument must be a number (400+): null');
+ done();
+});
+
+it('sets error code to unknown', function (done) {
+
+ var err = Boom.create(999);
+ expect(err.output.payload.error).to.equal('Unknown');
+ done();
+});
+
+describe('create()', function () {
+
+ it('does not sets null message', function (done) {
+
+ var error = Boom.unauthorized(null);
+ expect(error.output.payload.message).to.not.exist();
+ expect(error.isServer).to.be.false();
+ done();
+ });
+
+ it('sets message and data', function (done) {
+
+ var error = Boom.badRequest('Missing data', { type: 'user' });
+ expect(error.data.type).to.equal('user');
+ expect(error.output.payload.message).to.equal('Missing data');
+ done();
+ });
+});
+
+describe('isBoom()', function () {
+
+ it('returns true for Boom object', function (done) {
+
+ expect(Boom.badRequest().isBoom).to.equal(true);
+ done();
+ });
+
+ it('returns false for Error object', function (done) {
+
+ expect((new Error()).isBoom).to.not.exist();
+ done();
+ });
+});
+
+describe('badRequest()', function () {
+
+ it('returns a 400 error statusCode', function (done) {
+
+ var error = Boom.badRequest();
+
+ expect(error.output.statusCode).to.equal(400);
+ expect(error.isServer).to.be.false();
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.badRequest('my message').message).to.equal('my message');
+ done();
+ });
+
+ it('sets the message to HTTP status if none provided', function (done) {
+
+ expect(Boom.badRequest().message).to.equal('Bad Request');
+ done();
+ });
+});
+
+describe('unauthorized()', function () {
+
+ it('returns a 401 error statusCode', function (done) {
+
+ var err = Boom.unauthorized();
+ expect(err.output.statusCode).to.equal(401);
+ expect(err.output.headers).to.deep.equal({});
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.unauthorized('my message').message).to.equal('my message');
+ done();
+ });
+
+ it('returns a WWW-Authenticate header when passed a scheme', function (done) {
+
+ var err = Boom.unauthorized('boom', 'Test');
+ expect(err.output.statusCode).to.equal(401);
+ expect(err.output.headers['WWW-Authenticate']).to.equal('Test error="boom"');
+ done();
+ });
+
+ it('returns a WWW-Authenticate header set to the schema array value', function (done) {
+
+ var err = Boom.unauthorized(null, ['Test','one','two']);
+ expect(err.output.statusCode).to.equal(401);
+ expect(err.output.headers['WWW-Authenticate']).to.equal('Test, one, two');
+ done();
+ });
+
+ it('returns a WWW-Authenticate header when passed a scheme and attributes', function (done) {
+
+ var err = Boom.unauthorized('boom', 'Test', { a: 1, b: 'something', c: null, d: 0 });
+ expect(err.output.statusCode).to.equal(401);
+ expect(err.output.headers['WWW-Authenticate']).to.equal('Test a="1", b="something", c="", d="0", error="boom"');
+ expect(err.output.payload.attributes).to.deep.equal({ a: 1, b: 'something', c: '', d: 0, error: 'boom' });
+ done();
+ });
+
+ it('returns a WWW-Authenticate header when passed attributes, missing error', function (done) {
+
+ var err = Boom.unauthorized(null, 'Test', { a: 1, b: 'something', c: null, d: 0 });
+ expect(err.output.statusCode).to.equal(401);
+ expect(err.output.headers['WWW-Authenticate']).to.equal('Test a="1", b="something", c="", d="0"');
+ expect(err.isMissing).to.equal(true);
+ done();
+ });
+
+ it('sets the isMissing flag when error message is empty', function (done) {
+
+ var err = Boom.unauthorized('', 'Basic');
+ expect(err.isMissing).to.equal(true);
+ done();
+ });
+
+ it('does not set the isMissing flag when error message is not empty', function (done) {
+
+ var err = Boom.unauthorized('message', 'Basic');
+ expect(err.isMissing).to.equal(undefined);
+ done();
+ });
+
+ it('sets a WWW-Authenticate when passed as an array', function (done) {
+
+ var err = Boom.unauthorized('message', ['Basic', 'Example e="1"', 'Another x="3", y="4"']);
+ expect(err.output.headers['WWW-Authenticate']).to.equal('Basic, Example e="1", Another x="3", y="4"');
+ done();
+ });
+});
+
+
+describe('methodNotAllowed()', function () {
+
+ it('returns a 405 error statusCode', function (done) {
+
+ expect(Boom.methodNotAllowed().output.statusCode).to.equal(405);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.methodNotAllowed('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('notAcceptable()', function () {
+
+ it('returns a 406 error statusCode', function (done) {
+
+ expect(Boom.notAcceptable().output.statusCode).to.equal(406);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.notAcceptable('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('proxyAuthRequired()', function () {
+
+ it('returns a 407 error statusCode', function (done) {
+
+ expect(Boom.proxyAuthRequired().output.statusCode).to.equal(407);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.proxyAuthRequired('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('clientTimeout()', function () {
+
+ it('returns a 408 error statusCode', function (done) {
+
+ expect(Boom.clientTimeout().output.statusCode).to.equal(408);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.clientTimeout('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('conflict()', function () {
+
+ it('returns a 409 error statusCode', function (done) {
+
+ expect(Boom.conflict().output.statusCode).to.equal(409);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.conflict('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('resourceGone()', function () {
+
+ it('returns a 410 error statusCode', function (done) {
+
+ expect(Boom.resourceGone().output.statusCode).to.equal(410);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.resourceGone('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('lengthRequired()', function () {
+
+ it('returns a 411 error statusCode', function (done) {
+
+ expect(Boom.lengthRequired().output.statusCode).to.equal(411);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.lengthRequired('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('preconditionFailed()', function () {
+
+ it('returns a 412 error statusCode', function (done) {
+
+ expect(Boom.preconditionFailed().output.statusCode).to.equal(412);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.preconditionFailed('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('entityTooLarge()', function () {
+
+ it('returns a 413 error statusCode', function (done) {
+
+ expect(Boom.entityTooLarge().output.statusCode).to.equal(413);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.entityTooLarge('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('uriTooLong()', function () {
+
+ it('returns a 414 error statusCode', function (done) {
+
+ expect(Boom.uriTooLong().output.statusCode).to.equal(414);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.uriTooLong('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('unsupportedMediaType()', function () {
+
+ it('returns a 415 error statusCode', function (done) {
+
+ expect(Boom.unsupportedMediaType().output.statusCode).to.equal(415);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.unsupportedMediaType('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('rangeNotSatisfiable()', function () {
+
+ it('returns a 416 error statusCode', function (done) {
+
+ expect(Boom.rangeNotSatisfiable().output.statusCode).to.equal(416);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.rangeNotSatisfiable('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('expectationFailed()', function () {
+
+ it('returns a 417 error statusCode', function (done) {
+
+ expect(Boom.expectationFailed().output.statusCode).to.equal(417);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.expectationFailed('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('badData()', function () {
+
+ it('returns a 422 error statusCode', function (done) {
+
+ expect(Boom.badData().output.statusCode).to.equal(422);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.badData('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('preconditionRequired()', function () {
+
+ it('returns a 428 error statusCode', function (done) {
+
+ expect(Boom.preconditionRequired().output.statusCode).to.equal(428);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.preconditionRequired('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('tooManyRequests()', function () {
+
+ it('returns a 429 error statusCode', function (done) {
+
+ expect(Boom.tooManyRequests().output.statusCode).to.equal(429);
+ done();
+ });
+
+ it('sets the message with the passed-in message', function (done) {
+
+ expect(Boom.tooManyRequests('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+describe('serverTimeout()', function () {
+
+ it('returns a 503 error statusCode', function (done) {
+
+ expect(Boom.serverTimeout().output.statusCode).to.equal(503);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.serverTimeout('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+describe('forbidden()', function () {
+
+ it('returns a 403 error statusCode', function (done) {
+
+ expect(Boom.forbidden().output.statusCode).to.equal(403);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.forbidden('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+describe('notFound()', function () {
+
+ it('returns a 404 error statusCode', function (done) {
+
+ expect(Boom.notFound().output.statusCode).to.equal(404);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.notFound('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+describe('internal()', function () {
+
+ it('returns a 500 error statusCode', function (done) {
+
+ expect(Boom.internal().output.statusCode).to.equal(500);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ var err = Boom.internal('my message');
+ expect(err.message).to.equal('my message');
+ expect(err.isServer).to.true();
+ expect(err.output.payload.message).to.equal('An internal server error occurred');
+ done();
+ });
+
+ it('passes data on the callback if its passed in', function (done) {
+
+ expect(Boom.internal('my message', { my: 'data' }).data.my).to.equal('data');
+ done();
+ });
+
+ it('returns an error with composite message', function (done) {
+
+ try {
+ JSON.parse('{');
+ }
+ catch (err) {
+ var boom = Boom.internal('Someting bad', err);
+ expect(boom.message).to.equal('Someting bad: Unexpected end of input');
+ expect(boom.isServer).to.be.true();
+ done();
+ }
+ });
+});
+
+describe('notImplemented()', function () {
+
+ it('returns a 501 error statusCode', function (done) {
+
+ expect(Boom.notImplemented().output.statusCode).to.equal(501);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.notImplemented('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+
+describe('badGateway()', function () {
+
+ it('returns a 502 error statusCode', function (done) {
+
+ expect(Boom.badGateway().output.statusCode).to.equal(502);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.badGateway('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+describe('gatewayTimeout()', function () {
+
+ it('returns a 504 error statusCode', function (done) {
+
+ expect(Boom.gatewayTimeout().output.statusCode).to.equal(504);
+ done();
+ });
+
+ it('sets the message with the passed in message', function (done) {
+
+ expect(Boom.gatewayTimeout('my message').message).to.equal('my message');
+ done();
+ });
+});
+
+describe('badImplementation()', function () {
+
+ it('returns a 500 error statusCode', function (done) {
+
+ var err = Boom.badImplementation();
+ expect(err.output.statusCode).to.equal(500);
+ expect(err.isDeveloperError).to.equal(true);
+ expect(err.isServer).to.be.true();
+ done();
+ });
+});
+
+describe('stack trace', function () {
+
+ it('should omit lib', function (done) {
+
+ ['badRequest', 'unauthorized', 'forbidden', 'notFound', 'methodNotAllowed',
+ 'notAcceptable', 'proxyAuthRequired', 'clientTimeout', 'conflict',
+ 'resourceGone', 'lengthRequired', 'preconditionFailed', 'entityTooLarge',
+ 'uriTooLong', 'unsupportedMediaType', 'rangeNotSatisfiable', 'expectationFailed',
+ 'badData', 'preconditionRequired', 'tooManyRequests',
+
+ // 500s
+ 'internal', 'notImplemented', 'badGateway', 'serverTimeout', 'gatewayTimeout',
+ 'badImplementation'
+ ].forEach(function (name) {
+
+ var err = Boom[name]();
+ expect(err.stack).to.not.match(/\/lib\/index\.js/);
+ });
+
+ done();
+ });
+});
diff --git a/node_modules/fsevents/node_modules/brace-expansion/README.md b/node_modules/fsevents/node_modules/brace-expansion/README.md
new file mode 100644
index 00000000..17939297
--- /dev/null
+++ b/node_modules/fsevents/node_modules/brace-expansion/README.md
@@ -0,0 +1,122 @@
+# brace-expansion
+
+[Brace expansion](https://www.gnu.org/software/bash/manual/html_node/Brace-Expansion.html),
+as known from sh/bash, in JavaScript.
+
+[](http://travis-ci.org/juliangruber/brace-expansion)
+[](https://www.npmjs.org/package/brace-expansion)
+
+[](https://ci.testling.com/juliangruber/brace-expansion)
+
+## Example
+
+```js
+var expand = require('brace-expansion');
+
+expand('file-{a,b,c}.jpg')
+// => ['file-a.jpg', 'file-b.jpg', 'file-c.jpg']
+
+expand('-v{,,}')
+// => ['-v', '-v', '-v']
+
+expand('file{0..2}.jpg')
+// => ['file0.jpg', 'file1.jpg', 'file2.jpg']
+
+expand('file-{a..c}.jpg')
+// => ['file-a.jpg', 'file-b.jpg', 'file-c.jpg']
+
+expand('file{2..0}.jpg')
+// => ['file2.jpg', 'file1.jpg', 'file0.jpg']
+
+expand('file{0..4..2}.jpg')
+// => ['file0.jpg', 'file2.jpg', 'file4.jpg']
+
+expand('file-{a..e..2}.jpg')
+// => ['file-a.jpg', 'file-c.jpg', 'file-e.jpg']
+
+expand('file{00..10..5}.jpg')
+// => ['file00.jpg', 'file05.jpg', 'file10.jpg']
+
+expand('{{A..C},{a..c}}')
+// => ['A', 'B', 'C', 'a', 'b', 'c']
+
+expand('ppp{,config,oe{,conf}}')
+// => ['ppp', 'pppconfig', 'pppoe', 'pppoeconf']
+```
+
+## API
+
+```js
+var expand = require('brace-expansion');
+```
+
+### var expanded = expand(str)
+
+Return an array of all possible and valid expansions of `str`. If none are
+found, `[str]` is returned.
+
+Valid expansions are:
+
+```js
+/^(.*,)+(.+)?$/
+// {a,b,...}
+```
+
+A comma seperated list of options, like `{a,b}` or `{a,{b,c}}` or `{,a,}`.
+
+```js
+/^-?\d+\.\.-?\d+(\.\.-?\d+)?$/
+// {x..y[..incr]}
+```
+
+A numeric sequence from `x` to `y` inclusive, with optional increment.
+If `x` or `y` start with a leading `0`, all the numbers will be padded
+to have equal length. Negative numbers and backwards iteration work too.
+
+```js
+/^-?\d+\.\.-?\d+(\.\.-?\d+)?$/
+// {x..y[..incr]}
+```
+
+An alphabetic sequence from `x` to `y` inclusive, with optional increment.
+`x` and `y` must be exactly one character, and if given, `incr` must be a
+number.
+
+For compatibility reasons, the string `${` is not eligible for brace expansion.
+
+## Installation
+
+With [npm](https://npmjs.org) do:
+
+```bash
+npm install brace-expansion
+```
+
+## Contributors
+
+- [Julian Gruber](https://github.com/juliangruber)
+- [Isaac Z. Schlueter](https://github.com/isaacs)
+
+## License
+
+(MIT)
+
+Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+of the Software, and to permit persons to whom the Software is furnished to do
+so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/brace-expansion/index.js b/node_modules/fsevents/node_modules/brace-expansion/index.js
new file mode 100644
index 00000000..955f27c8
--- /dev/null
+++ b/node_modules/fsevents/node_modules/brace-expansion/index.js
@@ -0,0 +1,201 @@
+var concatMap = require('concat-map');
+var balanced = require('balanced-match');
+
+module.exports = expandTop;
+
+var escSlash = '\0SLASH'+Math.random()+'\0';
+var escOpen = '\0OPEN'+Math.random()+'\0';
+var escClose = '\0CLOSE'+Math.random()+'\0';
+var escComma = '\0COMMA'+Math.random()+'\0';
+var escPeriod = '\0PERIOD'+Math.random()+'\0';
+
+function numeric(str) {
+ return parseInt(str, 10) == str
+ ? parseInt(str, 10)
+ : str.charCodeAt(0);
+}
+
+function escapeBraces(str) {
+ return str.split('\\\\').join(escSlash)
+ .split('\\{').join(escOpen)
+ .split('\\}').join(escClose)
+ .split('\\,').join(escComma)
+ .split('\\.').join(escPeriod);
+}
+
+function unescapeBraces(str) {
+ return str.split(escSlash).join('\\')
+ .split(escOpen).join('{')
+ .split(escClose).join('}')
+ .split(escComma).join(',')
+ .split(escPeriod).join('.');
+}
+
+
+// Basically just str.split(","), but handling cases
+// where we have nested braced sections, which should be
+// treated as individual members, like {a,{b,c},d}
+function parseCommaParts(str) {
+ if (!str)
+ return [''];
+
+ var parts = [];
+ var m = balanced('{', '}', str);
+
+ if (!m)
+ return str.split(',');
+
+ var pre = m.pre;
+ var body = m.body;
+ var post = m.post;
+ var p = pre.split(',');
+
+ p[p.length-1] += '{' + body + '}';
+ var postParts = parseCommaParts(post);
+ if (post.length) {
+ p[p.length-1] += postParts.shift();
+ p.push.apply(p, postParts);
+ }
+
+ parts.push.apply(parts, p);
+
+ return parts;
+}
+
+function expandTop(str) {
+ if (!str)
+ return [];
+
+ // I don't know why Bash 4.3 does this, but it does.
+ // Anything starting with {} will have the first two bytes preserved
+ // but *only* at the top level, so {},a}b will not expand to anything,
+ // but a{},b}c will be expanded to [a}c,abc].
+ // One could argue that this is a bug in Bash, but since the goal of
+ // this module is to match Bash's rules, we escape a leading {}
+ if (str.substr(0, 2) === '{}') {
+ str = '\\{\\}' + str.substr(2);
+ }
+
+ return expand(escapeBraces(str), true).map(unescapeBraces);
+}
+
+function identity(e) {
+ return e;
+}
+
+function embrace(str) {
+ return '{' + str + '}';
+}
+function isPadded(el) {
+ return /^-?0\d/.test(el);
+}
+
+function lte(i, y) {
+ return i <= y;
+}
+function gte(i, y) {
+ return i >= y;
+}
+
+function expand(str, isTop) {
+ var expansions = [];
+
+ var m = balanced('{', '}', str);
+ if (!m || /\$$/.test(m.pre)) return [str];
+
+ var isNumericSequence = /^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(m.body);
+ var isAlphaSequence = /^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(m.body);
+ var isSequence = isNumericSequence || isAlphaSequence;
+ var isOptions = /^(.*,)+(.+)?$/.test(m.body);
+ if (!isSequence && !isOptions) {
+ // {a},b}
+ if (m.post.match(/,.*\}/)) {
+ str = m.pre + '{' + m.body + escClose + m.post;
+ return expand(str);
+ }
+ return [str];
+ }
+
+ var n;
+ if (isSequence) {
+ n = m.body.split(/\.\./);
+ } else {
+ n = parseCommaParts(m.body);
+ if (n.length === 1) {
+ // x{{a,b}}y ==> x{a}y x{b}y
+ n = expand(n[0], false).map(embrace);
+ if (n.length === 1) {
+ var post = m.post.length
+ ? expand(m.post, false)
+ : [''];
+ return post.map(function(p) {
+ return m.pre + n[0] + p;
+ });
+ }
+ }
+ }
+
+ // at this point, n is the parts, and we know it's not a comma set
+ // with a single entry.
+
+ // no need to expand pre, since it is guaranteed to be free of brace-sets
+ var pre = m.pre;
+ var post = m.post.length
+ ? expand(m.post, false)
+ : [''];
+
+ var N;
+
+ if (isSequence) {
+ var x = numeric(n[0]);
+ var y = numeric(n[1]);
+ var width = Math.max(n[0].length, n[1].length)
+ var incr = n.length == 3
+ ? Math.abs(numeric(n[2]))
+ : 1;
+ var test = lte;
+ var reverse = y < x;
+ if (reverse) {
+ incr *= -1;
+ test = gte;
+ }
+ var pad = n.some(isPadded);
+
+ N = [];
+
+ for (var i = x; test(i, y); i += incr) {
+ var c;
+ if (isAlphaSequence) {
+ c = String.fromCharCode(i);
+ if (c === '\\')
+ c = '';
+ } else {
+ c = String(i);
+ if (pad) {
+ var need = width - c.length;
+ if (need > 0) {
+ var z = new Array(need + 1).join('0');
+ if (i < 0)
+ c = '-' + z + c.slice(1);
+ else
+ c = z + c;
+ }
+ }
+ }
+ N.push(c);
+ }
+ } else {
+ N = concatMap(n, function(el) { return expand(el, false) });
+ }
+
+ for (var j = 0; j < N.length; j++) {
+ for (var k = 0; k < post.length; k++) {
+ var expansion = pre + N[j] + post[k];
+ if (!isTop || isSequence || expansion)
+ expansions.push(expansion);
+ }
+ }
+
+ return expansions;
+}
+
diff --git a/node_modules/fsevents/node_modules/brace-expansion/package.json b/node_modules/fsevents/node_modules/brace-expansion/package.json
new file mode 100644
index 00000000..6291362a
--- /dev/null
+++ b/node_modules/fsevents/node_modules/brace-expansion/package.json
@@ -0,0 +1,112 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "brace-expansion@^1.0.0",
+ "scope": null,
+ "escapedName": "brace-expansion",
+ "name": "brace-expansion",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/minimatch"
+ ]
+ ],
+ "_from": "brace-expansion@>=1.0.0 <2.0.0",
+ "_id": "brace-expansion@1.1.6",
+ "_inCache": true,
+ "_location": "/fsevents/brace-expansion",
+ "_nodeVersion": "4.4.7",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/brace-expansion-1.1.6.tgz_1469047715600_0.9362958471756428"
+ },
+ "_npmUser": {
+ "name": "juliangruber",
+ "email": "julian@juliangruber.com"
+ },
+ "_npmVersion": "2.15.8",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "brace-expansion@^1.0.0",
+ "scope": null,
+ "escapedName": "brace-expansion",
+ "name": "brace-expansion",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/minimatch"
+ ],
+ "_resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.6.tgz",
+ "_shasum": "7197d7eaa9b87e648390ea61fc66c84427420df9",
+ "_shrinkwrap": null,
+ "_spec": "brace-expansion@^1.0.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/minimatch",
+ "author": {
+ "name": "Julian Gruber",
+ "email": "mail@juliangruber.com",
+ "url": "http://juliangruber.com"
+ },
+ "bugs": {
+ "url": "https://github.com/juliangruber/brace-expansion/issues"
+ },
+ "dependencies": {
+ "balanced-match": "^0.4.1",
+ "concat-map": "0.0.1"
+ },
+ "description": "Brace expansion as known from sh/bash",
+ "devDependencies": {
+ "tape": "^4.6.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "7197d7eaa9b87e648390ea61fc66c84427420df9",
+ "tarball": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.6.tgz"
+ },
+ "gitHead": "791262fa06625e9c5594cde529a21d82086af5f2",
+ "homepage": "https://github.com/juliangruber/brace-expansion",
+ "keywords": [],
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "juliangruber",
+ "email": "julian@juliangruber.com"
+ },
+ {
+ "name": "isaacs",
+ "email": "isaacs@npmjs.com"
+ }
+ ],
+ "name": "brace-expansion",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/juliangruber/brace-expansion.git"
+ },
+ "scripts": {
+ "gentest": "bash test/generate.sh",
+ "test": "tape test/*.js"
+ },
+ "testling": {
+ "files": "test/*.js",
+ "browsers": [
+ "ie/8..latest",
+ "firefox/20..latest",
+ "firefox/nightly",
+ "chrome/25..latest",
+ "chrome/canary",
+ "opera/12..latest",
+ "opera/next",
+ "safari/5.1..latest",
+ "ipad/6.0..latest",
+ "iphone/6.0..latest",
+ "android-browser/4.2..latest"
+ ]
+ },
+ "version": "1.1.6"
+}
diff --git a/node_modules/fsevents/node_modules/buffer-shims/index.js b/node_modules/fsevents/node_modules/buffer-shims/index.js
new file mode 100644
index 00000000..1cab4c05
--- /dev/null
+++ b/node_modules/fsevents/node_modules/buffer-shims/index.js
@@ -0,0 +1,108 @@
+'use strict';
+
+var buffer = require('buffer');
+var Buffer = buffer.Buffer;
+var SlowBuffer = buffer.SlowBuffer;
+var MAX_LEN = buffer.kMaxLength || 2147483647;
+exports.alloc = function alloc(size, fill, encoding) {
+ if (typeof Buffer.alloc === 'function') {
+ return Buffer.alloc(size, fill, encoding);
+ }
+ if (typeof encoding === 'number') {
+ throw new TypeError('encoding must not be number');
+ }
+ if (typeof size !== 'number') {
+ throw new TypeError('size must be a number');
+ }
+ if (size > MAX_LEN) {
+ throw new RangeError('size is too large');
+ }
+ var enc = encoding;
+ var _fill = fill;
+ if (_fill === undefined) {
+ enc = undefined;
+ _fill = 0;
+ }
+ var buf = new Buffer(size);
+ if (typeof _fill === 'string') {
+ var fillBuf = new Buffer(_fill, enc);
+ var flen = fillBuf.length;
+ var i = -1;
+ while (++i < size) {
+ buf[i] = fillBuf[i % flen];
+ }
+ } else {
+ buf.fill(_fill);
+ }
+ return buf;
+}
+exports.allocUnsafe = function allocUnsafe(size) {
+ if (typeof Buffer.allocUnsafe === 'function') {
+ return Buffer.allocUnsafe(size);
+ }
+ if (typeof size !== 'number') {
+ throw new TypeError('size must be a number');
+ }
+ if (size > MAX_LEN) {
+ throw new RangeError('size is too large');
+ }
+ return new Buffer(size);
+}
+exports.from = function from(value, encodingOrOffset, length) {
+ if (typeof Buffer.from === 'function' && (!global.Uint8Array || Uint8Array.from !== Buffer.from)) {
+ return Buffer.from(value, encodingOrOffset, length);
+ }
+ if (typeof value === 'number') {
+ throw new TypeError('"value" argument must not be a number');
+ }
+ if (typeof value === 'string') {
+ return new Buffer(value, encodingOrOffset);
+ }
+ if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) {
+ var offset = encodingOrOffset;
+ if (arguments.length === 1) {
+ return new Buffer(value);
+ }
+ if (typeof offset === 'undefined') {
+ offset = 0;
+ }
+ var len = length;
+ if (typeof len === 'undefined') {
+ len = value.byteLength - offset;
+ }
+ if (offset >= value.byteLength) {
+ throw new RangeError('\'offset\' is out of bounds');
+ }
+ if (len > value.byteLength - offset) {
+ throw new RangeError('\'length\' is out of bounds');
+ }
+ return new Buffer(value.slice(offset, offset + len));
+ }
+ if (Buffer.isBuffer(value)) {
+ var out = new Buffer(value.length);
+ value.copy(out, 0, 0, value.length);
+ return out;
+ }
+ if (value) {
+ if (Array.isArray(value) || (typeof ArrayBuffer !== 'undefined' && value.buffer instanceof ArrayBuffer) || 'length' in value) {
+ return new Buffer(value);
+ }
+ if (value.type === 'Buffer' && Array.isArray(value.data)) {
+ return new Buffer(value.data);
+ }
+ }
+
+ throw new TypeError('First argument must be a string, Buffer, ' + 'ArrayBuffer, Array, or array-like object.');
+}
+exports.allocUnsafeSlow = function allocUnsafeSlow(size) {
+ if (typeof Buffer.allocUnsafeSlow === 'function') {
+ return Buffer.allocUnsafeSlow(size);
+ }
+ if (typeof size !== 'number') {
+ throw new TypeError('size must be a number');
+ }
+ if (size >= MAX_LEN) {
+ throw new RangeError('size is too large');
+ }
+ return new SlowBuffer(size);
+}
diff --git a/node_modules/fsevents/node_modules/buffer-shims/license.md b/node_modules/fsevents/node_modules/buffer-shims/license.md
new file mode 100644
index 00000000..01cfaefe
--- /dev/null
+++ b/node_modules/fsevents/node_modules/buffer-shims/license.md
@@ -0,0 +1,19 @@
+# Copyright (c) 2016 Calvin Metcalf
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+**THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.**
diff --git a/node_modules/fsevents/node_modules/buffer-shims/package.json b/node_modules/fsevents/node_modules/buffer-shims/package.json
new file mode 100644
index 00000000..e71dd04e
--- /dev/null
+++ b/node_modules/fsevents/node_modules/buffer-shims/package.json
@@ -0,0 +1,86 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "buffer-shims@^1.0.0",
+ "scope": null,
+ "escapedName": "buffer-shims",
+ "name": "buffer-shims",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/readable-stream"
+ ]
+ ],
+ "_from": "buffer-shims@>=1.0.0 <2.0.0",
+ "_id": "buffer-shims@1.0.0",
+ "_inCache": true,
+ "_location": "/fsevents/buffer-shims",
+ "_nodeVersion": "5.11.0",
+ "_npmOperationalInternal": {
+ "host": "packages-16-east.internal.npmjs.com",
+ "tmp": "tmp/buffer-shims-1.0.0.tgz_1462560889323_0.8640750856138766"
+ },
+ "_npmUser": {
+ "name": "cwmma",
+ "email": "calvin.metcalf@gmail.com"
+ },
+ "_npmVersion": "3.8.6",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "buffer-shims@^1.0.0",
+ "scope": null,
+ "escapedName": "buffer-shims",
+ "name": "buffer-shims",
+ "rawSpec": "^1.0.0",
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/readable-stream",
+ "/fsevents/tar-pack/readable-stream"
+ ],
+ "_resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz",
+ "_shasum": "9978ce317388c649ad8793028c3477ef044a8b51",
+ "_shrinkwrap": null,
+ "_spec": "buffer-shims@^1.0.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/readable-stream",
+ "bugs": {
+ "url": "https://github.com/calvinmetcalf/buffer-shims/issues"
+ },
+ "dependencies": {},
+ "description": "some shims for node buffers",
+ "devDependencies": {
+ "tape": "^4.5.1"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "9978ce317388c649ad8793028c3477ef044a8b51",
+ "tarball": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "ea89b3857ab5b8203957922a84e9a48cf4c47e0a",
+ "homepage": "https://github.com/calvinmetcalf/buffer-shims#readme",
+ "license": "MIT",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "cwmma",
+ "email": "calvin.metcalf@gmail.com"
+ }
+ ],
+ "name": "buffer-shims",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+ssh://git@github.com/calvinmetcalf/buffer-shims.git"
+ },
+ "scripts": {
+ "test": "tape test/*.js"
+ },
+ "version": "1.0.0"
+}
diff --git a/node_modules/fsevents/node_modules/buffer-shims/readme.md b/node_modules/fsevents/node_modules/buffer-shims/readme.md
new file mode 100644
index 00000000..7ea6475e
--- /dev/null
+++ b/node_modules/fsevents/node_modules/buffer-shims/readme.md
@@ -0,0 +1,21 @@
+buffer-shims
+===
+
+functions to make sure the new buffer methods work in older browsers.
+
+```js
+var bufferShim = require('buffer-shims');
+bufferShim.from('foo');
+bufferShim.alloc(9, 'cafeface', 'hex');
+bufferShim.allocUnsafe(15);
+bufferShim.allocUnsafeSlow(21);
+```
+
+should just use the original in newer nodes and on older nodes uses fallbacks.
+
+Known Issues
+===
+- this does not patch the buffer object, only the constructor stuff
+- it's actually a polyfill
+
+
diff --git a/node_modules/fsevents/node_modules/caseless/LICENSE b/node_modules/fsevents/node_modules/caseless/LICENSE
new file mode 100644
index 00000000..61789f4a
--- /dev/null
+++ b/node_modules/fsevents/node_modules/caseless/LICENSE
@@ -0,0 +1,28 @@
+Apache License
+Version 2.0, January 2004
+http://www.apache.org/licenses/
+TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+1. Definitions.
+"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
+"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
+"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
+"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
+"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
+"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
+"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
+"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
+"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
+"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
+2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
+3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
+4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
+You must give any other recipients of the Work or Derivative Works a copy of this License; and
+You must cause any modified files to carry prominent notices stating that You changed the files; and
+You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
+If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
+5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
+6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
+7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
+8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
+9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
+END OF TERMS AND CONDITIONS
\ No newline at end of file
diff --git a/node_modules/fsevents/node_modules/caseless/README.md b/node_modules/fsevents/node_modules/caseless/README.md
new file mode 100644
index 00000000..e5077a21
--- /dev/null
+++ b/node_modules/fsevents/node_modules/caseless/README.md
@@ -0,0 +1,45 @@
+## Caseless -- wrap an object to set and get property with caseless semantics but also preserve caseing.
+
+This library is incredibly useful when working with HTTP headers. It allows you to get/set/check for headers in a caseless manner while also preserving the caseing of headers the first time they are set.
+
+## Usage
+
+```javascript
+var headers = {}
+ , c = caseless(headers)
+ ;
+c.set('a-Header', 'asdf')
+c.get('a-header') === 'asdf'
+```
+
+## has(key)
+
+Has takes a name and if it finds a matching header will return that header name with the preserved caseing it was set with.
+
+```javascript
+c.has('a-header') === 'a-Header'
+```
+
+## set(key, value[, clobber=true])
+
+Set is fairly straight forward except that if the header exists and clobber is disabled it will add `','+value` to the existing header.
+
+```javascript
+c.set('a-Header', 'fdas')
+c.set('a-HEADER', 'more', false)
+c.get('a-header') === 'fdsa,more'
+```
+
+## swap(key)
+
+Swaps the casing of a header with the new one that is passed in.
+
+```javascript
+var headers = {}
+ , c = caseless(headers)
+ ;
+c.set('a-Header', 'fdas')
+c.swap('a-HEADER')
+c.has('a-header') === 'a-HEADER'
+headers === {'a-HEADER': 'fdas'}
+```
diff --git a/node_modules/fsevents/node_modules/caseless/index.js b/node_modules/fsevents/node_modules/caseless/index.js
new file mode 100644
index 00000000..d86a70ec
--- /dev/null
+++ b/node_modules/fsevents/node_modules/caseless/index.js
@@ -0,0 +1,66 @@
+function Caseless (dict) {
+ this.dict = dict || {}
+}
+Caseless.prototype.set = function (name, value, clobber) {
+ if (typeof name === 'object') {
+ for (var i in name) {
+ this.set(i, name[i], value)
+ }
+ } else {
+ if (typeof clobber === 'undefined') clobber = true
+ var has = this.has(name)
+
+ if (!clobber && has) this.dict[has] = this.dict[has] + ',' + value
+ else this.dict[has || name] = value
+ return has
+ }
+}
+Caseless.prototype.has = function (name) {
+ var keys = Object.keys(this.dict)
+ , name = name.toLowerCase()
+ ;
+ for (var i=0;i=0.11.0 <0.12.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/request"
+ ]
+ ],
+ "_from": "caseless@>=0.11.0 <0.12.0",
+ "_id": "caseless@0.11.0",
+ "_inCache": true,
+ "_location": "/fsevents/caseless",
+ "_nodeVersion": "1.8.1",
+ "_npmUser": {
+ "name": "mikeal",
+ "email": "mikeal.rogers@gmail.com"
+ },
+ "_npmVersion": "2.8.3",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "caseless@~0.11.0",
+ "scope": null,
+ "escapedName": "caseless",
+ "name": "caseless",
+ "rawSpec": "~0.11.0",
+ "spec": ">=0.11.0 <0.12.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/request"
+ ],
+ "_resolved": "https://registry.npmjs.org/caseless/-/caseless-0.11.0.tgz",
+ "_shasum": "715b96ea9841593cc33067923f5ec60ebda4f7d7",
+ "_shrinkwrap": null,
+ "_spec": "caseless@~0.11.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/request",
+ "author": {
+ "name": "Mikeal Rogers",
+ "email": "mikeal.rogers@gmail.com"
+ },
+ "bugs": {
+ "url": "https://github.com/mikeal/caseless/issues"
+ },
+ "dependencies": {},
+ "description": "Caseless object set/get/has, very useful when working with HTTP headers.",
+ "devDependencies": {
+ "tape": "^2.10.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "715b96ea9841593cc33067923f5ec60ebda4f7d7",
+ "tarball": "https://registry.npmjs.org/caseless/-/caseless-0.11.0.tgz"
+ },
+ "gitHead": "c578232a02cc2b46b6da8851caf57fdbfac89ff5",
+ "homepage": "https://github.com/mikeal/caseless#readme",
+ "keywords": [
+ "headers",
+ "http",
+ "caseless"
+ ],
+ "license": "Apache-2.0",
+ "main": "index.js",
+ "maintainers": [
+ {
+ "name": "mikeal",
+ "email": "mikeal.rogers@gmail.com"
+ },
+ {
+ "name": "nylen",
+ "email": "jnylen@gmail.com"
+ },
+ {
+ "name": "simov",
+ "email": "simeonvelichkov@gmail.com"
+ }
+ ],
+ "name": "caseless",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/mikeal/caseless.git"
+ },
+ "scripts": {
+ "test": "node test.js"
+ },
+ "test": "node test.js",
+ "version": "0.11.0"
+}
diff --git a/node_modules/fsevents/node_modules/caseless/test.js b/node_modules/fsevents/node_modules/caseless/test.js
new file mode 100644
index 00000000..084bbaf5
--- /dev/null
+++ b/node_modules/fsevents/node_modules/caseless/test.js
@@ -0,0 +1,40 @@
+var tape = require('tape')
+ , caseless = require('./')
+ ;
+
+tape('set get has', function (t) {
+ var headers = {}
+ , c = caseless(headers)
+ ;
+ t.plan(17)
+ c.set('a-Header', 'asdf')
+ t.equal(c.get('a-header'), 'asdf')
+ t.equal(c.has('a-header'), 'a-Header')
+ t.ok(!c.has('nothing'))
+ // old bug where we used the wrong regex
+ t.ok(!c.has('a-hea'))
+ c.set('a-header', 'fdsa')
+ t.equal(c.get('a-header'), 'fdsa')
+ t.equal(c.get('a-Header'), 'fdsa')
+ c.set('a-HEADER', 'more', false)
+ t.equal(c.get('a-header'), 'fdsa,more')
+
+ t.deepEqual(headers, {'a-Header': 'fdsa,more'})
+ c.swap('a-HEADER')
+ t.deepEqual(headers, {'a-HEADER': 'fdsa,more'})
+
+ c.set('deleteme', 'foobar')
+ t.ok(c.has('deleteme'))
+ t.ok(c.del('deleteme'))
+ t.notOk(c.has('deleteme'))
+ t.notOk(c.has('idonotexist'))
+ t.ok(c.del('idonotexist'))
+
+ c.set('tva', 'test1')
+ c.set('tva-header', 'test2')
+ t.equal(c.has('tva'), 'tva')
+ t.notOk(c.has('header'))
+
+ t.equal(c.get('tva'), 'test1')
+
+})
diff --git a/node_modules/fsevents/node_modules/chalk/index.js b/node_modules/fsevents/node_modules/chalk/index.js
new file mode 100644
index 00000000..2d85a917
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/index.js
@@ -0,0 +1,116 @@
+'use strict';
+var escapeStringRegexp = require('escape-string-regexp');
+var ansiStyles = require('ansi-styles');
+var stripAnsi = require('strip-ansi');
+var hasAnsi = require('has-ansi');
+var supportsColor = require('supports-color');
+var defineProps = Object.defineProperties;
+var isSimpleWindowsTerm = process.platform === 'win32' && !/^xterm/i.test(process.env.TERM);
+
+function Chalk(options) {
+ // detect mode if not set manually
+ this.enabled = !options || options.enabled === undefined ? supportsColor : options.enabled;
+}
+
+// use bright blue on Windows as the normal blue color is illegible
+if (isSimpleWindowsTerm) {
+ ansiStyles.blue.open = '\u001b[94m';
+}
+
+var styles = (function () {
+ var ret = {};
+
+ Object.keys(ansiStyles).forEach(function (key) {
+ ansiStyles[key].closeRe = new RegExp(escapeStringRegexp(ansiStyles[key].close), 'g');
+
+ ret[key] = {
+ get: function () {
+ return build.call(this, this._styles.concat(key));
+ }
+ };
+ });
+
+ return ret;
+})();
+
+var proto = defineProps(function chalk() {}, styles);
+
+function build(_styles) {
+ var builder = function () {
+ return applyStyle.apply(builder, arguments);
+ };
+
+ builder._styles = _styles;
+ builder.enabled = this.enabled;
+ // __proto__ is used because we must return a function, but there is
+ // no way to create a function with a different prototype.
+ /* eslint-disable no-proto */
+ builder.__proto__ = proto;
+
+ return builder;
+}
+
+function applyStyle() {
+ // support varags, but simply cast to string in case there's only one arg
+ var args = arguments;
+ var argsLen = args.length;
+ var str = argsLen !== 0 && String(arguments[0]);
+
+ if (argsLen > 1) {
+ // don't slice `arguments`, it prevents v8 optimizations
+ for (var a = 1; a < argsLen; a++) {
+ str += ' ' + args[a];
+ }
+ }
+
+ if (!this.enabled || !str) {
+ return str;
+ }
+
+ var nestedStyles = this._styles;
+ var i = nestedStyles.length;
+
+ // Turns out that on Windows dimmed gray text becomes invisible in cmd.exe,
+ // see https://github.com/chalk/chalk/issues/58
+ // If we're on Windows and we're dealing with a gray color, temporarily make 'dim' a noop.
+ var originalDim = ansiStyles.dim.open;
+ if (isSimpleWindowsTerm && (nestedStyles.indexOf('gray') !== -1 || nestedStyles.indexOf('grey') !== -1)) {
+ ansiStyles.dim.open = '';
+ }
+
+ while (i--) {
+ var code = ansiStyles[nestedStyles[i]];
+
+ // Replace any instances already present with a re-opening code
+ // otherwise only the part of the string until said closing code
+ // will be colored, and the rest will simply be 'plain'.
+ str = code.open + str.replace(code.closeRe, code.open) + code.close;
+ }
+
+ // Reset the original 'dim' if we changed it to work around the Windows dimmed gray issue.
+ ansiStyles.dim.open = originalDim;
+
+ return str;
+}
+
+function init() {
+ var ret = {};
+
+ Object.keys(styles).forEach(function (name) {
+ ret[name] = {
+ get: function () {
+ return build.call(this, [name]);
+ }
+ };
+ });
+
+ return ret;
+}
+
+defineProps(Chalk.prototype, init());
+
+module.exports = new Chalk();
+module.exports.styles = ansiStyles;
+module.exports.hasColor = hasAnsi;
+module.exports.stripColor = stripAnsi;
+module.exports.supportsColor = supportsColor;
diff --git a/node_modules/fsevents/node_modules/chalk/license b/node_modules/fsevents/node_modules/chalk/license
new file mode 100644
index 00000000..654d0bfe
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/index.js b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/index.js
new file mode 100644
index 00000000..4346e272
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/index.js
@@ -0,0 +1,50 @@
+'use strict';
+var argv = process.argv;
+
+var terminator = argv.indexOf('--');
+var hasFlag = function (flag) {
+ flag = '--' + flag;
+ var pos = argv.indexOf(flag);
+ return pos !== -1 && (terminator !== -1 ? pos < terminator : true);
+};
+
+module.exports = (function () {
+ if ('FORCE_COLOR' in process.env) {
+ return true;
+ }
+
+ if (hasFlag('no-color') ||
+ hasFlag('no-colors') ||
+ hasFlag('color=false')) {
+ return false;
+ }
+
+ if (hasFlag('color') ||
+ hasFlag('colors') ||
+ hasFlag('color=true') ||
+ hasFlag('color=always')) {
+ return true;
+ }
+
+ if (process.stdout && !process.stdout.isTTY) {
+ return false;
+ }
+
+ if (process.platform === 'win32') {
+ return true;
+ }
+
+ if ('COLORTERM' in process.env) {
+ return true;
+ }
+
+ if (process.env.TERM === 'dumb') {
+ return false;
+ }
+
+ if (/^screen|^xterm|^vt100|color|ansi|cygwin|linux/i.test(process.env.TERM)) {
+ return true;
+ }
+
+ return false;
+})();
diff --git a/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/license b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/license
new file mode 100644
index 00000000..654d0bfe
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/package.json b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/package.json
new file mode 100644
index 00000000..a891452b
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/package.json
@@ -0,0 +1,113 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "supports-color@^2.0.0",
+ "scope": null,
+ "escapedName": "supports-color",
+ "name": "supports-color",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/chalk"
+ ]
+ ],
+ "_from": "supports-color@>=2.0.0 <3.0.0",
+ "_id": "supports-color@2.0.0",
+ "_inCache": true,
+ "_location": "/fsevents/chalk/supports-color",
+ "_nodeVersion": "0.12.5",
+ "_npmUser": {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ "_npmVersion": "2.11.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "supports-color@^2.0.0",
+ "scope": null,
+ "escapedName": "supports-color",
+ "name": "supports-color",
+ "rawSpec": "^2.0.0",
+ "spec": ">=2.0.0 <3.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/chalk"
+ ],
+ "_resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz",
+ "_shasum": "535d045ce6b6363fa40117084629995e9df324c7",
+ "_shrinkwrap": null,
+ "_spec": "supports-color@^2.0.0",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/chalk",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/chalk/supports-color/issues"
+ },
+ "dependencies": {},
+ "description": "Detect whether a terminal supports color",
+ "devDependencies": {
+ "mocha": "*",
+ "require-uncached": "^1.0.2"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "535d045ce6b6363fa40117084629995e9df324c7",
+ "tarball": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz"
+ },
+ "engines": {
+ "node": ">=0.8.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "8400d98ade32b2adffd50902c06d9e725a5c6588",
+ "homepage": "https://github.com/chalk/supports-color",
+ "keywords": [
+ "color",
+ "colour",
+ "colors",
+ "terminal",
+ "console",
+ "cli",
+ "ansi",
+ "styles",
+ "tty",
+ "rgb",
+ "256",
+ "shell",
+ "xterm",
+ "command-line",
+ "support",
+ "supports",
+ "capability",
+ "detect"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ {
+ "name": "jbnicolai",
+ "email": "jappelman@xebia.com"
+ }
+ ],
+ "name": "supports-color",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/chalk/supports-color.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "version": "2.0.0"
+}
diff --git a/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/readme.md b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/readme.md
new file mode 100644
index 00000000..b4761f1e
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/node_modules/supports-color/readme.md
@@ -0,0 +1,36 @@
+# supports-color [](https://travis-ci.org/chalk/supports-color)
+
+> Detect whether a terminal supports color
+
+
+## Install
+
+```
+$ npm install --save supports-color
+```
+
+
+## Usage
+
+```js
+var supportsColor = require('supports-color');
+
+if (supportsColor) {
+ console.log('Terminal supports color');
+}
+```
+
+It obeys the `--color` and `--no-color` CLI flags.
+
+For situations where using `--color` is not possible, add an environment variable `FORCE_COLOR` with any value to force color. Trumps `--no-color`.
+
+
+## Related
+
+- [supports-color-cli](https://github.com/chalk/supports-color-cli) - CLI for this module
+- [chalk](https://github.com/chalk/chalk) - Terminal string styling done right
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)
diff --git a/node_modules/fsevents/node_modules/chalk/package.json b/node_modules/fsevents/node_modules/chalk/package.json
new file mode 100644
index 00000000..bbbfc827
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/package.json
@@ -0,0 +1,140 @@
+{
+ "_args": [
+ [
+ {
+ "raw": "chalk@^1.1.1",
+ "scope": null,
+ "escapedName": "chalk",
+ "name": "chalk",
+ "rawSpec": "^1.1.1",
+ "spec": ">=1.1.1 <2.0.0",
+ "type": "range"
+ },
+ "/Users/eshanker/Code/fsevents/node_modules/har-validator"
+ ]
+ ],
+ "_from": "chalk@>=1.1.1 <2.0.0",
+ "_id": "chalk@1.1.3",
+ "_inCache": true,
+ "_location": "/fsevents/chalk",
+ "_nodeVersion": "0.10.32",
+ "_npmOperationalInternal": {
+ "host": "packages-12-west.internal.npmjs.com",
+ "tmp": "tmp/chalk-1.1.3.tgz_1459210604109_0.3892582862172276"
+ },
+ "_npmUser": {
+ "name": "qix",
+ "email": "i.am.qix@gmail.com"
+ },
+ "_npmVersion": "2.14.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "raw": "chalk@^1.1.1",
+ "scope": null,
+ "escapedName": "chalk",
+ "name": "chalk",
+ "rawSpec": "^1.1.1",
+ "spec": ">=1.1.1 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/fsevents/har-validator"
+ ],
+ "_resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
+ "_shasum": "a8115c55e4a702fe4d150abd3872822a7e09fc98",
+ "_shrinkwrap": null,
+ "_spec": "chalk@^1.1.1",
+ "_where": "/Users/eshanker/Code/fsevents/node_modules/har-validator",
+ "bugs": {
+ "url": "https://github.com/chalk/chalk/issues"
+ },
+ "dependencies": {
+ "ansi-styles": "^2.2.1",
+ "escape-string-regexp": "^1.0.2",
+ "has-ansi": "^2.0.0",
+ "strip-ansi": "^3.0.0",
+ "supports-color": "^2.0.0"
+ },
+ "description": "Terminal string styling done right. Much color.",
+ "devDependencies": {
+ "coveralls": "^2.11.2",
+ "matcha": "^0.6.0",
+ "mocha": "*",
+ "nyc": "^3.0.0",
+ "require-uncached": "^1.0.2",
+ "resolve-from": "^1.0.0",
+ "semver": "^4.3.3",
+ "xo": "*"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "a8115c55e4a702fe4d150abd3872822a7e09fc98",
+ "tarball": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "0d8d8c204eb87a4038219131ad4d8369c9f59d24",
+ "homepage": "https://github.com/chalk/chalk#readme",
+ "keywords": [
+ "color",
+ "colour",
+ "colors",
+ "terminal",
+ "console",
+ "cli",
+ "string",
+ "str",
+ "ansi",
+ "style",
+ "styles",
+ "tty",
+ "formatting",
+ "rgb",
+ "256",
+ "shell",
+ "xterm",
+ "log",
+ "logging",
+ "command-line",
+ "text"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "name": "qix",
+ "email": "i.am.qix@gmail.com"
+ },
+ {
+ "name": "sindresorhus",
+ "email": "sindresorhus@gmail.com"
+ },
+ {
+ "name": "unicorn",
+ "email": "sindresorhus+unicorn@gmail.com"
+ }
+ ],
+ "name": "chalk",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/chalk/chalk.git"
+ },
+ "scripts": {
+ "bench": "matcha benchmark.js",
+ "coverage": "nyc npm test && nyc report",
+ "coveralls": "nyc npm test && nyc report --reporter=text-lcov | coveralls",
+ "test": "xo && mocha"
+ },
+ "version": "1.1.3",
+ "xo": {
+ "envs": [
+ "node",
+ "mocha"
+ ]
+ }
+}
diff --git a/node_modules/fsevents/node_modules/chalk/readme.md b/node_modules/fsevents/node_modules/chalk/readme.md
new file mode 100644
index 00000000..5cf111e3
--- /dev/null
+++ b/node_modules/fsevents/node_modules/chalk/readme.md
@@ -0,0 +1,213 @@
+
+
+
+
+
+
+
+
+
+> Terminal string styling done right
+
+[](https://travis-ci.org/chalk/chalk)
+[](https://coveralls.io/r/chalk/chalk?branch=master)
+[](https://www.youtube.com/watch?v=9auOCbH5Ns4)
+
+
+[colors.js](https://github.com/Marak/colors.js) used to be the most popular string styling module, but it has serious deficiencies like extending `String.prototype` which causes all kinds of [problems](https://github.com/yeoman/yo/issues/68). Although there are other ones, they either do too much or not enough.
+
+**Chalk is a clean and focused alternative.**
+
+
+
+
+## Why
+
+- Highly performant
+- Doesn't extend `String.prototype`
+- Expressive API
+- Ability to nest styles
+- Clean and focused
+- Auto-detects color support
+- Actively maintained
+- [Used by ~4500 modules](https://www.npmjs.com/browse/depended/chalk) as of July 15, 2015
+
+
+## Install
+
+```
+$ npm install --save chalk
+```
+
+
+## Usage
+
+Chalk comes with an easy to use composable API where you just chain and nest the styles you want.
+
+```js
+var chalk = require('chalk');
+
+// style a string
+chalk.blue('Hello world!');
+
+// combine styled and normal strings
+chalk.blue('Hello') + 'World' + chalk.red('!');
+
+// compose multiple styles using the chainable API
+chalk.blue.bgRed.bold('Hello world!');
+
+// pass in multiple arguments
+chalk.blue('Hello', 'World!', 'Foo', 'bar', 'biz', 'baz');
+
+// nest styles
+chalk.red('Hello', chalk.underline.bgBlue('world') + '!');
+
+// nest styles of the same type even (color, underline, background)
+chalk.green(
+ 'I am a green line ' +
+ chalk.blue.underline.bold('with a blue substring') +
+ ' that becomes green again!'
+);
+```
+
+Easily define your own themes.
+
+```js
+var chalk = require('chalk');
+var error = chalk.bold.red;
+console.log(error('Error!'));
+```
+
+Take advantage of console.log [string substitution](http://nodejs.org/docs/latest/api/console.html#console_console_log_data).
+
+```js
+var name = 'Sindre';
+console.log(chalk.green('Hello %s'), name);
+//=> Hello Sindre
+```
+
+
+## API
+
+### chalk.`
+
+
+
+ {+include("static/header.html")+}
+
+
+
+
+ {+publish.classesIndex+}
+
+
+
+ File Index
+
+
+
+
{+new Link().toSrc(item.alias).withText(item.name)+}
+
{+resolveLinks(item.desc)+}
+
+
+ Author:
+ {+item.author+}
+
+
+ Version:
+ {+item.version+}
+
+ {! var locations = item.comment.getTag('location').map(function($){return $.toString().replace(/(^\$ ?| ?\$$)/g, '').replace(/^HeadURL: https:/g, 'http:');}) !}
+
+ Location:
+
+ {+location+}
+
+
+
+
+
+
+
+
+
+
+
+ ©{+JSDOC.opt.D.copyright+}
+ Documentation generated by JsDoc Toolkit {+JSDOC.VERSION+} on {+new Date()+}
+
+ Theme based on Github Pages template by orderedlist
+
+
+
+
+
+