Documentation ¶
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func List ¶
func List(libraries []*structureSpec.Library)
Example ¶
package main import ( structureSpec "github.com/taubyte/go-specs/structure" libraryTable "github.com/taubyte/tau-cli/table/library" ) func main() { libraries := []*structureSpec.Library{ { Id: "QmbAA8hRosp5BaXFXikADCtpkQCgQCPdRVhnxjiSHfXdWH", Name: "someLibrary1", Provider: "github", RepoName: "taubyte-test/test_site1", }, { Id: "QmbUIDhRosp5BaXDASEWSCtpkQCgQCPdRVhnxjiSHfXdC0", Name: "someLibrary2", Provider: "github", RepoName: "taubyte-test/test_site2", }, } libraryTable.List(libraries) }
Output: ┌─────────────────┬────────────────────────────────────────────┐ │ ID │ NAME │ │ │ REPOSITORY │ ├─────────────────┼────────────────────────────────────────────┤ │ QmbAA8...HfXdWH │ someLibrary1 │ │ │ https://github.com/taubyte-test/test_site1 │ ├─────────────────┼────────────────────────────────────────────┤ │ QmbUID...HfXdC0 │ someLibrary2 │ │ │ https://github.com/taubyte-test/test_site2 │ └─────────────────┴────────────────────────────────────────────┘
func Query ¶
func Query(library *structureSpec.Library)
Example ¶
package main import ( structureSpec "github.com/taubyte/go-specs/structure" libraryTable "github.com/taubyte/tau-cli/table/library" ) func main() { library := &structureSpec.Library{ Id: "QmbAA8hRosp5BaXFXikADCtpkQCgQCPdRVhnxjiSHfXdWH", Name: "someProject", Description: "this is a library of some type", Tags: []string{"apple", "orange", "banana"}, Path: "/", Branch: "master", Provider: "github", RepoID: "591991", RepoName: "taubyte/example", } libraryTable.Query(library) }
Output: ┌──────────────┬────────────────────────────────────────────────┐ │ ID │ QmbAA8hRosp5BaXFXikADCtpkQCgQCPdRVhnxjiSHfXdWH │ ├──────────────┼────────────────────────────────────────────────┤ │ Name │ someProject │ ├──────────────┼────────────────────────────────────────────────┤ │ Description │ this is a library of some type │ ├──────────────┼────────────────────────────────────────────────┤ │ Tags │ apple, orange, banana │ ├──────────────┼────────────────────────────────────────────────┤ │ Path │ / │ ├──────────────┼────────────────────────────────────────────────┤ │ Repository │ https://github.com/taubyte/example │ ├──────────────┼────────────────────────────────────────────────┤ │ - Name │ taubyte/example │ ├──────────────┼────────────────────────────────────────────────┤ │ - ID │ 591991 │ ├──────────────┼────────────────────────────────────────────────┤ │ - Provider │ github │ ├──────────────┼────────────────────────────────────────────────┤ │ - Branch │ master │ └──────────────┴────────────────────────────────────────────────┘
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.