cms-dev / cms

Contest Management System
http://cms-dev.github.io/
GNU Affero General Public License v3.0
886 stars 360 forks source link

Allow configuring the filename format for OutputOnly tasks #1194

Open SvizelPritula opened 2 years ago

SvizelPritula commented 2 years ago

Is your feature request related to a problem? Please describe. The OutputOnly task type requires files named output_*code*.txt, but some organisers use different naming conventions, like *code*.out.

Describe the solution you'd like A text parameter could be added to the OutputOnly task type to replace the existing USER_OUTPUT_FILENAME_TEMPLATE constant.

Describe alternatives you've considered The ioi2022 fork simply changes the constant to their preferred format, but this could easily be configurable instead of requiring changing the source code.

Additional context I don't have too much experience with contributing to free software projects, but I could try to implement this once I get a development VM running, since this seems an easy change.

fushar commented 2 years ago

As a reference, for IOI 2022 we hardcode the filename format in this commit: https://github.com/ioi/cms/commit/eae340e3c4a5a2d210af32ae6623b11bcaa2a27d (Output-only: Change output filename extension from .txt to .out)

SvizelPritula commented 2 years ago

I've acually implemented this in https://github.com/SvizelPritula/cms/tree/output-filename, but thats based on the IOI 2022 CMS version and since I already have 2 PR in this repo and I'm a bit lost in all my git branches.