feat: HTTP server for exporting Arborix bundles
Introduces a read-only HTTP server (WAI/Warp) backed by the content store, exposing three bundle-export endpoints: - GET /bundle/name/:name — export by stored term name - GET /bundle/hash/:hash — export by full Merkle hash - GET /terms — plain-text listing (debug) Also adds `tricu server` (aka `--serve`) CLI mode, move `resolveExportTarget` / `namesForHash` / `looksLikeHash` out of `Main.hs` into `ContentStore.hs`, and cleans up unused exports and imports across `FileEval.hs` and `Wire.hs`.
This commit is contained in:
12
tricu.cabal
12
tricu.cabal
@@ -51,15 +51,20 @@ executable tricu
|
||||
, filepath
|
||||
, fsnotify
|
||||
, haskeline
|
||||
, http-types
|
||||
, megaparsec
|
||||
, memory
|
||||
, mtl
|
||||
, servant
|
||||
, sqlite-simple
|
||||
, stm
|
||||
, tasty
|
||||
, tasty-hunit
|
||||
, text
|
||||
, time
|
||||
, transformers
|
||||
, wai
|
||||
, warp
|
||||
, zlib
|
||||
other-modules:
|
||||
ContentStore
|
||||
@@ -70,6 +75,7 @@ executable tricu
|
||||
Paths_tricu
|
||||
REPL
|
||||
Research
|
||||
Server
|
||||
Wire
|
||||
default-language: Haskell2010
|
||||
|
||||
@@ -99,15 +105,20 @@ test-suite tricu-tests
|
||||
, filepath
|
||||
, fsnotify
|
||||
, haskeline
|
||||
, http-types
|
||||
, megaparsec
|
||||
, memory
|
||||
, mtl
|
||||
, servant
|
||||
, sqlite-simple
|
||||
, stm
|
||||
, tasty
|
||||
, tasty-hunit
|
||||
, text
|
||||
, time
|
||||
, transformers
|
||||
, warp
|
||||
, wai
|
||||
, zlib
|
||||
default-language: Haskell2010
|
||||
other-modules:
|
||||
@@ -119,4 +130,5 @@ test-suite tricu-tests
|
||||
Paths_tricu
|
||||
REPL
|
||||
Research
|
||||
Server
|
||||
Wire
|
||||
|
||||
Reference in New Issue
Block a user