Skip to content

Instantly share code, notes, and snippets.

View ritchiey's full-sized avatar

Ritchie Young ritchiey

View GitHub Profile
" Force the creation of the filename currently under the cursor
map gf! :e <cfile><CR>
" Allow moving between files without saving
set hidden
" Shortcuts for testing
map <leader>sm :wa\|:Rake spec:models<cr>
map <leader>sv :wa\|:Rake spec:views<cr>
map <leader>sc :wa\|:Rake spec:controllers<cr>
Date.fromSecondsSinceEpoch = function(seconds) {
return new Date(seconds * 1000);
};
// JSON call to retrieve queued order (using JQuery)
$.ajax({
type: 'GET',
success: handleQueuedOrder,
url: 'http://localhost:3000/queued_orders/1',
dataType: 'json'