From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 10.213.28.69 with SMTP id l5cs446811ebc; Tue, 19 Jan 2010 10:00:39 -0800 (PST) Received: by 10.224.74.209 with SMTP id v17mr5524020qaj.44.1263924038050; Tue, 19 Jan 2010 10:00:38 -0800 (PST) Return-Path: Received: from rubyforge.org (rubyforge.org [205.234.109.19]) by mx.google.com with ESMTP id 7si15934102qwf.14.2010.01.19.10.00.37; Tue, 19 Jan 2010 10:00:38 -0800 (PST) Received-SPF: pass (google.com: domain of sup-devel-bounces@rubyforge.org designates 205.234.109.19 as permitted sender) client-ip=205.234.109.19; Authentication-Results: mx.google.com; spf=pass (google.com: domain of sup-devel-bounces@rubyforge.org designates 205.234.109.19 as permitted sender) smtp.mail=sup-devel-bounces@rubyforge.org Received: from rubyforge.org (rubyforge.org [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id 16AE33C8041; Tue, 19 Jan 2010 13:00:35 -0500 (EST) Received: from pion.club.cc.cmu.edu (PION.CLUB.CC.cmu.edu [128.237.157.88]) by rubyforge.org (Postfix) with ESMTP id A7D251779945 for ; Tue, 19 Jan 2010 13:00:32 -0500 (EST) Received: from rlane by pion.club.cc.cmu.edu with local (Exim 4.69) (envelope-from ) id 1NXINU-0002W0-6h; Tue, 19 Jan 2010 13:00:32 -0500 From: Rich Lane To: Eric Sherman In-reply-to: <1263858172-sup-547@changeling.local> References: <1263858172-sup-547@changeling.local> Date: Tue, 19 Jan 2010 13:00:32 -0500 Message-Id: <1263920054-sup-9400@zyrg.net> User-Agent: Sup/git Cc: sup-devel Subject: Re: [sup-devel] [PATCH] Saved Search Support X-BeenThere: sup-devel@rubyforge.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: Sup developer discussion List-Id: Sup developer discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: sup-devel-bounces@rubyforge.org Errors-To: sup-devel-bounces@rubyforge.org Excerpts from Eric Sherman's message of 2010-01-18 18:44:37 -0500: > Start an index search with a \ backslash and press enter to get a list > of searches that were previously saved from search-results-mode with % > percent or added from search-list-mode directly. Saved searches may be > used in other searches by enclosing their names in {} curly braces. > Search names may contain letters, numbers, underscores and dashes. This is a nice feature. A few comments: I'd like it better if shrinking went away and the only time we expanded was right before giving it to parse_query. I'd rather not have the expand-on-delete or rename-tracking behaviors. These changes would simplify the code quite a bit. I think attempting to expand a nonexistent saved search should result in something false ("type:false", maybe), send a warning to the log, and perhaps flash an error message. On Ruby 1.9.1 I get: lib/sup/search.rb:69: warning: Hash#index is deprecated; use Hash#key SearchListMode#regen_text: looks like a mixup of each and map SearchListMode#add_new_search: Should flash an error message on name collisions, or allow overwriting. SearchListMode#rename_selected_search, SearchListMode#save_search: Name collision handling should be consistent with add_new_search. SearchManager: I'd replace the duplicated name checking regexes with a method. SearchManager#rename: I think the strip should be done by the caller. _______________________________________________ Sup-devel mailing list Sup-devel@rubyforge.org http://rubyforge.org/mailman/listinfo/sup-devel