Skip to content

Instantly share code, notes, and snippets.

@BlazerYoo
BlazerYoo / index.js
Last active June 17, 2021 23:40
ExpressJs static file server
const express = require('express');
const path = require('path');
const app = express();
const port = 3000;
app.use(express.static(path.join(__dirname + '/files')));
app.get('/', (req, res) => {
res.sendFile(path.join(__dirname + '/files/index.html'));
@BlazerYoo
BlazerYoo / rename_PNG.py
Last active May 14, 2021 10:12
Rename '.PNG' files made from Snipping Tool to '.png'
import os
for f in os.listdir():
if f.endswith('.PNG'):
os.rename(f,os.path.splitext(f)[0]+'.png')
@BlazerYoo
BlazerYoo / count_files.sh
Last active June 28, 2021 02:32
Terminal print number of files in current directory
python -c "import os;print(len(os.listdir(os.getcwd())))"
@BlazerYoo
BlazerYoo / README.md
Created May 7, 2021 07:51 — forked from astamicu/Remove videos from Youtube Watch Later playlist.md
Script to remove all videos from Youtube Watch Later playlist

UPDATED 3.12.2020

The old version of youtube with "disable_polymer" is not working anymore, so the script also stopped working.

Thanks to JanTheDeveloper we have a new working script. Big up!

I just changed the '//span[contains(text(),"Watch later")]', to '//span[contains(text(),"Remove from")]', and it should work for any playlist, not just the watch later one. (thanks to hudsonite for the tip)

setInterval(function () {
 document.querySelector('#primary button[aria-label="Action menu"]').click();
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.