diff options
Diffstat (limited to 'cmd/search.go')
-rw-r--r-- | cmd/search.go | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/cmd/search.go b/cmd/search.go index b6aaf3e..76babf4 100644 --- a/cmd/search.go +++ b/cmd/search.go @@ -113,12 +113,13 @@ func searchAnime(searchInput string) { } func init() { + fmt.Println("searchInit") rootCmd.AddCommand(searchCmd) - searchCmd.Flags().IntVarP(&ui.PromptLength, "prompt-length", "l", 5, "Length of select prompt") + searchCmd.Flags().IntVarP(&ui.PromptLength, "prompt-length", "l", promptLength, "Length of select prompt") searchCmd.Flags().BoolVarP(&mangaMode, "manga", "m", false, "Use manga mode") - searchCmd.Flags().IntVarP(&mal.SearchLength, "search-length", "n", 10, "Amount of search results to load") - searchCmd.Flags().IntVarP(&mal.SearchOffset, "search-offset", "o", 0, "Offset for the search results") - searchCmd.Flags().BoolVarP(&mal.SearchNSFW, "search-nsfw", "", false, "Include NSFW-rated items in search results") + searchCmd.Flags().IntVarP(&mal.SearchLength, "search-length", "n", searchLength, "Amount of search results to load") + searchCmd.Flags().IntVarP(&mal.SearchOffset, "search-offset", "o", searchOffset, "Offset for the search results") + searchCmd.Flags().BoolVarP(&mal.SearchNSFW, "search-nsfw", "", searchNsfw, "Include NSFW-rated items in search results") searchCmd.Flags().IntVarP(&entryId, "id", "i", -1, "Manually specify the ID of anime/manga (overrides search)") searchCmd.Flags().BoolVarP(&queryOnlyMode, "query", "q", false, "Query only (don't update data)") searchCmd.Flags().StringVarP(&mal.Secret, "authentication-token", "t", "", "MyAnimeList authentication token to use (overrides system keyring if any)") |