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
# Example of querying amenity=bicycle_parking using direct overpass query in r | |
# Limiting output based on existing area from Overpass API | |
# Documentation - see: | |
# https://docs.ropensci.org/osmdata/articles/osmdata.html#extracting-osm-data-from-a-query | |
# https://docs.ropensci.org/osmdata/reference/osmdata_sf.html | |
# set up packages | |
install.packages("osmdata") | |
install.packages("glue") |
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
/** | |
* Returns the intersection of two ranges, or null if there is no overlap. | |
* @param {SpreadsheetApp.Range} r1 Range 1 | |
* @param {SpreadsheetApp.Range} r2 Range 2 | |
* @returns {SpreadsheetApp.Range} | |
*/ | |
function Intersect(r1, r2) { | |
if (r1.getSheet().getSheetId() !== r2.getSheet().getSheetId()) return null; | |
const FIRSTROW = Math.max(r1.getRow(), r2.getRow()); |
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
// INSTRUCTIONS | |
// 1. Go to https://script.google.com/ and make a new project | |
// (optional: rename it too, so you remember what it is later...) | |
// 2. Paste in this script and add your email and playlist IDs below (see note [1]) | |
// 3. Save the script and do a test run to set up the permissions | |
// 4. Set up a trigger to run the check_playlists_youtube function every day | |
function check_playlists_youtube() { | |
// OPTIONS: specify playlists to check and email to notify | |
const PLAYLISTS = { |
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
/* | |
Sorry Counter | |
============= | |
Instructions: | |
- go to script.google.com | |
- new project | |
- paste this in, save, select "run" | |
- give the script permissions to search your email | |
- enjoy learning how apologetic you are |