Skip to content

Instantly share code, notes, and snippets.

View FrankKooij's full-sized avatar

Frank Kooij FrankKooij

View GitHub Profile
@FrankKooij
FrankKooij / obsidian-web-clipper.js
Created February 20, 2024 15:02 — forked from kepano/obsidian-web-clipper.js
Obsidian Web Clipper Bookmarklet to save articles and pages from the web (for Safari, Chrome, Firefox, and mobile browsers)
javascript: Promise.all([import('https://unpkg.com/turndown@6.0.0?module'), import('https://unpkg.com/@tehshrike/readability@0.2.0'), ]).then(async ([{
default: Turndown
}, {
default: Readability
}]) => {
/* Optional vault name */
const vault = "";
/* Optional folder name such as "Clippings/" */
@FrankKooij
FrankKooij / Things2Taskpaper
Last active June 15, 2021 19:59 — forked from wakatara/Things2Taskpaper
An AppleScript to migrate all tasks out of Cultured Code's Things 2 for OS X and put them in the proper text format for Hog Bay Software's Taskpaper
-- modified on 21 Feb 2013 by Daryl Manning https://daryl.wakatara.com/why-i-switched-back-to-taskpaper
-- modified 21 Oct 2019 - 15 Jun 2021 by Frank Kooij https://gist.github.com/frankkooij/b198a7edae072751281471e6e2f08b94
-- sources:
-- - https://gist.github.com/RichardHyde/3386ac57b55455b71140
-- - https://www.leonroy.com/blog/2015/11/getting-things-done
-- - https://www.taskpaper.com/guide/reference/dates
-- - https://culturedcode.com/things/download/Things2AppleScriptGuide.pdf
-- - https://www.oreilly.com/library/view/applescript-the-definitive/0596102119/ch13s06s01.html
set thePath to (path to desktop as Unicode text) & "Things2Taskpaper.taskpaper"
@FrankKooij
FrankKooij / next-doing-done.js
Created May 29, 2021 09:39 — forked from acdpnk/next-doing-done.js
@next → @doing@done for Taskpaper 3
'use strict'
function TaskPaperContextScript(editor, options) {
function clean_tags (string) {
return string.replace(/((\s*@done(\(.*?\))?)|\s*@next|\s*@doing|\s*@later)/, '');
}
function mark_next (string) {
return clean_tags(string) + ' @next'
@FrankKooij
FrankKooij / Things to CSV.scpt
Created October 21, 2019 19:38 — forked from leonroy/Things to CSV.scpt
Convert Things database to CSV. This script produces two CSVs on the user's Desktop. One for todos and the other for projects. It requires that Things.app is installed.
---------
-- Convert Things (from Cultured Code) database to CSV
-- https://culturedcode.com/things/
--
-- Version 1.0
--
-- This script produces two CSVs on the user's Desktop. One for todos and the other for projects.
-- It requires that Things.app is installed.
--
-- Things todos and projects can be tied either using the project name in the todos CSV or better
@FrankKooij
FrankKooij / things.sh
Created October 21, 2019 19:26 — forked from avdgaag/things.sh
Command-line read-only interface to your local Things database of to do items.
#!/bin/bash
#
# DESCRIPTION
#
# Simple read-only comand-line interface to your Things 2 database. Since
# Things uses a SQLite database (which should come pre-installed on your Mac)
# we can simply query it straight from the command line.
#
# We only do read operations since we don't want to mess up your data.
#
@FrankKooij
FrankKooij / things.sh
Created October 21, 2019 19:25 — forked from AlexanderWillner/things.sh
Command-line read-only interface to your local Things database of to do items.
Moved to https://github.com/alexanderwillner/things.sh/
@FrankKooij
FrankKooij / Synology-Diskstation-Git.md
Last active March 3, 2016 15:50 — forked from walkerjeffd/Synology-Diskstation-Git.md
Instructions for setting up git server on Synology Diskstation

Configure Synology NAS as Git Server

Instructions for setting up a git server on a Synology NAS with Diskstation. Specifically, I am using a DS414 with DSM 5.0.

Set Up User and Folder

  • Create user gituser via Diskstation interface (with File Station and WebDAV privilages)
  • Add new shared folder called git (located at /volume1/git) with read/write access for gituser and admin. This folder will hold all the repos.
  • Install Git Server package via Diskstation
@FrankKooij
FrankKooij / docx2md.md
Created October 27, 2015 08:53 — forked from carloscasalar/docx2md.md
Convert a Word Document into MD

Converting a Word Document to Markdown in One Move

The Problem

A lot of important government documents are created and saved in Microsoft Word (*.docx). But Microsoft Word is a proprietary format, and it's not really useful for presenting documents on the web. So, I wanted to find a way to convert a .docx file into markdown.

Installing Pandoc

On a mac you can use homebrew by running the command brew install pandoc.

The Solution