Skip to content

Instantly share code, notes, and snippets.

View juliozuppa's full-sized avatar

Julio Cesar Zuppa juliozuppa

  • Curitiba, PR, Brasil
View GitHub Profile
@juliozuppa
juliozuppa / postgres_queries_and_commands.sql
Last active January 9, 2020 20:02 — forked from rgreenjr/postgres_queries_and_commands.sql
Useful PostgreSQL Queries and Commands
-- show running queries (pre 8.2)
SELECT procpid, age(clock_timestamp(), query_start), usename, current_query
FROM pg_stat_activity
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%'
ORDER BY query_start desc;
-- show running queries (9.2)
SELECT pid, age(clock_timestamp(), query_start), usename, query
FROM pg_stat_activity
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%'
@juliozuppa
juliozuppa / UnidadeFederacao.java
Created July 9, 2018 21:07 — forked from rgiaviti/UnidadeFederacao.java
Enum Java com todas as Unidades da Federação do Brasil
/**
* Enum com todas as Unidades da Federação do Brasil. Contém o nome da Unidade, a sigla e a capital da Unidade da Federação.
*
* @author Ricardo Giaviti
* @version 1.0.0
* @since 1.0.0
*/
public enum UnidadeFederacao {
AMAZONAS("Amazonas", "AM", "Manaus"),
@juliozuppa
juliozuppa / loop.less
Created March 29, 2017 20:53 — forked from danro/loop.less
LESS css loop example
.loop (0) {}
.loop (@index) when (@index > 0) {
.classname-@{index} {
top: @index * 1px;
}
.loop (@index - 1);
}
#example {
.loop(5);
@juliozuppa
juliozuppa / gist:cf0285f61e8ca0769749b591d9975932
Created March 29, 2017 20:52 — forked from edwinwebb/gist:5155504
A simple less loop with comments and simple from, to syntax.
/* Define two variables as the loop limits */
@from : 0;
@to : 10;
/* Create a Parametric mixin and add a guard operation */
.loop(@index) when(@index =< @to) {
/* As the mixin is called CSS is outputted */
div:nth-child(@{index}) {
top: unit(@index * 100, px);
@juliozuppa
juliozuppa / 0_reuse_code.js
Created November 24, 2015 16:21
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@juliozuppa
juliozuppa / Git Configs
Last active August 29, 2015 14:03 — forked from tacsio/Git Configs
git config --global user.name "Tarcisio Coutinho"
git config --global user.email "[email protected]"
git config --global color.ui true
git config --global alias.s status
git config --global alias.c checkout
git config --global alias.b branch
git config --global alias.lol log --oneline --graph --decorate