diff --git a/README.md b/README.md index 384720c2379d8b9ead7cb6d88f51663b1443f44f..2a3e39c9a66606b1328a3f610b794bd1842f3fbd 100644 --- a/README.md +++ b/README.md @@ -12,21 +12,45 @@ In project directory, run `go run main.go` Required Args: -`-s <STRING>` : Address of server to which messages will be sent +`-n <INT>` : Number of nodes in the cMix network being connected to `-i <INT>` : User ID to log in as Optional Args: +`-g <STRING>` : Address of the gateway to connect to (Reqiured if not specified +in the config file) + `-d <INT>` : User ID of the user to send messages to `-m <STRING>` : Message to be sent -`-v` : Boolean indicating verbose logging +`-v` : Enables verbose logging when specified + +`-V` : Show version information + +`-f` : String containing path of file to store the session into. +If not included it will use Ram Storage -`-n` : Unsigned Integer indicating the number of nodes in the system +`--noratchet` : Disables ratcheting when specified + +`--noBlockingTransmission` : Disables transmission frequency limiting when +specified + +Example Configuration File +== -`-f` : String containing path of file to store the session into. If not included it will use Ram Storage +```yaml +logPath: "client.log" +numnodes : 3 +sessionstore: "session.data" +noratchet: true +textcolor: -1 +gateways: + - "gateway-0.prod.cmix.rip:11420" + - "gateway-1.prod.cmix.rip:11420" + - "gateway-2.prod.cmix.rip:11420" +``` Preparation to Build == diff --git a/cmd/root.go b/cmd/root.go index f4f47ca01a8dd1f478caf3235d2a6c3f4a6e51a6..b003cdb40c3bdbb7be9dbbe8a8c1fb452f08e70e 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -31,7 +31,6 @@ var numNodes uint var sessionFile string var noRatchet bool var dummyFrequency float64 -var nick string var noBlockingTransmission bool var rateLimiting uint32 var showVer bool @@ -149,7 +148,6 @@ var rootCmd = &cobra.Command{ } else { cmd.MarkPersistentFlagRequired("userid") cmd.MarkPersistentFlagRequired("numnodes") - cmd.MarkPersistentFlagRequired("serveraddr") } var dummyPeriod time.Duration @@ -289,8 +287,6 @@ func init() { rootCmd.PersistentFlags().Uint64VarP(&userId, "userid", "i", 0, "UserID to sign in as") - rootCmd.PersistentFlags().StringVarP(&nick, "nick", "", "", - "Nickname to register as") rootCmd.PersistentFlags().StringVarP(&gwAddr, "gwaddr", "g", "", "Gateway address to send messages to") // TODO: support this negotiating separate keys with different servers