Command-line tool for playing CheckiO games.
CheckiO - Coding games for beginners and advanced programmers where you can improve your coding skills by solving engaging challenges.
python3 is required
$ pip3 install --upgrade checkio_clientor if you plan to contribute, you can create a clone in a specific folder and install from there
$ git clone https://github.com/CheckiO/checkio-client.git
...
$ cd checkio-client
$ pip install -e .After the installation a new checkio command becomes available.
your first command should be
$ checkio configyou'll need a key in order to finish it. You can obtain the API Key by following this link for Python, and this one for JavaScript.
You can find all of the available commands by using
$ checkio -hand the detailed help for a specific command by using (for example, for a config command)
$ checkio config -hThe configuration process will create a configuration directory in $XDG_CONFIG_HOME or your home folder with a config.ini file inside.
[Main]
default_domain = py
[py_checkio]
key = b30523506050473b8f33ca440101026a
[js_checkio]
Here is a simple way in which you can get your solution for Median mission
$ checkio init median checkio_solutions/median.pyhere you have two options to test your solution. The first one is by using the checkio command
$ checkio check medianand the second one is to simply execute the solution with --check argument (without it will simply run the solution)
$ checkio_solutions/median.py --checkafter the successful check you will get a link for other players’ solutions and a link for sharing your own solution
$ checkio sync ~/checkio_solutionswill save all of your solutions in folder ~/checkio_solutions. Check out help for command sync in order to learn more about the synchronization options
$ checkio sync -hyour last synchronized folder will be saved into ~/.checkio/config.ini, so if you’ll need to resync your solutions you can simply do
$ checkio syncand to check and run the solutions by using the simpler command
$ checkio check median
$ checkio run medianif you configure Python as a default service, you can still use JS. In order to do so you need to add a key in config file for the js_checkio section, and then you can run any command by adding the extra option --domain=js, for example,
$ checkio --domain=js sync checkio_solutions
$ checkio --domain=js run median.jsIn order to work with repositories module GitPython is required
by using checkio tools you can also create your own checkio missions
$ checkio initrepo ~/checkio_mission/new_missionYou can link and push the source of your mission into the github repo
$ checkio linkrepo ~/checkio_mission/new_mission [email protected]:oduvan/checkio-mission-new-mission.gitAfter you are done editing the mission, you test your mission by using the command
$ checkio checkrepo ~/checkio_mission/new_missionand open https://py.checkio.org/mission/tester/ in your browser.
To learn more you can check out our blog post on the topic of creating missions on checkio (but with using our old tool) and also blog post about improving other mission