Skip to content

Instantly share code, notes, and snippets.

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=5f2d3ad5-9a91-49ee-8df9-cfd6f44a9d04 / ext4 errors=remount-ro 0 1
# /home was on /dev/sda2 during installation

Keybase proof

I hereby claim:

  • I am felipem775 on github.
  • I am felipem (https://keybase.io/felipem) on keybase.
  • I have a public key ASCRJMebLoMBCJWfls4DK8O-9ZhZMjPxGchyyOIpH224Nwo

To claim this, I am signing this object:

@felipem775
felipem775 / prepareNeogeoRoms.txt
Created November 23, 2017 21:58
Crear un directorio de roms solo con las de neogeo
$ wget https://raw.githubusercontent.com/libretro/fbalpha/master/gamelist.txt
$ cat gamelist.txt |grep "Neo Geo" | sort | awk '{print $2;}' > roms-neogeo.txt
$ xargs -0 -I {} -n 1 ln roms/{}.zip roms-neogeo/ < <(tr \\n \\0 < roms-neogeo.txt )
#!/bin/bash
export SCRIPT_PATH="`dirname \"$0\"`"
echo $SCRIPT_PATH
cd $SCRIPT_PATH
for DIR in */ ;
do
echo $DIR
cd $DIR
git remote update
cd $SCRIPT_PATH
-- original https://stackoverflow.com/a/19532132/2428230
CREATE FUNCTION make_uid() RETURNS text AS $$
DECLARE
new_uid text;
done bool;
BEGIN
done := false;
WHILE NOT done LOOP
new_uid := upper(substring(md5(''||now()::text||random()::text),1,8));
done := NOT exists(SELECT 1 FROM report_users WHERE confirm_key=new_uid);
@felipem775
felipem775 / png2mp4
Created June 6, 2018 07:11
convertir imágenes png a vídeo
ffmpeg -framerate 10 -pattern_type glob -i '*.png' -c:v libx264 \
-r 30 -pix_fmt yuv420p out.mp4
@felipem775
felipem775 / findMaxValue.js
Created July 31, 2018 10:59
Find the object whose property "X" has the greatest value in an array of objects
// https://stackoverflow.com/questions/4020796/finding-the-max-value-of-an-attribute-in-an-array-of-objects Andy Polhill
var n1 = { dateTime: new Date(), name: "n1"}
var n2 = { dateTime: new Date(), name: "n2"}
data = [n1, n2]
data.reduce(function (prev, current) { return (prev.dateTime > current.dateTime) ? prev : current })
@felipem775
felipem775 / untarFiles.sh
Created October 17, 2018 20:15
untar files in a different path
for filename in *.tar; do
tar -xf "$filename" -C "destino"
done
from datetime import datetime
import matplotlib.pyplot as plt
fn = "Nivel_Cares_1.csv"
X, Y = [], []
with open(fn) as f:
f.readline() # leer y descartar cabecero
for line in f:
y, x = line.strip().replace(",",".").split(";")