INTRODUCTION:
Hi there, since this is my first blog, please bear with me as I strive to bring value to help you with your problem with less effort. My name is Aman. I'm motivated to write after reading this blog by snapdragon3101. I also want to thank xalanq for this wonderful CP tool. So let's get to the solution right now.
FOR WINDOWS 10 (**64-bit**):
Prerequisite: CP Editor must be installed. Download the latest version from here.
INSTALLATION & SETUP GUIDE:
- Download the required files from https://github.com/xalanq/cf-tool/releases. NOTE: For some users, this file won't work. I don't know the actual reason behind that, but it's throwing me an error:
cannot find csrf
. For those users, I would highly recommend downloading the cf file from https://github.com/woshiluo/cf-tool/releases/tag/v1.0.1. - After this, you need to setup environment variable for this. This is how you do it: First copy the file "cf" to your root directory (in windows C:\Users<name>), and name it bin. Your cf may now be found in
C:\\Users\\bin\cf.exe
. In the same way that you would add other system variables, add this directory to your PATH. If you are facing problems, refer this. After adding your PATH correctly, open the windows PowerShell (_hold shift and right-click_) in the folder bin. Now type
cf --version
and you'll see Codeforces Tool Version. I hope you didn't face any errors so far.- You must now use cf tools to log into Codeforces. Type
cf config
into your Windows PowerShell, then select 0. Now enter your Codeforces credentials and if all goes according to plan, the CF tool will display a successful login. - You must now set templates in CF Tools. In this instance, templates will determine which code-forces language to use when submitting.
- You may now add as many templates as you like. And this is what you suppose to do:
-
- Open PowerShell in the bin folder
-
- Type
cf config
- Type
-
- Choose index 1 (to add template)
-
- Select language, I choose: GNU C++20 (64 bit)
-
- For the selected language, the cf tool will now request any template
-
- Put suffix some random C++ file
-
- For template alias, I put cpp
-
- Put script as empty
-
- Now it asks script. Type anything
-
- Not it asks after script. Keep it empty
-
- y / n, choose n
Now just like this, you can add other languages. You'll love doing this, I assure you. Lastly, change your CP editor file path [Options/Prefrences/Extensions/CF Tool
] to the 'cf' file present in bin folder.