This Gist is there to help you creating a Sankey Diagram from your Google Spreadsheets.
- Open a spreadsheet
- Click "Tools" -> "Scripts"
| /** | |
| * @param {SheetsOnEdit} e - edit event object | |
| */ | |
| function onEdit(e) { | |
| /** | |
| * @typedef {Object} MultiDropDown | |
| * @property {String} namedRange | |
| * @property {Number} handlingDuplicates | |
| * @property {String} separator | |
| * @property {Boolean} sortResult |
| /System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -dump | grep uti: | cut -c 29- | sort | uniq > utis.txt |
Hello and welcome to my Shortcuts Catalog!
This is a public resource designed to help people get started with Siri Shortcuts and the Shortcuts app.
It’s made up of the Shortcuts Library, a collection of over 125+ shortcuts grouped into folders, and the Action Directory, a documentation of 125+ of the actions in the Shortcuts app used to build shortcuts.
Enjoy!
This is a sample script for uploading a file to Google Drive from the external HTML without the authorization. In this case, the client side can be used at the outside of Google. And as the server side, the Web Apps created by Google Apps Script is used.
Please do the following flow.
| function parseXML(string) { | |
| /* | |
| * Part 1 | |
| * | |
| * Parse the xml into a DOM-like json | |
| * | |
| * Input: <tag attribute="value">text node<inline>text node</inline>text node</tag> | |
| * | |
| * Output: | |
| * { |
This is a sample script for notifying the new release of Google APIs and Google Apps Script with an email using Google Apps Script.
Recently, I published a sample script of "Retrieving Release Notes of Google Apps Script and Google APIs from RSS using Google Apps Script". After this was published, I got an email that it wants to automatically notice the new release of Google APIs and Google Apps Script with an email. From this, I prepared a sample script as follows.
Please set your email address to email in main. When you use this script, please manually run main function. By this, at 1st run, the new release in one month is checked as a test. And, the current date is stored in the PropertiesService. When you want to automatically obtain the notific
| /* | |
| To use you need to create an application on Github at https://github.com/settings/developers | |
| The callback in this needs to be set to https://script.google.com/macros/d/{SCRIPT ID}/usercallback | |
| Where {SCRIPT ID} is the ID of the script that is using this library. You can find your script's ID in the Apps Script code editor by clicking on the menu item "File > Project properties". | |
| In this example code I've stored the apllicaitons clientId and clientSecret in the Script Properties: | |
| - git_clientId | |
| - git_clientSecret |
| // Thanks to this gist: [Sample HTML/JS to parse a Google Spreadsheet](https://gist.github.com/terrywbrady/a03b25fe42959b304b1e) | |
| var htmlEndPoint = 'https://docs.google.com/spreadsheets/d/e/2PACX-1vREXBtuL2uKofq9ufXsIlytbONUR0-q_tf1Ucm14JpeE5KAdry97CCwvivf3e5NkCAnZ1Xg4qYa0RCo/pubhtml'; | |
| (function($){ | |
| var parseHtmlTableToJson = function($table){ | |
| var data = []; | |
| var $headers = $("tr:first-child td", $table); | |
| var headers = []; |
| /* | |
| How to setup | |
| ============ | |
| 1. Go to https://script.google.com and login | |
| 2. Click New Project | |
| 3. Give the project a name be clicking on "Untitled Project" and giving a new name | |
| 4. Copy this whole code and overwrite everything on Code.gs file. Click on the Save icon to save. | |
| 5. Go to Google drive and open the worksheet that you want to manipulate | |
| 6. Take a look at the url. It should be in this format -- https://docs.google.com/spreadsheets/d/spreadheet-id-as-some-long-seemingly-random-characters/edit#gid=478439860 |