Slide 3 of 74

Every command

$ hive emit hello.hive > main.go

$ hive check hello.hive --verbose
hive: `hive check` takes an entrypoint and nothing else. `--verbose` was given to it.

$ hive chekc hello.hive
hive: `chekc` is not a command. `hive` alone lists the ones there are.

$ hive build
hive: `hive build` needs an entrypoint: `hive build <entrypoint.hive>`.

Seven commands take an entrypoint, and each is taught later where it belongs:

  • hive check, hive run and hive build — the three above. build also takes --target <goos>/<goarch> to build for another platform.
  • hive test runs every test block the program reaches, and reports coverage.
  • hive emit prints the Go a program compiles to, and needs no Go toolchain.
  • hive analyze scores what each proc and func will cost to run, lists what the program declares and never reaches, and writes a page of findings beside the entrypoint.
  • hive container writes a Dockerfile that builds the program and runs it.
  • hive export --target android/arm64 packages a windowed program as an installable Android app.

Two take nothing: hive version prints which release this is, and hive agents writes .hivedocs/ — a page per feature for a coding agent to read — into the current folder. hive alone lists all of them.

A command refuses anything it does not take, rather than ignoring it: a flag it has no use for, a second file, a command that does not exist. Those mistakes are in what was typed rather than in any source, so their messages say who is complaining — hive: — and exit non-zero.