Skip to content

Instantly share code, notes, and snippets.

View alfredbaudisch's full-sized avatar

Alfred Reinold Baudisch alfredbaudisch

View GitHub Profile
Creation of an opposite macro
We want opposite 1 + 1
to return to 0 or essentially run 1 - 1
opposite 1 + 1
Transforms 1 + 1 into an AST
opposite({:+, [], [1,1]}
Our macro would then transform that AST (Abstract syntax tree)
@mattweldon
mattweldon / up-and-running-with-edeliver-on-do.md
Last active September 3, 2021 16:48
Getting Elixir / Phoenix running on Digital Ocean with edeliver

Build Server

  • Go to Digital Ocean
  • Create new droplet
  • London
  • Ubuntu
  • No apps
  • Add SSH keys
@msysyamamoto
msysyamamoto / lib-hello_phoenix-memcached_supervisor.ex
Created September 1, 2015 15:13
Poolboy Sample on Phoenix Framework
defmodule HelloPhoenix.Memcached.Supervisor do
use Supervisor
def start_link do
Supervisor.start_link(__MODULE__, [])
end
def init([]) do
pool_options = [
name: {:local, :memcached_pool},