https://sublime.wbond.net/installation#st3
- Source Code Pro -
sourcecodepro.sh - Hack -
hack.sh
| <?php | |
| function getURLs($ticker){ | |
| $content = file_get_content("https://www.valuespreadsheet.com/iedgar/results.php?stock=".$ticker."&output=xml"); | |
| $xml = simplexml_load_string($content); | |
| echo "<pre>"; print_r($xml); echo "</pre>"; | |
| } |
https://sublime.wbond.net/installation#st3
sourcecodepro.shhack.shThis is a helper function that will convert a given PDF file blob into text, as well as offering options to save the original PDF, intermediate Google Doc, and/or final plain text files. Additionally, the language used for Optical Character Recognition (OCR) may be specified, defaulting to 'en' (English).
Note: Updated 12 May 2015 due to deprecation of DocsList. Thanks to Bruce McPherson for the getDriveFolderFromPath() utility.
// Start with a Blob object
var blob = gmailAttchment.getAs(MimeType.PDF);
| function pullJSON() { | |
| var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
| var sheets = ss.getSheets(); | |
| var sheet = ss.getActiveSheet(); | |
| var url="http://example.com/feeds?type=json"; // Paste your JSON URL here | |
| var response = UrlFetchApp.fetch(url); // get feed | |
| var dataAll = JSON.parse(response.getContentText()); // |
| // Create custom menu within Spreadsheet | |
| function onOpen() { | |
| var submenu = [{name:"Save and Email PDF", functionName:"spreadsheetToPDF"}]; | |
| SpreadsheetApp.getActiveSpreadsheet().addMenu('Admin Functions', submenu); | |
| } | |
| // Start spreadsheetToPDF function | |
| function spreadsheetToPDF(key) { | |
| // Authentication stuff |
| /** | |
| * --- Continous Execution Library --- | |
| * | |
| * Copyright (c) 2013 Patrick Martinent | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| // vim: ft=javascript: | |
| /*jslint sloppy: true, vars: true, white: true, nomen: true, browser: true */ | |
| /*global SpreadsheetApp, UiApp, UrlFetchApp, Utilities */ | |
| /* | |
| * A script to automate requesting data from an external url that outputs CSV data. | |
| * | |
| * Adapted from the Google Analytics Report Automation (magic) script. | |
| * @author [email protected] (Nick Mihailovski) | |
| * @author [email protected] (Ian Lewis) | |
| */ |
| /*************************************************** | |
| * Simple and elegant, no code complexity | |
| * Disadvantages: Requires warming all data into server memory (could take a long time for MBs of data or millions of records) | |
| * (This disadvantage should go away as we add optimizations to the core product) | |
| ***************************************************/ | |
| var fb = firebase.database.ref(); | |
| /** | |
| * @param {string} emailAddress |
| /* | |
| ___________________________________________________________________________________ | |
| ***THE FOLLOWING METHOD(s) ARE USING SIMILAR ROUTINES AND ARE CALLED DYNAMICALLY. | |
| THEY REDIRECT TO INTERNAL METHOD(s), THUS, DOCUMENTATION IS STATED HERE*** | |
| ____________________________________________________________________________________ | |
| METHOD(s): addElement/insertElement | |
| DEFINITION: Appends or inserts an element node | |
| PARAMETER(s): |
Google Apps Script for Gmail to automatically forward Google Now notes to self onto Remember The Milk, transforming the transcribed speech into Smart Add syntax, and then archiving the thread in Gmail. Create a new script in Google Drive for Gmail, paste this JS into it, customize the rtm_email variable to your own, and customize the transformations to rtm_task for Smart Add to fit your style, and then set up a trigger to invoke the function every minute. Within approximately a minute after sending yourself a note via Google Now, the reminder will be added to your RTM account!
Example dictation: Note to self to look up article about widgets for work priority 1
Smart Add transformation: Look up article about widgets #work !1