File tree Expand file tree Collapse file tree 5 files changed +42
-10
lines changed Expand file tree Collapse file tree 5 files changed +42
-10
lines changed Original file line number Diff line number Diff line change @@ -130,11 +130,22 @@ go-build:
130130 $(GOBUILD ) -tags=" $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " -o litd-debug $(PKG ) /cmd/litd
131131 $(GOBUILD ) -tags=" $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " -o litcli-debug $(PKG ) /cmd/litcli
132132
133+
134+ go-build-noui :
135+ @$(call print, "Building lightning-terminal without UI.")
136+ $(GOBUILD ) -tags=" litd_no_ui $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " -o litd-debug $(PKG ) /cmd/litd
137+ $(GOBUILD ) -tags=" litd_no_ui $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " -o litcli-debug $(PKG ) /cmd/litcli
138+
133139go-install :
134140 @$(call print, "Installing lightning-terminal.")
135141 $(GOINSTALL ) -trimpath -tags=" $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " $(PKG ) /cmd/litd
136142 $(GOINSTALL ) -trimpath -tags=" $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " $(PKG ) /cmd/litcli
137143
144+ go-install-noui :
145+ @$(call print, "Installing lightning-terminal without UI.")
146+ $(GOINSTALL ) -tags=" litd_no_ui $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " $(PKG ) /cmd/litd
147+ $(GOINSTALL ) -tags=" litd_no_ui $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " $(PKG ) /cmd/litcli
148+
138149go-install-cli :
139150 @$(call print, "Installing all CLI binaries.")
140151 $(GOINSTALL ) -trimpath -tags=" $( LND_RELEASE_TAGS) " -ldflags " $( LDFLAGS) " github.com/lightningnetwork/lnd/cmd/lncli
Original file line number Diff line number Diff line change 1+ //go:build !litd_no_ui
2+ // +build !litd_no_ui
3+
4+ package terminal
5+
6+ import (
7+ "embed"
8+ )
9+
10+ var (
11+ // appBuildFS is an in-memory file system that contains all the static
12+ // HTML/CSS/JS files of the UI. It is compiled into the binary with the
13+ // go 1.16 embed directive below. Because the path is relative to the
14+ // root package, all assets will have a path prefix of /app/build/ which
15+ // we'll strip by giving a sub directory to the HTTP server.
16+ //
17+ //go:embed app/build/*
18+ appBuildFS embed.FS
19+ )
Original file line number Diff line number Diff line change 1+ //go:build litd_no_ui
2+ // +build litd_no_ui
3+
4+ package terminal
5+
6+ import "embed"
7+
8+ var (
9+ appBuildFS embed.FS
10+ )
Original file line number Diff line number Diff line change 66
77- [ Fixed a bug where REST calls for the ` WalletUnlocker ` service weren't allowed
88 on startup] ( https://github.com/lightninglabs/lightning-terminal/pull/806 ) .
9+ - [ Added build flag 'litd_no_ui' for building litd without the ui, accessible
10+ with 'make go-build-noui' and 'make go-install-noui'] ( https://github.com/lightninglabs/lightning-terminal/pull/500 ) .
911
1012### LND
1113
Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ package terminal
33import (
44 "context"
55 "crypto/tls"
6- "embed"
76 "encoding/binary"
87 "encoding/hex"
98 "errors"
9190 // the macaroon database before we give up with an error.
9291 macDatabaseOpenTimeout = time .Second * 5
9392
94- // appBuildFS is an in-memory file system that contains all the static
95- // HTML/CSS/JS files of the UI. It is compiled into the binary with the
96- // go 1.16 embed directive below. Because the path is relative to the
97- // root package, all assets will have a path prefix of /app/build/ which
98- // we'll strip by giving a sub directory to the HTTP server.
99- //
100- //go:embed app/build/*
101- appBuildFS embed.FS
102-
10393 // appFilesDir is the sub directory of the above build directory which
10494 // we pass to the HTTP server.
10595 appFilesDir = "app/build"
You can’t perform that action at this time.
0 commit comments