Skip to content

Instantly share code, notes, and snippets.

View tsubik's full-sized avatar

Tomasz Subik tsubik

View GitHub Profile
@tsubik
tsubik / FindProjectMissingFilesReferences.ps1
Created August 8, 2012 16:25
Looking for missing references to files in project config file
#Author: Tomasz Subik http://tsubik.com
#Date: 8/04/2012 7:35:55 PM
#Script: FindProjectMissingFiles
#Description: Looking for missing references to files in project config file
Param(
[parameter(Mandatory=$false)]
[alias("d")]
$Directory,
[parameter(Mandatory=$false)]
[alias("s")]
@tsubik
tsubik / vspniff_command
Created September 22, 2012 13:28
Keep your VS project files included. Fast and elegant solution Blog
PM> Find-MissingFiles
@tsubik
tsubik / dialogmanager.js
Created October 7, 2012 21:37
Simple jQueryUI DialogManager
;(function(w){
var DialogManager = (function(){
function DialogManager(){
this.dialogIdx= 1;
};
DialogManager.prototype.createDialog = function(options){
var defaults = {
modal: true,
resizeable: false,
@tsubik
tsubik / application.css
Last active December 10, 2015 15:58
Twitter bootstrap asp.net mvc 4 and sass
body {
padding-top: 40px;
padding-bottom: 40px;
background-color: #f5f5f5;
}
.form-signin {
max-width: 300px;
padding: 19px 29px 29px;
margin: 0 auto 20px;
@tsubik
tsubik / AddMigration.ps1
Created June 10, 2014 17:17
Powershell script to automate visual studio with creating migrations
#Author: Tomasz Subik http://tsubik.com
#Date: 2014-05-27
#License: MIT
Param(
[parameter(Mandatory=$false)]
[alias("n")]
$name = [System.Guid]::NewGuid().ToString(),
[parameter(Mandatory=$false)]
[alias("p")]
@tsubik
tsubik / XHRHelper.cs
Created September 27, 2014 13:14
XHRHelper for cordova that works on Windows Phone 8.1
using Microsoft.Phone.Controls;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.IO.IsolatedStorage;
using System.Linq;
using System.Text;
using System.Windows;
@tsubik
tsubik / application.controller.js
Last active January 19, 2016 11:29
Promise rejections
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle',
actions: {
save() {
Ember.RSVP.reject("something not error object");
}
}
@tsubik
tsubik / adapters.application.js
Created May 16, 2016 11:23
EmberFire Embedded Relations
import Ember from "ember";
import FirebaseAdapter from "emberfire/adapters/firebase";
const { inject } = Ember;
export default FirebaseAdapter.extend({
firebase: inject.service()
});
@tsubik
tsubik / adapters.application.js
Created January 21, 2017 13:38
EF hasmany bug
import FirebaseAdapter from 'emberfire/adapters/firebase';
export default FirebaseAdapter.extend({
});

#Setting up Docker Machine on Raspberry PI

  1. SSH into the pi and install docker with curl -sSL https://get.docker.com | sh (If we let Machine try to install the Docker daemon it will fail.)
  2. Change the OS's ID so Docker Machine won't throw errors. sudo nano /etc/os-release and change the line that says ID=raspbian to ID=debian
  3. From a new terminal window run docker-machine create --driver generic --generic-ip-address YOUR-PIS-IP --generic-ssh-key ~/.ssh/id_rsa --generic-ssh-user pi --engine-storage-driver overlay2 MACHINE-NAME