Skip to content

Instantly share code, notes, and snippets.

View mauron85's full-sized avatar

Marián Hello mauron85

View GitHub Profile
@mfmendiola
mfmendiola / ArrayUtil.java
Last active April 5, 2023 19:10
ReadableArray and ReadableMap serialization helpers for the React Native—Android bridge.
/*
ArrayUtil exposes a set of helper methods for working with
ReadableArray (by React Native), Object[], and JSONArray.
MIT License
Copyright (c) 2020 Marc Mendiola
Permission is hereby granted, free of charge, to any person obtaining a copy
@akunzai
akunzai / sqlite_backup.ps1
Last active August 30, 2019 10:43
SQLite Backup Rotation Script
# usage: powershell -ExecutionPolicy Bypass -file .\sqlite_backup.ps1 -dbFile .\tobackup.db3 -backupDir .\backup
# please make sure sqlite3.exe can be found in $PATH or specify it by -sqliteExe parameter
Param(
# https://chocolatey.org/packages/sqlite.shell
[string]$sqliteExe = "sqlite3.exe",
[Parameter(Mandatory = $true)]
[string]$dbFile,
# default same as dbFile's directory
[string]$backupDir = "",
# [default|fullday|fulltime]
@alexellis
alexellis / timelapse.md
Created March 9, 2017 08:48 — forked from porjo/timelapse.md
ffmpeg time-lapse

Convert sequence of JPEG images to MP4 video

ffmpeg -r 24 -pattern_type glob -i '*.JPG' -i DSC_%04d.JPG -s hd1080 -vcodec libx264 timelapse.mp4

  • -r 24 - output frame rate
  • -pattern_type glob -i '*.JPG' - all JPG files in the current directory
  • -i DSC_%04d.JPG - e.g. DSC_0397.JPG
  • -s hd1080 - 1920x1080 resolution

Slower, better quality

@CROSP
CROSP / dd-wrt-transparent-proxy.sh
Created August 30, 2017 16:48
DD-WRT Transparent proxy configuration
#!/bin/sh
PROXIFYING_MACHINE=192.168.0.145
MACHINE_TO_PROXIFY=192.168.0.113
iptables -I PREROUTING 1 -t mangle -s $MACHINE_TO_PROXIFY ! -d `nvram get lan_ipaddr`/`nvram get lan_netmask` -p tcp -m multiport --dports 80,443 -j MARK --set-mark 3
iptables -I PREROUTING 2 -t mangle -s $MACHINE_TO_PROXIFY ! -d `nvram get lan_ipaddr`/`nvram get lan_netmask` -p tcp -m multiport --dports 80,443 -j CONNMARK --save-mark
iptables -I PREROUTING 3 -t mangle -s $MACHINE_TO_PROXIFY ! -d `nvram get wan_ipaddr` -p tcp -m multiport --dports 80,443 -j MARK --set-mark 3
iptables -I PREROUTING 4 -t mangle -s $MACHINE_TO_PROXIFY ! -d `nvram get wan_ipaddr` -p tcp -m multiport --dports 80,443 -j CONNMARK --save-mark
ip rule add fwmark 3 table 13
@radfish
radfish / README
Created December 4, 2017 05:16
Route only Transmission through a VPN connection using your own VPN server
# The approach is to mark packets from a specific user,
# create a dedicated routing table with a default route
# through the VPN, and force all marked packets to be
# routed using that table.
#
# Sources:
# https://www.niftiestsoftware.com/2011/08/28/making-all-network-traffic-for-a-linux-user-use-a-specific-network-interface/
# http://freeaqingme.tweakblogs.net/blog/9340/netflix-using-a-vpn-for-just-one-application.html
# In this guide
@tuyenld
tuyenld / Original_vs_Mod_Chip.md
Last active October 13, 2025 18:42
2019-02-11-upgrade-flash-chip-tplink-tl-wr840n-4mb-to-8mb
Description Original Mod
flash GigaDevice GD25Q32B (4MB) Winbond GD25Q64CSIG (8MB)
firmware TL-WR840N(VN)_V5_170517 openwrt-18.06.1-ramips-mt76x8-tl-wr841n-v13-squashfs-sysupgrade