As we can write new challenges now, let’s try to upload the challenges in to kurukshetra so that other people can work on these challenges and solve them.
Uploading challenges
Once logged in as admin, visit /admin/add_new.php
to add a new challenge to the framework. Some of the essential information required are challenge Name, type/difficulty/language, challenge code, unittest, introduction and instructions (should be written in points where every new point should be written in a new line).
Challenge code and unittests should be uploaded as a file and its contents are saved in database after encoding with base64
(so as to preserve the indentation of the code).
Disabling challenges
Once logged in as admin, visit /admin/view_edit.php
to list all the challenges from which admin can approve/enable challenges. All challenges which gets uploaded are enabled by default. Any challenges which needs to be disabled should be manually disabled from the admin dashboard.
All the challenges present in the framework are listed above and one can simply click on the checkbox, to enable/disable any challenges.
Editing challenges
Once logged in as admin, visit /admin/view_edit.php
to list down all the challenge and click on edit
button at the end of the challenge which can be used to edit already uploaded challenges into the framework.
By default, all the fields already present in the database will be pre-populated. One can edit the information, upload the code again and submit it back to the framework (which will update the DB).