Skip to content

Instantly share code, notes, and snippets.

View yaymukund's full-sized avatar
🍅
tomato tomato

mukund yaymukund

🍅
tomato tomato
View GitHub Profile
@yaymukund
yaymukund / pylibmcmodule.c.patch
Created November 18, 2011 21:15
Patch for installing pylibmc
--- _pylibmcmodule.c.old»···2011-11-18 13:10:03.000000000 -0800
+++ _pylibmcmodule.c»···2011-11-18 02:51:05.000000000 -0800
@@ -45,6 +45,26 @@
#define PyModule_ADD_REF(mod, nam, obj) \
{ Py_INCREF(obj); \
PyModule_AddObject(mod, nam, obj); }
+size_t
+strnlen(const char *s, size_t maxlen)
+{
+ const char * eospos;
@yaymukund
yaymukund / memcache_multi_support.patch
Created November 18, 2011 21:39
Another patch for memcache multi support
Index: twisted/protocols/memcache.py
===================================================================
--- twisted/protocols/memcache.py (revision 23235)
+++ twisted/protocols/memcache.py (working copy)
@@ -182,7 +182,10 @@
self._getBuffer = None
self._bufferLength = None
cmd = self._current[0]
- cmd.value = val
+ if cmd.command == "get_multi":
# `git touch` will touch all files you've modified since you
# branched, including uncommitted stuff. You can use this to
# trigger tests when Guard is watching.
[alias]
touch = !sh -c 'touch $(git diff $(git merge-base master HEAD) HEAD --name-only --format="format:")'
class Category < ActiveRecord::Base
has_many :subcategories, :dependent => :destroy
has_many :users, :through => :subcategories
end
/**
* @license AngularJS v1.1.5-5bc2836
* (c) 2010-2012 Google, Inc. http://angularjs.org
* License: MIT
*
* TODO(vojta): wrap whole file into closure during build
*/
/**
* @ngdoc overview
// Every style that will be repeated more than once should be written as a mixin
btn-states($btnColor) {
background-color: $btnColor;
&:hover {
background-color: darken($btnColor, 15%);
}
&:active {
class BillingController < ApplicationController
def index
@companies = Company.includes(:transactions).merge(Transaction.pending)
end
end
This file has been truncated, but you can view the full file.
// Fetched from channel: canary, with url http://builds.emberjs.com/canary/ember.js
// Fetched on: 2014-03-15T01:26:03Z
/*!
* @overview Ember - JavaScript Application Framework
* @copyright Copyright 2011-2014 Tilde Inc. and contributors
* Portions Copyright 2006-2011 Strobe Inc.
* Portions Copyright 2008-2011 Apple Inc. All rights reserved.
* @license Licensed under MIT license
* See https://raw.github.com/emberjs/ember.js/master/LICENSE
* @version 1.6.0-beta.1+canary.8d91bf06
// Fetched from channel: canary, with url http://builds.emberjs.com/canary/ember-data.js
// Fetched on: 2014-03-15T01:26:15Z
/*!
* @overview Ember Data
* @copyright Copyright 2011-2014 Tilde Inc. and contributors.
* Portions Copyright 2011 LivingSocial Inc.
* @license Licensed under MIT license (see license.js)
* @version 1.0.0-beta.7+canary.02d7c7be
*/
(function(global) {
/*!
handlebars v1.3.0
Copyright (C) 2011 by Yehuda Katz
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell