meta data for this page
  •  

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
start_hacking [2020/02/15 23:45] revuskystart_hacking [2023/05/06 17:25] (current) revusky
Line 1: Line 1:
-If all you want to do is use the tool, all you need to do is download the following two files:+====== Start Hacking! ======
  
-[[https://javacc.com/download/javacc.jar]] 
-[[https://javacc.com/download/freemarker.jar]] 
  
-Put both files in the same directory somewhere and then the tool should be runnable via: +CongoCC is based on the idea that things should //just work//If all you want to do is use the tool, all you need to do is download the file:
-   java -jar <wherever-you-downloaded-thefiles>/javacc.jar <MyGrammar.javacc&rt;+
  
-That’s all, folks! The freemarker.jar must be in the same directory as the javacc.jar. Aside from that, there are no other dependencies. The above command-line should work on PC, Mac, or Linux.   +[[https://parsers.org/download/congocc.jar]] 
 + 
 +There are no dependencies (aside from a JDK) and it should be runnable via: 
 + 
 +   java -jar congocc.jar <MyGrammar.ccc> 
 + 
 +That’s all, folks! The above command-line should work on PC, Mac, or Linux.   
  
 The rest of the page is for the small minority of people who want to hack the code. The most basic requirements are: The rest of the page is for the small minority of people who want to hack the code. The most basic requirements are:
Line 17: Line 20:
 You should be able to check out and build the code like so: You should be able to check out and build the code like so:
  
-    git clone https://github.com/javacc21/javacc21.git +    git clone https://github.com/congo-cc/congo-parser-generator.git congo 
-    cd javacc21+    cd congo
     ant     ant
  
Line 26: Line 29:
 If the above is all successful, in principle, you are able to hack the code. None of this should require any tinkering with any environment variables such as CLASSPATH.  If the above is all successful, in principle, you are able to hack the code. None of this should require any tinkering with any environment variables such as CLASSPATH. 
  
-Now, of course, most people will want to get the code into an IDE, such as Eclipse or IntelliJ. I tried my best to have the project set up to work with either of those IDE'out of the boxI described that [[https://discuss.parsers.org/t/getting-started-with-the-latest-javacc-code-in-your-ide-of-choice/13|here]]+Now, of course, most people will want to get the code into an IDE, such as Eclipse or IntelliJ. As of this writing, it should be possible to open the base directory as a project in either one of those.  
 + 
 +===== Eclipse ===== 
 + 
 +In Eclipse, it is just ''File->'Open Projects from File System'' and then you click on ''Directory'' and choose the directory in which you checked out the projectThen press ''Finish''. After a pause, it will tell you in the "Problems" view that you have something over 900 errorsThis is because the parser component needs to be generated(JavaCC is used to build itself.) Once you run: ''Project->Build All'' the errors should disappear and you now have the project in Eclipse.  
 + 
 +===== IntelliJ ===== 
 + 
 +In IntelliJ, you can also directly open the base directory as a project. You can simply do: ''Build->Build Project'' (Ctrl-F9 is the default shortcut) and it should just build everything.
  
-You may run into some issue (in particular with Eclipse) in terms of defining the Project properties so it uses the appropriate JDK.+If you have any issues or suggestions about this topic (or any other), please go to the [[https://discuss.parsers.org/t/getting-started-with-the-latest-javacc-code-in-your-ide-of-choice/13|Discourse discussion forum]].