diff --git a/cmd/search.go b/cmd/search.go index 1a947d2..9186ced 100644 --- a/cmd/search.go +++ b/cmd/search.go @@ -2,9 +2,9 @@ package cmd import ( "fmt" - "genread-api/pkg/api" "github.com/manifoldco/promptui" "github.com/spf13/cobra" + "laureanray/clibgen/pkg/api" "log" "strconv" ) diff --git a/dist/artifacts.json b/dist/artifacts.json deleted file mode 100644 index ee89189..0000000 --- a/dist/artifacts.json +++ /dev/null @@ -1 +0,0 @@ -[{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_darwin_amd64_v1/libgen-api","goos":"darwin","goarch":"amd64","goamd64":"v1","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}},{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_linux_386/libgen-api","goos":"linux","goarch":"386","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}},{"name":"libgen-api.exe","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_windows_386/libgen-api.exe","goos":"windows","goarch":"386","type":"Binary","extra":{"Binary":"libgen-api","Ext":".exe","ID":"libgen-api"}},{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_linux_amd64_v1/libgen-api","goos":"linux","goarch":"amd64","goamd64":"v1","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}},{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_linux_arm64/libgen-api","goos":"linux","goarch":"arm64","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}},{"name":"libgen-api.exe","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_windows_arm64/libgen-api.exe","goos":"windows","goarch":"arm64","type":"Binary","extra":{"Binary":"libgen-api","Ext":".exe","ID":"libgen-api"}},{"name":"libgen-api.exe","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_windows_amd64_v1/libgen-api.exe","goos":"windows","goarch":"amd64","goamd64":"v1","type":"Binary","extra":{"Binary":"libgen-api","Ext":".exe","ID":"libgen-api"}},{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_darwin_arm64/libgen-api","goos":"darwin","goarch":"arm64","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}},{"name":"libgen-api_0.0.1-next_Linux_i386.tar.gz","path":"dist/libgen-api_0.0.1-next_Linux_i386.tar.gz","goos":"linux","goarch":"386","type":"Archive","extra":{"Binaries":["libgen-api"],"Builds":[{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_linux_386/libgen-api","goos":"linux","goarch":"386","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Windows_i386.tar.gz","path":"dist/libgen-api_0.0.1-next_Windows_i386.tar.gz","goos":"windows","goarch":"386","type":"Archive","extra":{"Binaries":["libgen-api.exe"],"Builds":[{"name":"libgen-api.exe","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_windows_386/libgen-api.exe","goos":"windows","goarch":"386","type":"Binary","extra":{"Binary":"libgen-api","Ext":".exe","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Windows_arm64.tar.gz","path":"dist/libgen-api_0.0.1-next_Windows_arm64.tar.gz","goos":"windows","goarch":"arm64","type":"Archive","extra":{"Binaries":["libgen-api.exe"],"Builds":[{"name":"libgen-api.exe","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_windows_arm64/libgen-api.exe","goos":"windows","goarch":"arm64","type":"Binary","extra":{"Binary":"libgen-api","Ext":".exe","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Linux_arm64.tar.gz","path":"dist/libgen-api_0.0.1-next_Linux_arm64.tar.gz","goos":"linux","goarch":"arm64","type":"Archive","extra":{"Binaries":["libgen-api"],"Builds":[{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_linux_arm64/libgen-api","goos":"linux","goarch":"arm64","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Darwin_arm64.tar.gz","path":"dist/libgen-api_0.0.1-next_Darwin_arm64.tar.gz","goos":"darwin","goarch":"arm64","type":"Archive","extra":{"Binaries":["libgen-api"],"Builds":[{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_darwin_arm64/libgen-api","goos":"darwin","goarch":"arm64","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Linux_x86_64.tar.gz","path":"dist/libgen-api_0.0.1-next_Linux_x86_64.tar.gz","goos":"linux","goarch":"amd64","goamd64":"v1","type":"Archive","extra":{"Binaries":["libgen-api"],"Builds":[{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_linux_amd64_v1/libgen-api","goos":"linux","goarch":"amd64","goamd64":"v1","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Windows_x86_64.tar.gz","path":"dist/libgen-api_0.0.1-next_Windows_x86_64.tar.gz","goos":"windows","goarch":"amd64","goamd64":"v1","type":"Archive","extra":{"Binaries":["libgen-api.exe"],"Builds":[{"name":"libgen-api.exe","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_windows_amd64_v1/libgen-api.exe","goos":"windows","goarch":"amd64","goamd64":"v1","type":"Binary","extra":{"Binary":"libgen-api","Ext":".exe","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"libgen-api_0.0.1-next_Darwin_x86_64.tar.gz","path":"dist/libgen-api_0.0.1-next_Darwin_x86_64.tar.gz","goos":"darwin","goarch":"amd64","goamd64":"v1","type":"Archive","extra":{"Binaries":["libgen-api"],"Builds":[{"name":"libgen-api","path":"/Users/laureanray.bahala/Projects/genread-api/dist/libgen-api_darwin_amd64_v1/libgen-api","goos":"darwin","goarch":"amd64","goamd64":"v1","type":"Binary","extra":{"Binary":"libgen-api","Ext":"","ID":"libgen-api"}}],"Format":"tar.gz","ID":"default","Replaces":null,"WrappedIn":""}},{"name":"checksums.txt","path":"dist/checksums.txt","type":"Checksum","extra":{"Refresh":"func() error"}}] \ No newline at end of file diff --git a/dist/checksums.txt b/dist/checksums.txt deleted file mode 100644 index 4fd7b06..0000000 --- a/dist/checksums.txt +++ /dev/null @@ -1,8 +0,0 @@ -09fa443f34f08d66cd8343e9970d13254f1b98c7feac73a371bfcf965e999bb5 libgen-api_0.0.1-next_Windows_arm64.tar.gz -0b750a936de77212ce29101e3aa5da9b4ee8b4d2f2aaf554817ad15b84d56ca5 libgen-api_0.0.1-next_Darwin_arm64.tar.gz -624daefeafd0e8b9a6a9940cb930fdfbbba3d777fc9555f6084bb985c9ff0f2a libgen-api_0.0.1-next_Darwin_x86_64.tar.gz -6da8f8860d6e2586b0ea8f580e88780f84fcd737ba801ac7c885055512c7d0ad libgen-api_0.0.1-next_Windows_i386.tar.gz -94211f7efbfde7a1f67defef2a435a65ea734e73a8ac64e97616b140cd74cd86 libgen-api_0.0.1-next_Linux_x86_64.tar.gz -ae44ae50d5f511383b24271c65c906c365058d695cd5f60959aff0560c005c14 libgen-api_0.0.1-next_Linux_i386.tar.gz -b8a1273f20c33c3a58558b7d8fb2fb9b5d6af76fd401b9ceb953c7ebd857a4fc libgen-api_0.0.1-next_Linux_arm64.tar.gz -d8165edcb0e5287703074c4cf28fb32a9c6c4d9df56eb9c62f21ab046239f7f5 libgen-api_0.0.1-next_Windows_x86_64.tar.gz diff --git a/dist/config.yaml b/dist/config.yaml deleted file mode 100644 index 8ae42e8..0000000 --- a/dist/config.yaml +++ /dev/null @@ -1,127 +0,0 @@ -project_name: libgen-api -release: - github: - owner: laureanray - name: libgen-api - name_template: '{{.Tag}}' -scoop: - name: libgen-api - commit_author: - name: goreleaserbot - email: bot@goreleaser.com - commit_msg_template: Scoop update for {{ .ProjectName }} version {{ .Tag }} - goamd64: v1 -builds: - - id: libgen-api - goos: - - linux - - windows - - darwin - goarch: - - amd64 - - arm64 - - "386" - goarm: - - "6" - gomips: - - hardfloat - goamd64: - - v1 - targets: - - linux_amd64_v1 - - linux_arm64 - - linux_386 - - windows_amd64_v1 - - windows_arm64 - - windows_386 - - darwin_amd64_v1 - - darwin_arm64 - dir: . - main: . - binary: libgen-api - env: - - CGO_ENABLED=0 - builder: go - gobinary: go - command: build - ldflags: - - -s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}} -X main.builtBy=goreleaser -archives: - - id: default - name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ with .Arm }}v{{ . }}{{ end }}{{ with .Mips }}_{{ . }}{{ end }}{{ if not (eq .Amd64 "v1") }}{{ .Amd64 }}{{ end }}' - replacements: - "386": i386 - amd64: x86_64 - darwin: Darwin - linux: Linux - windows: Windows - format: tar.gz - files: - - src: license* - - src: LICENSE* - - src: readme* - - src: README* - - src: changelog* - - src: CHANGELOG* -snapshot: - name_template: '{{ incpatch .Version }}-next' -checksum: - name_template: checksums.txt - algorithm: sha256 -changelog: - filters: - exclude: - - '^docs:' - - '^test:' - sort: asc -dist: dist -env_files: - github_token: ~/.config/goreleaser/github_token - gitlab_token: ~/.config/goreleaser/gitlab_token - gitea_token: ~/.config/goreleaser/gitea_token -before: - hooks: - - go mod tidy - - go generate ./... -source: - name_template: '{{ .ProjectName }}-{{ .Version }}' - format: tar.gz -gomod: - gobinary: go -announce: - twitter: - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - reddit: - title_template: '{{ .ProjectName }} {{ .Tag }} is out!' - url_template: '{{ .ReleaseURL }}' - slack: - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - username: GoReleaser - discord: - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - author: GoReleaser - color: "3888754" - icon_url: https://goreleaser.com/static/avatar.png - teams: - title_template: '{{ .ProjectName }} {{ .Tag }} is out!' - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - color: '#2D313E' - icon_url: https://goreleaser.com/static/avatar.png - smtp: - subject_template: '{{ .ProjectName }} {{ .Tag }} is out!' - body_template: 'You can view details from: {{ .ReleaseURL }}' - mattermost: - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - title_template: '{{ .ProjectName }} {{ .Tag }} is out!' - username: GoReleaser - linkedin: - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - telegram: - message_template: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}' - webhook: - message_template: '{ "message": "{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}"}' - content_type: application/json; charset=utf-8 -github_urls: - download: https://github.com -gitlab_urls: - download: https://gitlab.com diff --git a/dist/libgen-api_0.0.1-next_Darwin_arm64.tar.gz b/dist/libgen-api_0.0.1-next_Darwin_arm64.tar.gz deleted file mode 100644 index 274ab81..0000000 Binary files a/dist/libgen-api_0.0.1-next_Darwin_arm64.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Darwin_x86_64.tar.gz b/dist/libgen-api_0.0.1-next_Darwin_x86_64.tar.gz deleted file mode 100644 index fe749e3..0000000 Binary files a/dist/libgen-api_0.0.1-next_Darwin_x86_64.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Linux_arm64.tar.gz b/dist/libgen-api_0.0.1-next_Linux_arm64.tar.gz deleted file mode 100644 index 3341eb8..0000000 Binary files a/dist/libgen-api_0.0.1-next_Linux_arm64.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Linux_i386.tar.gz b/dist/libgen-api_0.0.1-next_Linux_i386.tar.gz deleted file mode 100644 index 62620eb..0000000 Binary files a/dist/libgen-api_0.0.1-next_Linux_i386.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Linux_x86_64.tar.gz b/dist/libgen-api_0.0.1-next_Linux_x86_64.tar.gz deleted file mode 100644 index 3e258d6..0000000 Binary files a/dist/libgen-api_0.0.1-next_Linux_x86_64.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Windows_arm64.tar.gz b/dist/libgen-api_0.0.1-next_Windows_arm64.tar.gz deleted file mode 100644 index b74e9d6..0000000 Binary files a/dist/libgen-api_0.0.1-next_Windows_arm64.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Windows_i386.tar.gz b/dist/libgen-api_0.0.1-next_Windows_i386.tar.gz deleted file mode 100644 index 688dad3..0000000 Binary files a/dist/libgen-api_0.0.1-next_Windows_i386.tar.gz and /dev/null differ diff --git a/dist/libgen-api_0.0.1-next_Windows_x86_64.tar.gz b/dist/libgen-api_0.0.1-next_Windows_x86_64.tar.gz deleted file mode 100644 index 8b091f4..0000000 Binary files a/dist/libgen-api_0.0.1-next_Windows_x86_64.tar.gz and /dev/null differ diff --git a/dist/libgen-api_darwin_amd64_v1/libgen-api b/dist/libgen-api_darwin_amd64_v1/libgen-api deleted file mode 100755 index bb75fb7..0000000 Binary files a/dist/libgen-api_darwin_amd64_v1/libgen-api and /dev/null differ diff --git a/dist/libgen-api_darwin_arm64/libgen-api b/dist/libgen-api_darwin_arm64/libgen-api deleted file mode 100755 index bf3b9c6..0000000 Binary files a/dist/libgen-api_darwin_arm64/libgen-api and /dev/null differ diff --git a/dist/libgen-api_linux_386/libgen-api b/dist/libgen-api_linux_386/libgen-api deleted file mode 100755 index c54ea0a..0000000 Binary files a/dist/libgen-api_linux_386/libgen-api and /dev/null differ diff --git a/dist/libgen-api_linux_amd64_v1/libgen-api b/dist/libgen-api_linux_amd64_v1/libgen-api deleted file mode 100755 index d9b752c..0000000 Binary files a/dist/libgen-api_linux_amd64_v1/libgen-api and /dev/null differ diff --git a/dist/libgen-api_linux_arm64/libgen-api b/dist/libgen-api_linux_arm64/libgen-api deleted file mode 100755 index 6a0c833..0000000 Binary files a/dist/libgen-api_linux_arm64/libgen-api and /dev/null differ diff --git a/dist/libgen-api_windows_386/libgen-api.exe b/dist/libgen-api_windows_386/libgen-api.exe deleted file mode 100755 index d3ccd8a..0000000 Binary files a/dist/libgen-api_windows_386/libgen-api.exe and /dev/null differ diff --git a/dist/libgen-api_windows_amd64_v1/libgen-api.exe b/dist/libgen-api_windows_amd64_v1/libgen-api.exe deleted file mode 100755 index bf4ce79..0000000 Binary files a/dist/libgen-api_windows_amd64_v1/libgen-api.exe and /dev/null differ diff --git a/dist/libgen-api_windows_arm64/libgen-api.exe b/dist/libgen-api_windows_arm64/libgen-api.exe deleted file mode 100755 index 55c4f27..0000000 Binary files a/dist/libgen-api_windows_arm64/libgen-api.exe and /dev/null differ diff --git a/dist/metadata.json b/dist/metadata.json deleted file mode 100644 index 0a52ece..0000000 --- a/dist/metadata.json +++ /dev/null @@ -1 +0,0 @@ -{"project_name":"libgen-api","tag":"v0.0.0","previous_tag":"","version":"0.0.1-next","commit":"ef5e1d5e6e060c74993a06e13f2855d408e8edab","date":"2022-06-14T13:44:12.600197+08:00","runtime":{"goos":"darwin","goarch":"amd64"}} \ No newline at end of file diff --git a/go.mod b/go.mod index 3f3068a..31d463b 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module genread-api +module laureanray/clibgen go 1.18 diff --git a/main.go b/main.go index f3e4ab8..22e425d 100644 --- a/main.go +++ b/main.go @@ -1,6 +1,6 @@ package main -import "genread-api/cmd" +import "laureanray/clibgen/cmd" func main() { cmd.Execute() diff --git a/pkg/api/libgen_test.go b/pkg/api/libgen_test.go deleted file mode 100644 index 440547e..0000000 --- a/pkg/api/libgen_test.go +++ /dev/null @@ -1,13 +0,0 @@ -package api - -import ( - "testing" -) - -func TestBook(t *testing.T) { - books, err := SearchBookByTitle("Search") - - if len(books) == 0 || err != nil { - t.Fatalf(`Empty books: %d`, len(books)) - } -}