Skip to content

Instantly share code, notes, and snippets.

View tsaiid's full-sized avatar

I-Ta Tsai tsaiid

View GitHub Profile
@tsaiid
tsaiid / PreviewMarkdownService.scpt
Last active October 30, 2015 11:26
AppleScript to preview Markdown with Marked 2 in Evernote
on run
tell application "Evernote"
if selection is not {} then
set nbsp to «data utxt00A0» as Unicode text
set tmp_file to POSIX path of (((path to documents folder) as text) & "EvernoteSelectionTmp.md")
set this_file to POSIX path of (((path to documents folder) as text) & "EvernoteSelection.md")
set the_selection to selection
set the_title to title of item 1 of the_selection
@tsaiid
tsaiid / everwatch.rb
Last active August 29, 2015 14:27
Watch Evernote for updates and put the current content of the editor into a preview file for Marked 2.app
#!/usr/bin/env ruby
# Modified from everwatch.rb by Brett Terpstra, 2011
# http://brettterpstra.com/2011/11/14/marked-scripts-nvalt-evernote-marsedit-scrivener/
# http://support.markedapp.com/kb/how-to-tips-and-tricks/marked-bonus-pack-scripts-commands-and-bundles
# Modified from everwatch.rb by regedor, 2014
# https://github.com/regedor/everwatch
#
# Watch Evernote for updates and put the current content of the editor into a preview file for Marked 2.app
account = ARGV[0] || ENV['EVERWATCH_ACCOUNT'] || ENV["USER"]
@tsaiid
tsaiid / default.custom.yaml
Created July 4, 2015 12:51
鼠鬚管自訂檔
patch:
schema_list:
- schema: boshiamy_t
- schema: boshiamy_j
@tsaiid
tsaiid / squirrel.custom.yaml
Last active September 9, 2015 03:36
鼠鬚管外觀設定
patch:
style/font_face: "Source Han Sans TC Light"
style/font_point: 18
style/color_scheme: starcraft
# 註:預設的配色方案及代碼(指定爲 style/color_scheme )
# 碧水 - aqua
# 青天 - azure
# 明月 - luna
# 墨池 - ink
@tsaiid
tsaiid / boshiamy_t.custom.yaml
Last active August 29, 2015 14:24
用注音反查嘸蝦米
patch:
schema/dependencies:
- bopomofo
reverse_lookup:
dictionary: terra_pinyin
prism: bopomofo
prefix: "`"
suffix: "'"
tips: 〔注音〕
preedit_format:
@tsaiid
tsaiid / smartwonder-activate-current-image-window.ahk
Created February 11, 2015 05:44
Move mouse to SmartIris to activate current image, and then confirm the report (^k)
;;; Move mouse to SmartIris to activate current image, and then confirm the report (^k).
$^k::
MouseGetPos, xpos,ypos
MouseMove, 1919, 0
SetMouseDelay, 250
MouseMove, 1921, 0
SetMouseDelay, 0
MouseMove, %xpos%, %ypos%
Send ^k
return
diff --git a/src/setup/win32/Include.wxi b/src/setup/win32/Include.wxi
index 91eda56..5f6b0bb 100644
--- a/src/setup/win32/Include.wxi
+++ b/src/setup/win32/Include.wxi
@@ -26,6 +26,6 @@
<?define UpgradeGuid="$(var.UpgradeGuid32)" ?>
<?endif?>
- <?define CRT="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC100_CRT_$(var.Platform).msm" ?>
+ <?define CRT="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC120_CRT_$(var.Platform).msm" ?>
diff --git a/ext/CMakeLists.txt b/ext/CMakeLists.txt
index d7f0ca2..752a173 100644
--- a/ext/CMakeLists.txt
+++ b/ext/CMakeLists.txt
@@ -4,7 +4,7 @@
# This package is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# found in the file COPYING that should have accompanied this file.
-#
+#
diff --git a/ext/toolchain/commands1.py b/ext/toolchain/commands1.py
index d0b0960..4c7eba0 100644
--- a/ext/toolchain/commands1.py
+++ b/ext/toolchain/commands1.py
@@ -451,16 +451,17 @@ class InternalCommands:
cmake_args += ' -DCMAKE_BUILD_TYPE=' + target.capitalize()
elif sys.platform == "darwin":
- macSdkMatch = re.match("(\d+)\.(\d+)", self.macSdk)
- if not macSdkMatch:
@tsaiid
tsaiid / RandRanges
Last active August 29, 2015 14:08
Rank a selected range by rand in Excel
Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
Function ExistInSelection(criteria) As Boolean
For Each a In Selection.Areas
If WorksheetFunction.CountIf(a, criteria) Then
ExistInSelection = True
Exit Function
End If
Next
ExistInSelection = False