SajidZakaria's blog

By SajidZakaria, 2 years ago, In English

UPD: Script significantly improved. If you're using it, please considering updating, instructions on the given repo

So I am using Sublime Text in Linux as my CP Environment. But I've always wondered whether it was possible to use terminal features (like timeout and -head) in Windows in the same way. I tried hard with CMD but it was too weak to do these. So I tried with Powershell. It was a long journey and after spending many hours I finally got it to do exactly what I wanted. I'll just copy paste the features of this build here.

Features of this build:

  1. Uses File I/O.
  2. Has a timeout feature, terminates process after hitting timeout.
  3. Has an output size limit, terminates program when the output generated is out of control.
  4. Terminates immediately after a runtime error occurs. (Normally Windows takes a lot longer)
  5. Easily customizable.

As far as I've tested this build felt very consistent. I also did the last Round #677 Div3 with this and I really didn't feel like I was using windows instead of linux. I know it's not a big deal, but if anyone ever wanted to have things like these and didn't find any other solution, you might want to have a go at this.

You can find the Build System here : https://github.com/SajidZakaria/ST3-CP-Environment

Full text and comments »

 
 
 
 
  • Vote: I like it
  • +33
  • Vote: I do not like it