This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# see mixins/posts_formable below | |
App.PostsNewRoute = Ember.Route.extend App.PostsFormable, | |
# set up a new blank instance of Post for the form's content | |
model: -> | |
App.Post.createRecord() | |
# perhaps alternatively, this could use 'needs post' in controller | |
# for setting the model instance | |
App.PostEditRoute = Ember.Route.extend App.PostsFormable, | |
model: -> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# form view that matches posts.form template | |
App.PostsFormView = Em.View.extend | |
tagName: 'form' | |
classNames: 'modal fade in form-custom-field-modal'.w() | |
didInsertElement: -> | |
@$().modal 'show' | |
willDestroyElement: -> | |
@$().modal 'hide' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; start server mode | |
(server-start) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### use emacsclient as editor | |
export EDITOR=/usr/local/bin/emacsclient |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App = require 'app' | |
require 'models/provider' | |
require 'stores/provider' | |
# Sample test case | |
describe 'Provider', -> | |
describe '#create()', -> | |
# essentially this is testing that our configuration is working | |
# so somewhat of a redundant test | |
it 'should return a new Provider record matching input', -> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App = require 'app' | |
# see Ember Model: https://github.com/ebryn/ember-model | |
# for how this is set up | |
require 'models/provider' | |
require 'adapters/provider' | |
describe 'Provider', -> | |
describe '#create()', -> | |
# essentially this is testing that our configuration is working | |
# so somewhat of a redundant test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App = require 'app' | |
require 'helpers/markdown' | |
module 'Markdown Helper', | |
setup: -> | |
Ember.run App, App.advanceReadiness | |
teardown: -> | |
App.reset() | |
test '#markdown', -> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
brew update | |
brew install zsh | |
sudo ln -s /etc/zshenv /etc/zprofile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# instead of just using chsh -s /bin/zsh (what comes with mac os x) | |
# symlink /bin/zsh to /usr/local/bin/zsh first | |
# as chsh -s /usr/local/bin/zsh isn't allowed | |
sudo mv /bin/zsh /bin/zsh-distribution-bak | |
sudo ln -s /usr/local/bin/zsh /bin/zsh | |
sudo chsh -s /bin/zsh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(setenv "ESHELL" "/usr/local/bin/zsh") | |
(setenv "SHELL" "/usr/local/bin/zsh") |