Add the YouTube domain driver#3
Merged
Merged
Conversation
Blank-import the youtube package from ytb-cli so ant can address videos, channels, playlists, and the rest of YouTube as URIs. The driver registers itself with kit on init, exactly like the goodreads, x, and wikipedia drivers, so every verb works for the youtube:// scheme after a rebuild. Verified end to end: ant domains lists the scheme with its yt/ytb aliases, ant get youtube://video/dQw4w9WgXcQ returns the JSON-LD record with a typed channel edge under @links, and ant resolve maps a youtu.be URL to its URI.
The kit-native rewrite that exposes the youtube.Domain driver has merged and tagged, so move off the kit-native branch pseudo-version onto the release.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add YouTube as an
antdomain by blank-importing theyoutubepackage from ytb-cli. The driver registers itself with kit on init, exactly like the goodreads, x, and wikipedia drivers, so every verb works for theyoutube://scheme after a rebuild.What you can address
Aliases
ytandytb; hostsyoutube.com,youtu.be,music.youtube.com.Verification
Built
antand ran it against youtube.com:ant domainslists theyoutubescheme with itsyt/ytbaliases.ant get youtube://video/dQw4w9WgXcQreturns the JSON-LD record with a typed channel edge under@links.ant resolve "https://youtu.be/dQw4w9WgXcQ"maps the short URL toyoutube://video/dQw4w9WgXcQ.go build ./...,go vet ./...,go test ./...all green.Dependency note
This currently pins ytb-cli at the
kit-nativebranch commit (a pseudo-version), since the kit-native rewrite that exposes theyoutube.Domaindriver is still in review at tamnd/ytb-cli#4. Once that merges and ytb-cli cuts a tag, this should bump to the tagged release before merging.