Home  >  Article  >  System Tutorial  >  Search from the command line using DuckDuckGo

Search from the command line using DuckDuckGo

王林
王林forward
2024-02-27 19:40:22660browse

Search from the command line using DuckDuckGo

DuckDuckGo Command Line Application

Search from the command line using DuckDuckGo
DuckDuckGo Bangs (DuckDuckGo Quick Search) can help you easily find the information you want on DuckDuckGo (even this website omgubuntu has a quick search). ddgr represents this functionality very faithfully.

Different from the web version, you can change how many results are returned per page. This is more convenient than looking at more than thirty results for each query. The default interface has been carefully designed to take up as little space as possible without affecting readability.

ddgr has many features and highlights, including:

  • Change the number of search results
  • Support Bash auto-completion
  • Use DuckDuckGo Bangs
  • Open link in browser
  • "I'm feeling lucky" option
  • Filtering functions based on time, region, file type, etc.
  • Minimal Dependencies

You can download ddgr that supports various systems from the Github project page:

  • Download “ddgr” from Github

Also, in Ubuntu 16.04 LTS or newer, you can use PPA to install ddgr. This repository is maintained by the developers of ddgr. This method of installation is recommended if you want to stay up to date with the latest version.

It should be reminded that at the time of writing this article, the ddgr in this PPA is not the latest version, but a slightly older version (missing the -num option).

Add the PPA using the following command:

sudo add-apt-repository ppa:twodopeshaggy/jarun
sudo apt-get update
How to use ddgr to search DuckDuckGo from the command line

After installation, you just need to open your terminal emulator and run:

ddgr

Then enter the query content:

search-term

You can limit the number of search results:

ddgr --num 5 search-term

Or automatically open the first search result in the browser:

ddgr -j search-term

You can use parameters and options to improve search accuracy. Use the following command to view all parameters:

ddgr -h

The above is the detailed content of Search from the command line using DuckDuckGo. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:linuxprobe.com. If there is any infringement, please contact admin@php.cn delete