Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

namespace :gem
task :spec => :version do
file = File.new(__DIR__ + "fold.gemspec", 'w+')
spec = %{
Gem::Specification.new do |s|
s.name = "fold"
s.version = "#{@version}"
s.platform = Gem::Platform::RUBY
s.has_rdoc = false
s.summary = "Toolkit for creating whitespace active mini-languages. Inspired by Haml. Feature light."
form.ajaxForm().ajaxSubmit({
// target: "#divToUpdate",
url: that._options.uploadUrl,
// dataType: "json",
method: "POST",
iframe: true,
success: function(response) {
that.insertImage(response,
form.find(that._options.titleSelector).val(),
form.find(that._options.altSelector).val());
$.password
:blur
if @value === ""
.hide()
var faux = $this.prev()
faux.show().val(faux.attr('default_value'))
.blur()
$.faux-password
Strangly, this breaks with Mongrel when uploading a matching "*.mp3" (possibly others)
@collin
collin / gist:3363
Created July 31, 2008 00:24 — forked from nex3/gist:3262
$.password
:blur
if @value === ""
.hide()
// Eventually, indenting beneath something will set it as the context
.prev()
.show().val(@default_value)
.blur()
require 'rubygems'
require 'pathname'
__DIR__ = Pathname.new(__FILE__).dirname.expand_path
eval (__DIR__+".irbrc").read if (__DIR__+".irbrc").exist?
module Johnson
module Nodes
attr_accessor :value
class FallThrough < Node
def initialize(_row, _column, value)
@value = value
end
end
end
/No, now I <3 Ruby
!!!
%html
%head
%link{:rel => :stylesheet, :type => "text/css", :href => "#{params[:name]}.css"}
%body
=yield
/I would not have done this with HTML
/hooray, haml enables awesome protoyping!
.compositions
%ul
%li
Resources
%ol
%li
.resources
%ol
%p Hello new user!
- 10.times do |n|
- unless n.odd?
== Why it's the number #{n}