Skip to content

Instantly share code, notes, and snippets.

View amarilindra's full-sized avatar
💯
Focusing

Amar Ilindra amarilindra

💯
Focusing
View GitHub Profile
@amarilindra
amarilindra / unsubscribe-all-youtube-channels.js
Created April 28, 2023 07:27
This is a JavaScript script for unsubscribing from YouTube channels. The script automatically clicks the unsubscribe button for each channel on the page and removes it from the DOM. The script uses the YouTube DOM elements to perform the unsubscribe action, so it should work regardless of changes to the YouTube website design. To use the script,…
// Get the total number of channels to unsubscribe
var channelCount = document.querySelectorAll("ytd-channel-renderer:not(.ytd-item-section-renderer)").length;
// Call the timer function
unsubscribeTimer();
function unsubscribeTimer() {
// Return if there are no channels left to unsubscribe
if (channelCount === 0) {
return;
@amarilindra
amarilindra / youtube-channel-unsubscriber.js
Last active April 28, 2023 07:34
This code automates the process of unsubscribing from all YouTube channels. When the code runs, it will first fetch all the channels present in the user's YouTube account and then click the "Unsubscribe" button for each channel one by one. The code also logs the process and displays the number of channels unsubscribed out of the total number of …
(async function unsubscribeChannels() {
// Set delay time to wait for confirmation dialog
const UNSUBSCRIBE_DELAY_TIME = 2000
// Function to execute function after delay
const executeAfterDelay = (func, delay) => new Promise((resolve, reject) => {
setTimeout(() => {
func()
resolve()
@amarilindra
amarilindra / split_csv.bat
Created October 21, 2022 11:59
Split CSV Files
split -l 1000 -d FILE_NAME.csv file_
for i in $(find file_*); do mv $i "$i.csv"; done
@amarilindra
amarilindra / slugify_excel
Created October 21, 2022 11:51
Create Slug from Any String in Excel and Google Sheets Without LAMDA
=SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
SUBSTITUTE(
@amarilindra
amarilindra / invite_all_friends_event.js
Created July 30, 2022 06:22
Invite All Facebook Friends to Event
javascript:var geekdashboard = document.getElementsByClassName('_1pt_ _1pu0');
for(var invite=0; invite<geekdashboard.length;invite++) {
geekdashboard[invite].click();
}
@amarilindra
amarilindra / invite_all_friends_page.js
Created July 30, 2022 06:17
Invite All Facebook Friends to Page
javascript:var geekdashboard = document.getElementsByClassName('uiButton _1sm');
for(var invite=0; invite<geekdashboard.length;invite++) {
geekdashboard[invite].click();
}
@amarilindra
amarilindra / Last-upadted-date-genesis
Last active March 24, 2022 06:05
Add this to code to your themes functions.php file to show last modified date in Genesis powered child themes
// Code for showing last updated date in Genesis Child Themes - (www.GeekDashboard.com)
add_filter( 'genesis_post_info', 'gd_post_last_modified_date' );
function gd_post_last_modified_date($post_info) {
if ( !is_page() ) {
$post_info = 'Last Updated on [post_modified_date] by [post_author_posts_link] [post_comments] [post_edit]';
return $post_info;
}
}
@amarilindra
amarilindra / genesis-simple-edit-entry-meta-field
Last active March 24, 2022 06:02
Add this line in Genesis Simple Edits; Entry Meta (above content) field
To show Only Last Modified Date:
Last Updated on [post_modified_date] By [post_author_posts_link] [post_comments] [post_edit]
To show both Published Date and Last Modified Dates:
Published on [post_date], Last Updated on [post_modified_date] by [post_author_posts_link] [post_comments] [post_edit]
@amarilindra
amarilindra / sources.list
Created March 3, 2022 11:12
Installing Firefox Standard Version on ARM-based Chromebooks
[Desktop Entry]
Name=Firefox
Comment=Browse the World Wide Web
GenericName=Web Browser
X-GNOME-FullName=Firefox Web Browser
Exec=/home/USERNAME/firefox/firefox %u
Terminal=false
X-MultipleArgs=false
Type=Application
Icon=firefox-esr
@amarilindra
amarilindra / VM_code.bat
Created November 27, 2018 14:21
Installing macOS (OS X) on Windows 10 PC or Laptop using Virtual Box
cd "C:\Program Files\Oracle\VirtualBox\"
VBoxManage.exe modifyvm "Name of your Virtual Machine" --cpuidset 00000001 000106e5 00100800 0098e3fd bfebfbff
VBoxManage setextradata "Name of your Virtual Machine" "VBoxInternal/Devices/efi/0/Config/DmiSystemProduct" "iMac11,3"
VBoxManage setextradata "Name of your Virtual Machine" "VBoxInternal/Devices/efi/0/Config/DmiSystemVersion" "1.0"
VBoxManage setextradata "Name of your Virtual Machine" "VBoxInternal/Devices/efi/0/Config/DmiBoardProduct" "Iloveapple"
VBoxManage setextradata "Name of your Virtual Machine" "VBoxInternal/Devices/smc/0/Config/DeviceKey" "ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc"
VBoxManage setextradata "Name of your Virtual Machine" "VBoxInternal/Devices/smc/0/Config/GetKeyFromRealSMC" 1