Skip to content

Instantly share code, notes, and snippets.

View musha68k's full-sized avatar

Oskar Maria Grande musha68k

View GitHub Profile
@atsaki
atsaki / Vagrantfile
Last active December 4, 2015 02:29
Vagrant+Docker Machine Generic Driverを使ってDockerホスト・Swarmクラスタを構築する ref: http://qiita.com/atsaki/items/0b48daf4858c61cb29e0
Vagrant.configure(2) do |config|
# vagrant-triggersをProvisionerとして使用し、
# 作成した仮想マシンに対してdocker-machine createを実行
config.vm.provision "trigger" do |trigger|
trigger.fire do
# docker-machine statusのexitstatusが0の場合はdocker-machine create実行済み
`docker-machine status #{@machine.name}`
if $?.exitstatus != 0
# 使用するIPとポートを取得
# VirtualBoxの場合には一度仮想マシンにログインしプライベートネットワークのIPを取得
@deplinenoise
deplinenoise / build-gcc-toolchain.sh
Created June 5, 2016 19:15
Build m68k-unknown-elf toolchain into subdir of PWD on Mac, relies on brew for GCC dependencies
#! /usr/bin/env bash
echo Building GCC m68k toolchain...
mkdir -p sources
mkdir -p build
CORES=8
TARGET=m68k-unknown-elf
PREFIX=$PWD/m68k-unknown-elf
@cezarneaga
cezarneaga / Workshop Handout.md
Last active November 23, 2017 19:22
a sum-up of recorded knowhow

Reason Workshop @ReactiveConf 2017

by: Sean Grove, Jared Forsyth, Daniel Woelfel
support team: Cristiano Calcagno, @reasonvienna - @ryyppy @svensauleau @cezarneaga and @nikgraf in spirit, @matystl, @MyNaartjie

Support and Questions: Join discord channel

Workshop Presentation

  • workshop flow and exercises
import React from 'react'
import revalidation from 'revalidation'
import gql from 'graphql-tag.macro'
import { filter } from 'graphql-anywhere'
import { curry } from 'ramda'
import { compose, withProps, withHandlers } from 'recompose'
import { graphql } from 'react-apollo'
import { Button } from '../common/styled'
import { getValue } from '../form/utils'
import { isRequired } from '../../utils/validation'
@Sanix-Darker
Sanix-Darker / [JS] Copy to clipboard
Created November 15, 2017 09:16
[JS] Copy to clipboard
<input name="exampleClipboard" placeholder="Insert the text you want to copy" value="Example text" tabindex="1" autocomplete="off" maxlength="240" style="width:200px" type="text">
<p>
<button id="copy">
Copy text
</button>
</p>
<p>
Right click paste or Ctr + v after click Copytext button <br/>
<textarea></textarea>
</p>
@iamgreaser
iamgreaser / gist:3022436
Created June 30, 2012 05:20
how to reverb on mega drive [Z80 component, WLA-DX assembler]
; basic memory map
;
; from Charles MacDonald's gen-hw.txt:
; 0000-1FFFh : RAM
; 2000-3FFFh : RAM (mirror)
; 4000-5FFFh : YM2612 (1)
; 6000-60FFh : Bank address register (2)
; 6100-7EFFh : Unused (3)
; 7F00-7FFFh : VDP (4)
; 8000-FFFFh : Bank area
@vrybas
vrybas / how-do-i-pomodoro.md
Last active March 12, 2019 11:08
Vladimir Rybas - How do I Pomodoro

vrybas.github.io

How do I Pomodoro

I'm a big fan of Pomodoro time management technique, created by Francesco Cirillo in the 80's. In this post I'll describe what it is, how I use it (tools and their tweaks), and how it helps me to get through my day.

Interruptions

@capttaco
capttaco / Fetchable.swift
Last active May 3, 2019 17:28
A utility protocol for custom NSManagedObjects that makes querying contexts simpler and more convenient. Requires Swift 2.
import CoreData
protocol Fetchable
{
typealias FetchableType: NSManagedObject
static func entityName() -> String
static func objectsInContext(context: NSManagedObjectContext, predicate: NSPredicate?, sortedBy: String?, ascending: Bool) throws -> [FetchableType]
static func singleObjectInContext(context: NSManagedObjectContext, predicate: NSPredicate?, sortedBy: String?, ascending: Bool) throws -> FetchableType?
static func objectCountInContext(context: NSManagedObjectContext, predicate: NSPredicate?) -> Int
# apiVersion and kind of Kustomization
# apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
# Adds namespace to all resources.
# namespace: my-namespace
# Value of this field is prepended to the
# names of all resources, e.g. a deployment named
# "wordpress" becomes "alices-wordpress".
@tmattio
tmattio / git-import-repository.md
Created December 3, 2019 15:47 — forked from martinbuberl/git-import-repository.md
Import existing Git repository into another

Import existing Git repository into another

Folder structure before (2 separate repositories):

XXX
 |- .git
 |- (project files)
YYY
 |- .git