From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Koch Subject: org-attach should detect git also higher in the filesystem Date: Mon, 05 Aug 2013 23:58:11 +0200 Message-ID: <4738097.ljaNXQUGza@x121e> Reply-To: thomas@koch.ro Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37607) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V6SnH-00063y-41 for emacs-orgmode@gnu.org; Mon, 05 Aug 2013 17:58:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V6SnA-0006KW-VH for emacs-orgmode@gnu.org; Mon, 05 Aug 2013 17:58:23 -0400 Received: from koch.ro ([88.198.2.104]:49802) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V6SnA-0006KQ-Oo for emacs-orgmode@gnu.org; Mon, 05 Aug 2013 17:58:16 -0400 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Cc: John Wiegley Hi, I tested org-attach with the org file being inside a git repo. I observed that the auto-commit feature of org-attach seems to work only if the data directory is the root of a git repo (detected by looking for a .git folder in the data folder). I'd like however to have the org file in the git repo too and the data folder being a sub-folder of the git repo. Actually I'd also like to use git-annex here. Some options of git rev-parse might be helpful here instead of coding the repo detection check by hand in elisp: --show-toplevel Show the absolute path of the top-level directory. --is-inside-work-tree When the current working directory is inside the work tree of the repository print "true", otherwise "false". What do you think? Regards, Thomas Koch, http://www.koch.ro