Skip to content

Commit 06053b7

Browse files
committed
docs for updating grammar
1 parent af20a96 commit 06053b7

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,21 @@ Allows you to edit xcodeproject files and write them back out.
2222
console.log('new project written');
2323
});
2424

25+
## Working on the parser
26+
27+
If there's a problem parsing, you will want to edit the grammar under
28+
`lib/parser/pbxproj.pegjs`. You can test it online with the PEGjs online thingy
29+
at http://pegjs.majda.cz/online - I have had some mixed results though.
30+
31+
Tests under the `test/parser` directory will compile the parser from the
32+
grammar. Other tests will use the prebuilt parser (`lib/parser/pbxproj.js`).
33+
34+
To rebuild the parser js file after editing the grammar, run:
35+
36+
./node_modules/.bin/pegjs lib/parser/pbxproj.pegjs
37+
38+
(easier if `./node_modules/.bin` is in your path)
39+
2540
## License
2641

2742
MIT

0 commit comments

Comments
 (0)