Skip to content

Instantly share code, notes, and snippets.

@Lucas-Geitner
Lucas-Geitner / osx-for-hackers.sh
Created July 4, 2016 09:03 — forked from brandonb927/osx-for-hackers.sh
OSX for Hackers: Yosemite/El Capitan Edition. This script tries not to be *too* opinionated and any major changes to your system require a prompt. You've been warned. Also, please don't email me about this script, my poor inbox...
#!/bin/sh
# Alot of these configs have been taken from the various places
# on the web, most from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Set the colours you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
@Lucas-Geitner
Lucas-Geitner / machine.js
Created December 17, 2019 10:56
Generated by XState Viz: https://xstate.js.org/viz
const createDonationMachine = Machine({
id: "createDonation",
initial: "inactive",
states: {
inactive: { on: { TOGGLE: "not_normalize" } },
not_normalize: { on: { TOGGLE: "send_slack_notification" } },
send_slack_notification: { on: { TOGGLE: "send_email_notification" } },
send_email_notification: { on: { TOGGLE: "send_to_identity" } },
send_to_identity: { on: { TOGGLE: "updatePetition" } },
updatePetition: { on: { TOGGLE: "active" } },
const {
ApolloServer,
} = require('apollo-server-express')
const express = require('express')
const app = express()
const {typeDefs} = require('./schema/TypeDefs')
const { PubSub } = require('apollo-server')
require('dotenv').config()
const mongoose = require('mongoose')
mongoose.connect(process.env.DATABASE, {
useNewUrlParser: true
})
mongoose.Promise = global.Promise // Tell Mongoose to use ES6 promises
mongoose.connection.on('error', (err) => {
//@eslint-ignore
#!/usr/bin/env zx
// await $`npm install --global @squoosh/cli`
// await $`npm install --global slug`
// await $`npm install --global escape-path-with-spaces`
import slug from 'slug'
import escape from 'escape-path-with-spaces'
@Lucas-Geitner
Lucas-Geitner / SETUP_DAY.md
Created June 15, 2021 19:48
Starting my coding journey...