※主観的かつ個人的な試行錯誤の備忘録です
- Model
- associations
- attr_accessors
- scopes
- validations
| /* create tables to store itunes music library data for quick access | |
| - rkumar 2010 July | |
| */ | |
| drop table tracks; | |
| create table tracks ( | |
| album_artist VARCHAR(50), | |
| album_rating_computed INTEGER, | |
| album_rating VARCHAR(50), | |
| album VARCHAR(50), | |
| all_items VARCHAR(50), |
| #!/usr/bin/env ruby | |
| # coding: utf-8 | |
| # QBのセリフで書けるプログラム言語を考えてみている。 | |
| # まだ案のレベルなので、細かい仕様(文法の扱いとか)は詰められていません。 | |
| =begin | |
| 基本的な仕様: | |
| * グローバルにアクセス可能なスタックが1つ存在し、 | |
| それを用いて必要な変数を格納する。(PostScriptとかと同様) |
| // ==UserScript== | |
| // @name Show Kanji Image | |
| // @namespace http://gyz.heroku.com/ | |
| // @include http://twitter.com/* | |
| // @include https://twitter.com/* | |
| // @version 1.0.2 | |
| // ==/UserScript== | |
| var $ = function(selectors, context) { | |
| return Array.prototype.slice.call((context || document).querySelectorAll(selectors), 0); |
| " You need https://github.com/tyru/open-browser.vim to open browser. | |
| function! OpenTrac() "{{{ | |
| let s:id = expand('<cword>') | |
| if s:id =~ '^[0-9]\+$' | |
| call openbrowser#open("http://trac.example.com/trac/ticket/" . s:id) | |
| endif | |
| endfunction "}}} | |
| command! OpenTrac call OpenTrac() |
| # Backbone.js の依存が気に食わなくて書きなおした版 | |
| # clientのcoffeekup に依存 | |
| class Model | |
| class View | |
| render: -> | |
| $(@selecter).html CoffeeKup.render @template ,@ | |
| class Todo extends Model | |
| constructor:(@name)-> |
太陽が 昨日より 眩しく照りつけ始めたら 真っ白な Tシャツに 今すぐ着替えて 君を誘いたい 海沿いの 国道を まだまだ
| pastak 0 | |
| moccai 21 | |
| bimalki 28 | |
| mactkg 85 | |
| Glass_saga 157 | |
| chihirow 241 | |
| rounin 258 | |
| flans 561 | |
| sora_h 2573 |