Skip to content

Instantly share code, notes, and snippets.

View spreadzp's full-sized avatar

Paul spreadzp

View GitHub Profile
@spreadzp
spreadzp / deploy-new-bot.yml
Created March 6, 2023 20:20 — forked from HenrySpartGlobal/deploy-new-bot.yml
Auto Deployment of Discord Bot with Systemd and GitHub Actions
# Author: Henry Koleoso
# Put these two files in .github/workflows/
# Prerequisites:
# SSH Key pair - Private key in GitHub Secrets, Public key in /root/.ssh/authorized_keys on your server
# Discord Bot token - In GitHub Secrets or Environment Variables.
# This file is the workflow that handles the initial setup of your Discord bot.
# This job should be run only ONCE. Changes in 'create-systemctl-service' are appended to the systemd.service file, not overwritten so the file will be invalid!
# If you make a mistake, and need to run this job more than once, navigate to /etc/systemd/system
pragma solidity ^0.5.2;
contract IFactRegistry {
/*
Returns true if the given fact was previously registered in the contract.
*/
function isValid(bytes32 fact)
external view
returns(bool);
# Waves node settins
waves {
max-cache-size = 10
# Blockchain settings
blockchain {
type = CUSTOM
custom {
address-scheme-character = "D"
functionality {
Verifying my Blockstack ID is secured with the address 12peec2BFodkFiH59dTPDFuE1dh5JY73WH https://explorer.blockstack.org/address/12peec2BFodkFiH59dTPDFuE1dh5JY73WH
0xC16Cd2dd3EA77B0eC4CdFd98ABF22013B4d33999
@spreadzp
spreadzp / crowdsale.sol
Created October 8, 2017 21:00
crowdsale
pragma solidity ^0.4.10;
contract UselessWorker {
int public successfullyExecutedIterations = 0;
function doWork(int _iterations) {
successfullyExecutedIterations = _iterations;
for (int i = 0; i < _iterations; i++)
{
@spreadzp
spreadzp / ico.sol
Created October 5, 2017 20:27
CrowdSale
pragma solidity ^0.4.15;
/**
* @title ERC20Basic
* @dev Simpler version of ERC20 interface
* @dev see https://github.com/ethereum/EIPs/issues/179
*/
contract ERC20Basic {
uint256 public totalSupply;
function balanceOf(address who) constant returns (uint256);