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

@voydwalkr/terrain

v0.2.0-alpha.1

Published

Flavored Terra development environment

Downloads

2

Readme

VoydWalkr's Terrain Fork

This is a flavored fork of @terra-money/terrain. What started as a simple mod quickly devolved into its own existence.

Proper documentation will follow. For now, I hope the terrain --help command suffices.

Table of Contents

Installation

Currently, VoydWalkr's Terrain is an alpha release. I lack the capacity to extensively test all facets of the fork; please report any issues you come across.

Install with npm via $ npm i --global @voydwalkr/terrain,

or with yarn via $ yarn global add @voydwalkr/terrain.

Linux: Setup libsecret

On Linux only, keytar depends on libsecret. If not already available on your system, install like so:

  • Debian/Ubuntu/PopOS: sudo apt install libsecret-1-dev
  • Red Hat: sudo yum install libsecret-devel
  • Arch Linux: sudo pacman -S libsecret

Notable Differences

There were some design choices which noticably distinguish this fork from the original - design choices which make it unfeasible to merge this fork back into the original.

Keytar Support

Rather than store private keys or entire mnemonics in plain text in the project root, we store them in secure storage dependent on your platform. We thus do not have the wallet topic, but the key topic.

TOML Configuration

I found the config.terrain.json file cumbersome and bulky, so I decided to implement project configuration with TOML.

Terrain Files Renamed

Terrain files followed the format <file>.terrain.<ext>. I changed it to terrain.<file>.<ext> to lexigraphically group terrain files together.

terrain code:new NAME

Generate new contract.

USAGE
  $ terrain code:new [NAME] [--path <value>] [--version <value>]

FLAGS
  --path=<value>     [default: ./contracts] path to keep the contracts
  --version=<value>  [default: 0.16]

DESCRIPTION
  Generate new contract.

See code: src/commands/code/new.ts

terrain code:store CONTRACT

Store code on chain.

USAGE
  $ terrain code:store [CONTRACT] --signer <value> [--no-rebuild] [--network <value>] [--config-path <value>]
    [--refs-path <value>] [--keys-path <value>] [--migrate]

FLAGS
  --config-path=<value>  [default: ./config.terrain.toml]
  --keys-path=<value>    [default: ./terrain.keys.js]
  --migrate              migrate the contract to an updated version after a chain upgrade; works only once per chain
                         upgrade
  --network=<value>      [default: localterra]
  --no-rebuild
  --refs-path=<value>    [default: ./terrain.refs.json]
  --signer=<value>       (required)

DESCRIPTION
  Store code on chain.

See code: src/commands/code/store.ts

terrain console

Start a repl console that provides context and convinient utilities to interact with the blockchain and your contracts.

USAGE
  $ terrain console [--network <value>] [--config-path <value>] [--refs-path <value>] [--keys-path <value>]

FLAGS
  --config-path=<value>  [default: config.terrain.toml]
  --keys-path=<value>    [default: terrain.keys.js]
  --network=<value>      [default: localterra]
  --refs-path=<value>    [default: terrain.refs.json]

DESCRIPTION
  Start a repl console that provides context and convinient utilities to interact with the blockchain and your
  contracts.

See code: src/commands/console.ts

terrain contract:instantiate CONTRACT

Instantiate the contract.

USAGE
  $ terrain contract:instantiate [CONTRACT] --signer <value> [--network <value>] [--config-path <value>] [--refs-path
    <value>] [--keys-path <value>] [--instance-id <value>] [--no-admin] [--admin <value>]

FLAGS
  --admin=<value>        admin address to set - defaults to signer
  --config-path=<value>  [default: ./config.terrain.toml]
  --instance-id=<value>  [default: default]
  --keys-path=<value>    [default: ./terrain.keys.js]
  --network=<value>      [default: localterra]
  --no-admin             instantiate contract w/o an admin; this prohibits migrations
  --refs-path=<value>    [default: ./terrain.refs.json]
  --signer=<value>       (required)

DESCRIPTION
  Instantiate the contract.

See code: src/commands/contract/instantiate.ts

terrain contract:migrate [CONTRACT]

migrate an existing contract instance

USAGE
  $ terrain contract:migrate [CONTRACT] --signer <value> [--network <value>] [--config-path <value>] [--refs-path
    <value>] [--keys-path <value>] [--instance-id <value>]

FLAGS
  --config-path=<value>  [default: ./config.terrain.toml]
  --instance-id=<value>  [default: default]
  --keys-path=<value>    [default: ./terrain.keys.js]
  --network=<value>      [default: localterra]
  --refs-path=<value>    [default: ./terrain.refs.json]
  --signer=<value>       (required)

DESCRIPTION
  migrate an existing contract instance

See code: src/commands/contract/migrate.ts

terrain contract:new NAME

Generate new contract.

USAGE
  $ terrain contract:new [NAME] [--path <value>] [--version <value>] [--authors <value>]

FLAGS
  --authors=<value>  [default: Terra Money <[email protected]>]
  --path=<value>     [default: ./contracts] path to keep the contracts
  --version=<value>  [default: 1.0-beta6]

DESCRIPTION
  Generate new contract.

EXAMPLES
  $ terrain code:new awesome_contract

  $ terrain code:new awesome_contract --path path/to/dapp

  $ terrain code:new awesome_contract --path path/to/dapp --authors "ExampleAuthor<[email protected]>"

