npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

codr

v0.0.15

Published

A node program to extract codeforces inputs and outputs

Downloads

46

Readme

Codr

Codr is a Node.js command line tool that extends my previous cfhelper.

It accepts a URL to a coding problem (on a listed platform), and sets up a folder for the problem with all the test cases. As a bonus, a template program and test script is generated! This saves a lot of setup time, so one can just focus on solving the problem! :smile:

Codr currently works for the following:

  1. Codeforces
  2. HackerRank (Work in progress)

NOTE: To use the default test script, the C++ executable should be named "sol" (g++ -std=c++14 <code.cpp> -o sol)

Codr is free to use! If you like it, please support me and give it a star on my Github, www.github.com/callistusystan/codr :star:

If there are any problems with the tool, feel free to raise an issue on the Github repo, www.github.com/callistusystan/codr/issues or send me an email at [email protected]

Background

Codr is the design I should have made when implementing cfhelper. It makes use of an extensible Parser superclass, which passes the responsibility of parsing to the concrete subclasses.

The arguments to pass in the command line is also simplified.

Thank you to all users for choosing to use Codr!

Installation

Requirements:

  1. Node.js with NPM

Steps:

  1. Open a terminal (with Node.js installed)

  2. Enter the following command:

    	> npm install -g codr

Usage

usage: codr [-h | --help]
            [<directory> <URL>]
            [-t | --template <templateFilePath>]
            [-r | --runscript <runScriptPath>]

actions:
  -h, --help          shows this help message and exit.

  <directory> <URL>   extracts the input, outputs of problem(s) in the URL
                      and sets up a new folder for the problem(s) in the
                      specified directory.
                      can also set up a new folder on the go by specifying a non-URL.

                      example: codr . http://codeforces.com/problemset/problem/1/A
                      example: codr . https://www.hackerrank.com/contests/projecteuler/challenges/euler001
                      example: codr . myprogram
                      example: codr .

                      NOTE: URL links must be publicly accessible link.

  -t, --template      sets the specified template file that will be generated when extracting problem data
                      the template file may be reset to default by specifying "default".

                      example: codr -t ./template.py
                      example: codr -t default

                      NOTE: templateFile must be a valid path to an existing file.
                      NOTE: may require "sudo su".

  -r, --runscript     sets the specified runscript that will be generated when extracting problem data.
                      the runscript may be reset to default by specifying "default".
                      the runscript can be disabled by specifying "off".

                      example: codr -r ./test.sh
                      example: codr -r default
                      example: codr -r off

                      NOTE: templateFile must be a valid path to an existing file.
                      NOTE: may require "sudo su".

Useful Documentation

  1. Install Bash on Ubuntu on Windows

    https://www.howtogeek.com/249966/how-to-install-and-use-the-linux-bash-shell-on-windows-10/

  2. Install Node.js with NPM on Bash on Ubuntu on Windows

    https://aigeec.com/installing-node-js-on-windows-10-bash/