Features
- Search for a specified term on DuckDuckGo.
- Customize the number of search results to retrieve.
- Save the search results to a text file.
- Automatically generate a User-Agent header for HTTP requests.
-
Run the program:
./duckduckgo-web-scraper -search "your search term" -count 10
Replace "your search term" with the term you want to search for and -count with the number of search results you want to retrieve (default is 10).
Flags
-
search or -s: Specify the search term.
-
user-agent: Customize the User-Agent string for HTTP requests (optional).
-
output: Specify the output file name (optional). By default, it's named after the search term.
-
count: Specify the number of search results to retrieve (default is 10).