mirror of
https://github.com/tnypxl/rollup.git
synced 2025-12-15 15:03:17 +00:00
fix: Add --verbose flag to web subcommand
This commit is contained in:
@@ -31,6 +31,8 @@ var webCmd = &cobra.Command{
|
||||
RunE: runWeb,
|
||||
}
|
||||
|
||||
var scraperConfig scraper.Config
|
||||
|
||||
func init() {
|
||||
rootCmd.AddCommand(webCmd)
|
||||
webCmd.Flags().StringSliceVarP(&urls, "urls", "u", []string{}, "URLs of the webpages to scrape (comma-separated)")
|
||||
@@ -40,6 +42,9 @@ func init() {
|
||||
webCmd.Flags().StringSliceVar(&excludeSelectors, "exclude", []string{}, "CSS selectors to exclude from the extracted content (comma-separated)")
|
||||
}
|
||||
|
||||
func runWeb(cmd *cobra.Command, args []string) error {
|
||||
scraperConfig.Verbose = verbose
|
||||
|
||||
func runWeb(cmd *cobra.Command, args []string) error {
|
||||
// Use config if available, otherwise use command-line flags
|
||||
var urlConfigs []scraper.URLConfig
|
||||
|
||||
Reference in New Issue
Block a user