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
| namespace ConsoleApp1 | |
| { | |
| using System; | |
| using System.Collections.Concurrent; | |
| using System.Diagnostics; | |
| using System.Linq; | |
| using System.Threading; | |
| using System.Threading.Tasks; | |
| public class Program |
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
| # run in elevated mode | |
| Set-ExecutionPolicy Unrestricted -Force | |
| # Install first http://boxstarter.org/ | |
| . { Invoke-WebRequest -useb http://boxstarter.org/bootstrapper.ps1 } | Invoke-Expression; get-boxstarter -Force | |
| # temporary disable UAC | |
| Disable-UAC | |
| # Windows Settings |
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 'buildr' | |
| repositories.remote << 'http://repo2.maven.org/maven2/' | |
| repositories.remote << 'https://repository.jboss.org/nexus/content/repositories/releases/' | |
| define 'helloworld' do | |
| project.group = 'example' | |
| project.version = '1.0-SNAPSHOT' | |
| compile.with "org.jboss.netty:netty:jar:3.2.7.Final" |
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
| # sort by price after sort by date if active projects listed | |
| collection.sort_by_date_asc.chain(|c| c.active.sort_by_price_asc if params[:active]).sort_by_customer_name_desc |
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
| # Rails 2.3.5 - 2.3.11 environment settings (config/environment.rb) | |
| config.gem 'airbrake', :version => '2.4.11', :require => "hoptoad_notifier" | |
| # Rails 3 - bundler Gemfile(config/Gemfile) | |
| gem 'airbrake', '2.4.11', require => "hoptoad_notifier" | |
| # In Hoptoad initializer (config/hoptoad.rb) | |
| HoptoadNotifier.configure do |config| | |
| config.api_key = '<api key>' | |
| config.host = 'airbrakeapp.com' |
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
| http { | |
| sendfile on; | |
| } |
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
| connection = ActiveRecord::Base.connection | |
| query = "COPY ( SELECT '#{header}' UNION ALL #{sql_query}) TO 'file.csv' WITH DELIMITER AS ',' CSV" | |
| connection.execute query |