Getting startedSlide 3 of 85
3hiveGetting started
Every command
Eight commands take an entrypoint, and each is taught later where it belongs:
hive check,hive runandhive build— the three above.buildalso takes--target <goos>/<goarch>to build for another platform.hive testruns everytestblock the program reaches, and reports coverage.hive emitprints the Go a program compiles to, and needs no Go toolchain.hive analyzescores what eachprocandfuncwill cost to run, lists what the program declares and never reaches, and writes a page of findings beside the entrypoint.hive containerwrites a Dockerfile that builds the program and runs it.hive installbuilds the program and moves it where a shell finds commands, so it runs by name — under--namewhere one is given.hive export --target android/arm64packages a windowed program as an installable Android app.
Three take nothing: hive version prints which release this is, hive agents writes .hivedocs/ — a page per feature for a coding agent to read — into the current folder, and hive lsp is the language server an editor starts, which the next slide sets up. 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.
$ 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>`.