Skip to content

Instantly share code, notes, and snippets.

@skilesare
skilesare / dan.sol
Last active November 9, 2017 16:13
pragma solidity ^0.4.15;
/*
******** Read this first: *********
Welcome to Dan's contract.
Metamask is required to interact with the production instance of this contract
if you would like to donate. MetaMask can be installed for Chrome or Firefox at
https://metamask.io/
pragma solidity ^0.4.15;
contract Dan {
address public owner;
uint256 public donated;
string public phone;
string public my_address;
string public my_name;
@skilesare
skilesare / foreignContract.sol
Created June 8, 2017 21:51 — forked from anonymous/foreignContract.sol
Created using browser-solidity: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://ethereum.github.io/browser-solidity/#version=soljson-v0.4.11+commit.68ef5810.js&optimize=undefined&gist=
pragma solidity ^0.4.8;
//© copyright 2017 - Catallax Bank and Rivvir Consulting
// Developed by Austin Fatheree
// http://catallax.info @hypercatallax
// All rights reserved.
contract NameService {
@skilesare
skilesare / ERC20.sol
Created June 1, 2017 03:17 — forked from anonymous/ERC20.sol
Created using browser-solidity: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://ethereum.github.io/browser-solidity/#version=soljson-v0.4.11+commit.68ef5810.js&optimize=undefined&gist=
pragma solidity ^0.4.8;
/**
* @title ERC20Basic
* @dev Simpler version of ERC20 interface
* @dev see https://github.com/ethereum/EIPs/issues/20
*/
contract ERC20Basic {
uint public totalSupply;
@skilesare
skilesare / index.js
Created May 25, 2017 19:17
Prove a message came from the owner of an ethereum address in Node.js
// copy this file into a directory as index.js
// from that directory run the following:
// npm install q
// npm install eth-lightwallet
// npm install ethereumjs-util
// npm install web3
//
// node index.js
var Q = require('q'); //I'm doing promises old school
@skilesare
skilesare / gist:1876678
Created February 21, 2012 13:54
Creating an object to add to an array
GS.cartItem = Em.Object.extend
id: null
orderItem: null
Note: null
@skilesare
skilesare / gist:1873086
Created February 21, 2012 02:23
Invalidating cached property
GS.cMenu = Em.Object.create
searchTerm : ""
menu: null
restaurantLocation: null
cart: Ember.A([])
addToCart: (orderItem,control) ->
newOrderItem = {orderItem: orderItem, id: guidGenerator()}
newA = @cart
newA.pushObject newOrderItem
@set 'GS.cMenu.cart',newA