Skip to content

Instantly share code, notes, and snippets.

View tokkenno's full-sized avatar
💭
I may be slow to respond.

Aitor González Fernández tokkenno

💭
I may be slow to respond.
View GitHub Profile
@tokkenno
tokkenno / librockchip-mpp.spec
Created January 22, 2026 20:37
RPM package scripts for Rockchip MPP
Name: librockchip-mpp
Version: 1.0.11
Release: 1%{?dist}
Summary: Rockchip Media Process Platform
Group: Development/Libraries
License: Proprietary
URL: http://www.rock-chips.com
Source0: mpp-%{version}.tar.gz
BuildRequires: cmake, gcc, g++, make, libtool, pkgconfig
@tokkenno
tokkenno / tmp.js
Last active July 10, 2019 08:04
tmp
console.log("codigo ejecuta");
setTimeout(() => {
console.log("codigo entra");
document.querySelectorAll('pre code').forEach((block) => {
hljs.highlightBlock(block);
console.log("codigo formateado");
});
}, 1000);
@tokkenno
tokkenno / router_restart.js
Created August 19, 2018 21:51
Restart script for the Sagemcom F@ST 3686 AC router
const router = {
user: "vodafone",
pass: "",
ip: "192.168.0.1"
};
const request = require('request');
const user_agent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36";
version: '3'
services:
bot:
image: reimashi/salien-bot:latest
restart: always
volumes:
- ./gettoken.json:/app/gettoken.json
labels:
com.centurylinklabs.watchtower.enable: "true"
updater:
@tokkenno
tokkenno / dkms.conf
Last active June 3, 2018 03:16
Intel I219-V Linux install script, with DKMS
PACKAGE_NAME="e1000e"
PACKAGE_VERSION="3.4.0.2"
BUILT_MODULE_NAME[0]="e1000e"
DEST_MODULE_NAME[0]="e1000e"
MAKE="'make' default"
CLEAN="'make' clean"
DEST_MODULE_LOCATION[0]="/kernel/drivers/net/ethernet/intel/e1000e/"
AUTOINSTALL="yes"
@tokkenno
tokkenno / Dockerfile
Created December 4, 2017 20:11
Grav (getgrav.org) docker image. On Docker hub: https://hub.docker.com/r/reimashi/grav/
FROM php:7.2-apache
# System Dependencies.
RUN apt update && \
apt upgrade -y && \
apt install -y unzip
# Copy grav to docker
COPY grav-v1.3.8.zip /tmp/
RUN cd /tmp && \
@tokkenno
tokkenno / compile_asm_os.sh
Created September 2, 2016 11:13
Compile an assambler file to be booted from a floppy or cdrom (ISO file).
#! /bin/bash
nasm -f bin -o os.bin src/os.asm
dd if=/dev/zero of=floppy.img bs=1024 count=1440
dd if=os.bin of=floppy.img seek=0 count=1 conv=notrunc
rm os.bin
mkdir iso
cp floppy.img dist/floppy.img
@tokkenno
tokkenno / install_seadas.sh
Last active January 1, 2020 09:16
Easy installer for SeaDAS and OCCSW from seadas.gsfc.nasa.gov (For Ubuntu or Debian-like systems)
#!/bin/bash
# Select the modules to install with true/false
INSTALL_AQUARIUS=false
INSTALL_AVHHR=false
INSTALL_CZCS=false
INSTALL_GOCI=false
INSTALL_HICO=false
INSTALL_MERIS=false
@tokkenno
tokkenno / horse.java
Created November 26, 2014 22:39
Clase Java que permite calcular los movimientos necesarios que debe hacer un caballo de ajedrez para pasar por todas las posiciones del tablero sin repetir ninguna. (Estrategia de backtraking)
public class Caballo
{
public static final int FILAS = 8;
public static final int COLUMNAS = 8;
protected int tabla[][] = new int[FILAS][COLUMNAS];
protected int desplaz_fil[] = {1, 2, -1, -2, 1, 2, -1, -2};
protected int desplaz_col[] = {2, 1, -2, -1, -2, -1, 2, 1};
/* Constructor que inicializa la propiedad con ceros */
@tokkenno
tokkenno / clean_abc_error.lua
Created November 26, 2014 21:09
Script de aegisub (http://www.aegisub.org/) que limpia el error que inserta strings ABC en los subtitulos .ass al demultiplexar desde Matroska (.mkv) archivos viejos.
local tr = aegisub.gettext
script_name = tr"Clean ABC Error"
script_description = tr"Clean ABC error created when demux .mkv files."
script_author = "Aitor González"
script_version = "0.1"
script_modified = "18/11/2012"
function clean_abc(subtitles)
startvar = 1