Skip to content

Instantly share code, notes, and snippets.

William Stuart Lazar billsaysthis

Block or report user

Report or block billsaysthis

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:8dd92315ef49f406845fc55708696f8a
### Keybase proof
I hereby claim:
* I am billsaysthis on github.
* I am billsaysthis (https://keybase.io/billsaysthis) on keybase.
* I have a public key ASDmnFF0xXoqPghmRVJms6VnKGZclXaaEAkaAhTTTKQ1WAo
To claim this, I am signing this object:
View designer.html
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-pages/core-pages.html">
<link rel="import" href="../core-icons/core-icons.html">
<link rel="import" href="../paper-icon-button/paper-icon-button.html">
<polymer-element name="my-element">
<template>
@billsaysthis
billsaysthis / grunt-watch-reference.sh
Created May 31, 2013
Problem with running grunt watch
View grunt-watch-reference.sh
$ grunt watch
>> Local Npm module "grunt-contrib-watch" not found. Is it installed?
>> Local Npm module "grunt-contrib-compass" not found. Is it installed?
Warning: Task "watch" not found. Use --force to continue.
/*global module:false*/
module.exports = function(grunt) {
// Project configuration.
@billsaysthis
billsaysthis / tonotdo-simple.zsh-theme
Created Mar 14, 2013
Variation of Toon's (https://github.com/To1ne) Oh-My-Zsh tonotdo theme, features a simpler prompt.
View tonotdo-simple.zsh-theme
PROMPT='%{$fg_no_bold[green]%}%3~$(git_prompt_info)%{$reset_color%}» '
RPROMPT='[%*]'
# git theming
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg_bold[blue]%}("
ZSH_THEME_GIT_PROMPT_SUFFIX=""
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg_bold[blue]%})"
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg_bold[magenta]%}✗%{$fg_bold[blue]%})"
# LS colors, made with http://geoff.greer.fm/lscolors/
@billsaysthis
billsaysthis / tw2wp-generic.rb
Created Sep 28, 2012
OSX terminal script to post tweets to a WordPress blog
View tw2wp-generic.rb
#!/usr/bin/ruby
require 'rubygems'
# https://github.com/nu7hatch/gmail
require 'gmail'
# https://github.com/sferik/twitter
require 'twitter'
def mail_tweet(gmail, tid, subj)
if !gmail.logged_in?
@billsaysthis
billsaysthis / gist:2346669
Created Apr 9, 2012
Backbone with TB2 modal sample View class
View gist:2346669
ZPCommon.Views.SocialSharesView = Backbone.View.extend({
template: 'public/common/socialShares_hb',
id: 'socialShares',
className: 'buttonBox',
initialize: function() {
_.bindAll(this, 'emailShare');
},
events: {
'click #emailShareBtn': 'emailShare'
},
@billsaysthis
billsaysthis / gist:2254144
Created Mar 30, 2012
LayoutManager jQuery plugin question code sample
View gist:2254144
Public.Views.StarQuestionView = Backbone.View.extend({
template: 'public/common/questions/starQuestion_hb',
className: 'questionContainer'
});
Public.Form = Backbone.View.extend({
...
questionView: function(question, questionNumber) {
@billsaysthis
billsaysthis / event.rb
Created Jan 16, 2012
Odd issue with rails_admin configuration
View event.rb
class Event < ActiveRecord::Base
has_many :presentations
has_many :speakers, :through => :presentations
EVT_ACTIVE_STATUSES = %w(on_sale at_door)
EVT_INACTIVE_STATUSES = %w(sold_out past)
...
def status_enum
View app.js
var auth_middleware = function() {
return function(req, res, next) {
var urlp= url.parse(req.url, true)
if( urlp.query.login_with ) {
req.authenticate([urlp.query.login_with], function(error, authenticated) {
if( error ) {
// Something has gone awry, behave as you wish.
console.log( error );
res.end();
} else {
View SmartMonth-stack-trace
Pow can’t start your application.
/Users/billlazar/Sites/SmallCommunities raised an exception during boot.
SyntaxError: /Users/billlazar/.rvm/gems/ruby-1.9.2-p136@ruby-1.9.2-head/gems/smart_month-1.0.0/lib/smart_month/rulesets.rb:124: syntax error, unexpected ':', expecting keyword_then or ',' or ';' or '\n'
when :date: qry = "Date.new(#{data[:year...
^
/Users/billlazar/.rvm/gems/ruby-1.9.2-p136@ruby-1.9.2-head/gems/smart_month-1.0.0/lib/smart_month/rulesets.rb:125: syntax error, unexpected keyword_when, expecting keyword_end
when :freq: qry = 'true'
^
/Users/billlazar/.rvm/gems/ruby-1.9.2-p136@ruby-1.9.2-head/gems/smart_month-1.0.0/lib/smart_month/rulesets.rb:151: syntax error, unexpected keyword_end, expecting $end
/Users/billlazar/.rvm/gems/ruby-1.9.2-p136@ruby-1.9.2-head/gems/activesupport-3.0.7/lib/active_support/dependencies.rb:239:in `require'
You can’t perform that action at this time.