Skip to content

Instantly share code, notes, and snippets.

Accounting.InvoiceEntryItemView = SC.View.extend(SC.Control,{
classNames:"invoice-entry-item",
acceptsFirstResponder:YES,
alternateClass:function() {
return this.get('contentIndex') % 2 === 0 ? "even" : "odd";
}.property('contentIndex'),
_accountChanged:function() {
this.displayDidChange();
}.observes('*content.account.number'),
Feb 1 23:34:15 vm1 kernel: device-mapper: multipath: Failing path 8:64.
Feb 1 23:34:15 vm1 multipathd: sde: readsector0 checker reports path is down
Feb 1 23:34:15 vm1 multipathd: checker failed path 8:64 in map 3600a0b800075bd86000002904d46ce98
Feb 1 23:34:15 vm1 multipathd: Path event for 3600a0b800075bd86000002904d46ce98, calling mpathcount
Feb 1 23:34:15 vm1 multipathd: 3600a0b800075bd86000002904d46ce98: remaining active paths: 1
Feb 1 23:34:20 vm1 multipathd: sde: readsector0 checker reports path is up
Feb 1 23:34:20 vm1 multipathd: 8:64: reinstated
Feb 1 23:34:20 vm1 multipathd: 3600a0b800075bd86000002904d46ce98: remaining active paths: 2
Feb 1 23:34:20 vm1 multipathd: Path event for 3600a0b800075bd86000002904d46ce98, calling mpathcount
@kuon
kuon / gist:838826
Created February 22, 2011 15:23
slickgrid with sproutcore
SGUI.TableView = SC.CollectionView.extend({
columns:[],
options:{},
reloadIfNeeded:function() {
var options = this.get('options');
var content = this.get('content');
var columns = this.get('columns');
function getItem(index) {
render:function(ctx, first) {
if(first) {
ctx.push('<label class="block">', "_clients.sidebar.label.name".loc(), '</label>',
'<input class="block" name="name" type="text">',
'<label class="block">', "_clients.sidebar.label.contentMgr".loc(), '</label>',
'<label class="block secondary">',
'<input type="radio" value="0" name="contentMgrType">',
"_clients.sidebar.label.screenGate".loc(),
'</label>',
'<label class="block secondary">',
fetch: function(S, query) {
var Q = SGIO.QUERIES;
console.log('fetch');
S.dataSourceDidFetchQuery(query); // We fetch all queries immediately, then we will push the new data
console.log(query);
if(query === Q.ALL_CLIENT) {
SC.Request.getUrl('/clients.json').json()
.notify(this, '_didFetchRecords', S, SGIO.Client)
`--> php bin/print_tags.inc /ampache/main/Yann\ Tiersen/Le\ Fabuleux\ Destin\ d\'Ame?^?lie\ Poulain\ \(bande\ originale\ de\ film\)/01\ J\'y\ suis\ jamais\ alle?^?.m4a Reading: /ampache/main/Yann Tiersen/Le Fabuleux Destin d'Amélie Poulain (bande originale de film)/01 J'y suis jamais allé.m4a
Using: AND for file pattern matching
Results Seen by GetID3()
vainfo Object
(
[encoding] => UTF-8
[encoding_id3v1] => ISO-8859-1
[encoding_id3v2] => ISO-8859-1
[filename] => /ampache/main/Yann Tiersen/Le Fabuleux Destin d'Amélie Poulain (bande originale de film)/01 J'y suis jamais allé.m4a
[type] => mp4
@kuon
kuon / gist:946123
Created April 28, 2011 10:12
json variants
class Ambience < ActiveRecord::Base
attr_accessible :name
short_serialize_options :only => [:id, :name]
long_serialize_options :except => :deleted
def serializable_hash(options = nil)
options ||= {}
def find_readable(*args)
type = args[0].to_s.capitalize
args.shift
cond = priv_conditions(type, :read => true)
type.constantize.find(*args).where(*cond)
end
private
def priv_conditions(type, rw)
Started GET "/auth/reset_password" for 127.0.0.1 at 2011-05-09 10:58:14 +0200
Processing by AuthController#reset_password_form as HTML
Rendered auth/reset_password_form.haml within layouts/application (6.9ms)
Completed 200 OK in 11ms (Views: 10.5ms | ActiveRecord: 0.0ms)
/Users/kuon/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/net/smtp.rb:589: [BUG] Segmentation fault
ruby 1.9.2p180 (2011-02-18 revision 30909) [x86_64-darwin10.6.0]
-- control frame ----------
c:0081 p:---- s:0431 b:0431 l:000430 d:000430 CFUNC :connect
set :domain, "goyman.com"
set :application, "goyman.com"
set :deploy_to, "/web/sites/#{domain}"
set :user, "web"
set :use_sudo, false
set :scm, :git
set :repository, "git@github.com:goyman/Goyman.com.git"
set :branch, 'master'