Value | Color |
---|---|
\e[0;30m | Black |
\e[0;31m | Red |
\e[0;32m | Green |
\e[0;33m | Yellow |
\e[0;34m | Blue |
\e[0;35m | Purple |
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 running queries (pre 9.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%' |
I hereby claim:
- I am murilobr on github.
- I am murilobr (https://keybase.io/murilobr) on keybase.
- I have a public key ASBzvZGdHm2Lwk3A2f1_eIKGr8uzwan4b-LWv5sxNSD-Kgo
To claim this, I am signing this object:
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
Chart.pluginService.register({ | |
afterDraw: function(chart) { | |
if (chart.config.options.elements.center) { | |
var helpers = Chart.helpers; | |
var ctx = chart.chart.ctx; | |
ctx.save(); | |
var width = (chart.chartArea.left + chart.chartArea.right), | |
height = (chart.chartArea.top + chart.chartArea.bottom); |
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
$(":not(input,select,textarea)").attr('unselectable', 'on') | |
.css({'-moz-user-select':'-moz-none', | |
'-moz-user-select':'none', | |
'-o-user-select':'none', | |
'-khtml-user-select':'none', /* you could also put this in a class */ | |
'-webkit-user-select':'none',/* and add the CSS class here instead */ | |
'-ms-user-select':'none', | |
'user-select':'none' | |
}).bind('selectstart', function(){ return false; }); |
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/bash | |
set -o errexit | |
# Author: David Underhill | |
# Script to permanently delete files/folders from your git repository. To use | |
# it, cd to your repository's root and then run the script with a list of paths | |
# you want to delete, e.g., sh remove.sh path1 path2 | |
if [ $# -eq 0 ]; then | |
exit 0 |
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
// Source: https://groups.google.com/forum/#!topic/angular/hVrkvaHGOfc | |
// jsFiddle: http://jsfiddle.net/pkozlowski_opensource/PxdSP/14/ | |
// author: Pawel Kozlowski | |
var myApp = angular.module('myApp', []); | |
//service style, probably the simplest one | |
myApp.service('helloWorldFromService', function() { | |
this.sayHello = function() { | |
return "Hello, World!" |
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
brew list | awk '{print "brew uninstall "$1}' | sh |
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
events { | |
worker_connections 5; | |
} | |
http{ | |
server { | |
listen 8090; | |
server_name localhost; | |
access_log /my_project_folder/access_nginx.log; | |
error_log /my_project_folder/error_nginx.log; |