Skip to content

Instantly share code, notes, and snippets.

View johnX9's full-sized avatar

John X johnX9

  • @infiniteXLabs
View GitHub Profile
cleos push action anorak update '["anorak",4,75,110]' -p anorak@active
executed transaction: 905c847178d47ca8a230fdf2ba1c92c42529aeebb118280fdbf9ccb1415992de 128 bytes 748 us
# anorak <= anorak::update {"account":"anorak","level":4,"healthPoints":75,"energyPoints":110}
cleos push action anorak getplayer '["anorak"]' -p anorak@active
executed transaction: 31bf65b2d69f0977474ddd0332faddf5495cf7050d4ad7d5e678fbd4f7ad4eea 104 bytes 5654 us
# anorak <= anorak::getplayer {"account":"anorak"}
>> Username: art3mis Level: 4 Health: 925 Energy: 890
git clone https://github.com/eosio/eos --recursive
sh ./eosio_build.sh darwin
/usr/local/bin/mongod -f /usr/local/etc/mongod.conf &
cd build
make test
cd build
sudo make install
# To print contract's output to console by default add:
# --contracts-console
nodeos -e -p eosio --plugin eosio::wallet_api_plugin --plugin eosio::chain_api_plugin --plugin eosio::history_api_plugin --contracts-console
cd ~/eos/build/programs/cleos/
# Outputs a password that you need to save to be able to lock/unlock the wallet
# If you don't want to use the "default" wallet add: -n {your_wallet_name} at the end of your command
cleos wallet create
# faucet-private-key = [public key, WIF private key] for signing for faucet creator account (eosio::faucet_testnet_plugin)
[EOS6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV,5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3]
cleos wallet import --private-key={eosio_account_private_key}