From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Gregor Zattler Newsgroups: gmane.emacs.help Subject: How to handle bare git repositories with emacs 23? Date: Wed, 14 Oct 2009 02:59:18 +0200 Message-ID: <20091014005918.GA28561@shi.workgroup> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1255507570 23188 80.91.229.12 (14 Oct 2009 08:06:10 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 14 Oct 2009 08:06:10 +0000 (UTC) To: help-gnu-emacs Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Oct 14 10:05:59 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Mxyro-0008I8-QZ for geh-help-gnu-emacs@m.gmane.org; Wed, 14 Oct 2009 10:05:53 +0200 Original-Received: from localhost ([127.0.0.1]:43242 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mxyro-0000pe-CM for geh-help-gnu-emacs@m.gmane.org; Wed, 14 Oct 2009 04:05:52 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MxsDh-00041a-Su for help-gnu-emacs@gnu.org; Tue, 13 Oct 2009 21:00:01 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MxsDb-00040d-Tf for help-gnu-emacs@gnu.org; Tue, 13 Oct 2009 21:00:01 -0400 Original-Received: from [199.232.76.173] (port=54933 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MxsDb-00040a-R4 for help-gnu-emacs@gnu.org; Tue, 13 Oct 2009 20:59:55 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]:45460) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1MxsDb-0005Nw-5J for help-gnu-emacs@gnu.org; Tue, 13 Oct 2009 20:59:55 -0400 Original-Received: (qmail invoked by alias); 14 Oct 2009 00:59:53 -0000 Original-Received: from p54BD407D.dip.t-dialin.net (EHLO shi.workgroup) [84.189.64.125] by mail.gmx.net (mp069) with SMTP; 14 Oct 2009 02:59:53 +0200 X-Authenticated: #19296480 X-Provags-ID: V01U2FsdGVkX1/3/bJDvC73cQnefjsa1K1puqynmssSev1EfjWuaO Q0Gy6/A0NcqTly Original-Received: from grfz by shi.workgroup with local (Exim 4.69) (envelope-from ) id 1MxsDK-0007vo-DR; Wed, 14 Oct 2009 02:59:38 +0200 Mail-Followup-To: help-gnu-emacs Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) X-Y-GMX-Trusted: 0 X-FuHaFi: 0.65 X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. X-Mailman-Approved-At: Wed, 14 Oct 2009 03:57:06 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:68947 Dear emacs users, I use bare git repositories for version contol of some dotfiles but they do not show up in vc nor dvc. For use cases like this git uses environment variables: These environment variables point to the repository and the working tree respectively: grfz@shi:~$ export GIT_DIR=~/.fgits/emacs.git grfz@shi:~$ export GIT_WORK_TREE="$GIT_DIR/$(git config --get core.worktree)" There are several files/directories under ~/.emacs.d: grfz@shi:~$ ls .emacs.d/ _abbrev_defs elisp games init.el tramp _abbrev_defs.old elpa _gnus lisp update-org.sh auto-save-list _emacs.bmk history _recentf _backup _emacs_orig _ido.last todo-do _diary _emms-history image-dired todo-top And some of them are version controlled: grfz@shi:~$ git ls-files .emacs.d/_abbrev_defs .emacs.d/_diary .emacs.d/_gnus .emacs.d/init.el When I visit one of the version controlled files with an emacs session which inherited the above mentioned environment variables neither vc nor dvc recognises the file as version controlled. But wired enough vc-dir shows only the files in ~/.emacs.d which are *not* version controlled. The state of all these files is "unregistered". If I vc-dir-show-fileentry one of the version controlled files it appears in the vc-dir buffer and its state is "nil". Now I vc-dir-find this file: The mode line gives no indication that the file is version controlled. I modify the file, save it and refresh the vc-dir buffer. Now the state of the file is "unregistered" whilst on the bash command line a git status shows the file as modified. dvc-status does not recognise the directories ~/ nor ~/.emacs.d as version controlled. Any ideas how to manipulate these files as version controlled ones? Ciao, Gregor -- -... --- .-. . -.. ..--.. ...-.-