AlexeyDmitriev / JHelper

GNU Lesser General Public License v3.0
119 stars 31 forks source link

Update output file without build and run (Shift + F10) #123

Closed GoBigorGoHome closed 4 years ago

GoBigorGoHome commented 4 years ago

I have noticed that the output file is updated only when you Compile and Run the task (Shift + F10) but not when you click the "Copy source" icon. As a result, if you make a minor change to task.cpp and forget to press Shift + F10 (or because you know for sure it will work and does not need another run), the old output file will be copied when clicking "Copy source" icon.

AlexeyDmitriev commented 4 years ago

That's sounds reasonable, I'll check if I see any problems with that.

GoBigorGoHome commented 4 years ago

It is reasonable that run file is updated on pressing Shift + F10 and output file is updated on clicking "Copy source".

AlexeyDmitriev commented 4 years ago

When running, both have to be updated, because you may want to submit a file, not pasted source code.

GoBigorGoHome commented 4 years ago

You are right, I missed that point.

AlexeyDmitriev commented 4 years ago

So I see few issues with that 1) Currently the logic is simple -- you have to run before submitting. After the change you'll just remember that "it always works" and it will be easier for you to forget to 2) You can run one problem A, then switch to write problem B (while waiting for problem A to finish if you have a lot of tests or you were ). You could just submit A at that point, but you now have to switch 2 more times now. 3) You could try several approaches in one problem: do some changes while waiting for it to finish, then if it was good then submit run code, if it wasn't, then quickly run new version. Now it's impossible

But I guess they are pretty minor so I am inclined to implement the change anyway

AlexeyDmitriev commented 4 years ago

Changed in 0.18

Thanks for the suggestion.

Please let me know if it doesn't work properly for you.