From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Maus Subject: Re: Why :ID: properties? Date: Sun, 12 Sep 2010 17:30:06 +0200 Message-ID: <87vd6b9dz5.wl%dmaus@ictsoc.de> References: <4C8647D8.1010105@gmail.com> <4C864920.1030404@ccbr.umn.edu> <4C864C75.1010202@gmail.com> <87hbi11us6.fsf@gnu.org> <4C86878C.2070303@gmail.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: multipart/mixed; boundary="===============1007460494==" Return-path: Received: from [140.186.70.92] (port=41553 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OuoVb-0002oa-GO for Emacs-orgmode@gnu.org; Sun, 12 Sep 2010 11:30:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OuoVV-0007jr-P5 for Emacs-orgmode@gnu.org; Sun, 12 Sep 2010 11:30:23 -0400 Received: from mysql1.xlhost.de ([213.202.242.106]:57066) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OuoVV-0007iv-GI for Emacs-orgmode@gnu.org; Sun, 12 Sep 2010 11:30:17 -0400 In-Reply-To: <4C86878C.2070303@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Rainer M Krug Cc: Emacs-orgmode@gnu.org, Bastien --===============1007460494== Content-Type: multipart/signed; boundary="pgp-sign-Multipart_Sun_Sep_12_17:30:05_2010-1"; micalg=pgp-sha256; protocol="application/pgp-signature" Content-Transfer-Encoding: 7bit --pgp-sign-Multipart_Sun_Sep_12_17:30:05_2010-1 Content-Type: text/plain; charset=US-ASCII Rainer M Krug wrote: >-----BEGIN PGP SIGNED MESSAGE----- >Hash: SHA1 >On 07/09/10 16:40, Bastien wrote: >> Rainer M Krug writes: >> >>> On 07/09/10 16:16, Erik Iverson wrote: >>>> Did you recently start using MobileOrg? >>> >>> No - I only inserted a link, and around that time the :ID:s appeared. I >>> deleted them all manually, but they came back. >> >> I suspect you need this: >> >> (set org-link-to-org-use-id nil) >That sounds like the most likely solution - thanks. >Now I just have to find an easy way to delete all the :PROPERTIES blocks. This one should do the trick: (defun dmj:org:remove-empty-propert-drawers () "*Remove all empty property drawers in current file." (interactive) (unless (eq major-mode 'org-mode) (error "You need to turn on Org mode for this function.")) (save-excursion (goto-char (point-min)) (while (re-search-forward ":PROPERTIES:" nil t) (save-excursion (org-remove-empty-drawer-at "PROPERTIES" (match-beginning 0)))))) If called interactively in an Org mode buffer it searches for the string ":PROPERTIES:" and tells Org to remove the drawer if it is empty. Just used it to get rid of empty CLOCK drawers -- but beware: It is a very stupid function, i.e. it does not check if the string :PROPERTIES: is actually a property drawer or not. HTH, -- David -- OpenPGP... 0x99ADB83B5A4478E6 Jabber.... dmjena@jabber.org Email..... dmaus@ictsoc.de --pgp-sign-Multipart_Sun_Sep_12_17:30:05_2010-1 Content-Type: application/pgp-signature Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iF4EABEIAAYFAkyM8f0ACgkQma24O1pEeObHFgD+MjgoQwPpYtQlsTeaz+afABbk HOtfDfxogBB+HScfXFkBAOLlgBkqhQiA0VJakjj5VBk7nNHGxCF6F1akm0PnHtIg =jeSs -----END PGP SIGNATURE----- --pgp-sign-Multipart_Sun_Sep_12_17:30:05_2010-1-- --===============1007460494== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============1007460494==--