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

@netixsol01/v4-cli

v0.1.11-beta.1

Published

PoolTogether V4 Command Line Interface

Downloads

242

Readme

📇 PoolTogether V4 CLI

CI Version Downloads/week License ts GPLv3 license oclif

The @pooltogether/v4-cli node module package is a NODE command line interface (CLI) to interact with the PoolTogether V4 protocol. The CLI uses the v4-client-js and v4-utils-js modules to fetch and run calculations/computations for essential PoolTogether V4 tasks.

Primary CLI Commands (help)

npx @pooltogether/v4-cli help compute drawPrizes
npx @pooltogether/v4-cli help compute poolPrizes
npx @pooltogether/v4-cli help compute networkPrizes

⌨️ CLI Installation

$ npm install -g @netixsol01/v4-cli
$ ptv4 COMMAND
running command...
$ ptv4 (--version)
@netixsol01/v4-cli/0.1.11-beta.1 linux-x64 node-v16.15.1
$ ptv4 --help [COMMAND]
USAGE
  $ ptv4 COMMAND
...

Commands

Compute Draw Prizes

ptv4 compute drawPrizes

Computes single Draw prizes for a PrizePool to a target output directory.

Simply pass a chainId, ticket drawId and outDir to compute and locally save the results.

USAGE
  $ ptv4 compute drawPrizes --chainId 1 --drawId 65 --outDir ./temp --ticket '0xdd4d117723C257CEe402285D3aCF218E9A8236E1'

DESCRIPTION
  Computes single Draw prizes for a PrizePool to a target output directory.

EXAMPLES
  $ ptv4 compute drawPrizes --chainId 1 --drawId 1 --ticket 0x0000000000000000000000000000000000000000 --outDir ./temp
    Running compute:drawPrizes on chainId: 1 using drawID: 1

Status File (status.json)

{
  "status": "LOADING",
  "createdAt": "11"
}

Success

{
  "status": "SUCCESS",
  "createdAt": "11",
  "updatedAt": "33",
  "runtime": "22",
  "meta": {
    "prizeLength": "10",
    "amountsTotal": "5000000"
  }
}

Failure

{
  "status": "FAILURE",
  "createdAt": "11",
  "updatedAt": "33",
  "runtime": "22",
  "error": "ErrorCode"
}

Compute PrizePool Prizes

Computes all historical Draw prizes for a PrizePool to a target output directory.

ptv4 compute poolPrizes
USAGE
  $ ptv4 compute poolPrizes --chainId 1 --outDir ./temp --ticket '0xdd4d117723C257CEe402285D3aCF218E9A8236E1'

DESCRIPTION
  Computes all historical Draw prizes for a PrizePool to a target output directory.

EXAMPLES
  $ ptv4 compute poolPrizes --chainId 1--ticket 0x0000000000000000000000000000000000000000 --outDir ./temp
    Running compute:drawPrizes on chainId: 1 using drawID: 1

Compute Network of PrizePool Prizes

Computes Draw prizes for all PoolTogether V4 network PrizePools to a target output directory.

ptv4 compute networkPrizes
USAGE
  $ ptv4 compute networkPrizes --outDir ./temp

DESCRIPTION
  Computes Draw prizes for all PoolTogether V4 network PrizePools to a target output directory.

EXAMPLES
  $ ptv4 compute poolPrizes --chainId 1 --ticket 0x0000000000000000000000000000000000000000 --outDir ./temp
    Running compute:drawPrizes on chainId: 1 using drawID: 1

Help

ptv4 help [COMMAND]

Display help for ptv4.

USAGE
  $ ptv4 help [COMMAND] [-n]

ARGUMENTS
  COMMAND  Command to show help for.

FLAGS
  -n, --nested-commands  Include all nested commands in the output.

DESCRIPTION
  Display help for ptv4.