text stringlengths 0 834k |
|---|
$rep = $o->rep_uniq($rep); |
return unless $o->assert( |
$o->rep_exists($rep), |
""no such repository '$rep'"" |
); |
} |
$o->rep_down($rep); |
} |
else { |
$o->warn(<<END) and return; |
No such repository command '$cmd'; see 'help repository'. |
END |
} |
} |
&$refresh; |
unless(@reps) { |
$o->warn(""No repositories. Use 'rep add' to add a repository.\n""); |
} |
else { |
my $i = 0; |
my $count = @reps_on; |
my $l = length($count); |
$o->inform(""Repositories:\n""); |
for my $r (@reps_on) { |
my $n = sprintf(""%${l}d"", $i + 1); |
$o->inform(""[$n] $r\n""); |
$i++; |
} |
for my $r ($o->dictsort(@reps_off)) { |
my $s = ' ' x $l; |
$o->inform(""[$s] $r\n""); |
} |
} |
1; |
} |
#============================================================================ |
# Search: |
# search # displays previous searches |
# search <\d+> # displays results of previous search |
# search <terms> # executes a new search on the current repository |
#============================================================================ |
sub smry_search { ""searches for packages in a repository"" } |
sub help_search { <<'END' } |
search -- Search for Packages |
Synopsis |
search Displays list of previous searches |
search <number> Displays results of search <number> |
search <glob pattern> Performs a new search |
search <field>=<glob> Searches for all packages matching the field. |
search * Displays all packages in the current repository |
The available fields are 'ABSTRACT', 'NAME', 'TITLE', 'AUTHOR', and |
'VERSION'. 'NAME' is used when you do not specify a field. |
Description |
Use the search command to look through the repository for packages. PPM |
version 3 provides powerful search functionality. For example: |
1. Search for 'CGI' anywhere in the name: |
search CGI |
Example results: |
Apache-CGI |
CGI-Application |
CGI-ArgChecker |
2. Search for 'CGI' at the beginning of the name: |
search CGI* |
Example results: |
CGI-ArgChecker |
CGI-Application |
3. Search for all modules authored by someone with 'smith' in their |
name or email: |
search AUTHOR=smith |
Example results: |
Apache-ProxyPass |
Business-ISBN |
4. Search for 'compress' anywhere in the abstract: |
search ABSTRACT=compress |
Example results: |
Apache-GzipChain |
IO-Zlib |
5. Search for 'CGI' in the name, or 'web' in the abstract: |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.