This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- This script automatically `cd`s to the directory of the current document. | |
| -- You can use $f to represent the file for the current document. | |
| -- This is nowhere near perfect, just a quick and dirty script. | |
| -- NOTE: you need to have "Enable access for assistive devices" checked... | |
| -- in the Accessibility preference pane. | |
| -- Example: select a file in Finder, and type: echo The filename is $f | |
| on getCurrentDocument() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Requirements: | |
| # - python-lxml | |
| # - pyquery | |
| # | |
| # As implemented in http://mybucket.co | |
| # html_util.py | |
| from pyquery import PyQuery as pq | |
| def extract_delicious_data_from_html(html): | |
| results = [] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Hash | |
| def downcase_all_keys | |
| result = self.map do |k,v| | |
| [ | |
| k.downcase, | |
| case v.class.name | |
| when "Hash" then v.downcase_all_keys | |
| when "Array" then v.map {|i| i.downcase_all_keys } | |
| else v | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * CloudExtension and factory for creating CloudExtension instances. | |
| * Example: | |
| * {{{ | |
| * val application = CloudExtension(system, config) | |
| * }}} | |
| * | |
| * @author Helena Edelson | |
| */ | |
| object CloudExtension extends ExtensionId[CloudExtension] with ExtensionIdProvider { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function customize_theme(){ | |
| // set the custom properties here | |
| // the keys of custom_theme must be css selectors. | |
| // the values of custom_theme must be: | |
| // if the key (css selector) already exist in the Visual Studio Code stylesheet, the value must be an object with css property-values. | |
| // else (if the key doesn't exist yet), the value it must be a string with the inner text of a Css rule. | |
| var custom_theme = { | |
| /*'.monaco-workbench.vs-dark .explorer-viewlet .monaco-tree .monaco-tree-row > .content .explorer-item.folder-icon': { background: 'linear-gradient(to right, rgba(109,109,72,0.42) 0%,rgba(209,211,96,0) 14%)', color: '#B5B580'},*/ | |
| '.monaco-workbench.vs-dark .explorer-viewlet .monaco-tree .monaco-tree-row > .content .explorer-item.folder-icon': { color: '#B5B580', 'font-weight': 'bold'}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #coding: utf-8 | |
| from bottle import route, error, post, get, run, static_file, abort, redirect, response, request, template | |
| @route('/') | |
| @route('/index.html') | |
| def index(): | |
| return '<a href="/hello">Go to Hello World page</a>' | |
| @route('/hello') | |
| def hello(): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Your Stylesheet | |
| * | |
| * This stylesheet is loaded when Atom starts up and is reloaded automatically | |
| * when it is changed. | |
| * | |
| * If you are unfamiliar with LESS, you can read more about it here: | |
| * http://www.lesscss.org | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! /usr/bin/python2 | |
| import gtk.gdk | |
| w = gtk.gdk.window_foreign_new( gtk.gdk.get_default_root_window().property_get("_NET_ACTIVE_WINDOW")[2][0] ) | |
| w.set_decorations( (w.get_decorations()+1)%2 ) # toggle between 0 and 1 | |
| gtk.gdk.window_process_all_updates() | |
| gtk.gdk.flush() | |
| # now bind this to super-r or something |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This example will make Adobe Source Code Pro font look snug in TextMate. | |
| # Adjust space above the line | |
| defaults write com.macromates.TextMate.preview fontAscentDelta -float -2 | |
| # Adjust space below the line | |
| defaults write com.macromates.TextMate.preview fontLeadingDelta -float 0 | |
| # Reset to default | |
| defaults delete com.macromates.TextMate.preview fontAscentDelta |
OlderNewer