Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/0xs34n/coin-cli
ðļA minimal cryptocurrency CLI implementation in TypeScript & Immutable.js
https://github.com/0xs34n/coin-cli
Last synced: 1 day ago
JSON representation
ðļA minimal cryptocurrency CLI implementation in TypeScript & Immutable.js
- Host: GitHub
- URL: https://github.com/0xs34n/coin-cli
- Owner: 0xs34n
- License: apache-2.0
- Created: 2017-12-15T22:26:06.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2022-02-10T17:11:09.000Z (almost 3 years ago)
- Last Synced: 2024-10-29T23:33:58.552Z (15 days ago)
- Language: TypeScript
- Homepage: https://coindemo.io
- Size: 6.63 MB
- Stars: 188
- Watchers: 13
- Forks: 37
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Coin CLI
A minimal cryptocurrency CLI implementation in TypeScript & Immutable.js
## Demo
#### Connect
![connect](https://raw.githubusercontent.com/seanjameshan/coin-cli/master/media/demo/connect.gif)#### Mining
![mining](https://raw.githubusercontent.com/seanjameshan/coin-cli/master/media/demo/mine.gif)#### Payment
![payment](https://raw.githubusercontent.com/seanjameshan/coin-cli/master/media/demo/pay.gif)## ð Features
- ð° Wallet with public and private key.
- ðģ Make Payments between wallets.
- ð Transactions are signed with the wallet's private key.
- ð Blocks with index, hash, data, transactions, and timestamp.
- â Proof-of-work implementation.
- â In-memory JavaScript array to store the blockchain.
- â Block & Transaction integrity validation.
- ðĄ Decentralized and distributed peer-to-peer communication.
- âĻ Minimal implementation in 900 lines of code.## ðĶ Installation
To install this application, you'll need
[Node.js](https://nodejs.org/en/download/) 7+ (which comes with
[npm](http://npmjs.com)) installed on your computer. From your command line:#### Source (recommended)
You'll need [Git](https://git-scm.com) to run the project from source. From your
command line:```bash
# Clone this repository
$ git clone https://github.com/seanjameshan/coin-cli# Go into the repository
$ cd coin-cli# Install dependencies
$ npm install# Run the app
$ npm start
```## ðđïļ Usage
| p | Make payment to address with and using wallet | pay xxx... 10 5 mypassword |
| Command | Alias | Description | Example |
|------------------------------------------|-------|---------------------------------------------------------------------------|----------------------------|
| open | o | Open port to accept incoming connections. | open 5000 |
| connect | c | Connect to a new peer with host and | connect localhost 5000 |
| blockchain | bc | See the current state of the blockchain. | |
| peers | p | Get the list of connected peers. | |
| mine [address] | m | Mine a new block with rewards going to optional [address]. | mine or mine xxx... |
| transactions | tx | See unconfirmed transactions that can be mined. | |
| wallet | w | Create a new wallet with | wallet mypassword |
| key | k | Get your public key | |
| pay
| balance [address] | b | Balance of optional address | balance or balance xxx... |
| help [command...] | | Provides help for a given command | help balance or help |
| exit | | Exits application. | |