From: stardiviner <numbchild@gmail.com>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: emacs-orgmode@gnu.org
Subject: Re: [ANN] Changes to link syntax
Date: Mon, 18 Mar 2019 09:04:25 +0800 [thread overview]
Message-ID: <8736nlkn6u.fsf@gmail.com> (raw)
In-Reply-To: <87wol0tnjr.fsf@nicolasgoaziou.fr>
Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:
> Hello,
>
> stardiviner <numbchild@gmail.com> writes:
>
>> Hi, @Nicolas, will you release a method to update all existing Org
>> file links?
>
> This is not limited to file links.
>
> There is no method that can, with certainty, convert old syntax into the
> new one. More accurately, it is possible to convert them with:
>
> (org-link-escape (org-link-decode URI))
>
> but in some cases, it may be difficult to tell when the URI should be
> decoded in the first place.
>
> I suggest to first try the linter on a document. Once we know it detects
> with a good ratio links to convert, we can write a wrapper to also
> convert them.
I agree, but I have so many Org files.
#+begin_src sh :async
find ~/Org/ -iname "*.org" -print | wc -l
#+end_src
#+RESULTS[<2019-03-16 16:34:21> d5afbee25c7529c23db70bb758b4bb1e7bdad9a3]:
: 9872
So I have to consider a safer and larger method to upgrade link. I can't
manually open every Org files and run linter on them. (Maybe linter can run on
Org files automatically in programtically way?) Seems I can wait for better
solution now.
>
>> I don't know which special escaped characters need to be converted.
>
> %20, %25, %5B and %5D.
This is helpful, I will try to use external command-line tools to search and
replace them. Like ripgrep.el wapper, etc. Then use wgrep mode to query-replace.
This might be more safely.
I'm wandering whether is it possible to extract my Org links out for testing
before I really apply upgrade solution on my mess Org files. Because once I
applied method, I will lose original data. Of course I can backup all files. I
did backup them regularly about 1 week repeatedly.
Also this upgrade experience can help Org Mode figure out a flow about how to do
backward compatibility broken steps. That will reduce other user's damage. :)
Seems this will keep me spin on before new link syntax commit for a while. I
always catch up the latest Org Mode code as I like it so much.
>
> Regards,
Thanks for your working :)
--
[ 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
next prev parent reply other threads:[~2019-03-18 1:04 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-10 17:19 [ANN] Changes to link syntax Nicolas Goaziou
2019-03-10 20:02 ` Samuel Wales
2019-03-10 22:13 ` Amin Bandali
2019-03-12 13:44 ` Nicolas Goaziou
2019-03-10 23:00 ` Daniele Nicolodi
2019-03-11 16:35 ` Nicolas Goaziou
2019-03-11 17:06 ` Eric S Fraga
2019-03-11 17:31 ` Daniele Nicolodi
2019-03-11 17:27 ` Marco Wahl
2019-03-11 18:00 ` Diego Zamboni
2019-03-11 23:07 ` Nicolas Goaziou
2019-03-12 5:42 ` Diego Zamboni
2019-03-15 5:23 ` stardiviner
2019-03-15 10:55 ` Nicolas Goaziou
2019-03-18 1:04 ` stardiviner [this message]
2019-03-18 21:33 ` Nicolas Goaziou
2019-03-19 8:06 ` stardiviner
2019-03-15 11:55 ` Nicolas Goaziou
2019-03-26 9:08 ` stardiviner
2019-03-27 2:00 ` stardiviner
2019-04-02 21:16 ` Nicolas Goaziou
2019-04-07 11:20 ` stardiviner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8736nlkn6u.fsf@gmail.com \
--to=numbchild@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=mail@nicolasgoaziou.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).