Skip to content

Instantly share code, notes, and snippets.

@MatthewVita
MatthewVita / KOTemplateLoader.js
Last active August 29, 2015 13:57
KOTemplateLoader.js - Loader that easily renders external Knockout.js templates [jQuery dependency]
/*
* @desc: loads an external
* HTML Knockout.js template
* file, places it in the DOM,
* and applies the KO bindings
*
* @param: tmplFile - the template
* file
*
* @param: targetElem - the target
@MatthewVita
MatthewVita / keybase.md
Last active August 29, 2015 13:57
keybase.md

Keybase proof

I hereby claim:

  • I am MatthewVita on github.
  • I am matthewvita (https://keybase.io/matthewvita) on keybase.
  • I have a public key whose fingerprint is A1B4 7008 225E 3FB2 7427 CE4E 8195 0C2C 22C8 46C9

To claim this, I am signing this object:

@MatthewVita
MatthewVita / Empty.js
Last active August 29, 2015 14:07
Empty.js - Convenience function, checks for "empty" values
//@desc: Convenience function that
//checks for "empty" values
//@use: console.log(Empty('hello!')); //false
function Empty(val) {
return (typeof(val) === 'undefined' || typeof(val) === 'null' || val === '' || typeof(val) === 'NaN' || val === false);
}
@MatthewVita
MatthewVita / AmberParser.go
Last active August 29, 2015 14:07
AmberParser.go - Convenience package for parsing Amber templates with JSON parameters
/*
*@desc: Convenience package for parsing
* Amber templates with JSON parameters
*
*@use:
ambrPrsr := amberParser.New("src/views/foobar.amber", `{
"favorite_color":"grey",
"year":"2014",
"baz":"bar"
}`)
@MatthewVita
MatthewVita / Hashtagify.js
Last active August 29, 2015 14:07
Hashtagify.js - Simple regex function that converts hashtags to urls
/*
*@desc: Simple regex function that converts hashtags to urls
*@usage:
* console.log("I love #JavaScript it's a fan#tastic language!".hashtagify());
* ...returns `I love <a href="http://twitter.com/#!/search/#JavaScript">#JavaScript</a> it's a fan#tastic language!`
*/
String.prototype.hashtagify = function() {
return (this.replace(/ (#[a-z0-9][a-z0-9\-_]*)/ig, ' <a href="http://twitter.com/#!/search/$1">$1</a> '));
};
git checkout develop
git fetch
git pull
git checkout us_123_impl_foobar_feature
git merge origin/develop # Creates a new commit on us_123_impl_foobar_feature, that contains all changes from develop
git reset --soft origin/develop # Generates a set of staged changes
git add -A
git commit -m '[US-123] Adds Foobar'
git checkout develop
git merge us_123_impl_foobar_feature
<?xml version="1.0" encoding="UTF-8"?>
<code_scheme name="GoogleStyle">
<option name="JAVA_INDENT_OPTIONS">
<value>
<option name="INDENT_SIZE" value="2" />
<option name="CONTINUATION_INDENT_SIZE" value="4" />
<option name="TAB_SIZE" value="8" />
<option name="USE_TAB_CHARACTER" value="false" />
<option name="SMART_TABS" value="false" />
<option name="LABEL_INDENT_SIZE" value="0" />
@MatthewVita
MatthewVita / lint.sh
Last active February 25, 2017 17:32
OpenEMR Parallel Linter
#!/bin/bash
if [ -z "$1" ] || [ "$1" == "-h" ] || [ "$1" == "--help" ] ; then
printf "OpenEMR Parallel Linter\n\n"
printf " Arguments\n"
printf " -h, --help | Information on using this script\n"
printf " -d, --dir | The codebase directory for OpenEMR\n"
exit 0
fi
<?php
class C_ClinicalDocumentProcessing extends Controller {
var $test_data = array(
// Patient ID 1
"1" => array(
// A new patient note ID 32
"encounter_note_32" => array(
"RXNORM" => array(
array(
@MatthewVita
MatthewVita / gist:ea277dd2969f6cf291b481a1fd5eb818
Last active July 11, 2019 19:28
OpenEMR Rest API Dev Setup

Hi Sherwin and Daniel,

Sorry for my delayed response on this - I have been very ill. Follow these steps to get the REST API up and running so we can continue with some of the TODO items.

  1. Install Ubuntu on your computer or in a VirtualBox via https://itsfoss.com/install-linux-in-virtualbox/
  2. Install Docker:
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo apt-key fingerprint 0EBFCD88