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
import os | |
import fire | |
import toml | |
import yaml | |
def merge_a_into_b(a, b): | |
# merge dict a into dict b. values in a will overwrite b. | |
for k, v in a.items(): | |
if isinstance(v, dict) and k in b: |
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
import argparse | |
import os | |
import time | |
import random | |
from pathlib import Path | |
import yt_dlp | |
from yt_dlp import DownloadError | |
import timeout_decorator | |
from timeout_decorator.timeout_decorator import TimeoutError |
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
#!/usr/bin/env bash | |
# Please first configure your ~/.config/youtube-dl/config | |
# Specifically add aria2c for parallel download | |
# e.g., | |
# --external-downloader aria2c | |
# --external-downloader-args '-c -j 3 -x 3 -s 3 -k 1M' | |
if [[ $# < 1 ]]; then | |
echo -e "Input: [.csv file] [download path] [proxy]" |
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
# 1. install neovim | |
echo "[step 1] installing neovim" | |
if command -v nvim > /dev/null; then | |
echo "nvim has been installed" | |
else | |
NVIM_HOME="$HOME/modules/neovim" | |
printf "Neovim will be installed into this location:\\n" | |
printf "%s\\n" "${NVIM_HOME}" |
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
" Specify a directory for plugins | |
" - For Neovim: ~/.local/share/nvim/plugged | |
" - Avoid using standard Vim directory names like 'plugin' | |
call plug#begin('~/.vim/plugged') | |
set clipboard=unnamedplus " Use system clipboard | |
set cursorline " Highlight the cursor line | |
set hlsearch |