Skip to content

Instantly share code, notes, and snippets.

@UdjinM6
UdjinM6 / electrumx.sh
Last active April 16, 2021 19:42
ElectrumX setup for Dash
#!/bin/sh
# ElectrumX setup for Dash
# NOTE: with this setup ElectrumX will be running under root (to simplify things),
# modify it accordingly if you want to run it under some specific user
# NOTE: this script itself is not enough, you'll have to edit a couple of files manually,
# pls read comments below
# python3.7 is requried for ElectrumX,
@riongull
riongull / discoverdash.com.json
Created February 7, 2020 18:57
Dash merchant data
This file has been truncated, but you can view the full file.
[
{
"meta": {
"page": 1,
"listingOnPage": 1,
"listingOnSite": 1
},
"main": {
"name": "Pure Bliss Cleaning Service",
"postId": "53024",
@seigler
seigler / dashcore-node.json
Created September 12, 2019 16:51
nginx proxied dashpay-dapi docker compose with letsencrypt certificate
{
"network": "testnet",
"port": 3001,
"services": [
"dashd",
"web",
"@dashevo/insight-api"
],
"servicesConfig": {
"dashd": {
@jhodges10
jhodges10 / dash_payment_ranks.py
Created June 24, 2019 20:42
Return masternodes nodes ranked for payment
from rpc_methods import get_prgtx_info, get_best_block
from pprint import pprint
from collections import OrderedDict
"""
Sort the set in ascending order by "testHeight" and “ProRegTx hash”.
“testHeight” is determined for each individual entry and equals the “last paid height” (or “registered height” if the masternode was never paid).
If the masternode was PoSe-banned before and revived later, the “revival height” of the masternode is used instead of the “registered height”.
If the “testHeight” of two masternodes is identical, the ProRegTx hash acts as a deterministic tie breaker.
"""
@nmarley
nmarley / dash.conf
Last active June 14, 2019 16:07
Docker example using "official" dashpay/dashd image
# network
testnet=0
listen=1
daemon=0 # leave this set to 0 for Docker
logtimestamps=1
maxconnections=256
debug=0
printtoconsole=1
# optional indices (required for Insight)
@aseure
aseure / manual-merge-and-rebase.sh
Created December 6, 2017 16:01
Manual "Merge and rebase"
git checkout my-new-feat
git rebase master
git checkout master
git merge my-new-feat --ff
@Deadlyelder
Deadlyelder / bitcoin_rpc_class.py
Last active November 12, 2020 22:06
A python script that has as a class Class script
from __future__ import print_function
import time, requests, json
class RPCHost(object):
def __init__(self, url):
self._session = requests.Session()
self._url = url
self._headers = {'content-type': 'application/json'}
def call(self, rpcMethod, *params):
payload = json.dumps({"method": rpcMethod, "params": list(params), "jsonrpc": "2.0"})
@application2000
application2000 / how-to-install-latest-gcc-on-ubuntu-lts.txt
Last active February 21, 2024 03:02
How to install latest gcc on Ubuntu LTS (12.04, 14.04, 16.04)
These commands are based on a askubuntu answer http://askubuntu.com/a/581497
To install gcc-6 (gcc-6.1.1), I had to do more stuff as shown below.
USE THOSE COMMANDS AT YOUR OWN RISK. I SHALL NOT BE RESPONSIBLE FOR ANYTHING.
ABSOLUTELY NO WARRANTY.
If you are still reading let's carry on with the code.
sudo apt-get update && \
sudo apt-get install build-essential software-properties-common -y && \
sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y && \
@vidavidorra
vidavidorra / auto-deploy_documentation.md
Last active February 19, 2023 17:37
Auto-deploying Doxygen documentation to gh-pages with Travis CI

Auto-deploying Doxygen documentation to gh-pages with Travis CI

This explains how to setup for GitHub projects which automatically generates Doxygen code documentation and publishes the documentation to the gh-pages branch using Travis CI. This way only the source files need to be pushed to GitHub and the gh-pages branch is automatically updated with the generated Doxygen documentation.

Sign up for Travis CI and add your project

Get an account at Travis CI. Turn on Travis for your repository in question, using the Travis control panel.

Create a clean gh-pages branch

To create a clean gh-pages branch, with no commit history, from the master branch enter the code below in the Git Shell. This will create a gh-pages branch with one file, the README.md in it. It doesn't really matter what file is uploaded in it since it will be overwritten when the automatically generated documentation is published to th

@mesgarpour
mesgarpour / appsScript_ListFilesFolders_ver.2.js
Last active April 22, 2024 01:35
[Google Apps Script] List all files & folders in a Google Drive folder, & write into a speadsheet
/*
* Copyright 2017 Mohsen Mesgarpour
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software