From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Marcin Borkowski Newsgroups: gmane.emacs.help Subject: Re: Project idea: a poor man's VC backend Date: Thu, 11 Dec 2014 20:44:54 +0100 Message-ID: <87egs66keh.fsf@wmi.amu.edu.pl> References: <87h9x26ue6.fsf@wmi.amu.edu.pl> <83388mt6dp.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1418327141 13614 80.91.229.3 (11 Dec 2014 19:45:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 11 Dec 2014 19:45:41 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Dec 11 20:45:34 2014 Return-path: Envelope-to: geh-help-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 1Xz9g4-00011f-Vd for geh-help-gnu-emacs@m.gmane.org; Thu, 11 Dec 2014 20:45:33 +0100 Original-Received: from localhost ([::1]:54089 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xz9g4-0000S6-Gc for geh-help-gnu-emacs@m.gmane.org; Thu, 11 Dec 2014 14:45:32 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33944) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xz9fl-0000Rh-2J for help-gnu-emacs@gnu.org; Thu, 11 Dec 2014 14:45:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xz9fg-0007GO-1F for help-gnu-emacs@gnu.org; Thu, 11 Dec 2014 14:45:12 -0500 Original-Received: from msg.wmi.amu.edu.pl ([2001:808:114:2::50]:44795) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xz9ff-0007Cv-Qu for help-gnu-emacs@gnu.org; Thu, 11 Dec 2014 14:45:07 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by msg.wmi.amu.edu.pl (Postfix) with ESMTP id 43E2B42066 for ; Thu, 11 Dec 2014 20:45:05 +0100 (CET) Original-Received: from msg.wmi.amu.edu.pl ([127.0.0.1]) by localhost (msg.wmi.amu.edu.pl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0gNgCsu1RbQu for ; Thu, 11 Dec 2014 20:45:05 +0100 (CET) Original-Received: from localhost (117-116.echostar.pl [213.156.117.116]) by msg.wmi.amu.edu.pl (Postfix) with ESMTPSA id DC52042061 for ; Thu, 11 Dec 2014 20:45:04 +0100 (CET) In-reply-to: <83388mt6dp.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:808:114:2::50 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:101526 Archived-At: On 2014-12-11, at 18:59, Eli Zaretskii wrote: >> From: Marcin Borkowski >> Date: Thu, 11 Dec 2014 17:09:05 +0100 >> >> In a recent question on ESE >> (http://emacs.stackexchange.com/questions/2849/save-current-file-with-a-slightly-different-name) >> the topic of versioning by means of putting a timestamp into the >> filename came up again (it does have its place, especially when >> communicating with people unable to learn a real VCS). >> >> Just wondering: would it be possible/easy/reasonable to provide >> something like this within the Emacs VC framework? > > Are you talking about time-stamp.el? Not really. I mean that e.g. C-x v v will "do the right thing", for instance: I'm editing file.el (the only file in the current directory). I press C-x v v. I'm asked for a "commit message" and the current contents of file.el are save as e.g. file.el.2014-12-11-20:39:01-CET or something like that, with the "commit message" put at the beginning in a comment (for example). I edit it further, and C-x v v behaves similarly. Then, I can press C-x v =, and see the diff between the current version and the last stamped one. Or C-u C-x v = and be asked (with autocompletion) for the timestamp. Then, have similar commands for analogs of blame/annotate, revert to earlier versions etc. Of course, it's impossible to recreate the functionality of Git in this way. Or even RCS, I'm afraid. But for many use cases this might be enough (for instance, one/two authors working on a single LaTeX file of the paper). (One paticular functionality that would be difficult to implement would be branching; while possible, it might be even misleading and hence dangerous. Remember, the target would be the users, uhm, not wise enough to use a real VCS;-).) The rationale would be that e.g. if I work with a non-computer-savvy researcher, any "real" VCS might be confusing; I might be expected to e.g. send him file versions with a timestamp in the filename etc. Best, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University