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
// Note that this script will remove all permissions of all files and subfolders | |
// (including files in subfolders) of the given folder | |
// https://drive.google.com/drive/folders/abcdefgh | |
const id = "abcdefgh"; | |
function start() { | |
const folder = DriveApp.getFolderById(id); | |
getSubFolders(folder); | |
// At the end, reset for parent folder |
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
import gzip | |
import shutil | |
import hashlib | |
import os | |
original_file = "file/path" | |
zipped_file = "file/path" | |
unzipped_file = "file/path" | |
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
let isInProgress = true; | |
const PAGE_DURATION = 90000; // as milliseconds | |
const BUTTON_TITLE = "Next Page"; | |
const getElement = selector => document.querySelector(selector); | |
setInterval(() => { | |
if (isInProgress && getElement(`[title="${BUTTON_TITLE}"]`)) { | |
isInProgress = false; | |
setTimeout(() => { | |
getElement(`[title="${BUTTON_TITLE}"]`).click(); |
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
// Put the ID of the folder you want to process | |
// https://drive.google.com/drive/folders/abcdefgh | |
const id = "abcdefgh"; | |
// we will store file names in this dictionary. | |
// using Set could be more efficient to check if it contains file (time complexity: O(1)) | |
// App Script does not support Set | |
const allFiles = []; | |
// Keep deleted file URLs and report in the end |