Skip to content

Instantly share code, notes, and snippets.

View fabiobruna's full-sized avatar

Fabio Bruna fabiobruna

View GitHub Profile
@tobi
tobi / kindle.rb
Last active September 25, 2022 02:37
Download your Kindle Highlights to local markdown files. Great for Obsidian.md.
#!/usr/bin/env ruby
# gem install active_support
require 'active_support/inflector'
require 'active_support/core_ext/string'
# gem install webrick (only ruby3)
require 'webrick'
# gem install mechanize
var current_url = window.location.href;
var feedbin_url = "https://feedbin.me/?subscribe="
var inst_regex = new RegExp("https:\/\/www\.instagram\.com\/(.*)\/");
var inst_username = inst_regex.exec(current_url)[1];
if (inst_username !== "" || inst_username !== undefined) {
var feed_url = "https://rsshub.app/instagram/user/" + inst_username;
window.location = feedbin_url + feed_url;
}
// The bookmarklet
@sscarduzio
sscarduzio / relog.sh
Created August 24, 2014 21:20
BtWiFi_with_FON automatic login written as a bash script. I have this running every 10 minutes on my raspberry pi
#!/bin/bash
# CONF
DBG=true
RELOG_UNAME=your@email.com
RELOG_PASSW=xxxxxxxxxxxxxxx
# END CONF
@cliss
cliss / organize-photos.py
Created October 6, 2013 14:43
Photo management script. This script will copy photos from "~/Pictures/iPhone Incoming" into a tree the script creates, with folders representing month and years, and photo names timestamped. Completely based on the work of the amazing Dr. Drang; see here: http://www.leancrew.com/all-this/2013/10/photo-management-via-the-finder/ You can see more…
#!/usr/bin/python
import sys
import os, shutil
import subprocess
import os.path
from datetime import datetime
######################## Functions #########################
@jvhaarst
jvhaarst / movedigiphotos.bash
Last active December 12, 2022 22:02
Bash script to move images, based on exif data and file timestamp
#!/bin/bash
# Reads EXIF creation date from all .JPG files in the
# current directory and moves them carefully under
#
# $BASEDIR/YYYY/YYYY-MM/YYYY-MM-DD/
#
# ...where 'carefully' means that it does not overwrite
# differing files if they already exist and will not delete
# the original file if copying fails for some reason.
@jacobheric
jacobheric / extjs-example-grid-search-paging.js
Created March 13, 2011 16:02
An example Ext JS CRUD grid with search and paging
Ext.ns('youbrew', 'youbrew.recipe');
/**
* youbrew.recipe.Grid
* A recipe EditorGridPanel, clearly derived from the extjs examples.
*/
youbrew.recipe.Grid = Ext.extend(Ext.grid.EditorGridPanel, {
renderTo: 'recipe-grid',
iconCls: 'silk-grid',
frame: true,
title: 'YouBrew Recipe Grid',
@markembling
markembling / gitutils.ps1
Last active March 29, 2023 01:47
Powershell functions for git information
# Git functions for PowerShell
# Copyright 2009-2019 Mark Embling (http://www.markembling.info/)
#
# 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
# furnished to do so, subject to the following conditions:
#