How to query a particular field of brew cask/ formula info?
https://docs.brew.sh/Manpage#cask-command-options-cask
brew cask info github

should work.
--desc is not listed as a valid option for cask.

To specifically check a field in the JSON file /api/cask/github.json (JSON API), use the info command with --json flag and use jq to get the values of a particular field.
While you may find a better way to do it by reading the manual, here's what will work, at least.
brew info --json=v1 github | jq &quot;map(.|.desc)&quot;


https://stedolan.github.io/jq/manual/#Basicfilters
https://docs.brew.sh/Querying-Brew#brew-info---json