migrator: fix default entrypoint behaviour
Created by: bobheadxi
I broke this in https://github.com/sourcegraph/sourcegraph/pull/33758 by not correctly using the modified args []string
provided
Test plan
Before:
➜ sourcegraph git:(main) go run ./cmd/migrator
NAME:
migrator - Validates and runs schema migrations
USAGE:
migrator command [command options] [arguments...]
COMMANDS:
up Apply all migrations
upto Ensure a given migration has been applied - may apply dependency migrations
downto Revert any applied migrations that are children of the given targets - this effectively "resets" the schmea to the target version
validate Validate the current schema
add-log Add an entry to the migration log
help, h Shows a list of commands or help for one command
OPTIONS:
--help, -h show help (default: false)
After:
➜ sourcegraph git:(fix-migrator-default-cmd) go run ./cmd/migrator
error: databases frontend and codeintel must be distinct, but both target postgres://127.0.0.1:5432
exit status 1