From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#21383: Static revisions in vc-working-revision Date: Wed, 2 Sep 2015 13:49:10 +0300 Message-ID: <55E6D426.10105@yandex.ru> References: <55E41499.5030501@yandex.ru> <55E5094A.3010108@yandex.ru> <55E59487.1050804@yandex.ru> <55E5CA42.1080005@yandex.ru> <55E5DF1A.9010902@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1441191070 27281 80.91.229.3 (2 Sep 2015 10:51:10 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 2 Sep 2015 10:51:10 +0000 (UTC) Cc: 21383-done@debbugs.gnu.org, Jonathan H To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 02 12:50:58 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZX5d4-0000Lf-9D for geb-bug-gnu-emacs@m.gmane.org; Wed, 02 Sep 2015 12:50:58 +0200 Original-Received: from localhost ([::1]:36294 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZX5d3-00075Z-OS for geb-bug-gnu-emacs@m.gmane.org; Wed, 02 Sep 2015 06:50:57 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58980) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZX5cG-0006Md-Le for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2015 06:50:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZX5cC-0007f4-24 for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2015 06:50:08 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:53762) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZX5cB-0007eG-Qb for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2015 06:50:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1ZX5cB-0004Km-0c for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2015 06:50:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 02 Sep 2015 10:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21383 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 21383-done@debbugs.gnu.org id=D21383.144119095716594 (code D ref 21383); Wed, 02 Sep 2015 10:50:02 +0000 Original-Received: (at 21383-done) by debbugs.gnu.org; 2 Sep 2015 10:49:17 +0000 Original-Received: from localhost ([127.0.0.1]:45972 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZX5bR-0004JZ-3q for submit@debbugs.gnu.org; Wed, 02 Sep 2015 06:49:17 -0400 Original-Received: from mail-wi0-f169.google.com ([209.85.212.169]:37759) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZX5bP-0004JS-Si for 21383-done@debbugs.gnu.org; Wed, 02 Sep 2015 06:49:16 -0400 Original-Received: by wicfx3 with SMTP id fx3so14450377wic.0 for <21383-done@debbugs.gnu.org>; Wed, 02 Sep 2015 03:49:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-type:content-transfer-encoding; bh=szqn8GT72NOZhCd/RsYmnBTCOZuxNloL4goNbPinlYk=; b=r8Sd5W1d3SPEmvIp+Swe5Lds/1plJSlkJlhJ8MwduPea7l6/XGq1NcHcuFoUSbX8AQ CPy8g8gnzAFjZqEYMD2aa5HnOrWSpexe7NOSLFgk0LvbCTsoIS/tBb6JfVKLqKxPZRC5 4DNgDCLzw9koc0P9XEU16OC3VFNvIhRxwQqb/E5j1h2svEASt9yoTLshiVvo/yDVfXhj nuSk0ZqRlU7Jb9sJRkFMqAgGWhtKSCMhau+u588wZ9D1OTyoOWKTGx8koHWE9BhDrLfh E7x2U6KlPjQmdCUtHh85KQX0SgExzr6Mx0j6VkxVfU9jAnBTmoSjDT1rISlbmO3mpxPo HYdg== X-Received: by 10.181.12.5 with SMTP id em5mr3365924wid.67.1441190955121; Wed, 02 Sep 2015 03:49:15 -0700 (PDT) Original-Received: from [10.9.0.103] (nat.webazilla.com. [78.140.128.228]) by smtp.googlemail.com with ESMTPSA id hr17sm2960994wib.16.2015.09.02.03.49.13 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 02 Sep 2015 03:49:14 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:40.0) Gecko/20100101 Thunderbird/40.0 In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:106083 Archived-At: On 09/02/2015 06:50 AM, Stefan Monnier wrote: >> Maybe you see it better. I only imagined the problem limited to the >> non-file-granularity backends. > > You mean like most current backends? ;-) Yes. But as long as its only limited to the backends (and can be fixed there), as opposed to being inherently present in vc.el, log-edit.el, etc, it's less of a problem. >> And we can't simply remove the FILE argument in many backend commands: it's >> often used for vc-file-get/setprop. > > I know. > > In any case, it's not that bad: it works. But there's something fishy > that will surely bite at some point. Maybe those FILE args should be > redefined to be relative to default-directory (and can't use things like > "../.."). vc-file-setprop won't work on a relative path. Or shouldn't, at least. And are you talking about FILE arg to vc-status, or e.g. vc-git-status? If vc-status requires the path to be relative, that will complicate the consumer interface (now I have to worry about producing the relative path). If vc-status will be responsible for that before calling vc-git-status, it won't work in file-granular backends. Anyway, why would we want that extra call, even if it's cached? And vc-git-working-revision won't care if FILE is absolute or relative, which is the crux of the problem. I'd rather backends like Git, if we're going to fix this, used FILE's parent directory to change default-directory temporarily before calling Git.