Skip to content

Instantly share code, notes, and snippets.

View bumble-bee-chuna's full-sized avatar

Bee bumble-bee-chuna

  • Anchorage, Alaska
View GitHub Profile
@bumble-bee-chuna
bumble-bee-chuna / sendRawEth.c
Created February 6, 2016 02:38 — forked from austinmarton/sendRawEth.c
Send a raw Ethernet frame in Linux
/*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*/
#include <arpa/inet.h>
#include <linux/if_packet.h>
#include <stdio.h>
CREATE ROLE mystore LOGIN PASSWORD 'mystore' NOINHERIT CREATEDB;
Errors you will get in rails if you don't have the username available:
ActiveRecord::NoDatabaseError: FATAL: role does not exist rails
friggin start and stop the damn thing:
$ brew services list
$ brew services restart postgresql
https://<dc>.api.mailchimp.com/2.0/lists/subscribe.json?apikey=<my_api_key>&id=<my_list_id>&email[email][email protected]&merge_vars[FNAME]=John&merge_vars[LNAME]=Doe&double_optin=false&send_welcome=false
Where <dc> should be replaced with the portion after the dash in your API Key. e.g. "us1", "us2", "uk1", etc.
http://stackoverflow.com/questions/19671676/javascript-mailchimp-api-subscribe
<!DOCTYPE HTML>
<html lang="en">
<head itemscope itemtype="http://schema.org/WebSite">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="msapplication-tap-highlight" content="no">
<!-- Color the status bar on mobile devices -->
/*************************
General Assets
**************************/
html, body, div, h1, h2, h3, h4, h5, h6, ul, ol, dl, li, dt, dd, p, blockquote,
pre, form, fieldset, table, th, td, article { margin: auto 0; padding: 0; }
body, nav, article, #hero {
width: 100%;
}
/* If on a desktop, change nav's logo and hamburger when past the hero */
if( screen.width >= 875 ) {
var scroll_pos = 0;
$(document).scroll(function() {
scroll_pos = $(this).scrollTop();
if(scroll_pos > 520) {
$("#logo").attr("src", "assets/images/logo-scroll.svg");
$("#hamburger").attr("src", "assets/images/hamburger-scroll.svg")
} else {
package com.snapwebdevelopment.scanhappy.paymentApi;
import android.content.Context;
import android.support.annotation.NonNull;
import android.util.Log;
import com.android.volley.Request;
import com.android.volley.RequestQueue;
import com.android.volley.Response;
import com.android.volley.VolleyError;
import com.android.volley.toolbox.StringRequest;
class IssuesController < ApplicationController
before_action :get_jira_client
def index
@issues = @jira_client.Issue.all
end
def show
@issue = @jira_client.Issue.find(params[:id])
end
{
"project":{
"components":[
{
"name":"1",
"description":"1"
},
{
"name":"1-subitem1",
"description":"1A"
<% if defined? project %>
<%
components = retrieve_components(project)
previous_component = {}
components.each do |component|
%>
<%= open_or_close_unordered_list(previous_component, component).html_safe %>
<% if !containsLetter(component.description) %>