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
| # I get: | |
| # dpkg-deb: parse error, in file `root/DEBIAN/control' near line 7: | |
| # missing package name | |
| Source: ioncube-loader | |
| Section: hos | |
| Priority: extra | |
| Maintainer: Sheldon Hearn <[email protected]> | |
| Build-Depends: debhelper (>= 5) | |
| Standards-Version: 3.7.2 |
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
| Index: app/models/hos_server.rb | |
| =================================================================== | |
| --- app/models/hos_server.rb (revision 554) | |
| +++ app/models/hos_server.rb (working copy) | |
| @@ -8,6 +8,8 @@ | |
| # to be able to use the rails reserved word 'type' as a column name. | |
| self.inheritance_column = nil | |
| + alias_attribute :status, "Status" | |
| + |
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
| ---- ~/bin/re | |
| #!/bin/sh | |
| exec vim -X -u ${HOME}/.vimrc-ruby $* | |
| ---- ~/.vimrc-ruby | |
| :syntax enable | |
| :filetype indent on | |
| :set backspace=indent,eol,start | |
| :set modeline | |
| :set ts=2 sw=2 expandtab ai |
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 'facter' | |
| def hos_server(host, attr) | |
| value = nil | |
| server_block = nil | |
| File.open("/etc/hos_server").each do |line| | |
| line.chomp! | |
| if line =~ /^server:\s+(\S+)\s+\{\s*$/ | |
| if host == $1 | |
| server_block = host |
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
| moo |
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
| 93 lib/flow_base/util/pid_file.rb | |
| 114 lib/flow_base/util/file_worker.rb | |
| 56 lib/flow_base/aggregator.rb | |
| 1 lib/flow_base/model.rb | |
| 47 lib/flow_base/command/config.rb | |
| 50 lib/flow_base/command/aggregator.rb | |
| 46 lib/flow_base/command/database_exporter.rb | |
| 3 lib/flow_base/command.rb | |
| 15 lib/flow_base/flow.rb | |
| 2 lib/flow_base/util.rb |
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 | |
| module Loud | |
| module ClassMethods | |
| def shout(message) | |
| loud = if message =~ /!$/ | |
| message.upcase | |
| else | |
| message.upcase + '!' | |
| 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
| require File.join(File.dirname(__FILE__), '..', '..', 'test_helper') | |
| require 'unix_like/spool/file' | |
| require 'time' | |
| class FileTest < Test::Unit::TestCase | |
| def setup | |
| prepare_vroot | |
| @spool = stub('spool_directory', :path => VROOT) |
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
| Aggregate.transaction do | |
| write_count = 0 | |
| HourlyAggregate.connection.create_savepoint | |
| Aggregate.find(...).each do |aggregate| | |
| ... | |
| write_count += 1 # Only if you actually write | |
| if write_count % 1000 == 0 | |
| HourlyAggregate.connection.release_savepoint | |
| HourlyAggregate.connection.create_savepoint | |
| 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 | |
| default_classes = %w( | |
| sudo | |
| fastcgi | |
| ) | |
| node_types = { | |
| :webmail => { | |
| :hosts => %w( |