Searching for a project or file (AEN 4.1.3)
===========================================

.. raw:: html

    <div class="contents local topic" id="contents">
    <ul class="simple">
    <li><a class="reference internal" href="#types-of-files-searched" id="id1">Types of files searched</a></li>
    <li><a class="reference internal" href="#search-indexing" id="id2">Search indexing</a></li>
    <li><a class="reference internal" href="#using-search-constructs" id="id3">Using search constructs</a></li>
    <li><a class="reference internal" href="#searching-metadata-fields" id="id4">Searching metadata fields</a></li>
    <li><a class="reference internal" href="#searching-a-project" id="id5">Searching a project</a></li>
    <li><a class="reference internal" href="#saving-a-search" id="id6">Saving a search</a></li>
    <li><a class="reference internal" href="#removing-a-saved-search" id="id7">Removing a saved search</a></li>
    </ul>
    </div>
    <p>To search for projects and files, use the Search box in the
    AEN navigation bar. The search provides different results
    depending on which page you search from:</p>
    <ul class="simple">
    <li>On a project home page, search results include any files that
    match your search criteria within the current project.</li>
    <li>On any other AEN page, search results include any files that
    match your search criteria within all projects.</li>
    </ul>
    <p>TIP: Your search results include only files and projects that you
    can view: public projects, and private projects to which you have
    a minimum of view access.</p>
    <div class="section" id="types-of-files-searched">
    <h2><a class="toc-backref" href="#id1">Types of files searched</a><a class="headerlink" href="#types-of-files-searched" title="Permalink to this headline">¶</a></h2>
    <p>The following types of files are included in search results:</p>
    <ul class="simple">
    <li><code class="docutils literal"><span class="pre">.py</span></code>&#8212;Python source files.</li>
    <li><code class="docutils literal"><span class="pre">.ipynb</span></code>&#8212;IPython/Jupyter notebooks.</li>
    <li><code class="docutils literal"><span class="pre">.txt</span></code>&#8212;plain text files.</li>
    <li><code class="docutils literal"><span class="pre">.md</span></code>&#8212;Markdown files.</li>
    </ul>
    </div>
    <div class="section" id="search-indexing">
    <h2><a class="toc-backref" href="#id2">Search indexing</a><a class="headerlink" href="#search-indexing" title="Permalink to this headline">¶</a></h2>
    <p>Files that are modified while a project is running are
    automatically re-indexed shortly after the files are modified.
    If you create or update a large number of files&#8212;such as cloning
    a git repository or copying a directory&#8212;search results may take
    several minutes to update.</p>
    <p>Files that are modified while the project is not running are
    re-indexed only after the project is started.</p>
    </div>
    <div class="section" id="using-search-constructs">
    <h2><a class="toc-backref" href="#id3">Using search constructs</a><a class="headerlink" href="#using-search-constructs" title="Permalink to this headline">¶</a></h2>
    <p>You can use the following search constructs:</p>
    <ul>
    <li><p class="first">Ordinary words will match the full-text contents of any file.</p>
    </li>
    <li><p class="first">Wildcards are permitted.</p>
    <p>EXAMPLE: <code class="docutils literal"><span class="pre">John*</span></code> will match John and Johnny.  These are
    glob patterns and are similar to their usage in the command
    line.</p>
    </li>
    <li><p class="first">Combine queries using <code class="docutils literal"><span class="pre">AND</span></code> or <code class="docutils literal"><span class="pre">OR</span></code>, and group them using
    parentheses <code class="docutils literal"><span class="pre">()</span></code>.</p>
    </li>
    </ul>
    <p>Regular expression patterns can be embedded in the query string by wrapping
    them in forward-slashes (<code class="docutils literal"><span class="pre">/</span></code>):</p>
    <div class="highlight-default"><div class="highlight"><pre><span></span>name:/joh?n(ath[oa]n)/
    </pre></div>
    </div>
    <p>The supported regular expression syntax is explained in
    <a class="reference external" href="https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-regexp-query.html#regexp-syntax">the Elasticsearch reference</a>.</p>
    <p>NOTE: Wildcards apply inside a regular expression. A query string
    such as <code class="docutils literal"><span class="pre">/.*n/</span></code> would force the search to visit every term in the index.</p>
    </div>
    <div class="section" id="searching-metadata-fields">
    <h2><a class="toc-backref" href="#id4">Searching metadata fields</a><a class="headerlink" href="#searching-metadata-fields" title="Permalink to this headline">¶</a></h2>
    <p>You can search in specific metadata fields:</p>
    <ul class="simple">
    <li><code class="docutils literal"><span class="pre">imports:name</span></code>&#8212;matches files that import the module name.</li>
    <li><code class="docutils literal"><span class="pre">uses:name</span></code>&#8212;matches files that reference the identifier
    name. Referenced names include any functions and globals
    imported from other modules, as well as the names of any
    methods invoked on any object.</li>
    <li><code class="docutils literal"><span class="pre">defines:name</span></code>&#8212;matches files that define the identifier
    name. Defined names include functions defined at global scope,
    class names, and method names within classes.</li>
    <li><code class="docutils literal"><span class="pre">acl:user</span></code>&#8212;matches files in which the named user has
    read access or higher.</li>
    </ul>
    </div>
    <div class="section" id="searching-a-project">
    <h2><a class="toc-backref" href="#id5">Searching a project</a><a class="headerlink" href="#searching-a-project" title="Permalink to this headline">¶</a></h2>
    <ol class="arabic">
    <li><p class="first">In the Search box, type a string of text:</p>
    <div class="figure">
    <a class="reference internal image-reference" href="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_box.png"><img alt="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_box.png" src="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_box.png" style="width: 50%;" /></a>
    </div>
    <div class="line-block">
    <div class="line"><br /></div>
    </div>
    <p>TIP: Search by glob patterns, which are similar to file
    matching in the command line.</p>
    <p>EXAMPLE: To find projects in the test family that are
    numbered from 00 to 99, search for <code class="docutils literal"><span class="pre">Test-??</span></code>. To find all
    projects whose name ends with &#8220;Stats,&#8221; search for <code class="docutils literal"><span class="pre">*Stats</span></code>.</p>
    </li>
    <li><p class="first">Press Enter.</p>
    </li>
    <li><p class="first">In the search results, click the plus + icon above a project
    name to show a list of matching files in the selected project:</p>
    <div class="figure">
    <a class="reference internal image-reference" href="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_results_expansion_icon.png"><img alt="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_results_expansion_icon.png" src="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_results_expansion_icon.png" style="width: 50%;" /></a>
    </div>
    <div class="line-block">
    <div class="line"><br /></div>
    </div>
    <p>TIP: Click the project name to open the project&#8217;s home page.</p>
    </li>
    <li><p class="first">To view a file, click its file name in the matching files
    list:</p>
    <div class="figure">
    <a class="reference internal image-reference" href="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_results_details.png"><img alt="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_results_details.png" src="../../../../../_images/ae-notebooks/4.1.3/aen-user-search_results_details.png" style="width: 50%;" /></a>
    </div>
    <div class="line-block">
    <div class="line"><br /></div>
    </div>
    </li>
    </ol>
    </div>
    <div class="section" id="saving-a-search">
    <h2><a class="toc-backref" href="#id6">Saving a search</a><a class="headerlink" href="#saving-a-search" title="Permalink to this headline">¶</a></h2>
    <ol class="arabic">
    <li><p class="first">At the top of the search results, click Save this search:</p>
    <div class="figure">
    <a class="reference internal image-reference" href="../../../../../_images/ae-notebooks/4.1.3/aen-user-save_search.png"><img alt="../../../../../_images/ae-notebooks/4.1.3/aen-user-save_search.png" src="../../../../../_images/ae-notebooks/4.1.3/aen-user-save_search.png" style="width: 50%;" /></a>
    </div>
    <div class="line-block">
    <div class="line"><br /></div>
    </div>
    </li>
    </ol>
    <p>The &#8220;save this search&#8221; text changes to &#8220;stored&#8221; and your search
    is saved. Your saved searches are listed on your home page.</p>
    </div>
    <div class="section" id="removing-a-saved-search">
    <h2><a class="toc-backref" href="#id7">Removing a saved search</a><a class="headerlink" href="#removing-a-saved-search" title="Permalink to this headline">¶</a></h2>
    <p>On your home page, in the Saved searches section, click X next
    the saved search that you want to remove:</p>
    <div class="figure">
    <a class="reference internal image-reference" href="../../../../../_images/ae-notebooks/4.1.3/aen-user-saved_searches.png"><img alt="../../../../../_images/ae-notebooks/4.1.3/aen-user-saved_searches.png" src="../../../../../_images/ae-notebooks/4.1.3/aen-user-saved_searches.png" style="width: 50%;" /></a>
    </div>
    <div class="line-block">
    <div class="line"><br /></div>
    </div>
    </div>
