Skip to content

Add list and search commands for MIT OpenCourseWare#1

Merged
tamnd merged 1 commit into
mainfrom
feat/list-search
Jun 14, 2026
Merged

Add list and search commands for MIT OpenCourseWare#1
tamnd merged 1 commit into
mainfrom
feat/list-search

Conversation

@tamnd

@tamnd tamnd commented Jun 14, 2026

Copy link
Copy Markdown
Owner

Summary

  • Parse OCW sitemap.xml (361KB, 2577 courses) to extract course number, title, term, and slug
  • ocwmit list returns up to 50 courses by default (configurable with -n)
  • ocwmit search <query> filters client-side by title, number, or term; default limit 20
  • All output formats supported: table, json, jsonl, csv, tsv, url, raw

Test plan

  • go build ./... passes
  • go test ./... passes (TestList, TestListLimit, TestSearch)
  • ocwmit list -o table shows courses in tabular format
  • ocwmit search ethics returns the ethics for engineers course

Parses the OCW sitemap.xml (2577 courses) to extract course number, title,
term and slug. list shows up to 50 by default, search filters client-side
by title, number or term with a default limit of 20.
@tamnd tamnd merged commit ad6ac97 into main Jun 14, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant