Skip to content

Instantly share code, notes, and snippets.

View goughjt's full-sized avatar

goughjt

View GitHub Profile
@goughjt
goughjt / channel_case.ex
Created December 15, 2017 01:12
A default auto-generated channel_case.ex
defmodule MyAppServerWeb.ChannelCase do
use ExUnit.CaseTemplate
using do
quote do
# Why can alchemist not see this?
use Phoenix.ChannelTest
end
end
@goughjt
goughjt / room_channel_test.exs
Last active December 15, 2017 01:10
A default auto-generated room_channel_test.exs
defmodule MyAppServerWeb.RoomChannelTest do
use MyAppServerWeb.ChannelCase
alias MyAppServerWeb.RoomChannel
# if I uncomment this then alchemist-help-search-at-point does work on "socket"
# use Phoenix.ChannelTest
setup do
{:ok, _, socket} =
@goughjt
goughjt / user-data.yml
Created December 13, 2017 00:15
user data YAML for flashing hyprtio OS v1.7.1 to raspberry pi with wifi - assumes using ssh-keygen
# You need to change any variables wrapped <like-this> to your own variables.
#cloud-config
hostname: <hostname>
manage_etc_hosts: true
users:
- name: <username>
primary-group: users
shell: /bin/bash
sudo: ALL=(ALL) NOPASSWD:ALL
groups: users,docker,adm,dialout,audio,plugdev,netdev,video
@goughjt
goughjt / boot-config.txt
Created December 13, 2017 00:13
Boot config file for flashing hypriot OS v1.7.1 to raspberry pi with wifi
hdmi_force_hotplug=1
enable_uart=0
# camera settings, see http://elinux.org/RPiconfig#Camera
start_x=1
disable_camera_led=1
gpu_mem=128
# Enable audio (added by raspberrypi-sys-mods)