From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/85078 Path: news.gmane.org!not-for-mail From: Alexander Baier Newsgroups: gmane.emacs.gnus.general Subject: Re: Deleting mail in virtual group Date: Sat, 04 Oct 2014 16:10:15 +0200 Message-ID: <874mvkexiw.fsf@mailbox.org> References: <87mw9cfazu.fsf@mailbox.org> <87zjdcyp8o.fsf@ericabrahamsen.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1412433728 28103 80.91.229.3 (4 Oct 2014 14:42:08 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 4 Oct 2014 14:42:08 +0000 (UTC) Cc: ding@gnus.org To: Eric Abrahamsen Original-X-From: ding-owner+M33322@lists.math.uh.edu Sat Oct 04 16:42:01 2014 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XaQX2-0001Aa-Rf for ding-account@gmane.org; Sat, 04 Oct 2014 16:42:01 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1XaQ2l-0007nj-78; Sat, 04 Oct 2014 09:10:43 -0500 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1XaQ2h-0007nE-NP for ding@lists.math.uh.edu; Sat, 04 Oct 2014 09:10:39 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtps (TLSv1:AES128-SHA:128) (Exim 4.76) (envelope-from ) id 1XaQ2f-0000b3-Sc for ding@lists.math.uh.edu; Sat, 04 Oct 2014 09:10:38 -0500 Original-Received: from mx1.mailbox.org ([80.241.60.212]) by quimby.gnus.org with esmtp (Exim 4.80) (envelope-from ) id 1XaQ2c-000582-3w for ding@gnus.org; Sat, 04 Oct 2014 16:10:34 +0200 Original-Received: from smtp1.mailbox.org (smtp1.mailbox.org [80.241.60.240]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.mailbox.org (Postfix) with ESMTPS id 2DE40404A4; Sat, 4 Oct 2014 16:10:26 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=mailbox.org; h= content-type:content-type:mime-version:user-agent:message-id :in-reply-to:date:date:references:subject:subject:from:from :received; s=mail20140220; t=1412431825; bh=eN9Yf7hVlJKU4v09rpxo +cb1J+zP3B9TEQ//8lp3MKQ=; b=VMawe7KJRTHzaobyqIx9H8u2nNo25iKMcMck +U/1tfYRuFGvkJUqi2jypPT2pa9owHo3Pra8BnFJz4yMsYYC7PiUMXYP8c1K55wv 1x1FYjMh0eUqiOU+4RuO3EHAXSBDURM/gh9i7SALUo6Q1SJlzTf9siZFz+fVEP15 VCVh2FJSCtlFoCMLGTEHgznql7MyTzjm/UjkIxdLs+OTNrrv2AtPyxbgrv4gg7fd c/Sd/vpGAjrMWveX/ye5r349tXz/CBOu8LM9L7JljodUSne8WoyNGVcOPoMlD7VU nYOTNoAkyZyP+I+ejzej5a4j2xqg+rnKZgUEpjScreMHX0x1svHaLG9gC3MDn9uD eUkwS9uYy03/cOHtcNpHHAFtHpK8eXKK/c1+iUNqP06+DLUmuEsYK2ZrnUfXBBbt eb3rmyMy7Idph9u2HC5SaUeG8tsfX53mp6WyNLRZlN5S79PsQqeLtARKWgy/zzcD 9qiFoxv6Q2Pg2Zk7hvNIJRztgnoy6StTBLxkukbCIHX5ZBLq0bKOnHuU9BUdZYCT QopeTHYWj+y7p2AZIXBjFB5mt1UPXFZ5MOrCkHtTc9kOB X-Virus-Scanned: amavisd-new at heinlein-support.de Original-Received: from smtp1.mailbox.org ([80.241.60.240]) (using TLS with cipher AES256-GCM-SHA384) by hefe.heinlein-support.de (hefe.heinlein-support.de [91.198.250.172]) (amavisd-new, port 10030) with ESMTPS id QjSmhtSpwz6Q; Sat, 4 Oct 2014 16:10:25 +0200 (CEST) Mail-Followup-To: Eric Abrahamsen , ding@gnus.org In-Reply-To: <87zjdcyp8o.fsf@ericabrahamsen.net> (Eric Abrahamsen's message of "Sat, 04 Oct 2014 20:48:55 +0800") User-Agent: Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.3 (gnu/linux) X-Spam-Score: -3.0 (---) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:85078 Archived-At: On 2014-10-04 14:48 Eric Abrahamsen wrote: >> I want to write my own command that finds the original group of the >> article in question and executes the move in that group. Is there a >> function that gets me the original group of an article in a virtual >> group? > > I'm pretty sure that nnvirtual-find-group-art will do what you want. > Feed it the article number of the article under point, along with > gnus-newsgroup-name in the virtual Summary buffer. See how it works! Thank you for your quick reply! These to functions do what I want and I get the correct original group and article. But now I am stuck and do not know how to get to the original group. This is what I tried: #+BEGIN_SRC emacs-lisp (defun my-nnvirtual-delete-article () (interactive) (let ((original (nnvirtual-find-group-art gnus-newsgroup-name (gnus-summary-article-number)))) (with-current-buffer gnus-group-buffer (gnus-group-goto-group (car original)) (gnus-summary-goto-article (cdr original))))) #+END_SRC The group and article number returned by nnvirtual-find-group-art are correct, I checked. But the with-current-buffer part does not seem to work, as gnus always displays the article from the nnvirtual group with the original number. How do I switch to the original group? TIA, -- Alexander Baier