Skip to content

Instantly share code, notes, and snippets.

Ext.define('App.ODataProxy', { extend:'Ext.data.proxy.Ajax', requires:[ 'Ext.data.reader.Json', 'Ext.data.writer.Json' ], alias:'proxy.odata', sortParam:'$orderby', filterParam:'$filter', pageParam:null, limitParam:'$top', startParam:'$skip', actionMethods: { create:'POST', read:'GET', //Changed from PUT to allow writer to not writeAllFields. update: Ext.isIE8m ? 'PUT' : 'PATCH', destroy:'DELETE' }, headers:{ Accept:'application/json;odata=verbose', Prefer:'return-content' }, constructor:function(cfg) { cfg.reader = { type:'json', readRecords:function(data) { if (data.status == 204) { return null; } return this.self.prototype.readRecords.call(this, data['d']); }, buildExtractors:function() { this.self.prototype.buildExtractors.apply(this, argumen
#########################
# Autoinstall script using chocolatey
#########################
# Note: Net 4.0 must be installed prior to running this script
#
#Modify this line to change packages
$items = @("git-credential-winstore", "console-devel", "sublimetext3", "poshgit", "driverbooster", "revouninstallerpro", "malwarebytes", "powerquery", "TimRayburn.GitAliases", "sudo", "Evernote5", "javaruntime", "DotNet4.5.1", "NSSM", "ConsoleZ", "git.install")
@philbritton
philbritton / windows-config.txt
Last active December 28, 2015 02:19
config 01-20-14
Set-ExplorerOptions -showHidenFilesFoldersDrives -showProtectedOSFiles -showFileExtensions
Enable-RemoteDesktop
cinst sublimetext3
cinst git.install
cinst 7zip.install
cinst poshgit
cinst DotNet4.5
cinst nodejs.install
cinst ruby.devkit
@philbritton
philbritton / dedupe-cml.liquid
Created October 29, 2013 23:17
CML for Dedupe job
<!-- BEGIN CUSTOMIZABLE SECTION -->
<!--
This section ensures that no invalid values are included in the google search queries we construct below. Each 3-line segment uses liquid to do two things:
1. Check if if the header's data for this row (from the input data, above) is valid
2. Assign this data to a new variable (for example, 'street_a') - ONLY IF the original header's data for this row is valid!
Finally, we use this variable in the google search below.
-->
{% if name != "Not_Found_In_Source_System" and name != "" and name != "No data available" %}
@philbritton
philbritton / 0_reuse_code.js
Created October 15, 2013 17:21
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console

Make it real

Ideas are cheap. Make a prototype, sketch a CLI session, draw a wireframe. Discuss around concrete examples, not hand-waving abstractions. Don't say you did something, provide a URL that proves it.

Ship it

Nothing is real until it's being used by a real user. This doesn't mean you make a prototype in the morning and blog about it in the evening. It means you find one person you believe your product will help and try to get them to use it.

Do it with style

{
"definitions": {
"MedicalSignOrSymptom": {
"title": "Medical Sign or Symptom",
"anyOf": [
{
"$ref": "#/definitions/MedicalEntity"
}
],
"description": "Any indication of the existence of a medical condition or disease.",
@philbritton
philbritton / mono.rb
Last active December 19, 2015 05:29 — forked from shtirlic/mono.rb
# http://www.mono-project.com/Compiling_Mono_on_OSX
require 'formula'
class Mono < Formula
url 'http://download.mono-project.com/sources/mono/mono-3.0.6.tar.bz2'
sha1 'e2187f80366fcd65c55a1ab946f8d3b39e81be77'
#url 'http://download.mono-project.com/sources/mono/mono-2.10.9.tar.bz2'
#sha1 '1a6e8c5a0c3d88d87982259aa04402e028a283de'
module CapybaraWithPhantomJs
include Capybara
# Create a new PhantomJS session in Capybara
def new_session
# Register PhantomJS (aka poltergeist) as the driver to use
Capybara.register_driver :poltergeist do |app|
Capybara::Poltergeist::Driver.new(app)
end