This file contains 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
<style> | |
a.negrito { font-weight: bold; } | |
input.fundo_verde { background-color: #8CDFAD} | |
</style> | |
<script> | |
$(document).ready(function(){ | |
$("input").focus(function(){ | |
$(this).addClass("fundo_verde"); | |
}); |
This file contains 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
<!-- with gem "jquery-rails" --> | |
<%= javascript_include_tag :defaults %> | |
<script>jQuery.noConflict();</script> | |
<%= javascript_include_tag 'prototype' %> |
This file contains 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
# ~/.nanorc | |
set const | |
set tabsize 2 |
This file contains 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 | |
# | |
# Copy of /etc/init.d/nginx for Fedora/RedHat/CentOS | |
# | |
# CAUTION: modified for use nginx="/opt/nginx/sbin/nginx" and NGINX_CONF_FILE="/opt/nginx/conf/nginx.conf" | |
# | |
# nginx - this script starts and stops the nginx daemon | |
# | |
# chkconfig: - 85 15 | |
# description: Nginx is an HTTP(S) server, HTTP(S) reverse \ |
This file contains 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
# Download and add repository key | |
wget http://apt.brightbox.net/release.asc -O - | sudo apt-key add - | |
# Add this line on /etc/apt/source.list | |
deb http://apt.brightbox.net hardy main | |
sudo apt-get update | |
sudo apt-get install nginx-brightbox |
This file contains 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 | |
### BEGIN INIT INFO | |
# Provides: nginx | |
# Required-Start: $all | |
# Required-Stop: $all | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: starts the nginx web server | |
# Description: starts nginx using start-stop-daemon |
This file contains 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
Dir["app/models/*.rb"].each do |file| | |
model = file.gsub("app/models/", "").gsub(".rb", "") | |
"#{model.camelize}".constantize.unscoped.delete_all rescue nil | |
end |
This file contains 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
# Add on /usr/share/applications | |
[Desktop Entry] | |
Name=Tilda | |
Exec=tilda | |
Icon=tilda.png | |
Terminal=false | |
Type=Application | |
Categories=GTK;Utility;TerminalEmulator |
This file contains 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
Show hidden characters
{ | |
"color_scheme": "Packages/Color Scheme - Default/Mac Classic.tmTheme", | |
"font_size": 12, | |
"tab_size": 2, | |
"translate_tabs_to_spaces": true, | |
"word_wrap": "true", | |
"wrap_width": 80 | |
} |
This file contains 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
class Class: | |
def __init__(self): | |
self.attribute = "value" | |
instance = Class() | |
print(instance.attribute) # "value" | |
del instance.attribute | |
print(instance.attribute) # ops, AttributeError | |
del Class | |
new_instance = Class() # ops, NameError |
OlderNewer