debian/0000755000000000000000000000000012177500414007167 5ustar debian/README.Source0000644000000000000000000000016712177477341011326 0ustar hg clone https://code.google.com/p/codesearch/ tar czvf codesearch_0.0~hg20120502.orig.tar.gz codesearch --exclude=.hg debian/cgrep.10000644000000000000000000000261712177477341010373 0ustar .\" Hey, EMACS: -*- nroff -*- .TH CGREP 1 "2013-06-23" .\" Please adjust this date whenever revising the manpage. .SH NAME cgrep \- like grep(1) over all indexed files .SH SYNOPSIS .B cgrep .RB [\|\-c\|] .RB [\|\-h\|] .RB [\|\-i\|] .RB [\|\-l\|] .RB [\|\-n\|] .IR regexp .RB [ .IR file... .RB ] .SH DESCRIPTION Cgrep behaves like grep, searching for regexp, an RE2 (nearly PCRE) regular expression. The \-c, \-h, \-i, \-l, and \-n flags are as in grep, although note that as per Go's flag parsing convention, they cannot be combined: the option pair \-i \-n cannot be abbreviated to \-in. .SH OPTIONS .TP .B \-c Suppress normal output; instead print a count of matching lines for each input file. .TP .B \-h Suppress the prefixing of file names on output. .TP .B \-i Ignore case distinctions in both the \fIregexp\fP and the input files. .TP .B \-l Suppress normal output; instead print the name of each input file from which output would normally have been printed. .TP .B \-n Prefix each line of output with the 1-based line number within its input file. .SH ENVIRONMENT Cgrep uses the index stored in $CSEARCHINDEX or, if that variable is unset or empty, $HOME/.csearchindex. .SH SEE ALSO .BR cindex (1), .BR csearch (1), .BR grep (1). .SH AUTHOR .PP This manual page was written by Michael Stapelberg , for the Debian project (and may be used by others). debian/codesearch.install0000644000000000000000000000001212177477613012666 0ustar usr/bin/* debian/codesearch.lintian-overrides0000644000000000000000000000015112177477341014660 0ustar codesearch: statically-linked-binary # There is no upstream changelog. codesearch: no-upstream-changelog debian/codesearch.manpages0000644000000000000000000000001312177477341013012 0ustar debian/*.1 debian/compat0000644000000000000000000000000212177477341010401 0ustar 8 debian/copyright0000644000000000000000000000472012177477341011141 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: codesearch Source: https://code.google.com/p/codesearch/ Files: * Copyright: 2011 The Go Authors License: BSD-3-clause Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: . * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Google Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. . THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Files: debian/* Copyright: 2012 Michael Stapelberg License: GPL-2+ This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this program. If not, see . On Debian systems, the complete text of the GNU General Public License version 2 can be found in "/usr/share/common-licenses/GPL-2". debian/csearch.10000644000000000000000000000400212177477341010671 0ustar .\" Hey, EMACS: -*- nroff -*- .TH CSEARCH 1 "2013-06-23" .\" Please adjust this date whenever revising the manpage. .SH NAME csearch \- like grep(1) over all indexed files .SH SYNOPSIS .B csearch .RB [\|\-c\|] .RB [\|\-f .IR fileregexp \|] .RB [\|\-h\|] .RB [\|\-i\|] .RB [\|\-l\|] .RB [\|\-n\|] .IR regexp .SH DESCRIPTION Csearch behaves like grep over all indexed files, searching for regexp, an RE2 (nearly PCRE) regular expression. The \-c, \-h, \-i, \-l, and \-n flags are as in grep, although note that as per Go's flag parsing convention, they cannot be combined: the option pair \-i \-n cannot be abbreviated to \-in. The \-f flag restricts the search to files whose names match the RE2 regular expression fileregexp. Csearch relies on the existence of an up-to-date index created ahead of time. To build or rebuild the index that csearch uses, run: cindex path... where path... is a list of directories or individual files to be included in the index. If no index exists, this command creates one. If an index already exists, cindex overwrites it. See \fBcindex\fP(1) for more details. .SH OPTIONS .TP .B \-c Suppress normal output; instead print a count of matching lines for each input file. .TP .B \-f fileregexp Restricts the search to files whose names match the RE2 regular expression \fIfileregexp\fP. .TP .B \-h Suppress the prefixing of file names on output. .TP .B \-i Ignore case distinctions in both the \fIregexp\fP and the input files. .TP .B \-l Suppress normal output; instead print the name of each input file from which output would normally have been printed. .TP .B \-n Prefix each line of output with the 1-based line number within its input file. .SH ENVIRONMENT Csearch uses the index stored in $CSEARCHINDEX or, if that variable is unset or empty, $HOME/.csearchindex. .SH SEE ALSO .BR cindex (1), .BR cgrep (1), .BR grep (1). .SH AUTHOR .PP This manual page was written by Michael Stapelberg , for the Debian project (and may be used by others). debian/docs0000644000000000000000000000000712177477341010053 0ustar README debian/golang-codesearch-dev.install0000644000000000000000000000002512177477341014711 0ustar usr/share/gocode/src debian/golang-codesearch-dev.lintian-overrides0000644000000000000000000000011712177477341016703 0ustar # There is no upstream changelog. golang-codesearch-dev: no-upstream-changelog debian/source/0000755000000000000000000000000012177477341010503 5ustar debian/source/format0000644000000000000000000000001412177477341011711 0ustar 3.0 (quilt) debian/source/lintian-overrides0000644000000000000000000000037712177477341014073 0ustar # debian/watch is missing intentionally. Russ does not do releases, he just # uploads code into the repository. In case codesearch gets a new maintainer # who does it differently, debian/watch can be added. codesearch source: debian-watch-file-is-missing debian/changelog0000644000000000000000000000066312177500414011046 0ustar codesearch (0.0~hg20120502-2) unstable; urgency=low * cindex: document TMPDIR in cindex(1) (Closes: #718679) * switch to dh-golang instead of building manually in debian/rules -- Michael Stapelberg Sun, 04 Aug 2013 18:01:09 +0200 codesearch (0.0~hg20120502-1) unstable; urgency=low * Initial release (Closes: #713899) -- Michael Stapelberg Mon, 31 Dec 2012 22:46:11 +0100 debian/cindex.10000644000000000000000000000417112177477350010542 0ustar .\" Hey, EMACS: -*- nroff -*- .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .TH CINDEX 1 "2013-06-23" .\" Please adjust this date whenever revising the manpage. .SH NAME cindex \- prepares the trigram index for csearch(1) .SH SYNOPSIS .B cindex .RB [\|\-list\|] .RB [\|\-reset\|] .RB [ .IR path... .RB ] .SH DESCRIPTION Cindex prepares the trigram index for use by csearch. The index is the file named by $CSEARCHINDEX, or else $HOME/.csearchindex. The simplest invocation is .Vb 11 \& cindex path... .Ve which adds the file or directory tree named by each path to the index. For example: .Vb 11 \& cindex $HOME/src /usr/include .Ve or, equivalently: .Vb 11 \& cindex $HOME/src \& cindex /usr/include .Ve If cindex is invoked with no paths, it reindexes the paths that have already been added, in case the files have changed. Thus, 'cindex' by itself is a useful command to run in a nightly cron job. The \-list flag causes cindex to list the paths it has indexed and exit. By default cindex adds the named paths to the index but preserves information about other paths that might already be indexed (the ones printed by cindex \-list). The \-reset flag causes cindex to delete the existing index before indexing the new paths. With no path arguments, cindex \-reset removes the index. .SH OPTIONS .TP .B \-list List the indexed paths and exit. .TP .B \-reset Delete the existing index before indexing the new paths. With no path arguments, \-reset removes the index. .SH ENVIRONMENT Cindex uses the index stored in $CSEARCHINDEX or, if that variable is unset or empty, $HOME/.csearchindex. Furthermore, cindex honors the standard TMPDIR environment variable when creating its temporary files. In case the temporary files exceed the space you have in /tmp, possibly because /tmp is a tmpfs and thus using your RAM, feel free to set TMPDIR to a different path than /tmp. .SH SEE ALSO .BR csearch (1), .BR cgrep (1). .SH AUTHOR .PP This manual page was written by Michael Stapelberg , for the Debian project (and may be used by others). debian/control0000644000000000000000000000272012177477705010613 0ustar Source: codesearch Section: utils Priority: extra Maintainer: Michael Stapelberg Build-Depends: debhelper (>= 9), golang-go, libparse-debcontrol-perl, dh-golang (>= 1.1) Standards-Version: 3.9.4 Homepage: https://code.google.com/p/codesearch/ Vcs-Git: git://anonscm.debian.org/collab-maint/codesearch.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=collab-maint/codesearch.git;a=summary Package: codesearch Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} Built-Using: ${misc:Built-Using} Description: regular expression search over large bodies of source code Code Search is a tool for indexing and then performing regular expression searches over large bodies of source code. It is a set of command-line programs written in Go. . For background and an overview of the commands, see Regular Expression Matching with a Trigram Index: http://swtch.com/~rsc/regexp/regexp4.html Package: golang-codesearch-dev Architecture: all Depends: ${shlibs:Depends}, ${misc:Depends} Built-Using: ${misc:Built-Using} Description: regexp search over large bodies of source (development files) Code Search is a tool for indexing and then performing regular expression searches over large bodies of source code. It is a set of command-line programs written in Go. . For background and an overview of the commands, see Regular Expression Matching with a Trigram Index: http://swtch.com/~rsc/regexp/regexp4.html . This package contains the source. debian/rules0000755000000000000000000000123212177500372010250 0ustar #!/usr/bin/make -f # -*- makefile -*- # Sample debian/rules that uses debhelper. # This file was originally written by Joey Hess and Craig Small. # As a special exception, when this file is copied by dh-make into a # dh-make output file, you may use that output file without restriction. # This special exception was added by Craig Small in version 0.37 of dh-make. # Uncomment this to turn on verbose mode. export DH_VERBOSE=1 # DH_GOPKG is the upstream path which you would normally “go get”. # Using it allows us to build applications without patching locations. export DH_GOPKG := code.google.com/p/codesearch %: dh $@ --buildsystem=golang --with=golang