Skip to content

Instantly share code, notes, and snippets.

/*
# Resize an Image
- Prompts user to install "jimp"
- Uses image path from currently selected file in Finder
- Prompts user for resize dimensions
- Resizes and reveals new file in Finder
*/
// Menu: Resize an Image
// Description: Select an Image in Finder to Resize
componentDidMount() {
this.props.onRef&&this.props.onRef(this)
}
componentWillUnmount() {
this.props.onRef&&this.props.onRef(undefined)
}
const CodeBlock = ({ children }) => (<small>
<pre>{children}</pre>
</small>)
<CodeBlock>{`
import Flow from '@cypherlab/react-flow'
import FlowBundle from '@cypherlab/react-flow-bundles'
<Flow flows='one,two,three'>
{ flow => (<FlowBundle bundle="microdot" flow={flow} />) }
import Flow from '@cypherlab/react-flow'
import FlowBundle from '@cypherlab/react-flow-bundles'
<Flow flows='one,two,three'>
{ flow => (<FlowBundle bundle="microdot" flow={flow} />) }
</Flow>
@larafale
larafale / mifareClassic1K.js
Created July 9, 2014 18:10
Read/Write miFare classic 1K
var tessel = require('tessel')
, rfidLib = require('rfid-pn532')
, log = console.log
, rfid = rfidLib.use(tessel.port['A'], { listen: false })
var card = {}
, cursor = 0x00
, auth_key = [0xff,0xff,0xff,0xff,0xff,0xff]
, auth_type = 0
@larafale
larafale / fullnode.md
Last active August 24, 2018 15:04
A simple guide to financial sovereignty (set up your Bitcoin fullnode)

In 2009, a 9 pages white paper by satoshi Nakamoto described a protocol that made central banking obselete. It's a new paradigm where monney is no longer controlled by a few, but by the whole network.

The shift is already happening, as we speak, even if it's hard to see, especially if you lack the fundamental knowledege of cryptoghraphy, game theory and economics. It's just a matter of time before you realize that Bitcoin is hard money, and for the first time we have a framework to apply austrian economics, without permission. Time to reset the keynesian monopoly game.

I don't think people are inherently bad, it's just that in the actual system (which I call the legacy system) people are incentivised to make decisions that are good from their individual perspective, but unfortunately, the sum of those individual decisions are bad from the collective group perspective. That's just plain simple game theory. What makes Bitcoin so special is it's perfectly aligned set of

COIN=BitcoinSegwit
NET=mainnet
ELECTRUMX=/home/larafale/Sites/electrumx/electrumx_server.py
DB_DIRECTORY=/home/larafale/.electrumx
DAEMON_URL=http://foo:bar@localhost:8332/
DAEMON_VERSION=16.0.1
TCP_PORT=50001
SSL_PORT=50002
HOST=
ANON_LOGS=nope
var Gpio = require('onoff').Gpio
var signal = new Gpio(23, 'in', 'both')
var _ = require('lodash')
var captureTimeOut
var startTime
var data = []
signal.watch((err, val) => {
var irc = require('../lib/irc/lib/irc')
, utils = require('../lib/utils')
, _ = require('lodash')
, EventEmitter = require('events').EventEmitter
var IRCBot = module.exports = function(options){
EventEmitter.call(this)
var requiredFields = ['server', 'name', 'rootCmd']

Keybase proof

I hereby claim:

  • I am larafale on github.
  • I am larafale (https://keybase.io/larafale) on keybase.
  • I have a public key whose fingerprint is 75BF E913 AB89 24BF B5E3 FEB3 146F 4DC5 1256 73A1

To claim this, I am signing this object: