Shipped this project!
I created a utility to quickly retrieve DuckDuckGo search results from the CLI. While tools like SearchSploit help identify security vulnerabilities, I wanted to create a version of such a tool for everyday use. In particular, I was always concerned about the high data charges incurred when using a web browser to search Google while surfing the web on a mobile data network, so I set out to solve this problem. Therefore, while other similar tools like ddgr crawl html.duckduckgo.com, I designed my tool to access lite.duckduckgo.com—DuckDuckGo’s lightest version—to retrieve search results, thereby minimizing data usage. The most challenging part was parsing HTML using only net/html instead of goquery, which I implemented with the help of Copilot. As a result, I successfully built a tool that fetches DuckDuckGo search results in plain text or JSON format in about one second, depending on network speed. I’m proud that, despite using only a single dependency, it outperforms the well-known tool ddgr in terms of CPU/memory usage and speed. Since it’s written in pure Go, it can be used immediately on various platforms without any modifications.
Translated with DeepL.com (free version)