Build a bridge between Sublime Text and Competitive Companion

Revision en2, by tiger2005, 2023-02-26 04:33:42

( My English is poor, and the blog might be a little confusing :( )

If you use Sublime Text for competitive programming, you shouldn't miss the extension called FastOlympicCoding. You can see more from its repository. The extension will create a single file containing the test cases for each code file, and you can run it easily with a key combination.

Also, Competitive Companion is a nice extension for competitive programming website. it will parse the test cases in the current website and send it to your code editors by POST requests.

Unfortunately, FastOlympicCoding cannot link with this extension. When I tried to find out how to link them, I clicked into a repository called FastOlympicCodingHook. The extension works as following: When you right click at a file and select Listen to Competitive Companion, a local server will be started to handle the POST requests from Competitive Companion. A file of test cases will be generated by the server, and you can test your code by FastOlympicCoding.

The extension is great but not convenient for me, as I needed to do several actions to make my test cases ready. So I did some modifies to the source code and finally I succeeded in making my own FastOlympicCodingHook. The server part works the same as the original one, but after selecting a template file and a problem directory, the new extension can generate code files along with test cases files automatically.

The extension worked greatly in some coders' computers, but as I'm not good at writing python code, I'm not sure if there's any bug in the extension. I hope someone can make a better extension and make the bridge between Sublime Text and Competitive Companion stronger.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English tiger2005 2023-02-26 04:33:42 6 Tiny change: 'on code, I don't sure if ' -> 'on code, I'm not sure if '
en1 English tiger2005 2023-02-25 14:33:39 1975 Initial revision (published)