emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Uniquely url-ify sentences?
@ 2011-03-05 19:38 Ross A. Laird
  2011-03-07 21:54 ` Jason Dunsmore
  2011-03-17  9:50 ` Bastien
  0 siblings, 2 replies; 4+ messages in thread
From: Ross A. Laird @ 2011-03-05 19:38 UTC (permalink / raw)
  To: emacs-orgmode


Although most users of orgmode and emacs seem to be members of the
programming world, a few professional writers also use these tools (and
I cannot imagine why everyone else uses Word...). As a writer and
non-programmer, I have a task that is probably very simple for a
programmer but seems a bit complicated to me. It's something that could
be done in many different ways, but I'd like to do it in orgmode/emacs with the
simplest possible workflow. Here's the situation:

I have a narrative manuscript. I'd like to post one sentence from this
manuscript every day as a tweet with a link back to the sentence (and
then show the previous and next paragraphs of the manuscript on the page
that is linked from the tweet). The manuscript is in an org file (I also
have a version in LaTeX). Given my limited knowledge, I imagine I
could do this with a macro in emacs:

1. From the beginning of the first sentence, search to dot-then-space
(or zap to dot, or something similar).

2. Insert line break (or move sentence into another buffer).

3. Go to end of sentence and insert unique link anchor (main url plus
incremented line number or part of sentence or something similar).

4. Use the list of sentences with links as daily tweets.

This type of macro workflow would probably work, with some fiddling, but
I find that with macros there is always something to mess up the
workflow at some point. For example, in this case, there may be some
situation in which dot-space does not define the sentence precisely
(ellipses, say, or a sentence that ends with an exclamation). I predict
this will happen (it seems to happen every time with macros), and I
wonder if I should try some other approach.

What do you think might be the best way to do this? Is there a way to
uniquely url-ify sentences? If so, I could just create a second version
of the manuscript and url-ify the whole thing in one step. All I really
need is to create a unique anchor (#) for each sentence. The main url
can be consistent through the whole thing.

Feedback and suggestions most welcome.

Ross

-- 
Ross A. Laird, PhD
www.rosslaird.com

^ permalink raw reply	[flat|nested] 4+ messages in thread
* Uniquely url-ify sentences?
@ 2011-03-05 19:40 Ross A. Laird
  0 siblings, 0 replies; 4+ messages in thread
From: Ross A. Laird @ 2011-03-05 19:40 UTC (permalink / raw)
  To: emacs-orgmode


Although most users of orgmode and emacs seem to be members of the
programming world, a few professional writers also use these tools (and
I cannot imagine why everyone else uses Word...). As a writer and
non-programmer, I have a task that is probably very simple for a
programmer but seems a bit complicated to me. It's something that could
be done in many different ways, but I'd like to do it in orgmode/emacs with the
simplest possible workflow. Here's the situation:

I have a narrative manuscript. I'd like to post one sentence from this
manuscript every day as a tweet with a link back to the sentence (and
then show the previous and next paragraphs of the manuscript on the page
that is linked from the tweet). The manuscript is in an org file (I also
have a version in LaTeX). Given my limited knowledge, I imagine I
could do this with a macro in emacs:

1. From the beginning of the first sentence, search to dot-then-space
(or zap to dot, or something similar).

2. Insert line break (or move sentence into another buffer).

3. Go to end of sentence and insert unique link anchor (main url plus
incremented line number or part of sentence or something similar).

4. Use the list of sentences with links as daily tweets.

This type of macro workflow would probably work, with some fiddling, but
I find that with macros there is always something to mess up the
workflow at some point. For example, in this case, there may be some
situation in which dot-space does not define the sentence precisely
(ellipses, say, or a sentence that ends with an exclamation). I predict
this will happen (it seems to happen every time with macros), and I
wonder if I should try some other approach.

What do you think might be the best way to do this? Is there a way to
uniquely url-ify sentences? If so, I could just create a second version
of the manuscript and url-ify the whole thing in one step. All I really
need is to create a unique anchor (#) for each sentence. The main url
can be consistent through the whole thing.

Feedback and suggestions most welcome.

Ross

-- 
Ross A. Laird, PhD
www.rosslaird.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-03-17  9:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-05 19:38 Uniquely url-ify sentences? Ross A. Laird
2011-03-07 21:54 ` Jason Dunsmore
2011-03-17  9:50 ` Bastien
  -- strict thread matches above, loose matches on Subject: below --
2011-03-05 19:40 Ross A. Laird

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).