Skip to content

Instantly share code, notes, and snippets.

View konsumer's full-sized avatar

David Konsumer konsumer

View GitHub Profile
@konsumer
konsumer / require.js
Last active December 29, 2015 09:49
Dum-dum-stupid CommonJS, in teh browser Not complete, by any remote stretch of the imagination, but it does the trick, in a quick multi-platform pinch.
/**
* Dum-dum-stupid CommonJS, in teh browser
* Not complete, by any remote stretch of the imagination.
*/
// synchronous shim-require for CommonJS in browser
var require = function (name) {
var AJAX;
if (!require.imported[name]){
if (window.XMLHttpRequest) {
// from https://clients3.google.com/cast/chromecast/device/config
var services=[ 'TicTacToe',
'00000000-0000-0000-0000-000000000000',
'PlayMovies',
'Netflix',
'Pandora_App',
'GoogleMusic',
'YouTube',
'ChromeCast',
'Hulu_Plus',
[{
"kind": "track",
"id": 96391624,
"created_at": "2013/06/11 10:24:10 +0000",
"user_id": 668105,
"duration": 140787,
"commentable": true,
"state": "finished",
"original_content_size": 1665146,
"sharing": "public",
sudo add-apt-repository ppa:gma500/emgd
sudo apt-get update
sudo apt-get install xorg-emgd emgd-dkms emgd-xorg-conf

I was contacted by Nathan Bernard to work on this project. It was phrased as if it's an actual thing that does something functional (and I got excited for just a sec), but the more I look around, the more I realize that it's not really a thing. I don't know what OSS projects you have worked on (actually I do: none) but that is not really how it works, for the most part.

I will help you, since you are new here:

  • first be a programmer, you know someone who makes stuff. Put in a massive amount of time & energy to learn how the technologies work that you are hoping to utilize. Alternately: have money to pay programmers to implement your sweet-ass scheme & listen to their advice, when they tell you "that's not real, but here is another cool thing we could do instead, that might work ok"
  • when you have the details worked out (actual functional code) make a public repo. get people writing about it, you know because it's useful
  • wait for more qualified developers to stream in and help you make it even
/**
* Synchronously query the Pebble application to see if the connected watch is running a firmware version that supports PebbleKit messages.
* @return {Boolean}
*/
Pebble.areAppMessagesSupported = function(){}
/**
* Send a message to the connected Pebble to close an application identified by a UUID.
* @param {String} watchappUuid [description]
*/
@konsumer
konsumer / Gruntfile.js
Created January 10, 2014 00:11
Gruntfile for cordova: generates all images
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
app: {
name: '<%= pkg.name %>'
},
clean: {
<!DOCTYPE html>
<html>
<head>
<script src="bower_components/platform/platform.js"></script>
<link rel="import" href="app/s-app.html">
<style>
html, body{
margin:0;
padding:0;
}
<!DOCTYPE html>
<html>
<head>
<script src="bower_components/platform/platform.js"></script>
<link rel="import" href="app/s-app.html">
<style>
html, body{
margin:0;
padding:0;
}
<!DOCTYPE html>
<html>
<head>
<script src="bower_components/platform/platform.js"></script>
<link rel="import" href="app/s-app.html">
<style>
html, body{
margin:0;
padding:0;
height: 100%;