This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require File.dirname(__FILE__) + '/../spec_helper' | |
| describe 'a band\'s preferences' do | |
| fixtures :groups, :users, :emails | |
| before(:each) do | |
| @band = groups(:pfunk) | |
| @band.should be_is_a Band # pref definition is in band | |
| @band.class.base_class.should == Group # base class is group |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'rubygems' | |
| require 'metaid' | |
| o= Object.new | |
| module Mixd | |
| def sommeth | |
| puts 'k' | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;(function ($) { | |
| $.fn.deletes = function () { | |
| this.click(function () { | |
| $.ajax({ | |
| success: function () { | |
| this | |
| .parents('.deletable:first').remove(); | |
| }.bind(this) | |
| }) | |
| }).bind(this); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| User < ActiveRecord::Record # thats right | |
| has_many :comments | |
| has_many :bands | |
| def active_comments | |
| comments.find :all do |c| | |
| c.is_active == true | |
| end | |
| end | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| # super hacky git-export command | |
| case ARGV.length | |
| when 0 | |
| puts 'usage:' | |
| puts "git-export [target] : defaults repository to CWD" | |
| puts "git-export [repository] [target]" | |
| exit 1 | |
| when 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Dir.glob('./**/*.erb').each do |dir| | |
| new_dir = dir.sub( File.basename(dir), File.basename(dir).sub(/.erb$/, '.haml')) | |
| `html2haml #{dir} #{new_dir}` | |
| `rm #{dir}` | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CFLAGS="-arch x86_64 -I/usr/local/php5/include/" LDFLAGS="-L/usr/local/php5/include/" './configure' '--disable-dependency-tracking' '--prefix=/usr/local/php5.3' '--with-apxs2=/usr/sbin/apxs' '--with-config-file-scan-dir=/usr/local/php5.3/php.d' '--with-openssl=/usr' '--with-zlib=/usr' '--with-zlib-dir=/usr' '--with-ldap' '--with-xmlrpc' '--enable-exif' '--enable-soap' '--enable-sqlite-utf8' '--enable-wddx' '--enable-ftp' '--enable-sockets' '--with-bz2=/usr' '--enable-zip' '--enable-pcntl' '--enable-shmop' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-memory-limit' '--enable-mbstring' '--enable-bcmath' '--with-libxml-dir=/usr/local/php5' '--with-xsl=/usr/local/php5' '--with-curl=shared,/usr/local/php5' '--with-png-dir=/usr/local/php5' '--with-freetype-dir=/usr/local/php5' '--with-mysql=shared,/usr/local/php5' '--with-mysqli=shared,/usr/local/php5/bin/mysql_config' '--with-pdo-mysql=shared,/usr/local/php5' '--with-pgsql=shared,/usr/local/php5' '--with-pdo-pgsql=shared,/usr/local/php5' '--wi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -enum { | |
| - XT_CONNMARK_SET = 0, | |
| - XT_CONNMARK_SAVE, | |
| - XT_CONNMARK_RESTORE | |
| +struct xt_connmark_info { | |
| + unsigned long mark, mask; | |
| + u_int8_t invert; | |
| }; | |
| -struct xt_connmark_target_info { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module Drupal | |
| RepositoryName = :drupal | |
| Repository = repository(Drupal::RepositoryName) | |
| def self.common | |
| " | |
| include DataMapper::Resource | |
| def self.default_repository_name | |
| Drupal::RepositoryName |