Skip to content

Instantly share code, notes, and snippets.

View evias's full-sized avatar
👻
One man’s constant is another man’s variable.

Grégory Saive evias

👻
One man’s constant is another man’s variable.
View GitHub Profile
@evias
evias / dhealth-voting-update.md
Last active September 23, 2021 11:52
dHealth Node Voting Keys Update Guide

Hello dear community 👋

I am happy to share an update of the yourdlt tool that will let you update your voting keys.

  1. Remove the yourdlt software We recommend that you stop your node and remove any previous installation of yourdlt with the following example:
$ cd /opt/dhealth
$ yourdlt stop -t dual-node
@evias
evias / dhealth-nodes.md
Last active October 21, 2021 04:43
dHealth Network Node Install Guide

How to install Nodes for DHealth Network

1. Download all install scripts

$ cd ~
$ curl -fsSL https://yourdlt.tools/files/install-requirements.sh -o install-requirements.sh

Keybase proof

I hereby claim:

  • I am evias on github.
  • I am evias (https://keybase.io/evias) on keybase.
  • I have a public key ASD7NhnsBUGYD3UBmSIyOsRYMd121GC2aeBZ-ZU6J7bGawo

To claim this, I am signing this object:

@evias
evias / nem-php-broadcast_tx.php
Last active October 31, 2018 15:12
nem-php: broadcast transaction
<?php
use NEM\API;
use NEM\Models\MosaicAttachments;
use NEM\Models\MosaicAttachment;
use NEM\Models\Mosaic;
use NEM\Models\Transaction\Transfer;
use NEM\Infrastructure\Transaction as TransactionService;
// prepare the transaction
@evias
evias / nem-sdk-v1.6.2.js
Last active December 27, 2018 04:40
nem-sdk-v1.6.2.js
This file has been truncated, but you can view the full file.
require=(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
'use strict';
var _helpers = require('../../utils/helpers');
var _helpers2 = _interopRequireDefault(_helpers);
var _headers = require('./headers');
var _headers2 = _interopRequireDefault(_headers);
@evias
evias / composer.json
Last active June 19, 2018 11:18
PHP KeyPair Creation - Case Reproduction
{
"require": {
"php": ">=5.5.9",
"evias/nem-php": "dev-master",
"kornrunner/keccak": "@dev"
},
"require-dev": {
},
"autoload": {
"classmap": [
@evias
evias / nem-convert-to-multisig.js
Created April 12, 2018 16:31
NEM-SDK@1.6.2: Convert Account to Multisig
let endpoint = {
'host': 'http://bigalice2.nem.ninja',
'port': 7890
};
let networkId = -104;
let privateKeyOfAccountToConvert = "PRIV_KEY_HEX_ACCOUNT_TO_CONVERT";
let privateKeyOfCosig = "PRIV_KEY_HEX_ACCOUNT_SINGLE_COSIG";
let kpc = sdk.crypto.keyPair.create(privateKeyOfAccountToConvert);
@evias
evias / nem_sdk_interpret_mosaic_transfer.js
Last active July 30, 2017 12:13
Interpret a Mosaic Transfer Transaction on the NEM blockchain with Node.js and NEM-sdk
// nem-sdk: npmjs.com/package/nem-sdk
// class OutgoingTransactionStream from gist: https://gist.github.com/evias/aea14ff6bea618239ca21a7f3802773e.js
let sdk = require("nem-sdk").default;
/**
* The Transaction class defines some utilities methods to keep
* reading data from NEM Transactions organized a little bit.
*
* @param {Object} transactionMetaDataPair Transaction object received in NIS response
@evias
evias / nem_sdk_read_transactions.js
Last active July 29, 2017 12:26
read all outgoing transactions of a given Wallet with Node.js and the NEM-sdk
/**
* Class OutgoingTransactionStream can be used to read
* outgoing transactions of a given NEM Account.
*
* This class is kept quite simple and only defines a
* function to read *all* outgoing transactions of an
* account.
*
* @param {Object} sdk use `require('nem-sdk').default`
* @param {Object} endpoint
@evias
evias / nem_sdk_last_block.js
Last active August 26, 2018 11:22
retrieve last block from the NEM blockchain using the Node.js NEM-sdk
// include the NEM-sdk package in your package.json first.
// nem-sdk: npmjs.com/package/nem-sdk
let nem_ = require("nem-sdk").default;
let connectedNode = nem_.model.objects.create("endpoint")("http://bigalice2.nem.ninja", "7890");
nem_.com.requests.chain.lastBlock(connectedNode)
.then(function(err, block)
{
if (! err && block) {