Skip to content

Instantly share code, notes, and snippets.

View joemarct's full-sized avatar

Joemar Taganna joemarct

View GitHub Profile
{
"$schema": "https://cashtokens.org/bcmr-v2.schema.json",
"version": {
"major": 0,
"minor": 1,
"patch": 0
},
"latestRevision": "2023-06-29T08:40:22.274Z",
"registryIdentity": {
"name": "Metadata for Spice Token",
{
"$schema": "https://cashtokens.org/bcmr-v2.schema.json",
"version": {
"major": 0,
"minor": 1,
"patch": 0
},
"latestRevision": "2023-06-29T08:40:22.274Z",
"registryIdentity": {
"name": "Metadata for Spice Token",
{
"version": {
"major": 0,
"minor": 1,
"patch": 0
},
"latestRevision": "2023-04-29T09:11:27Z",
"registryIdentity": {
"name": "SPICE",
"description": "The official SPICE token in chipnet",
pragma cashscript ^0.7.5;
/**
* @title Escrow Contract
* An escrow is a financial arrangement where a third party holds and regulates the payment
* of funds required for two parties involved in a transaction. The funds are held by the
* escrow service until it is confirmed that all of the terms of an agreement between the buyer
* and seller have been met, at which point the funds are released.
* @dev The arbiter is a person or entity that is appointed or selected to act as a neutral and
* impartial third party in a dispute or conflict.
@joemarct
joemarct / TagannaCoin_flat.sol
Last active March 5, 2018 09:22
TagannaCoin ERC20 Contract
pragma solidity ^0.4.17;
/**
* @title SafeMath
* @dev Math operations with safety checks that throw on error
*/
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
from bottle import TEMPLATE_PATH, route, jinja2_template as template
from models import *
TEMPLATE_PATH.append("./app/templates")
@route('/')
@route('/hello/:name')
def hello(name='Stranger'):
return template('home.html', name=name)
#!/usr/bin/env python
import sys, os
package_dir = "packages"
package_dir_path = os.path.join(os.path.dirname(__file__), package_dir)
sys.path.insert(0, package_dir_path)
import bottle
from app import views
application: <your-app-name>
version: 1
runtime: python
api_version: 1
handlers:
- url: /media
static_dir: media
seq = FastaParser("path-to-your-fasta-file")
@joemarct
joemarct / newick_parser.py
Created March 28, 2013 14:18
A simple Newick tree parser
class Newick(object):
def __init__(self, newick_file):
f = open(newick_file, 'r')
t = f.read().split(';')[0]
t.replace('"', "'")
t = t.splitlines()
self.t = ''.join(t)