Skip to content

Instantly share code, notes, and snippets.

View chriskyfung's full-sized avatar

Chris K.Y. FUNG chriskyfung

View GitHub Profile
@chriskyfung
chriskyfung / youtube2rss.php
Last active July 19, 2020 04:24 — forked from Skalman/index.php
Dynamic RSS feeds from Youtube links * DOES NOT WORK FOR NEW YOUTUBE FRONTEND *
<?php
if (!isset($_GET['url'])) {
?>
<!DOCTYPE html>
<meta charset="utf-8">
<title>Youtube RSS creator</title>
<form>
<p>Create an RSS feed for the videos on the following page:
<p><input name="url" placeholder="E.g. https://www.youtube.com/user/scishow/videos" style="width: 30em">
@chriskyfung
chriskyfung / fblink_mobile2desktop.user.js
Last active September 2, 2023 11:03
User script to automatically redirect a Facebook mobile link to a desktop version on Chrome and Firefox with Tampermonkey
#myBtn {
height: 100%;
}
.modal {
display: none;
position: fixed;
top: 0px;
left: 0;
width:100%;
height: 100%;
@chriskyfung
chriskyfung / wordpress-plugins-filter.user.js
Last active September 15, 2019 14:51
User script for browsers to filter outdated plugins in wordpress.org
// ==UserScript==
// @name Filter WordPress Outdated Plugins
// @namespace wordpress
// @version 0.1
// @description try to take over the world!
// @author Chris K. Fung
// @match https://wordpress.org/plugins/*
// @grant none
// ==/UserScript==
@chriskyfung
chriskyfung / rclone_<template>.vbs
Last active August 29, 2022 09:56
VBScript for mounting multiple cloud storages (Box, Dropbox and OneDrive) to Windows OS with Rclone
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set colDrives = objFSO.Drives
Dim FlagO, FlagP , WS
FlagO = true
FlagP = true
For Each objDrive in colDrives
if strcomp(objDrive.DriveLetter, "<Drive Letter #1>") = 0 then
FlagO = false
Wscript.Echo "Drive <Drive Letter #1> has already been used!"
elseif strcomp(objDrive.DriveLetter, "<Drive Letter #2>") = 0 then
@chriskyfung
chriskyfung / gmail2gdrive.gs
Last active September 22, 2019 09:31
Google App Script for Copying Attachments from a Gmail Message to Your Google Drive
/**************************************************************************************
* Gmail to Google Drive Template v1.0.0
* Short Desc.:
* - Google App Script for Copying Attachments from a Gmail Message to Your Google Drive
* Description:
* - Search first email thread that matches the subject and has attachement(s), then make a copy of all the attachments to a specific Google Drive folder.
* Services:
* - Gmail
* - Drive
* Author: Chris KY Fung
@chriskyfung
chriskyfung / f5sys-extension.user.js
Last active November 7, 2019 07:48
Userscript for f5sys.com Binary plan calculator extension
// ==UserScript==
// @name binary plan calculator extension
// @namespace https://chriskyfung.github.io
// @version 0.1
// @description Userscript for f5sys.com Binary plan calculator extension
// @author Chris KY Fung (https://chriskyfung.github.io)
// @match http://www.f5sys.com/calculation/binary+plan+calculator
// @grant none
// ==/UserScript==
@chriskyfung
chriskyfung / qwiklabs.jinja
Last active March 26, 2020 02:01
Deployment Template for Configure a Firewall and a Startup Script with Deployment Manager
resources:
- type: compute.v1.instance
name: vm-test
properties:
zone: {{ properties["zone"] }}
machineType: https://www.googleapis.com/compute/v1/projects/{{ env["project"] }}/zones/{{ properties["zone"] }}/machineTypes/f1-micro
disks:
- deviceName: boot
type: PERSISTENT
boot: true
@chriskyfung
chriskyfung / hide-watched-youtube.user.js
Last active May 7, 2020 19:26
Hide Watched YouTube Videos
// ==UserScript==
// @name Hide Watched YouTube Videos
// @namespace https://chriskyfung.github.io/
// @version 0.5.1
// @description Hide 100% watched videos in suggested video grid or list on YouTube
// @author Chris KY Fung (https://chriskyfung.github.io)
// @updateURL https://gist.github.com/chriskyfung/95fe7fe24ae06930f25ce19c4a73c5e8/raw/
// @match https://www.youtube.com/*
// @grant none
// ==/UserScript==
@chriskyfung
chriskyfung / fb-photo-bulk-downloader.user.js
Last active May 12, 2024 19:49
Userscript for batch downloading Facebook photos from facebook with the post link and captions
// ==UserScript==
// @name Facebook photos bulk downloader
// @namespace https://chriskyfung.github.io
// @version 1.0.0
// @description Bulk download Facebook photos from facebook with the post link and captions
// @author Chris KY Fung
// @match https://www.facebook.com/*/photos/*
// @match https://www.facebook.com/photo.php?*
// @match https://www.facebook.com/photo?*
// @match https://www.facebook.com/photo/*