From 1c86a66cbe0f4871dd40b8352c1f1b2de97e8442 Mon Sep 17 00:00:00 2001 From: Michael Muré Date: Fri, 21 Sep 2018 12:54:48 +0200 Subject: bridge: add the beginning of a github importer --- bridge/core/bridge.go | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 bridge/core/bridge.go (limited to 'bridge/core') diff --git a/bridge/core/bridge.go b/bridge/core/bridge.go new file mode 100644 index 00000000..3ff8404b --- /dev/null +++ b/bridge/core/bridge.go @@ -0,0 +1,26 @@ +package core + +import "github.com/MichaelMure/git-bug/cache" + +type Common interface { + // Configure handle the user interaction and return a key/value configuration + // for future use + Configure() (map[string]string, error) +} + +type Importer interface { + Common + ImportAll(repo *cache.RepoCache) error + Import(repo *cache.RepoCache, id string) error +} + +type Exporter interface { + Common + ExportAll(repo *cache.RepoCache) error + Export(repo *cache.RepoCache, id string) error +} + +type NotSupportedImporter struct{} +type NotSupportedExporter struct{} + +// persist -- cgit