// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only

/*!
    \page creator-how-to-silver-searcher.html
    \previouspage creator-how-tos.html

    \ingroup creator-how-to-search

    \title Turn on Silver Searcher

    You can use Silver Searcher as a search engine in \QC if you install
    Silver Searcher on the computer.

    \image {qtcreator-search-file-system.webp} {Files in File System scope in Search Results view}

    \note Enable the SilverSearcher plugin to use it.

    To use Silver Searcher:

    \list 1
        \li Download and install Silver Searcher from \l{The Silver Searcher}
            or \l{GitHub: The Silver Searcher}{GitHub}.

            You might have to build Silver Searcher from sources for some
            platforms.
        \li When searching, select \uicontrol {Silver Searcher} in
            \uicontrol {Search engine}.
    \endlist

    If \QC cannot find Silver Searcher, you might have installed it in a
    location that is not set in the \c{PATH} environment variable.

    \section1 Set location of Silver Searcher

    To tell \QC where Silver Searcher is:

    \list 1
        \li Go to \preferences > \uicontrol Environment > \uicontrol System.
            \image {qtcreator-preferences-environment-system.webp} {System tab in Environment preferences}
        \li In \uicontrol Environment, select \uicontrol Change.
        \li In \uicontrol {Edit Environment}, add the path to the Silver Searcher
            executable:
            \badcode
            PATH=</path/to/bin>:${PATH}
            \endcode
            \image {qtcreator-edit-environment.webp} {Edit Environment dialog}
    \endlist

    \sa {Enable and disable plugins}, {Search}{How to: Search},
    {Edit environment settings}
*/
