Skip to content

Instantly share code, notes, and snippets.

View tompedals's full-sized avatar

Tom Graham tompedals

View GitHub Profile
@tompedals
tompedals / heyupdate.sh
Created August 26, 2015 20:16
A simple command line interface for HeyUpdate
#!/bin/bash
# You can generate a new personal API token in your user settings (/user/tokens).
TOKEN="";
# Send the input as an update
curl -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d "{\"message\": \"$*\"}" \
Status Response
200 ```json
{
"id": 10,
"username": "alanpartridge",
"email": "alan@alan.com",
"password_hash": "$2a$10$uhUIUmVWVnrBWx9rrDWhS.CPCWCZsyqqa8./whhfzBZydX7yvahHS",
"password_salt": "$2a$10$uhUIUmVWVnrBWx9rrDWhS.",
"created_at": "2015-02-14T20:45:26.433Z",
{
"name": "HeyUpdate",
"description": "Send a summary of your teams updates to HipChat",
"keys": "com.heyupdate",
"links": {
"homepage": "http://www.heyupdate.com",
"self": "https://demo.heyupdate.dev/app_dev.php/hipchat/capabilities"
},
"capabilities": {
"hipchatApiConsumer": {
@tompedals
tompedals / Version20141205212145.php
Created December 5, 2014 22:36
Migration to convert database, table and column charset to utf8mb4 (for Emoji support)
<?php
namespace HeyUpdate\Application\Migrations;
use Doctrine\DBAL\Migrations\AbstractMigration;
use Doctrine\DBAL\Schema\Schema;
class Version20141205212145 extends AbstractMigration
{
public function up(Schema $schema)