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_env = ENV['RAILS_ENV'] || "production" | |
rails_root = ENV['RAILS_ROOT'] || "/var/www/discourse" | |
user = ENV["DISCOURSE_USER"] || ENV['USER'] || 'user_running_app' | |
group = ENV["DISCOURSE_GROUP"] || ENV['GROUP'] || 'www-data' | |
num_webs = ENV["NUM_WEBS"].to_i > 0 ? ENV["NUM_WEBS"].to_i : 4 | |
# to debug use | |
#Bluepill.application("your_app", :foreground => true) do |app| | |
Bluepill.application("discourse") do |app| |
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 | |
# Author: Carl Youngblood, 2010 | |
# Based on http://www.novell.com/coolsolutions/feature/15380.html | |
### BEGIN INIT INFO | |
# Provides: bluepill | |
# Required-Start: | |
# Required-Stop: | |
# Default-Start: 2 3 4 5 |
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
afsdfdsfsj lkjf safasdf | |
sdfklsjafsdf | |
safloremq |
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
CKEDITOR.lang.load('en', 'en', function() { | |
CKEDITOR.lang['en']['numberedlist'] = 'Numbers'; | |
CKEDITOR.lang['en']['bulletedlist'] = 'Bullets'; | |
CKEDITOR.replace('project_description', { | |
toolbar: [['Bold', 'Italic', '-', 'NumberedList', 'BulletedList']], | |
toolbarCanCollapse: false, | |
resize_enabled: false, | |
customConfig: '', | |
removePlugins: 'elementspath' | |
}); |
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
STDOUT.sync = true | |
require 'queue' | |
start_time = Time.now.to_i | |
msg = 0 | |
queue = Queue.new("testing") | |
queue.subscribe do |obj| | |
msg += 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
>> config.authentication.username | |
=> "[email protected]@" | |
>> config.authentication.password | |
=> "myhackproofpassword" |
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
# Author: Pieter Noordhuis | |
# Description: Simple demo to showcase Redis PubSub with EventMachine | |
# | |
# Requirements: | |
# - rubygems: eventmachine, thin, cramp, sinatra, yajl-ruby | |
# - a browser with WebSocket support | |
# | |
# Usage: | |
# ruby redis_pubsub_demo.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
# Rails | |
alias ss="script/server" | |
alias sc="script/console" | |
alias sq="sqlite3 db/development.sqlite3" | |
alias sqldev="sqlite3 db/development.sqlite3" | |
alias svn_add_all="svn st --ignore-externals | grep ^? | sed 's/\?/svn add/' | sh" | |
alias svn_del_all="svn st --ignore-externals | grep ^? | sed 's/\!/svn del/' | sh" | |
alias cdp="cd $HOME/workspace/proyectos" | |
alias remove_svn="find . -type d -name .svn | xargs rm -rf" | |
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
CREATE TABLE "aeropuertos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "descripcion" varchar(255) DEFAULT NULL NULL, "country_id" integer DEFAULT NULL NULL, "province_id" integer DEFAULT NULL NULL, "city_id" integer DEFAULT NULL NULL, "created_at" datetime DEFAULT NULL NULL, "updated_at" datetime DEFAULT NULL NULL); | |
CREATE TABLE "cities" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "description" varchar(255) DEFAULT NULL NULL, "province_id" integer DEFAULT NULL NULL, "created_at" datetime DEFAULT NULL NULL, "updated_at" datetime DEFAULT NULL NULL); | |
CREATE TABLE "countries" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "description" varchar(255) DEFAULT NULL NULL, "created_at" datetime DEFAULT NULL NULL, "updated_at" datetime DEFAULT NULL NULL); | |
CREATE TABLE "planes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "codigo" varchar(255) DEFAULT NULL NULL, "cant_tripulacion" integer DEFAULT NULL NULL, "cant_asientos_turista" integer DEFAULT NULL NULL, "cant_asientos_business" integer DEFA |
NewerOlder