emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Document backward-incompatible change in ORG-NEWS? (was: [BUG] Recen


From: stardiviner
Subject: Re: Document backward-incompatible change in ORG-NEWS? (was: [BUG] Recently master branch commit breaks open file: link)
Date: Tue, 25 Feb 2020 15:02:20 +0800
User-agent: mu4e 1.3.8; emacs 27.0.50

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256


Samuel Wales <address@hidden> writes:

> no opinion on anything but a suggestion.
>
> i really like these little scripts that update your org files so they
> are compatible with new org versions.
>
> perhaps one can give them an argument or something to work on all
> agenda files, or a list of files, or somethign liek that?

Sounds reasonable. Apply function on Org Agenda files will be the most case.

>
> On 2/24/20, Bastien <address@hidden> wrote:
>> Hi Nicolas,
>>
>> it seems that org-store-link stored links to headlines as
>>
>> [[*TODO headline][headline]]
>>
>> keeping the TODO keyword, if any.
>>
>> This is fixed in master but I won't if we should document this bug
>> fix in ORG-NEWS (or if org-store-link was just momentarily broken.)
>>
>> If org-store-link was storing the todo keyword, perhaps we can add
>> a command similar to this one to help users fix broken links:
>>
>> (defun org-fix-links ()
>>   "Fix ill-formatted internal links.
>> E.g. replace [[*TODO Headline][headline]] by [[*Headline][headline]].
>> Go through the buffer and ask for the replacement."
>>   (interactive)
>>   (visible-mode 1)
>>   (save-excursion
>>     (goto-char (point-min))
>>     (while (re-search-forward org-link-any-re nil t)
>>       (let* ((raw (match-string 2))
>>           (desc (match-string 3))
>>           fix new)
>>      (when (and raw desc
>>                 (string-match-p
>>                  (concat "^\*" (regexp-opt org-todo-keywords-1)
>>                          "\\s-+\\(.+\\)$")
>>                  raw))
>>        (setq new (replace-regexp-in-string
>>                   (concat (regexp-opt org-todo-keywords-1) "\\s-+")
>>                   "" raw))
>>        (set-text-properties 0 (length new) nil new)
>>        (setq fix (completing-read "Replace link at point by: "
>>                                   nil nil nil new))
>>        (replace-match (format "[[%s][%s]]" fix desc))))))
>>   (visible-mode -1))
>>
>> WDYT?
>>
>> --
>>  Bastien
>>
>>


- -- 
[ stardiviner ]
       I try to make every word tell the meaning what I want to express.

       Blog: https://stardiviner.github.io/
       IRC(freenode): stardiviner, Matrix: stardiviner
       GPG: F09F650D7D674819892591401B5DF1C95AE89AC3
      
-----BEGIN PGP SIGNATURE-----

iQFIBAEBCAAyFiEE8J9lDX1nSBmJJZFAG13xyVromsMFAl5UxnwUHG51bWJjaGls
ZEBnbWFpbC5jb20ACgkQG13xyVromsPwpgf/RqdCj+Y5dC+3lRUwPwYsi8crTrYP
tOZdszU/V1mAPaEep8Q2ksJwvYBa/0TaZ7H+3M8rS55Ug9vSzQyZ/vO+MBSQIPu4
GcyWvyl6qxuWsn8YJr/2E5gGrvgCkGXbqf4tW4iSxm5gWT+Ui6wziW+c00++UFR9
40TnIVx5xx/2F3vuJGmXA9cyhm/K1O8rzG/7NUhvxypXZhFrU0Tns1WmeCUWi9/7
DPI+FRIxUBzcUlLhuZq3gHjDoCaIOie69MCFkrDFlHakr8s+rvbzokdff5C0r4vp
DCtdIgEAFUFQvcfD7v4b5+5YiYe6Aq2erX7Jrkhn1Pkguku11xNu17HeFQ==
=QjPn
-----END PGP SIGNATURE-----



reply via email to

[Prev in Thread] Current Thread [Next in Thread]