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
| module TaskDbConnector | |
| module Connector | |
| def self.task_runner(block, params = {}) | |
| if params[:tenant].blank? | |
| db_configs = db_configurations | |
| if db_configs.is_a?(Hash) && db_configs.values.first.is_a?(String) | |
| # Single database case | |
| run_rake(block, params.merge(tenant: Rails.env)) | |
| else |
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 searchMails(searchQuery) { | |
| return GmailApp.search(searchQuery, 0, 100); | |
| } | |
| function moveEmailsToTrash(emailThread) { | |
| emailThread.moveToTrash(); | |
| } | |
| function deleteEmailsPermanently(emailThread) { | |
| Gmail.Users.Threads.remove('me', emailThread.getId()); |
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 doGet(req) { | |
| let spreadsheet = SpreadsheetApp.getActiveSpreadsheet(); | |
| let personalDetails = spreadsheet.getSheetByName('personal-details'); //sheet name is personal-details | |
| let personalDetailsValues = personalDetails.getDataRange().getValues(); //reading the sheet data(2D array of sheet data) | |
| /* | |
| personalDetailsValues output | |
| [ [ 'First Name', 'Nikhil' ], | |
| [ 'Last Name', 'Bhatt' ], | |
| [ 'Email', 'nikhilbhatt931@gmail.com' ] ] |
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
| javascript:(function(){setInterval(()=>{const skipButton = document.querySelector('.ytp-ad-skip-button'); const adOverlay= document.querySelector('.ytp-ad-overlay-close-container'); if(adOverlay !=undefined) adOverlay.click(); if(skipButton != undefined) skipButton.click();}, 2000)})(); |