update + yt-dlp

This commit is contained in:
JMARyA 2024-03-13 22:12:02 +01:00
parent 564e956ba4
commit b03d2641c3
Signed by: jmarya
GPG key ID: 901B2ADDF27C2263
2 changed files with 39 additions and 3 deletions

View file

@ -17,7 +17,7 @@ alias cat="bat -p"
alias gfold="gfold -d classic" alias gfold="gfold -d classic"
function hs() { function hs() {
$(cat ~/.zsh_history|sk) rg "$1" ~/.zsh_history
} }
alias notes="codium ~/Notes" alias notes="codium ~/Notes"

View file

@ -18,7 +18,43 @@ function downloadList() {
} }
# info_json VIDEO_FILE # info_json VIDEO_FILE
# View info.json from video file # Extract info.json from video file
function info_json() { function info_json() {
mkvextract -q attachments "$1" "1:/proc/self/fd/1"|jq . mkvextract -q attachments "$1" "1:/proc/self/fd/1"
}
# info_json_url VIDEO_FILE
# Get URL from info.json
function info_json_url() {
info_json "$1" | jq -r .webpage_url
}
# info_json_title VIDEO_FILE
# Get Title from info.json
function info_json_title() {
info_json "$1" | jq -r .title
}
# info_json_desc VIDEO_FILE
# Get description from info.json
function info_json_desc() {
info_json "$1" | jq -r .description
}
# info_json_uploader VIDEO_FILE
# Get uploader from info.json
function info_json_uploader() {
info_json "$1" | jq -r .uploader
}
# info_json_uploader_url VIDEO_FILE
# Get uploader URL from info.json
function info_json_uploader_url() {
info_json "$1" | jq -r .uploader_url
}
# info_json_upload_date VIDEO_FILE
# Get upload date from info.json
function info_json_upload_date() {
info_json "$1" | jq -r .upload_date
} }