Skip to content

Instantly share code, notes, and snippets.

View Pushplaybang's full-sized avatar
:octocat:
0_0

Paul Pushplaybang

:octocat:
0_0
View GitHub Profile
@Pushplaybang
Pushplaybang / meteor_deployment_token.sh
Created March 27, 2017 17:38
generate a meteor deployment token for deploying with CI
METEOR_SESSION_FILE=deployment_token.json meteor login
@Pushplaybang
Pushplaybang / circle.yml
Last active February 2, 2019 20:10
Circle CI configuration for building, linting, testing and deploying a meteor application to galaxy.
# use the default node box and isntall meteor
machine:
node:
version: 4.2.6
pre:
# download if meteor isn't already installed in the cache
- meteor || curl https://install.meteor.com | /bin/sh
post:
- meteor --version
@Pushplaybang
Pushplaybang / setup github issues labels.sh
Created September 13, 2016 11:37 — forked from rentzsch/setup github issues labels.sh
Shell script to set up a GitHub Project's Issues' Labels as described in <http://rentzsch.tumblr.com/post/252878320/my-lighthouse-ticket-settings-with-colors>. WARNING: script assumes a newish project that hasn't really used labels yet. It deletes all default labels, which means DATA LOSS if you've used them for anything.
USER=rentzsch
PASS=mypassword
REPO=mogenerator
# Delete default labels
curl --user "$USER:$PASS" --include --request DELETE "https://api.github.com/repos/$USER/$REPO/labels/bug"
curl --user "$USER:$PASS" --include --request DELETE "https://api.github.com/repos/$USER/$REPO/labels/duplicate"
curl --user "$USER:$PASS" --include --request DELETE "https://api.github.com/repos/$USER/$REPO/labels/enhancement"
curl --user "$USER:$PASS" --include --request DELETE "https://api.github.com/repos/$USER/$REPO/labels/invalid"
curl --user "$USER:$PASS" --include --request DELETE "https://api.github.com/repos/$USER/$REPO/labels/question"
@Pushplaybang
Pushplaybang / Common-Currency.json
Created August 3, 2016 11:02 — forked from ksafranski/Common-Currency.json
Common Currency Codes in JSON
{
"USD": {
"symbol": "$",
"name": "US Dollar",
"symbol_native": "$",
"decimal_digits": 2,
"rounding": 0,
"code": "USD",
"name_plural": "US dollars"
},
@Pushplaybang
Pushplaybang / _html_entities.scss
Last active June 8, 2016 14:45 — forked from apisandipas/_html_entities.scss
HTML Entities map - The pseudo-element 'content' property doesnt accept normal (&raquo;) style HTML entities. These variables below easy the pain of looking up the HEX codes...
/**
* The pseudo-element 'content' property doesnt accept normal (&raquo;) style
* HTML entities. These variables below easy the pain of looking up the HEX codes...
*
* Referenced from http://www.danshort.com/HTMLentities/
*
* TODO: Add all the other entities? Worth it? Some day? Maybe?
*/
// Punctuation
@Pushplaybang
Pushplaybang / font_variables.scss
Created June 7, 2016 20:20 — forked from jacrook/font_variables.scss
Sass Css Font Stack Variables
//////////////////////////////////////////////////////////////
// Font Variables (http://cssfontstack.com/)
//////////////////////////////////////////////////////////////
//
// Serif font-stacks
//
$baskerville-font-stack: "Big Caslon", "Book Antiqua", "Palatino Linotype", Georgia, serif !default;
@Pushplaybang
Pushplaybang / is_installed.sh
Created May 22, 2016 14:36 — forked from JamieMason/is_installed.sh
Check if a program exists from a bash script. Thanks to twitter.com/joshnesbitt and twitter.com/mheap for the help with detecting npm packages.
#!/bin/bash
# Functions ==============================================
# return 1 if global command line program installed, else 0
# example
# echo "node: $(program_is_installed node)"
function program_is_installed {
# set to 1 initially
local return_=1
@Pushplaybang
Pushplaybang / free-meteor-deployment-heroku.md
Last active July 29, 2019 13:38
no frills instructions for getting meteor up on a free heroku and mongolab instance, no credit card required.

Prerequisites

You're going to need to create accounts at both Heroku and mlab, get the heroku toolbelt, create a database and get the full db url with the credentials.

  1. Have a meteor project you want to deploy setup on GIT
    • if your not yet on git, you'll need to get up to speed before proceeding with this, of course you should be on git, versioning all your work, and luckily getting started is pretty easy. You'll also need a github account to follow this tutorial.
  2. Setup a Heroku Account here
  3. Setup a mongo lab account
  4. Install the Heroku tool belt
  5. create a new db on mlab
  6. create a new user for that db
@Pushplaybang
Pushplaybang / cordova-device-permissions.js
Created April 27, 2016 22:01
Cordova Device Permissions
/*
Example invoking device permissions using the cordova diagnostic plugin
https://github.com/dpa99c/cordova-diagnostic-plugin
*/
// with meteor on mobile this fires onDeviceReady
Meteor.startup(function() {
// This only checks on app startup, ideally it should be functionality specifct
if (Meteor.isCordova) {
// check and request microphone access
@Pushplaybang
Pushplaybang / stop-dropping-frames.md
Last active September 19, 2016 14:09
list of practical micro optimisations and patterns to help stop dropping frames in hybrid apps

Stop Dropping Frames

Some practical tips from recent experiements in building performant hybrid mobile apps.

Approach

  • Question your assumptions about behaviour and perforamnce
  • Measure as much as possible
  • Optimise for the most common case
  • Simplify where ever possible