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
| # handle (most of) the color/encoding issues w/ using vim+solarized+tmux under crouton in the chrome shell window | |
| export TERM=xterm-256color | |
| export LC_ALL=en_US.utf-8 | |
| export LC_LANG=en_US.utf-8 | |
| tmux -2 |
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
| import json | |
| import click | |
| from jinja2 import Environment, FileSystemLoader, StrictUndefined | |
| @click.command() | |
| @click.argument('template_file') | |
| @click.argument('data_file') | |
| def main(template_file, data_file): | |
| env = Environment(loader=FileSystemLoader(searchpath='.'), undefined=StrictUndefined) |
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
| /* | |
| * Scrapes text Q&A data out of a Quizlet deck list view | |
| * | |
| * usage: paste this function into developer console, then | |
| * copy(scrape_quizlet()) to get a JSON string on | |
| * the clipboard. | |
| */ | |
| function scrape_quizlet() { | |
| var get_text = function(i,elem) { return jQuery(elem).text(); }; |
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 ConCat(Delimiter As Variant, ParamArray CellRanges() As Variant) As String | |
| Dim Cell As Range, Area As Variant | |
| If IsMissing(Delimiter) Then Delimiter = "" | |
| For Each Area In CellRanges | |
| If TypeName(Area) = "Range" Then | |
| For Each Cell In Area | |
| If Len(Cell.Value) Then ConCat = ConCat & Delimiter & Cell.Value | |
| Next | |
| Else | |
| ConCat = ConCat & Delimiter & Area |
NewerOlder