Skip to content

Instantly share code, notes, and snippets.

View tamvodopad's full-sized avatar
🏠
Working from home

Konstantin Popov tamvodopad

🏠
Working from home
View GitHub Profile
@alexpgates
alexpgates / Use DayOne Journal data with php
Created April 6, 2011 20:05
Use DayOne data with php.
<?php
// DayOne is a nice little journaling app for iOS / Mac (available via App Store).
// This code requires php_class_lib available here: https://github.com/jsjohnst/php_class_lib
include('php_class_lib/classes/parsers/plist/PlistParser.inc');
// grab filenames for all of your journal entries
$entries = array();
if ($handle = opendir('/path/to/your/Journal.dayone/entries')) {
@ttscoff
ttscoff / tp-dailylog.rb
Created February 26, 2012 04:33
Daily background logger to write completed TaskPaper tasks (system-wide) to a Day One entry
#!/usr/bin/ruby
# tp-dailylog.rb - Log TaskPaper tasks completed on the current day to a Day One entry
# Brett Terpstra 2012 <http://brettterpstra.com>
#
# Run it with launchd at 11pm and forget about it
#
# Notes:
# * Uses `mdfind` to locate all .taskpaper files changed in the last day
# * Scans for @done(xxxx-xx-xx) tags in each line matching today's date
# * Does not alter TaskPaper files in any way
@jamband
jamband / console.php
Created July 16, 2012 04:50
Yii Framework: console command in module.
<?php
'commandMap' => array(
'deleteexpireduser' => array(
'class' => 'application.modules.user.commands.DeleteExpiredUserCommand',
),
),
@judismith
judismith / Log tasks and hours to Day One
Created August 10, 2012 16:36
AppleScript to create Day One entry for hours logged in TaskPaper - Based on the AppleScript from Brett Terpstra to log TaskPaper completed tasks to Day One. This script does both
set archivedTasks to ""
set hoursEntries to ""
tell application "TaskPaper"
tell front document
-- don't care which file your log entry came from?
-- comment the next line out
set archivedTasks to "## " & name & return
set hoursEntries to "## " & name & ": Hours" & return
repeat with _task in search with query "project != Archive and @done"
if entry type of _task is not project type then
@ttscoff
ttscoff / webexcursions.rb
Created January 14, 2013 11:20
A script for gathering new Pinboard links with a certain tag and generating Markdown/Jekyll posts when enough are collected.
#!/usr/bin/ruby
# WebExcursions, a script for gathering new Pinboard links with a certain tag
# and generating Markdown/Jekyll posts when enough are collected.
# Brett Terpstra 2013
#
# -f to force writing out current bookmarks to file regardless of count
%w[fileutils set net/https zlib rexml/document time base64 uri cgi stringio].each do |filename|
require filename
end
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active June 18, 2024 20:30
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@dbreunig
dbreunig / ReporterSaveFileDescription.md
Last active January 22, 2021 16:07
A description of the data written to the Reporter App Dropbox save folder.

#Reporter Save File Schema

##The Reporter Export File

Reporter saves to your Dropbox account with plaintext JSON files, one for each day. When a Report is entered in the app a file is created for that day if it does not exist. Otherwise, the report is appended to the existing file. The save folder is located in 'Dropbox/Apps/Reporter-App/'.

Reporter save files are named according to the following convention:

YYYY-MM-DD-reporter-export.json
@craigeley
craigeley / recurring_taskpaper_task.rb
Last active February 28, 2016 18:43
Set this script to run at various times using launchd to automatically add lines to TaskPaper files if they don't exist. A solution for recurring tasks for plain-text task management.
#!/usr/bin/ruby
# Change to your filepath in lines 9 and 12
# Add your exact search term to line 9
# Add your exact to-do in line 13
require 'time'
today = Time.now.strftime('%Y-%m-%d')
if File.readlines('/Users/USERNAME/Dropbox/Listacular/list.taskpaper', encoding: 'UTF-8').grep(/TERM/).any?
exit
@derickfay
derickfay / tp2fantastical
Last active August 20, 2016 13:57
Sends the input text to Fantastical, converting TaskPaper @Due(YYYY-MM-DD) tags to plain text for Fantastical to parse as a Reminder. Designed for use with Drafts and Pythonista.
# tp2fantastical
#
# by Derick Fay, 2014-04-06
#
# an adaptation of the Selection to Fantastical Editorial workflow
# (http://editorial-app.appspot.com/workflow/6172238982152192/Y3VYajI3Hzc )
# for use with Drafts and Pythonista (both required)
#
# works on iPhone and iPad
# I have also written an equivalent script for TaskPaper for the Mac
@drdrang
drdrang / clockface
Last active August 4, 2016 21:13
Prints Emoji clockface of the given time rounded to the nearest half-hour. Uses current time if none given. After https://github.com/RobTrew/txtquery-tools/blob/master/utilities/emotime.sh
#!/usr/bin/python
# -*- coding: utf-8 -*-
from sys import argv
from time import strftime
clocks = {'12:00': '🕛', '12:30': '🕧', '1:00': '🕐', '1:30': '🕜',
'2:00': '🕑', '2:30': '🕝', '3:00': '🕒', '3:30': '🕞',
'4:00': '🕓', '4:30': '🕟', '5:00': '🕔', '5:30': '🕠',
'6:00': '🕕', '6:30': '🕡', '7:00': '🕖', '7:30': '🕢',