See code: src/commands/contract/new.ts

terrain contract:store CONTRACT

Store code on chain.

USAGE
  $ terrain contract:store [CONTRACT] --signer <value> [--no-rebuild] [--network <value>] [--config-path <value>]
    [--refs-path <value>] [--keys-path <value>] [--arm64] [--migrate]

FLAGS
  --arm64
  --config-path=<value>  [default: ./config.terrain.toml]
  --keys-path=<value>    [default: ./terrain.keys.js]
  --migrate
  --network=<value>      [default: localterra]
  --no-rebuild
  --refs-path=<value>    [default: ./terrain.refs.json]
  --signer=<value>       (required)

DESCRIPTION
  Store code on chain.

See code: src/commands/contract/store.ts

terrain contract:updateAdmin CONTRACT ADMIN

Update the admin of a contract.

USAGE
  $ terrain contract:updateAdmin [CONTRACT] [ADMIN] --signer <value> [--network <value>] [--config-path <value>]
    [--refs-path <value>] [--keys-path <value>] [--instance-id <value>]

FLAGS
  --config-path=<value>  [default: ./config.terrain.toml]
  --instance-id=<value>  [default: default]
  --keys-path=<value>    [default: ./terrain.keys.js]
  --network=<value>      [default: localterra]
  --refs-path=<value>    [default: ./terrain.refs.json]
  --signer=<value>       (required)

DESCRIPTION
  Update the admin of a contract.

See code: src/commands/contract/updateAdmin.ts

terrain key:add:mnemonic NAME

add a new private key by mnemonic

USAGE
  $ terrain key:add:mnemonic [NAME]

DESCRIPTION
  add a new private key by mnemonic

See code: src/commands/key/add/mnemonic.ts

terrain key:add:raw NAME [KEY]

add a new raw private key

USAGE
  $ terrain key:add:raw [NAME] [KEY]

DESCRIPTION
  add a new raw private key

See code: src/commands/key/add/raw.ts

terrain key:delete NAME

delete an existing private key

USAGE
  $ terrain key:delete [NAME]

DESCRIPTION
  delete an existing private key

See code: src/commands/key/delete.ts

terrain key:list [TYPE]

list stored private keys by name

USAGE
  $ terrain key:list [TYPE]

DESCRIPTION
  list stored private keys by name

See code: src/commands/key/list.ts

terrain new NAME

Create new dapp from a template.

USAGE
  $ terrain new [NAME] [--path <value>] [--framework ] [--version <value>] [--authors <value>]

FLAGS
  --authors=<value>     [default: Terra Money <[email protected]>]
  --framework=<option>  [default: react] Choose the frontend framework you want to use. Non-react framework options have
                        better wallet-provider support but less streamlined contract integration.
                        <options: >
  --path=<value>        [default: .] Path to create the workspace
  --version=<value>     [default: 1.0]

DESCRIPTION
  Create new dapp from a template.

EXAMPLES
  $ terrain new awesome-dapp

  $ terrain new awesome-dapp --path path/to/dapp

  $ terrain new awesome-dapp --path path/to/dapp --authors "ExampleAuthor<[email protected]>"

  $ terrain new awesome-dapp --path path/to/dapp --framework vue --authors "ExampleAuthor<[email protected]>"

See code: src/commands/new.ts

terrain schema:compile [CONTRACT]

compile JSON schemas and their corresponding TypeScript type definitions

USAGE
  $ terrain schema:compile [CONTRACT]

DESCRIPTION
  compile JSON schemas and their corresponding TypeScript type definitions

See code: src/commands/schema/compile.ts

terrain sync-refs [FILE]

Sync configuration with frontend app.

USAGE
  $ terrain sync-refs [FILE] [--refs-path <value>] [--dest <value>]

FLAGS
  --dest=<value>       [default: ./frontend/src/terrain.refs.json]
  --refs-path=<value>  [default: ./terrain.refs.json]

DESCRIPTION
  Sync configuration with frontend app.

See code: src/commands/sync-refs.ts

terrain task:new [TASK]

create new task

USAGE
  $ terrain task:new [TASK]

DESCRIPTION
  create new task

See code: src/commands/task/new.ts

terrain task:run [TASK]

run predefined task

USAGE
  $ terrain task:run [TASK] [--network <value>] [--config-path <value>] [--refs-path <value>] [--keys-path
    <value>]

FLAGS
  --config-path=<value>  [default: config.terrain.toml]
  --keys-path=<value>    [default: terrain.keys.js]
  --network=<value>      [default: localterra]
  --refs-path=<value>    [default: terrain.refs.json]

DESCRIPTION
  run predefined task

See code: src/commands/task/run.ts

terrain test CONTRACT-NAME

Runs unit tests for a contract directory.

USAGE
  $ terrain test [CONTRACT-NAME] [--no-fail-fast]

FLAGS
  --no-fail-fast  Run all tests regardless of failure.

DESCRIPTION
  Runs unit tests for a contract directory.

EXAMPLES
  $ terrain test counter

  $ terrain test counter --no-fail-fast

See code: src/commands/test.ts

terrain version

USAGE
  $ terrain version

See code: @oclif/plugin-version