Skip to content

Instantly share code, notes, and snippets.

View dansheffler's full-sized avatar

Dan Sheffler dansheffler

View GitHub Profile
# Free Will Problem #
Under this heading I mean to separate off those issues of
[[Freedom]] that have to do with the *metaphysical* problem of free
will and determinism. As opposed to political or theological
freedom. This is also distinct from the problem of the compatibility
of free will and divine foreknowledge.
According to [[Peter van Inwagen]]'s proposal we should understand
the "problem of free will" as (I am glossing):
@dansheffler
dansheffler / zettel_link.tmLanguage
Last active May 7, 2021 21:31
A syntax definition for Sublime Text 3 that extends Academic Markdown to include my own wiki-style links
tell application "Skim"
set theFile to the file of the front document
set outText to ""
set newLine to ASCII character 10
# Get the relevant bibliographic information for the front PDF in Skim
tell application "BibDesk"
repeat with currentPub in publications of front document
if linked file of currentPub is {} then
set bibFile to 0
@dansheffler
dansheffler / skimmer.scpt
Last active June 26, 2019 20:44
Applescript for system-wide URL integrating Skim and Bibdesk
on open location skimmerURL
set oldDelims to AppleScript's text item delimiters
set newDelims to {"sk://", "#"}
set AppleScript's text item delimiters to newDelims
set bibKey to item 2 of the text items of skimmerURL
set pdfPage to item -1 of the text items of skimmerURL as integer
set AppleScript's text item delimiters to oldDelims
@dansheffler
dansheffler / default.tex
Last active June 26, 2019 17:44
default.latex
%!TEX TS-program = xelatex
%!TEX encoding = UTF-8 Unicode
\RequirePackage{etoolbox}
% $if(documentclass)$
% $if(classoption)$
% \documentclass[$for(classoption)$$classoption$$sep$,$endfor$)]{$documentclass$}
% $else$
% \documentclass[12pt,oneside]{$documentclass$}
% $endif$
@dansheffler
dansheffler / MyWiki.py
Created May 7, 2015 10:54
MyWikiLinks
import sublime, sublime_plugin, os, re, subprocess
class FollowWikiLinkCommand(sublime_plugin.TextCommand):
def run(self, edit):
settings = sublime.load_settings('MyWiki.sublime-settings')
directory = settings.get('wiki_directory')
directory = os.path.expanduser(directory)
extension = settings.get('wiki_extension')
@dansheffler
dansheffler / jQueryWordcountStyle.html
Last active June 18, 2019 03:23
Style Blockquotes based on Wordcount
<script src="/js/jquery-1.8.3.min.js"></script>
// A little clever jQuery styling of blockquotes
<script>
$('blockquote p').each(function(){
var $numWords = $(this).text().split(" ").length;
console.log($numWords)
@dansheffler
dansheffler / pandoc.sublime-build
Created July 12, 2016 16:20
Pandoc Build System
{
"selector": "text.html.markdown",
"path": "C:\\Users\\Dan\\AppData\\Local\\Pandoc\\;C:\\Program Files (x86)\\MiKTeX 2.9\\miktex\\bin\\",
"cmd": ["pandoc",
"--smart",
"--chapters",
"--template=C:\\Users\\Dan\\Dropbox\\Pandoc\\default.latex",
"--csl=C:\\Users\\Dan\\Dropbox\\Pandoc\\default.csl",
"--bibliography=C:\\Users\\Dan\\Dropbox\\Jabref\\mybib.bib",
"--latex-engine=xelatex",
[
{ "keys": ["ctrl+super+f"], "command": "make_footnote"}
]
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLName</key>
<string>Skimmer</string>
<key>CFBundleURLSchemes</key>
<array>
<string>sk</string>
</array>
</dict>