Skip to content

Instantly share code, notes, and snippets.

@fabiolimace
fabiolimace / Formato de arquivo GZ.TAR.md
Last active November 24, 2025 06:27
Formato de arquivo GZ.TAR

Formato de arquivo GZ.TAR

O quê

Um arquivo gz.tar é um arquivo de fita cujos arquivos internos estão compactados individualmente.

Primeiro, os arquivos são compactados recursivamente dentro de um diretório. Depois disso, o arquivo de fita desse diretório é gerado.

@fabiolimace
fabiolimace / calibre-list-mobi-asin.sh
Last active November 24, 2025 03:30
List Amazon Book IDs of all ebooks in a Calibre Library
#!/bin/bash
#
# List all MOBI-ASIN codes extracted from OPF files.
#
# Usage
#
# calibre-list-mobi-asin.sh LIBRARY
#
@fabiolimace
fabiolimace / _etc_udev_rules.d_80-smartlink-mp3-player.rules
Last active November 5, 2025 20:36
Smartlink Technology - Genai MP3 Player - USB Mass Storage - YP3 - Not working on Ubuntu
@fabiolimace
fabiolimace / audiobook.sh
Last active October 27, 2025 08:45
Convert a ebook into an audiobook.
#!/bin/bash
#
# Convert a ebook into an audiobook.
#
# Input format: TXT
# Output format: MP3
#
# USAGE
#
@fabiolimace
fabiolimace / g1-rss-downloader.sh
Last active August 16, 2025 23:19
Este script baixa o RSS do site G1 da Globo.
#!/bin/bash
#
# Este script baixa o RSS do site G1 da Globo.
#
# Produz dois arquivos:
#
# 1. Um arquivo XML o conteúdo inalterado;
# 2. Um arquivo Record-Jar gerado a partir do XML.
#
@fabiolimace
fabiolimace / stdquote.js
Created March 27, 2025 10:22 — forked from thanpolas/stdquote.js
Normalize all UTF quotes in Javascript
/**
* Will normalize quotes in a given string. There are many variations of quotes
* in the unicode character set, this function attempts to convert any variation
* of quote to the standard Quotation Mark - U+0022 Standard Universal: "
*
* @param {string} str The string to normalize
* @return {string} Normalized string.
* @see https://unicode-table.com/en/sets/quotation-marks/
*/
helpers.stdQuote = (str) => {
@fabiolimace
fabiolimace / cookie-jar-search-by-key.awk
Last active April 5, 2025 22:10
Search records in a Cookie-Jar format file. Moved to https://github.com/fabiolimace/awk-tools
@fabiolimace
fabiolimace / Awk script.awk
Last active April 5, 2025 23:39
Modelos/Templates do Ubuntu
#!/usr/bin/mawk -f
#
# description
#
BEGIN {
}
{
@fabiolimace
fabiolimace / csv-to-tsv.awk
Last active April 5, 2025 21:23
Convert a comma-setarated values file (CSV) into a tab-separated values file (TSV) using AWK, and vice-versa. Moved to https://github.com/fabiolimace/awk-tools
#!/usr/bin/awk -f
#
# Reads a CSV file and prints a TSV file to standard output.
#
# Usage:
# ./csv-to-tsv.awk input.csv > output.tsv
# ./csv-to-tsv.awk -v SEP=";" input.csv > output.tsv
# ./csv-to-tsv.awk -v COLUMNS=10 input.csv > output.tsv
#
@fabiolimace
fabiolimace / zless
Created February 14, 2025 18:54
Gzip tools like zcat
#!/bin/sh
zcat "$1" | less