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 | |
| # This script converts xccolorthemes to dtvcolorthemes for porting xcode 3.x themes to xcode 4.x | |
| # created by ashley towns <ashleyis@me.com> | |
| # Public domain. | |
| # ./dvtcolorconvert <inputfile> | |
| # spits out a .dtvcolortheme file | |
| require 'rubygems' | |
| require 'plist' | |
| raise "Error: need a source file #{__FILE__} [file.xccolortheme]" if ARGV.length == 0 |
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 'haml' | |
| require 'yaml' | |
| task :default => :env do | |
| Dir["#{@site_source}/_layouts/*.haml"].each do |file| | |
| basename = File.basename(file, '.haml') | |
| engine = Haml::Engine.new(File.read(file), :format => :html5) | |
| File.open(File.join(@site_source, '_layouts', "#{basename}.html"), 'w') do |f| | |
| f.write engine.render | |
| 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 -wKU | |
| # Adapted from Brett Terpstra’s original “Markdown to Evernote” service (http://brettterpstra.com/a-better-os-x-system-service-for-evernote-notes-with-multimarkdown/) | |
| # Martin Kopischke 2011 – License: Creative Commons Attribution Share-Alike (CC BY-SA) 3.0 Unported (http://creativecommons.org/licenses/by-sa/3.0/) | |
| # Changes: – create only one Evernote note per (Multi)Markdown input passed (instead of one per line) | |
| # – do not choke on shell escape characters (use Tempfile instead of shell pipe for osascript) | |
| # – default to MultiMarkdown 3 executable (instead of MMD 2 Perl script) | |
| # – make smart typography processing optional (set SMARTY to 'false' to bypass processing; | |
| # note smart typography cannot be disabled in MMD 3.0 and 3.0.1 | |
| # – handle both smart typography processing scripts (ie. SmartyPants.pl) |
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/sh | |
| # install into /etc/ppp/ip-down | |
| # chmod a+x /etc/ppp/ip-down | |
| source /etc/ppp/ip.config | |
| case "${IPREMOTE}" in | |
| ${MY_IPREMOTE}) | |
| /sbin/route delete ${MY_ROUTE} -interface ${IFNAME} |
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
| Remove ._*- and .AppleDouble-files from folders. | |
| Adapted from Torkel's comment on http://hints.macworld.com/article.php?story=20021118060850652 | |
| Cred to hiber for suggesting adding -print0/-0 to solve whitespace issue. | |
| See all ._*-files: | |
| find . -name '._*' | more | |
| Remove all ._*-files: | |
| find . -name '._*' -print0 | xargs -0 rm |
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
| load 'deploy' if respond_to?(:namespace) | |
| require 'rubygems' | |
| require 'capistrano' | |
| require 'railsless-deploy' | |
| load 'config/deploy' | |
| load 'config/cap_colors' # Optional; uses the capistrano_colors gem to customize output colorization |
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 sh | |
| ## | |
| # This is script with usefull tips taken from: | |
| # https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
| # | |
| # install it: | |
| # curl -sL https://raw.github.com/gist/2108403/hack.sh | sh | |
| # |
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 PuppetMaster | |
| def self.puppetmaster_cmd | |
| 'puppet master --debug --verbose' | |
| end | |
| def self.start | |
| puts "Starting Puppet Master in Debug+Verbose+Daemon mode logging to /var/log/puppet/a.log" | |
| puts "Started." if system("#{puppetmaster_cmd} >> /var/log/puppet/a.log") |
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 'google_drive' | |
| # set your username and password | |
| login = GoogleDrive.login(GoogleDrive::USERNAME, GoogleDrive::PASSWORD) | |
| # set your spreadsheet key | |
| sheet = login.spreadsheet_by_key(GoogleDrive::SPREADSHEET) | |
| sheet.worksheets.each do |ws| | |
| p ws.title |