Skip to content

Instantly share code, notes, and snippets.

View edbizarro's full-sized avatar
🎲
Crunching data

Eduardo Bizarro edbizarro

🎲
Crunching data
View GitHub Profile
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active July 27, 2024 16:01
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@rgreenjr
rgreenjr / postgres_queries_and_commands.sql
Last active July 27, 2024 16:50
Useful PostgreSQL Queries and Commands
-- 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%'
@franklinjavier
franklinjavier / install-sublime-ubuntu.sh
Created April 9, 2013 04:20
Install Sublime Text 2 on Ubuntu
#!/bin/bash
# Script to install Sublime Text on Ubuntu
# Apr 9 2013 - @franklinjavier
echo "Downloading Sublime Text 2"
wget http://c758482.r82.cf2.rackcdn.com/Sublime\ Text\ 2.0.1\ x64.tar.bz2
echo "Unziping and moving"
tar -xvf Sublime\ Text\ 2.0.1\ x64.tar.bz2
mv Sublime\ Text\ 2 sublimeText
@radiosilence
radiosilence / gist:5891672
Created June 29, 2013 16:01
Xresources for urxvt
!URxvt.font: -*-unifont-medium-*-*-*-16-*-*-*-*-*-*-*
!URxvt.boldFont: -*-unifont-medium-*-*-*-16-*-*-*-*-*-*-*
! Terminus
!URxvt.font: -*-terminus-medium-*-*-*-16-*-*-*-*-*-iso10646-*
!URxvt.boldFont: -*-terminus-bold-*-*-*-16-*-*-*-*-*-iso10646-*
! Tamzen
URxvt.font: -misc-tamzen-medium-r-normal--17-*-*-*-*-*-iso8859-1
URxvt.boldFont: -misc-tamzen-bold-r-normal--17-*-*-*-*-*-iso8859-1
! Source Sans
!URxvt.font: xft:Source Code Pro:size=7
@t3chnoboy
t3chnoboy / gist:8322246
Created January 8, 2014 18:55
Convert all files in folder to utf-8 using iconv
# http://stackoverflow.com/questions/4544669/batch-convert-latin-1-files-to-utf-8-using-iconv
find . -type f -exec bash -c 'iconv -f iso-8859-1 -t utf-8 "{}" > /path/to/destination/"{}"' \;
@XVilka
XVilka / TrueColour.md
Last active July 9, 2024 23:28
True Colour (16 million colours) support in various terminal applications and terminals

THIS GIST WAS MOVED TO TERMSTANDARD/COLORS REPOSITORY.

PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!

@laracasts
laracasts / gist:f4a304232c1be6dbb4f8
Last active February 16, 2023 20:19
Laracasts PHPStorm theme.
@kamilZ
kamilZ / xdebug-install-php7
Created December 5, 2015 00:10
Install xdebug from sources php7.0
sudo apt-get install php7.0-dev
wget http://xdebug.org/files/xdebug-2.4.0rc2.tgz
tar -xzf xdebug-2.4.0rc2.tgz
cd xdebug-2.4.0RC2/
phpize
./configure --enable-xdebug
make
sudo cp modules/xdebug.so /usr/lib/.
#FOR FPM
sudo echo 'zend_extension="/usr/lib/xdebug.so"' > /etc/php/7.0/fpm/conf.d/20-xdebug.ini
ssl = off
maintenance_work_mem = 2GB
work_mem = 2GB
fsync = off
synchronous_commit = off
wal_level = minimal
max_wal_senders = 0
archive_mode = off
wal_buffers = -1
wal_writer_delay = 20ms
@criccomini
criccomini / test_dags.py
Created June 22, 2016 15:18
test_dags.py
import os
import unittest
from airflow.models import DagBag
class TestDags(unittest.TestCase):
"""
Generic tests that all DAGs in the repository should be able to pass.
"""