Skip to content

Instantly share code, notes, and snippets.

from __future__ import print_function
import datetime
import pickle
import os.path
import os
from googleapiclient.discovery import build
from google_auth_oauthlib.flow import InstalledAppFlow
from google.auth.transport.requests import Request
// package.json
{
"dependencies": {
"web3": "0.17.0-alpha",
"solc": "^0.4.4",
"fs": "0.0.1-security"
}
}
contract Escrow {
address public buyer;
address public seller;
address public arbiter;
function Escrow (address _seller, address _arbiter) payable {
buyer = msg.sender;
seller = _seller;
arbiter = _arbiter;
// package.json
{
"dependencies": {
"web3": "0.17.0-alpha",
"solc": "^0.4.4"
}
}
//make new directory and add package.json file to it
// package.json
{
"dependencies": {
"web3": "0.17.0-alpha",
"ethereumjs-util": "4.5.0",
"ethereumjs-tx": "1.1.2"
}
}
.container-fluid
.stable.row: .col-xs-12
- var hasTrinkets = 'user.purchased.plan.consecutive.trinkets > 0'
.pull-left-sm.col-centered(ng-class='#{hasTrinkets} ? "npc_timetravelers_active" : "npc_timetravelers"')
.popover.static-popover.fade.right.in.pull-left-sm.col-centered
.arrow.hidden-xs
h3.popover-title(ng-if='#{hasTrinkets}')=env.t('timeTravelersTitle')
h3.popover-title(ng-if='!(#{hasTrinkets})')!=env.t('timeTravelersTitleNoSub', {linkStartTyler: "<a href='https://github.com/lefnire' target='_blank'>", linkStartVicky: "<a href='http://blog.habitrpg.com/who' target='_blank'>", linkEnd: "</a>"})
.popover-content(ng-if='!(#{hasTrinkets})')
p!=env.t('timeTravelersPopoverNoSub', {linkStart: "<a href='https://habitica.com/#/options/settings/subscription' target='_blank'>", linkEnd: "</a>"})
@NathanMaton
NathanMaton / pulluser.js
Created November 29, 2015 20:42
pull prod user into habitrpg
//Load the request module
var request = require('request');
var mongodb = require('mongodb');
var user = []
//Lets configure and request
request({
url: 'https://habitica.com:443/api/v2/user', //URL to hit
//qs: {from: 'blog example', time: +new Date()}, //Query string data