This repository was archived by the owner on Oct 27, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
Installation
Adithya Joshua Dsilva edited this page Nov 8, 2020
·
1 revision
📣 📣 The following installation instructions are for first time users only.
Existing users can upgrade the command line tool and the checkers with the following commands.
cpt upgrade -m s
cpt upgrade -m c
Download the tarball corresponding to your system from the latest release page. Extract the executable from the archive, and follow the instructions below, corresponding to your OS.
- Move the executable to
/home/<username>/.local/bindirectory (create the folder if not exists). - To add the directory to the system path, follow the instructions given here (
zshusers might need to use.zshrcinstead of.bashrc).
Note: WSL users must follow the Linux installation instructions specified above.
- Move the executable to
C:\Program Files\directory. - Add
C:\Program Files\to the path if not present.
- Move the executable to
/usr/local/bindirectory. - To add the directory to the system path, follow the instructions given here (
zshusers might need to use.zshrcinstead of.bashrc).
Run cpt --help in the terminal. If installed correctly, the following help menu will appear.
Lightweight cli tool for competitive programming!
Usage:
cpt [command]
Available Commands:
codeforces Functions exclusive to codeforces
config Configure global settings
generate Create file using template
help Help about any command
test Run code file against sample tests
upgrade Upgrade cli to latest version
Flags:
-h, --help help for cpt
-v, --version version for cpt
Use "cpt [command] --help" for more information about a command.
To build from source, run the following commands.
git clone https://github.com/cp-tools/cpt.git
cd cpt/
go build -ldflags "-s -w"The compiled executable will be present in the root project directory. Follow the above instructions to add the executable to system path, to run it from any directory.