Skip to content

Instantly share code, notes, and snippets.

@emattson
emattson / install_postgresql_client.sh
Last active May 15, 2022 15:10
Install postgresql-client-10 on Debian 9
# taken from https://www.postgresql.org/download/linux/debian/
# assumes you are root
echo 'deb http://apt.postgresql.org/pub/repos/apt/ stretch-pgdg main' > /etc/apt/sources.list.d/pgdg.list
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add -
apt-get update
yes Y | apt-get install postgresql-client-10
@roylee0704
roylee0704 / dockergrep.sh
Created December 9, 2016 08:24
how to grep docker log
docker logs nginx 2>&1 | grep "127."
# ref: http://stackoverflow.com/questions/34724980/finding-a-string-in-docker-logs-of-container
@weberste
weberste / gist:354a3f0a9ea58e0ea0de
Last active January 28, 2022 13:47
Dates only with Angular-UI Bootstrap datepicker
app.directive('datepickerLocaldate', ['$parse', function ($parse) {
var directive = {
restrict: 'A',
require: ['ngModel'],
link: link
};
return directive;
function link(scope, element, attr, ctrls) {
var ngModelController = ctrls[0];