Skip to content

Instantly share code, notes, and snippets.

@mofe23
mofe23 / README.md
Created September 8, 2023 17:44 — forked from rrrnld/README.md
Interacting with your Firefox bookmarks and history from the command line

Firefox History and Bookmark Command Line Interface

These scripts use fzf and sqlite to efficiently query your firefox history and bookmarks. This is heavily inspired by a post from the creator of fzf: https://junegunn.kr/2015/04/browsing-chrome-history-with-fzf/. fzf allows you to select multiple items and the results returned will be the URLs.

What Does It Look Like?

asciicast

#include <Adafruit_MotorShield.h>
#include <stdarg.h>
/* Serial Port Print Helpers for string formatting */
#define SERIAL_PRINTF_MAX_BUFF 256
void serialPrintf(const char *fmt, ...);
void serialPrintf(const char *fmt, ...) {
char buff[SERIAL_PRINTF_MAX_BUFF];
va_list pargs;
va_start(pargs, fmt);
@mofe23
mofe23 / mozlz4a.py
Created March 25, 2023 17:17 — forked from Tblue/mozlz4a.py
MozLz4a compression/decompression utility
#!/usr/bin/env python3
# vim: sw=4 ts=4 et tw=100 cc=+1
#
####################################################################################################
# DESCRIPTION #
####################################################################################################
#
# Decompressor/compressor for files in Mozilla's "mozLz4" format. Firefox uses this file format to
# compress e. g. bookmark backups (*.jsonlz4).
#
@mofe23
mofe23 / migrate-liquid.sh
Created September 15, 2022 10:53
A script to rename html files a jekyll project to be compatible with JetBrains liquid extension, which automatically associates files with .liquid extension. Layout key in front matter and include tags are also adapted.
#!/usr/bin/env bash
set -euo pipefail
function exit_error() {
echo "${1}";
exit 1
}
git diff --quiet || exit_error "Working tree not clean, aborting"
#!/usr/bin/env bash
read -r -d '' USAGE <<- EOM
Dumps an lightroom catalogue to an sql file, then recreates a new one from it.
Idea taken from: http://mein-lightroom-tag.blogspot.com/2014/02/einen-katalog-reparieren-welchen.html
Example:
$ fix-lightroom XYZ.lrcat
@mofe23
mofe23 / setup
Created February 7, 2019 17:05
dotfiles setup script
#!/bin/bash
CURRENT_DIR=$(pwd)
for f in .bashrc \
.bash_profile \
.gitconfig \
.gitignore_global \
.git-completion.bash \
.vimrc