Skip to content

Instantly share code, notes, and snippets.

View victorferraz's full-sized avatar

Victor victorferraz

View GitHub Profile

Configurando sequelize

const models = require('./models/'); const { User } = models;

npm install express sequelize pg pg-hstore

npm install -D sequelize

npz sequelize init

apt-get install -y ppa-purge
add-apt-repository -y ppa:ondrej/php5-oldstable
apt-get update
ppa-purge ppa:ondrej/php5
apt-get update && apt-get upgrade -y && apt-get autoremove -y && apt-get autoclean -y
apt-get install -y ppa-purge
add-apt-repository -y ppa:ondrej/php5-oldstable
apt-get update
ppa-purge ppa:ondrej/php5
apt-get update && apt-get upgrade -y && apt-get autoremove -y && apt-get autoclean -y
apt-get install -y ppa-purge
add-apt-repository -y ppa:ondrej/php5-oldstable
apt-get update
ppa-purge ppa:ondrej/php5
apt-get update && apt-get upgrade -y && apt-get autoremove -y && apt-get autoclean -y
@victorferraz
victorferraz / gist:6664598
Created September 22, 2013 22:47
convert px to em
$base-font-size: 14px;
@function em($px : 0, $base: $base-font-size) {
$value : 0;
@if $px > 0 and $base > 0{
$value : ($px / $base) * 1em;
}@else{
$value : 0;
}
@return $value;
# remgit.sh
# Creates a remote git repository from the current local directory
# Configuration
# Replace SSH_USERNAME, SSH_HOST, SSH_GIT_PATH with your details
USER=SSH_USERNAME
HOST=SSH_HOST
GIT_PATH=SSH_GIT_PATH
REPO=${PWD##*/}
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.0-wip/css/bootstrap.min.css">
<style>
.button {
padding: 10px;
.button {
width: 200px;
height: 50px;
padding: 10px;
}
.header {
width: 800px;
}
#button {
width: 200px;
height: 50px;
padding: 10px;
border: solid 1px #ccc;
background: linear-gradient(#ccc, #222);
border-radius: 10px;
box-shadow: rgba(0, 0, 0, .5) 2px 2px 5px;
}
$autoload['libraries'] = array(`sidebar');