Skip to content

Instantly share code, notes, and snippets.

View KushalP's full-sized avatar

Kushal Pisavadia KushalP

View GitHub Profile
@KushalP
KushalP / cloud_policy_proto_compile.target.mk.diff
Created January 26, 2012 12:01
Diff of cloud_policy_proto_compile
5,22c5,174
< ### Rules for action "compile_generated_proto":
< quiet_cmd_cloud_policy_proto_compile_compile_generated_proto = ACTION Compiling generated cloud policy protobuf $@
< cmd_cloud_policy_proto_compile_compile_generated_proto = LD_LIBRARY_PATH=$(builddir)/lib.host:$(builddir)/lib.target:$$LD_LIBRARY_PATH; export LD_LIBRARY_PATH; cd chrome/app/policy; mkdir -p $(builddir)/pyproto/device_management_pb $(obj)/gen/protoc_out/chrome/browser/policy/proto; "$(builddir)/protoc" "--proto_path=$(obj)/gen/policy/policy" "$(obj)/gen/policy/policy/cloud_policy.proto" "--cpp_out=$(obj)/gen/protoc_out/chrome/browser/policy/proto" "--python_out=$(builddir)/pyproto/device_management_pb"
<
< $(builddir)/pyproto/device_management_pb/cloud_policy_pb2.py: obj := $(abs_obj)
< $(builddir)/pyproto/device_management_pb/cloud_policy_pb2.py: builddir := $(abs_builddir)
< $(builddir)/pyproto/device_management_pb/cloud_policy_pb2.py: export SRCROOT := ${abs_srcdir}/chrome/app/policy
< $(builddir)/pyproto/device_management_pb/cl
@KushalP
KushalP / failed.diff
Created February 22, 2012 23:50
The build that failed!
diff --git a/third_party/cacheinvalidation/cacheinvalidation.gyp b/third_party/cacheinvalidation/cacheinvalidation.gyp
index 819b9cc..061c4cc 100644
--- a/third_party/cacheinvalidation/cacheinvalidation.gyp
+++ b/third_party/cacheinvalidation/cacheinvalidation.gyp
@@ -117,9 +117,6 @@
'../../base/base.gyp:base',
'cacheinvalidation_proto',
],
- # This target exports a hard dependency because its include files
- # include generated header files from cache_invalidation_proto_cpp.
@KushalP
KushalP / cacheinvalidation.target.mk
Created February 23, 2012 00:47
cacheinvalidation.target.mk without 'hard_dependency': 1
# This file is generated by gyp; do not edit.
TOOLSET := target
TARGET := cacheinvalidation
DEFS_Debug := '-DCHROMIUM_BUILD' \
'-DENABLE_REMOTING=1' \
'-DENABLE_WEBRTC=1' \
'-DENABLE_P2P_APIS=1' \
'-DENABLE_CONFIGURATION_POLICY' \
'-DENABLE_INPUT_SPEECH' \
diff --git a/lib/bootstrapper.rb b/lib/bootstrapper.rb
index f54bd1a..e5ff73f 100644
--- a/lib/bootstrapper.rb
+++ b/lib/bootstrapper.rb
@@ -57,9 +57,9 @@ module Skewer
end
def go
- add_ssh_hostkey
+ add_ssh_hostkey if not @options[:rackspace]
@KushalP
KushalP / play.rb
Created February 29, 2012 15:05
This breaks in rcov when running: `rcov play.rb play_spec.rb`
module Play
class Dummy
attr :count
def initialize
@count = 0
end
def gaga
@count += 1
Testing ring.middleware.test.cookies
ERROR in (wrap-cookies-accepts-expires) (cookies.clj:103)
Uncaught exception, not in assertion.
expected: nil
actual: java.lang.AssertionError: Assert failed: (every? valid-attr? attrs)
at ring.middleware.cookies$write_attr_map.invoke (cookies.clj:103)
ring.middleware.cookies$write_cookies$iter__665__669$fn__670.invoke (cookies.clj:122)
clojure.lang.LazySeq.sval (LazySeq.java:42)
clojure.lang.LazySeq.seq (LazySeq.java:56)
@KushalP
KushalP / gyp_chromium_output.py
Created March 22, 2012 19:19
What happens when you print 'descendants' before "def EnsureNoIDCollisions(self)" does its thing
This file has been truncated, but you can view the full file.
[<XCProjectFile at 0x1087f9390>,
<PBXProject 'chrome' at 0x1087f9190>,
<PBXGroup None at 0x1087f91d0>,
<PBXGroup 'Source' at 0x1088afdd0>,
<PBXGroup '..' at 0x1088afd10>,
<PBXGroup 'base' at 0x108e39a90>,
<PBXGroup 'files' at 0x10964d610>,
<PBXFileReference 'file_path_watcher_browsertest.cc' at 0x10964d810>,
<PBXGroup 'test' at 0x108e43190>,
<PBXFileReference 'run_all_unittests.cc' at 0x108e43110>,
@KushalP
KushalP / output.sh
Created June 17, 2012 22:22
Attempt at implementing Python decorators in Ruby
$ ruby squarer.rb
about to call square(5)
25
about to call cube(5)
125
/**
* The Nomensa accessible media player is a flexible multimedia solution for websites and intranets.
* The core player consists of JavaScript wrapper responsible for generating an accessible HTML toolbar
* for interacting with a media player of your choice. We currently provide support for YouTube (default),
* Vimeo and JWPlayer although it should be possible to integrate the player with almost any media player on
* the web (provided a JavaScript api for the player in question is available).
*
* Copyright (C) 2012 Nomensa Ltd
*
* This program is free software: you can redistribute it and/or modify
@KushalP
KushalP / books.txt
Created December 17, 2012 23:45
Tonight (17/12/2012) I asked on Twitter what books people have enjoyed this year. Not all of the posters provided authors, but this should suffice. The list is provided in alphabetical order rather than in reply order.
Anansi Boys
Angelmaker by @Harkaway
Baroque Cycle, The
Basement, The
Being Geek
Building Stories
Cryptonomicon
Death by Black Hole: And Other Cosmic Quandaries
Edible Selby, by Todd Selby
Emperor of All Maladies, The