Thanks to https://www.alec.fyi/set-up-google-sheets-apis-and-treat-sheets-like-a-database.html
This file contains 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
/** | |
* Compares two objects and returns the differences, or null if they're the same | |
* @param {Object} original - Original form data | |
* @param {Object} current - Current form data | |
* @returns {Object|null} Object containing only the changed fields, or null if no changes | |
*/ | |
function getObjectDiff(original, current) { | |
const changes = {}; | |
for (const [key, value] of Object.entries(current)) { |
To access the Sheets API, you will need to enable the Sheets API, obtain credentials, and grant access to your Sheet.
Based on these instructions
- Open the Google Developers Console
- Select your project or create a new one (and then select it)
(Inspired by https://medium.com/@icanhazedit/clean-up-unused-github-rpositories-c2549294ee45#.3hwv4nxv5)
-
Open in a new tab all to-be-deleted github repositores (Use the mouse’s middle click or Ctrl + Click) https://github.com/username?tab=repositories
-
Use one tab https://chrome.google.com/webstore/detail/onetab/chphlpgkkbolifaimnlloiipkdnihall to shorten them to a list.
-
Save that list to some path
-
The list should be in the form of “ur_username\repo_name” per line. Use regex search (Sublime text could help). Search for ' |.*' and replace by empty.