Skip to content

Instantly share code, notes, and snippets.

@akirk
akirk / .profile
Created February 26, 2013 10:09
except from my ~/.profile . i use this all the time!
# change directory to the currently open finder window.
cdf () {
currFolderPath=$( /usr/bin/osascript << EOT
tell application "Finder"
try
set currFolder to (folder of the front window as alias)
on error
set currFolder to (path to desktop folder as alias)
end try
POSIX path of currFolder
<!DOCTYPE html>
<html>
<head>
<title></title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<script type="text/javascript">
var I18n = {
l: function() {}
};
</script>
@akirk
akirk / qtranslate_core.php.diff
Last active August 29, 2015 13:59
Proper fix for qTranslate plugin for Wordpress 3.9
diff --git i/public/wp-content/plugins/qtranslate/qtranslate_core.php w/public/wp-content/plugins/qtranslate/qtranslate_core.php
index 17b4669..b4c49cf 100644
--- i/public/wp-content/plugins/qtranslate/qtranslate_core.php
+++ w/public/wp-content/plugins/qtranslate/qtranslate_core.php
@@ -455,9 +455,9 @@ function qtrans_strftime($format, $date, $default = '', $before = '', $after = '
return $before.strftime($format, $date).$after;
}
-function qtrans_dateFromPostForCurrentLanguage($old_date, $format ='', $before = '', $after = '') {
+function qtrans_dateFromPostForCurrentLanguage($old_date, $format ='') {