Some checks failed
smoke-mm / Install & smoke test mm --help (push) Has been cancelled
1.9 KiB
1.9 KiB
Quick Reference: get-url URL Search
Basic Syntax
# Search mode (new)
get-url -url "pattern"
# Original mode (unchanged)
@1 | get-url
Examples
Exact domain match
get-url -url "google.com"
Matches: https://www.google.com, http://google.com/search, https://google.com/maps
YouTube URL search
get-url -url "https://www.youtube.com/watch?v=xx_88TDWmEs"
Normalizes to: youtube.com/watch?v=xx_88tdwmes
Matches: Any video with same ID across different protocols
Wildcard domain
get-url -url "youtube.com*"
Matches: All YouTube URLs (videos, shorts, playlists, etc.)
Subdomain wildcard
get-url -url "*.example.com*"
Matches: cdn.example.com, api.example.com, www.example.com
Specific path pattern
get-url -url "youtube.com/watch*"
Matches: Only YouTube watch URLs (not shorts or playlists)
Single character wildcard
get-url -url "example.com/file?.mp4"
Matches: example.com/file1.mp4, example.com/fileA.mp4 (not file12.mp4)
How It Works
- Normalization: Strips
https://,www.prefix from pattern and all URLs - Pattern Matching: Uses
*and?wildcards (case-insensitive) - Search: Scans all configured stores for matching URLs
- Results: Groups matches by store, shows URL and hash
Return Values
- Exit code 0 if matches found
- Exit code 1 if no matches or error
Piping Results
get-url -url "youtube.com*" | grep -i video
get-url -url "example.com*" | add-tag -tag "external-source"
Common Patterns
| Pattern | Matches | Notes |
|---|---|---|
google.com |
Google URLs | Exact domain (after normalization) |
youtube.com* |
All YouTube | Wildcard at end |
*.example.com* |
Subdomains | Wildcard at start and end |
github.com/user* |
User repos | Path pattern |
reddit.com/r/* |
Subreddit | Path with wildcard |