Skip to content

Instantly share code, notes, and snippets.

View jobdiogenes's full-sized avatar

Job Diógenes Ribeiro Borges jobdiogenes

View GitHub Profile
@jobdiogenes
jobdiogenes / demo-of-use-google-drive-sheets-in-r-with-google-colaboratory.ipynb
Last active August 14, 2024 14:01
Demo of use Google Drive/Sheets in R with Google Colaboratory.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jobdiogenes
jobdiogenes / data_science_gist_03_pt.ipynb
Last active August 28, 2019 13:57
data_science_gist_03_pt
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jobdiogenes
jobdiogenes / data_science_gist_02_pt.ipynb
Last active August 21, 2019 02:41
data_science_gist_02_pt
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jobdiogenes
jobdiogenes / data-science-gist-01-pt.ipynb
Created August 4, 2019 19:34
data-science-gist-01-pt.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

SheetConverter library (formerly "Spreadsheet to HTML")

This is the source repository for the SheetConverter Google Apps Script library.

Libary documentation is available here.

Caveats

This script is incomplete, ignoring some types of formatting. (Feel free to fork and enhance it, if you wish! Broadly applicable enhancements can be merged and the library updated) There are also some known issues:

@jobdiogenes
jobdiogenes / outerLoop.js
Created March 5, 2017 23:40 — forked from peterherrmann/outerLoop.js
outerLoop for Google Apps Script triggered functions is some boilerplate that encapsulates best practice ways to deal with running workloads that may take longer to process that the time available in an Apps Script triggered run.
//load configuration details and start logging - creates and sets up sheets the first time they are run
var CONFIG_SPREADSHEET_KEY = '<ssid_goes_here>';
var Config = SettingsManager.load(CONFIG_SPREADSHEET_KEY); //Add Mafviu9bMfg9xVu21LGfpWnHAGDwXQ1CH in Resources > Libraries
Logger = BetterLog.useSpreadsheet(Config['logSpreadsheetId'].value);//Add MYB7yzedMbnJaMKECt6Sm7FLDhaBgl_dE in Resources > Libraries
// trigger this function
function outerLoop() {
try {
// to calc elapsed time
var isOverMaxRuntime = false,
@jobdiogenes
jobdiogenes / xmlToJson.js
Created February 24, 2017 03:00 — forked from erickoledadevrel/xmlToJson.js
A function to convert an XML string to a JSON object in Apps Script, using logic similar to the sunset method Xml.parse().
/**
* Converts an XML string to a JSON object, using logic similar to the
* sunset method Xml.parse().
* @param {string} xml The XML to parse.
* @returns {Object} The parsed XML.
*/
function xmlToJson(xml) {
var doc = XmlService.parse(xml);
var result = {};
var root = doc.getRootElement();
@jobdiogenes
jobdiogenes / xml2json.gs
Created February 24, 2017 02:52 — forked from jupegarnica/xml2json.gs
XML to JSON google apps scripts
/**
* Converts an XML string to a JSON object, using logic similar to the
* sunset method Xml.parse().
* @param {string} xml The XML to parse.
* @returns {Object} The parsed XML.
*/
function XML_to_JSON(xml) {
var doc = XmlService.parse(xml);
var result = {};
var root = doc.getRootElement();
// Available under Creative Commons Attribution-ShareAlike 2.5 UK: Scotland License
// Bashed by mhawksey
var SPREADSHEET_ID = ""; // If using within Google Sites paste the spreadsheet key here (this is everything between key= and &hl in the address bar)
// JavaScript Document
function onOpen() {
if (SPREADSHEET_ID == ""){
var ss = SpreadsheetApp.getActiveSpreadsheet();
var menuEntries = [ {name: "Setup", functionName: "setup"}, {name: "Send Booking Confirmations", functionName: "sendBookingConf"}];