Skip to content

Instantly share code, notes, and snippets.

Avatar
🤷‍♂️
I delete UTM tags before sharing links just for fun.

Julio J. Foulquie j3j5

🤷‍♂️
I delete UTM tags before sharing links just for fun.
  • The Next Web
View GitHub Profile
@j3j5
j3j5 / rules-both.iptables
Created May 13, 2021 — forked from jirutka/rules-both.iptables
Basic iptables template for ordinary servers (both IPv4 and IPv6)
View rules-both.iptables
###############################################################################
# The MIT License
#
# Copyright 2012-2014 Jakub Jirutka <jakub@jirutka.cz>.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
@j3j5
j3j5 / vacunas-dpto-historical.csv
Last active May 25, 2021
Vacunación en Uruguay (series históricas)
View vacunas-dpto-historical.csv
ARTIGAS CANELONES CERRO LARGO COLONIA DURAZNO FLORES FLORIDA LAVALLEJA MALDONADO MONTEVIDEO PAYSANDÚ RIVERA ROCHA RÍO NEGRO SALTO SAN JOSÉ SORIANO TACUAREMBÓ TREINTA Y TRES
2021-02-27 4 27 3 7 5 1 0 2 22 210 8 26 4 0 26 6 11 9 1
2021-02-28 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
2021-03-01 488 1368 778 727 621 244 543 349 1089 7021 545 860 488 465 615 538 574 509 191
2021-03-02 383 1655 266 376 449 243 410 338 415 6788 423 464 303 272 627 407 303 392 177
2021-03-03 493 2131 569 647 507 237 591 359 917 9817 556 716 457 323 669 557 495 757 446
2021-03-04 259 1519 184 203 143 98 200 255 319 3731 232 327 164 123 435 275 165 188 135
2021-03-05 256 1379 204 287 175 65 281 200 374 3953 290 311 4 119 433 222 174 312 157
2021-03-06 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
2021-03-07 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
@j3j5
j3j5 / varnishlog-examples.sh
Created Nov 28, 2018 — forked from cupracer/varnishlog-examples.sh
varnishlog examples (version 4.x)
View varnishlog-examples.sh
# filter by request host header
varnishlog -q 'ReqHeader ~ "Host: example.com"'
# filter by request url
varnishlog -q 'ReqURL ~ "^/some/path/"'
# filter by client ip (behind reverse proxy)
varnishlog -q 'ReqHeader ~ "X-Real-IP: .*123.123.123.123"'
# filter by request host header and show request url and referrer header
@j3j5
j3j5 / cloak.ovpn
Created Jun 28, 2018 — forked from derwentx/cloak.ovpn
This is an OpenVPN settings file for Cloak. Forked for compatibility the OpenVPN client in ASUS RT routers
View cloak.ovpn
client
dev tun
comp-lzo
auth-user-pass
# remote-cert-tls server
server-poll-timeout 10
auth-nocache
auth-retry interact
verb 1
remote openvpn.getcloakvpn.com 443 udp
@j3j5
j3j5 / functions.php
Created Aug 28, 2017
Log all SQL queries made from Wordpress
View functions.php
<?php
// Include this on your functions.php
function log_sql_queries($text_query){
/* //Uncomment me if you want a lot of info about where the sql query comes from and what action started it off
$traces = debug_backtrace();
foreach ($traces as $tobj => $trace) {
if($trace['function'] == 'do_action'){
$args = $trace['args'];
}
@j3j5
j3j5 / clean_all_svgs.sh
Created Jun 1, 2017
Apply SVG Cleaner to all the SVGs on a given folder
View clean_all_svgs.sh
# https://github.com/RazrFalcon/svgcleaner/ must be installed
find . -type f -name "*.svg" | sudo xargs -I file svgcleaner file file
@j3j5
j3j5 / video2gif.sh
Created Dec 19, 2016
Convert from video to GIF using ffmpeg
View video2gif.sh
# Replace the parameters on capital letters
ffmpeg -y -ss 30 -t 3 -i EXAMPLE.mp4 -vf fps=10,scale=320:-1:flags=lanczos,palettegen palette.png
ffmpeg -ss START_TIME -t DURATION -i EXAMPLE.mp4 -i palette.png -filter_complex "fps=10,scale=320:-1:flags=lanczos[x];[x][1:v]paletteuse" OUTPUT.gif
@j3j5
j3j5 / country_code.php
Last active Dec 15, 2016
Get the country name from a ISO country code
View country_code.php
<?php
/**
* Copied from http://snipplr.com/view/36868/ for posterity
*/
function country_code_to_country( $code ){
$country = '';
if( $code == 'AF' ) $country = 'Afghanistan';
if( $code == 'AX' ) $country = 'Aland Islands';
if( $code == 'AL' ) $country = 'Albania';
View URL testing
SHOULD MATCH:
http://foo.com/blah_blah
http://foo.com/blah_blah/
http://foo.com/blah_blah_(wikipedia)
http://foo.com/blah_blah_(wikipedia)_(again)
http://www.example.com/wpstyle/?p=364
https://www.example.com/foo/?bar=baz&inga=42&quux
http://✪df.ws/123
http://userid:password@example.com:8080
http://userid:password@example.com:8080/
@j3j5
j3j5 / duendeando.csv
Last active Aug 8, 2016
Todos los programas del programa de RNE 3, Duendeando (hasta el 5/8/2016)
View duendeando.csv
Título Tipo Duración Popularidad Fecha Link
Duendeando - 06/12/08 Completo 1:59:33 32% popularidad 06 dic 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEND/mp3/3/5/1228477463753.mp3
Duendeando - 22/11/08 Completo 2:00:53 32% popularidad 22 nov 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEND/mp3/7/4/1227190438947.mp3
Duendeando - 15/11/08 Completo 2:00:04 32% popularidad 15 nov 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEND/mp3/7/8/1226587434987.mp3
Duendeando - 08/11/08 Completo 1:59:56 32% popularidad 08 nov 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEND/mp3/8/2/1226065380828.mp3
Duendeando - 01/11/08 Completo 2:00:34 32% popularidad 01 nov 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEND/mp3/6/9/1225705277196.mp3
Duendeando - 25/10/08 Completo 1:59:25 32% popularidad 25 oct 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEND/mp3/8/6/1224842980068.mp3
Duendeando - 18/10/08 Completo 2:00:36 32% popularidad 18 oct 2008 http://mvod.lvlt.rtve.es/resources/TE_SDUEN