Facebook Twitter Instagram
    TecAdmin
    • Home
    • Ubuntu 20.04
      • Upgrade Ubuntu
      • Install Java
      • Install Node.js
      • Install Docker
      • Install LAMP Stack
    • Tutorials
      • AWS
      • Shell Scripting
      • Docker
      • Git
      • MongoDB
    • FeedBack
    • Submit Article
    • About Us
    Facebook Twitter Instagram
    TecAdmin
    Home»General Articles»How to List All Packages Available in a Repository on Ubuntu

    How to List All Packages Available in a Repository on Ubuntu

    RahulBy RahulOctober 4, 20202 Mins ReadUpdated:October 5, 2020

    APT or Advanced Package Tool is an software package used to install, update and remove packages on Debian based systems. It is the default package manager on Ubuntu and Debian based systems. The apt, apt-get and apt-cache are quickly used commands to manage packages and configuration on system.

    Apt don’t provide any command to list available package under the specific repository. But you can find the list from a cache file, which contains list of available package to that repository with other details.

    This tutorial will help you to find all the available packages in a repository on Ubuntu and other Debian based systems.

    Find Packages Details in Repository

    Apt keeps all repository cache files under /var/lib/apt/lists directory. So, first update the apt cache on your system

    sudo apt-get update 
    

    Now, navigate to /var/lib/apt/lists directory. Then search for the file with the repository name, path and architecture, ends with _Packages in there name.

    See the content of *_Packages to view details about all packages available under that repository.

    List available packages in a repository on Ubuntu and Debian

    To list the packages only available in file, execute below like:

    grep -h -P -o "^Package: \K.*" /var/lib/apt/lists/ppa.launchpad.net_*_Packages | sort -u 
    

    Conclusion

    In this article, you have learned to find all the available packages in a specific repository.

    apt apt-get debian Ubuntu
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email WhatsApp
    Previous ArticleHow To Install Apache mod_cloudflare on Debian
    Next Article How to List Installed Repositories In Ubuntu & Debian

    Related Posts

    Change Screen Resolution of An Ubuntu VM in Hyper-V

    Updated:May 2, 20222 Mins Read

    Download Ubuntu 22.04 – DVD ISO Images

    Updated:May 7, 20222 Mins Read

    How to Find Django Install Location in Linux

    Updated:April 27, 20221 Min Read

    (Resolved) – ReactJS 404 Error on Page Reload

    2 Mins Read

    Adding a New SSH Key in GitHub

    Updated:April 1, 20223 Mins Read

    13 Best Linux Terminal Emulators and Bash Editors

    8 Mins Read

    Leave A Reply Cancel Reply

    Recent Posts
    • How to Install JAVA on Ubuntu 22.04
    • Switching Display Manager in Ubuntu – GDM, LightDM & SDDM
    • Changing the Login Screen Background in Ubuntu 22.04 & 20.04
    • How To Install PHP (8.1, 7.4 or 5.6) on Ubuntu 22.04
    • (Resolved) Please install all available updates for your release before upgrading
    Facebook Twitter Instagram Pinterest
    © 2022 Tecadmin.net. All Rights Reserved | Terms  | Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.