This is the reference point. All the other options are based off this.
|-- app
| |-- controllers
| | |-- admin
=Navigating= | |
visit('/projects') | |
visit(post_comments_path(post)) | |
=Clicking links and buttons= | |
click_link('id-of-link') | |
click_link('Link Text') | |
click_button('Save') | |
click('Link Text') # Click either a link or a button | |
click('Button Value') |
pt-BR: | |
flash: | |
actions: | |
create: | |
notice: "%{resource_name} criado com sucesso." | |
alert: "* Preencha todos os campos corretamente." | |
update: | |
notice: "%{resource_name} foi atualizado com sucesso." | |
destroy: | |
notice: "%{resource_name} foi removido com sucesso." |
# See http://unicorn.bogomips.org/Unicorn/Configurator.html for complete | |
# documentation. | |
worker_processes 2 | |
# Help ensure your application will always spawn in the symlinked | |
# "current" directory that Capistrano sets up. | |
working_directory "/home/deployer/myapp.com/current" | |
# listen on both a Unix domain socket and a TCP port, | |
# we use a shorter backlog for quicker failover when busy | |
listen "/tmp/myapp.com.sock", :backlog => 64 | |
listen 8080, :tcp_nopush => true |
namespace :ubuntu do | |
desc "Setup Environment" | |
task :setup_env, :roles => :app do | |
update_apt_get | |
install_dev_tools | |
install_git | |
install_subversion | |
install_sqlite3 | |
# Install and setup RVM instead of old Rails stack | |
#install_rails_stack |
// http://jsfiddle.net/hiddenloop/TPeJt/ | |
var array = [2, 3, 4, 6, 2, 5, 7, 2, 4, 5, 99]; | |
var within_std_of = 3; | |
outputResult = function(str) { | |
var content = $('#results').html(); | |
$('#results').html(content + str); | |
} |
#!/usr/bin/ruby1.9.1 -Kw | |
# -*- coding: utf-8 -*- | |
class Edge | |
attr_accessor :src, :dst, :length | |
def initialize(src, dst, length = 1) | |
@src = src | |
@dst = dst | |
@length = length |
When building a new instance of Amazon EC2 choose quick-start-1 as the security group not default | |
#LOCALLY | |
$ capify . | |
$ chmod +x config/unicorn_init.sh | |
$ git add . | |
$ git commit -m "deployment configs" | |
If rebuilding an instance don't forget to remove the ssh keys |
This gist contains the nginx and tor configurations for the [mike.tig.as][mta] servers, mainly to show:
chris-lea/nginx-devel
PPA to allow use of SPDY.ssl_ciphers
selection to mitigate BEAST attack, enable
[perfect forward secrecy][pfs] if possible and select the strongest
possible ciphers within those bounds. (Exception is made for several
ciphers at the end of list, for compatibility reasons.)