From c4b1e4351859d8f954ac28627f91f83b74d1688d Mon Sep 17 00:00:00 2001 From: hwh33 Date: Tue, 17 Dec 2024 11:36:26 -0700 Subject: [PATCH] Add documentation for command-line implementation (#1269) --- README.md | 11 +++++++++++ cli/cli.go | 2 ++ 2 files changed, 13 insertions(+) diff --git a/README.md b/README.md index 9b372eaee..322f28b4b 100644 --- a/README.md +++ b/README.md @@ -107,6 +107,17 @@ All these dependencies must be in your PATH. Some of this is Android specific, s * `flutter pub get` * `flutter run --flavor prod` or if you are using android studio use desktop configuration +#### As a Command-Line Application + +A command-line implementation of Lantern is defined in the `cli` directory. + +* `go build -o lantern-cli ./cli` +* `./lantern-cli ` (run with `-h` or `--help` to see available arguments) + +You will likely want to specify the `-addr` argument (e.g. `-addr localhost:8080`) to define where the local proxy should be available. + +If you want to point at a specific remote proxy, consult `hit_proxy.bash` for an example on how to set up a config directory with specific proxy config. + ### Running on emulators You can easily run emulators directly from the command line with the following: diff --git a/cli/cli.go b/cli/cli.go index 0a11ce9b1..dd0f86567 100644 --- a/cli/cli.go +++ b/cli/cli.go @@ -1,3 +1,5 @@ +// Command cli provides a command-line implementation of the Lantern client. Run this command with +// -h or --help to see all available arguments. package main import (