Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀

Felipe Astroza Araya astroza

🚀
View GitHub Profile
View ReformString.s
.arch armv5t
.fpu softvfp
.text
.syntax unified
.align 2
.global ReformString
.type ReformString, %function
ReformString:
push {r2, r3}
cmp r1, #0
@astroza
astroza / boost.rb
Last active Jun 29, 2020
Boost 1.73
View boost.rb
class Boost < Formula
desc "Collection of portable C++ source libraries"
homepage "https://www.boost.org/"
revision 3
head "https://github.com/boostorg/boost.git"
stable do
url "https://dl.bintray.com/boostorg/release/1.73.0/source/boost_1_73_0.tar.bz2"
sha256 "4eb3b8d442b426dc35346235c8733b5ae35ba431690e38c6a8263dce9fcbb402"
@astroza
astroza / boost.rb
Created Jun 28, 2020
Boost formula without patch for HEAD version
View boost.rb
class Boost < Formula
desc "Collection of portable C++ source libraries"
homepage "https://www.boost.org/"
revision 3
head "https://github.com/boostorg/boost.git"
stable do
url "https://dl.bintray.com/boostorg/release/1.72.0/source/boost_1_72_0.tar.bz2"
mirror "https://dl.bintray.com/homebrew/mirror/boost_1_72_0.tar.bz2"
sha256 "59c9b274bc451cf91a9ba1dd2c7fdcaf5d60b1b3aa83f2c9fa143417cc660722"
View beck.sh
#!/bin/bash
vmsMount=$(mount|grep /Users/felipe/vms)
if [ "x$vmsMount" == "x" ]; then
sudo mount -t nfs -o resvport 192.168.3.173:/export/vms /Users/felipe/vms
fi
cd /Users/felipe/vms/beck
# Linux
@astroza
astroza / mtd2_files
Created Nov 4, 2018
mtd2 full list of files
View mtd2_files
felipe@astroza-macmini:~/projects/foscamc1$ find _mtd2.extracted/squashfs-root
_mtd2.extracted/squashfs-root
_mtd2.extracted/squashfs-root/mtd_ext
_mtd2.extracted/squashfs-root/mtd_ext/app_ext
_mtd2.extracted/squashfs-root/mtd_ext/app_ext/diff_cn
_mtd2.extracted/squashfs-root/mtd_ext/app_ext/diff_cn/js
_mtd2.extracted/squashfs-root/mtd_ext/app_ext/diff_cn/js/main.js
_mtd2.extracted/squashfs-root/mtd_ext/app_ext/diff_cn/js/class.js
_mtd2.extracted/squashfs-root/mtd_ext/app_ext/diff_cn/html
_mtd2.extracted/squashfs-root/mtd_ext/app_ext/diff_cn/html/login.html
@astroza
astroza / sh
Created Nov 4, 2018
foscam c1 mtd1 files
View sh
felipe@astroza-macmini:~/projects/foscamc1$ find _mtd1.extracted/
_mtd1.extracted/
_mtd1.extracted/_3BFC.extracted
_mtd1.extracted/_3BFC.extracted/1B68FD.crt
_mtd1.extracted/_3BFC.extracted/4FD8E8
_mtd1.extracted/_3BFC.extracted/_4FD8E8.extracted
_mtd1.extracted/_3BFC.extracted/_4FD8E8.extracted/cpio-root
_mtd1.extracted/_3BFC.extracted/_4FD8E8.extracted/cpio-root/bin
_mtd1.extracted/_3BFC.extracted/_4FD8E8.extracted/cpio-root/bin/scriptreplay
_mtd1.extracted/_3BFC.extracted/_4FD8E8.extracted/cpio-root/bin/gunzip
View deep_hash.rb
def index_path(deep_hash, path)
sp = path.split("/")
d = 0
while d < sp.length
hk = sp.slice(sp.length - d - 1, sp.length)
if deep_hash[d] == nil
deep_hash[d] = {}
end
l = deep_hash[d][hk]
if l == nil
@astroza
astroza / check_frames.js
Created Feb 26, 2018
Tool to analyse segments
View check_frames.js
/* fastroza@ned.cl
*/
const spawn = require('child_process').spawn;
const frame_regex = /\[FRAME\]\n([\/\w=\n\.:\d\-_\s]*)\[\/FRAME\]\n/g;
const value_regex = /([\w_]*)=([\/\d\.\w_:]*)/g;
function digest_frame(str)
{
ret = {};
View autoclip-wordpress.user.js
// ==UserScript==
// @name Autoclip
// @namespace http://nedmedia.io
// @version 0.1
// @description try to take over the world!
// @author F
// @update https://gist.github.com/astroza/ff89cc940b33ad9319bf3ae8ae6da641/raw/17f3e11fda0f4c7831bc232870c4971165f9bf42/autoclip-wordpress.user.js
// @match http://*/wp/wp-admin/post.php?post=*
// @grant none
// ==/UserScript==
View js_arithmetic.js
// fastroza (TM)
// Comments about https://mobile.twitter.com/lukaseder/status/867080556470730752
var js_behavior = false
function add(_x, _y) { // (x) + (b)
// Normalization to Number
var x = +_x
var y = +_y
if(!js_behavior)