Skip to content

Instantly share code, notes, and snippets.

View JMalysiak's full-sized avatar

Jan Małysiak JMalysiak

  • Kraków, Poland
View GitHub Profile
@JMalysiak
JMalysiak / html-to-text-extractor.js
Created December 20, 2019 07:32
Extracts content of HTML elements into a plain text
var selector = prompt('Insert CSS selector');
var elements = document.querySelectorAll(selector);
var text = '';
for (var i = 0; i < elements.length; i++) {
text += elements[i].innerHTML + "\n";
}
console.log(text);
@JMalysiak
JMalysiak / facetags.py
Last active March 8, 2024 09:12
Import Picasa face tags into Digikam database
# This is a script to import face tags from Picasa into Digikam's SQLite database.
# First you need to export Picasa database into XML using this tool:
# https://sourceforge.net/projects/exportpicasa/
# Later you need to adjust this script to fit your needs and then just run it.
import xml.etree.ElementTree as ET
import sqlite3
# Adjust the values below:
XML_FILE_PATH = '/path/to/file.xml'