Skip to content

Instantly share code, notes, and snippets.

View robphoenix's full-sized avatar
🤘
Design Systems 4 lyfe

Rob Phoenix robphoenix

🤘
Design Systems 4 lyfe
View GitHub Profile
@robphoenix
robphoenix / build.md
Last active February 9, 2016 08:46
Build.

Elixir

  • IPA: An IP address library.
  • Format: Simple string formatting
  • Enigma: Implement the Enigma machine.

Phoenix

  • CV: A CV generator.
  • Not A Wasted Day: Simple CRUD app to record the days achievements. A DONE app, rather than a TODO app.
  • Entwurf: An insight into the messy first draft of the translation process.
iex> string = "Hello, <%= 2 + 2 %>!"
"Hello, <%= 2 + 2 %>!"
iex(55)> EEx.compile_string string
{:<>, [context: EEx.Engine, import: Kernel],
 [{:__block__, [],
   [{:=, [],
     [{:tmp1, [], EEx.Engine},
      {:<>, [context: EEx.Engine, import: Kernel], ["", "Hello, "]}]},
 {:&lt;&gt;, [context: EEx.Engine, import: Kernel],

Keybase proof

I hereby claim:

  • I am robphoenix on github.
  • I am robphoenix (https://keybase.io/robphoenix) on keybase.
  • I have a public key ASB-aboRV_tyb6roe20y1_L98XiAAecN-rU421MRxMW7ywo

To claim this, I am signing this object:

---
- name: Create tmp Directory
hosts: 127.0.0.1
connection: local
tasks:
- name: Create tmp Directory
file: path=../../tmp state=directory
@robphoenix
robphoenix / xgo.sh
Created April 3, 2017 19:33
shell scripts
#!/bin/bash
for dir in ./exercises/*/
do
dir=${dir%*/}
file="$dir/example_gen.go"
if [ -f "$file" ]; then
metadir="${dir}/.meta/"
mkdir -p "${metadir}"
mv "$file" "${metadir}gen.go"
fi
{
"Reggae": [
"The Abyssinians",
"The Aces",
"Glen Adams",
"Admiral T",
"Yasus Afari",
"African Brothers",
"The Aggrovators",
"Aisha",
import { InMemoryDbService } from 'angular-in-memory-web-api'
import { Hero } from './hero'
export class InMemoryDataService implements InMemoryDbService {
createDb() {
const heroes = [
{ id: 11, name: 'Mr. Nice' },
{ id: 12, name: 'Narco' },
{ id: 13, name: 'Bombasto' },
{ id: 14, name: 'Celeritas' },
@robphoenix
robphoenix / cloudSettings
Last active January 7, 2019 09:10
Visual Studio Code Settings Sync Gist
{"lastUpload":"2019-01-07T09:10:24.054Z","extensionVersion":"v3.2.4"}
@robphoenix
robphoenix / cloudSettings
Last active April 21, 2019 08:22
Visual Studio Code Settings Sync Gist
{"lastUpload":"2019-04-21T08:22:13.740Z","extensionVersion":"v3.2.8"}
@robphoenix
robphoenix / flex.tsx
Created December 9, 2019 10:30
react flexbox component with as prop
/** @jsx jsx */
import { jsx } from '@emotion/core'
import React from 'react'
const Flex: React.FC<{
as?: React.ReactType
row?: boolean
column?: boolean
}> = ({ as: Component = `div`, row, column }) => {
const flexDirection = row ? 'row' : column ? 'column' : ''