Skip to content

Replace r4.channel+track with r4 view? #9

@oskarrough

Description

@oskarrough

Related to the discussion in #8 I'm wondering about changing the commands a bit.

  • r4 view '' -> data to stdout
  • r4 dl '' -> media/files to disk for tracks in that view
  • r4 backup '@channel' -> snapshot bundle, basically a view + plus timestamp
  • remove r4 channel + track

ViewURI is the abstraction. Reuse the one from r4-sync-tests/docs/views.md.

  • r4 view '' is the main read command.
  • r4 view returns one shape:
    {
    "uri": "@ko002 #house?limit=20",
    "channels": [],
    "tracks": []
    }

More notes..

  • view is the export/read story
  • dl is the file/materialization story
  • backup is just a named snapshot format, not a core abstraction
  • no separate export command
  • avoid old channel view / track list --channel style
  • let the URI carry query semantics instead of duplicating them as flags
    Minimal flags for view:
  • --format <text|json|ndjson|sql|m3u>
  • maybe --limit, --order, --direction only if you want CLI overrides on top of URI semantics, but ideally keep those in the URI
    So the UX becomes:
r4 view '@ko002'
r4 view '@ko002 #house?limit=50'
r4 view '@alice;@bob'
r4 dl '@ko002'
r4 backup '@ko002' > ko002.backup.json

Not sure about the @ symbols everywhere. bit annoying, but needed for the view string at least..

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status

    ecosystem-network

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions