Delete backend and rename cli to ricochet-cli

ricochet-cli can act as a headless backend, so for now there is no point
to having a separate backend program. It may be reintroduced later for
multiprocess use by other frontends -- to be determined.
John Brooks 2016-11-05 16:57:00 -06:00
parent 569a138e21
commit bbc58e5815
9 changed files with 3 additions and 43 deletions

.gitignore vendored
View File

@ -1,3 +1,2 @@

View File

@ -30,6 +30,4 @@ Architecture
**rpc** defines a [gRPC]( and [protobuf]( API for communication between the client backend and frontend. This API is for trusted backends to communicate with frontend UI clients, and it's expected that both will usually be on the same machine and invisible to the end-user. Anything capable of speaking gRPC could implement a frontend.
**backend** is the backend application, providing the gRPC server and using the core implementation.
**cli** is the first frontend, a Go readline-style text-only client.
**ricochet-cli** is a commandline program that acts as a backend and a readline-style CLI frontend. It can be used as a standalone client, to run a headless backend, or to attach to a running backend.

View File

@ -1,37 +0,0 @@
package main
import (
ricochet ""
rpc ""
const (
defaultListener = ""
func main() {
listener, err := net.Listen("tcp", defaultListener)
if err != nil {
log.Fatalf("listen failed: %v", err)
config, err := ricochet.LoadConfig(".")
if err != nil {
log.Fatalf("config error: %v", err)
core := new(ricochet.Ricochet)
if err := core.Init(config); err != nil {
log.Fatalf("init error: %v", err)
server := &ricochet.RpcServer{
Core: core,
grpcServer := grpc.NewServer()
rpc.RegisterRicochetCoreServer(grpcServer, server)