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 overdueCheck() { | |
| var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
| var sheet = ss.getSheetByName("Data"); | |
| // var values = sheet.getRange("J2:J").getValues(); | |
| var values = sheet.getRangeByName("FollowUp").getValues(); | |
| var today = new Date(); | |
| var todays = today.getTime(); | |
| var TO = "foo@domain.com"; | |
| var URL = "https://docs.google.com/spreadsheets/d/1hMZnkvsVE1B_9X37V-WH6o7dYmX_BoHxwP2YCY8DOWE/edit#gid=0"; | |
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 onEdit(e) { | |
| var range = e.range; | |
| var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
| var target = "Data"; | |
| var sheet = ss.getSheetByName(target); | |
| var datestamp = Utilities.formatDate(new Date(), "PST", "dd/MM/yyyy hh:mm:ss a"); | |
| // SpreadsheetApp.getUi().alert("Edited in A1 Notation is: " + range.getA1Notation() + "\nDatestamp: " + datestamp ); //If you're having problems, uncomment this to make sure your named range is properly defined | |
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
| #!/bin/sh | |
| # echo "RSS feed?" | |
| # read FeedName | |
| domain="https://ramahnorcal.smugmug.com" | |
| if [ "$1" = "1" ]; then | |
| path="/hack/feed.mg?Type=gallery&Data=194176300_3dMVQd&format=rss200" | |
| foldername="Day 1" | |
| elif [ "$1" = "2" ]; then |
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 onEdit(e) { | |
| var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
| var sName = ss.getSheetName(); | |
| var target = 'Data' | |
| Logger.log('Starting script...'); | |
| if (sName == target){ | |
| Logger.log('The sheet name: "' + target +'" was edited.'); | |
| var destSheet = ss.getSheetByName(target); |
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/env bash | |
| # Configure/Initialize | |
| # Configure/Initialize | |
| # read sensitive data from local files. Example: | |
| # KEY=value | |
| BASEDIR=$(dirname "$0") | |
| APIKEY="$(cat $BASEDIR/arrisdata.txt | grep API | cut -f2 -d "=" )" | |
| USER="$(cat $BASEDIR/arrisdata.txt | grep USER | cut -f2 -d "=" )" | |
| PASS="$(cat $BASEDIR/arrisdata.txt | grep PASS | cut -f2 -d "=" )" |
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 DeleteOldFiles() { | |
| var Folders = new Array( | |
| 'insert dir ID', //Entry | |
| 'insert dir ID', //Garage | |
| 'insert dir ID' //Kitchen | |
| ); | |
| var Files; | |
| Logger.clear(); | |
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 importData() { | |
| var fSource = DriveApp.getFolderById('enter ID Here'); // reports_folder_id = id of folder where csv reports are saved | |
| var fi = fSource.getFilesByName('report.csv'); // latest report file | |
| var ss = SpreadsheetApp.openById('enter ID here'); // data_sheet_id = id of spreadsheet that holds the data to be updated with new report data | |
| // Convert CSV > Google Sheet | |
| if ( fi.hasNext() ) { // proceed if "report.csv" file exists in the reports folder | |
| var file = fi.next(); | |
| // Logger.log('starting point: ' + file.getName()); | |
| Drive.Files.copy({}, file.getId(), {convert: true}); |
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 importData() { | |
| var fSource = DriveApp.getFolderById('1x_iNzrNZDfgWz1MykMiADa_7Yd0kMtln'); // reports_folder_id = id of folder where csv reports are saved | |
| var fi = fSource.getFilesByName('report.csv'); // latest report file | |
| var ss = SpreadsheetApp.openById('1BkLfWzBB9WFmUxkBtM8ID43Y34nO9kC0IpjSZQ5aCBA'); // data_sheet_id = id of spreadsheet that holds the data to be updated with new report data | |
| // Convert CSV > Google Sheet | |
| if ( fi.hasNext() ) { // proceed if "report.csv" file exists in the reports folder | |
| var file = fi.next(); | |
| // Logger.log('starting point: ' + file.getName()); | |
| Drive.Files.copy({}, file.getId(), {convert: true}); |
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 importData() { | |
| var fSource = DriveApp.getFolderById('1x_iNzrNZDfgWz1MykMiADa_7Yd0kMtln'); // reports_folder_id = id of folder where csv reports are saved | |
| var fi = fSource.getFilesByName('report.csv'); // latest report file | |
| var ss = SpreadsheetApp.openById('1BkLfWzBB9WFmUxkBtM8ID43Y34nO9kC0IpjSZQ5aCBA'); // data_sheet_id = id of spreadsheet that holds the data to be updated with new report data | |
| // Convert CSV > Google Sheet | |
| if ( fi.hasNext() ) { // proceed if "report.csv" file exists in the reports folder | |
| var file = fi.next(); | |
| // Logger.log('starting point: ' + file.getName()); | |
| Drive.Files.copy({}, file.getId(), {convert: true}); |
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/env bash | |
| MACH=$(hostname -s) | |
| tool="$HOME/Documents/Applications/bin/osx-cpu-temp" | |
| if [ ! -f ${tool} ]; then | |
| echo -e "\n\nSorry, you need to install osx-cup-temp on \"$MACH\" for this to function.\n Check https://github.com/lavoiesl/osx-cpu-temp\n" | |
| exit | |
| fi |