Skip to content

Instantly share code, notes, and snippets.

@simplymathematics
simplymathematics / CopyLikes.md
Created October 7, 2025 00:11 — forked from senecaso/CopyLikes.md
YouTube Music: Copy liked music to a playlist

I was looking for a way to copy my "likes" in YouTube music over to a playlist, in the hopes of stopping YTM from losing songs I have liked. I found this script, but it didn't work for me, so I had to look for other solutions. In the end, this is what worked for me.

It's a small Python script that uses the YTMusic python library to copy tracks from my likes to a new playlist. I will try to outline the steps to run the script, but this will assume some familiarity with Python.

Hopefully this will work for others as well!

from ytmusicapi import YTMusic

yt = YTMusic('oauth.json')
import base64
import json
import os
def export_images(notebook_filepath,
output_directory):
notebook_image_exporter = NotebookImageExporter(notebook_filepath,
output_directory)
@simplymathematics
simplymathematics / bridge-conf
Created May 9, 2019 11:16 — forked from Belphemur/bridge-conf
Configuration and scripts for OpenVPN in Bridged Mode. Script to generate new client (with their keys and configuration file for OpenVPN). Script to manage the bridge. Configuration for systemd to start/stop the OpenVPN with Brige.
#!/bin/bash
# Define physical ethernet interface to be bridged
# with TAP interface(s) above.
eth="eth0"
eth_ip="192.168.42.2"
eth_netmask="255.255.255.0"
eth_broadcast="192.168.42.255"
eth_gateway="192.168.42.1"
eth_mac="XX:XX:XX:XX:XX:XX"
@simplymathematics
simplymathematics / file0.txt
Created February 18, 2017 02:56 — forked from acro5piano/file0.txt
ASUS Chromebook C300MAに、Croutonを使わずにArch Linuxをインストール ref: http://qiita.com/acro5piano/items/af672c9a445b5a23e0f8
cd
rm -f flash_chromebook_rom.sh
curl -O https://johnlewis.ie/flash_chromebook_rom.sh
sudo -E bash flash_chromebook_rom.sh