* [PATCH] Second proposal for ":session" doc @ 2014-12-07 10:51 Thierry Pellé 2014-12-10 21:58 ` Aaron Ecay 0 siblings, 1 reply; 3+ messages in thread From: Thierry Pellé @ 2014-12-07 10:51 UTC (permalink / raw) To: emacs-orgmode Hi, here is a proposal for some change on the ":session" header doc. Comments are welcome! Thierry diff --git a/doc/org.texi b/doc/org.texi index c1e84d4..45e177e 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -15566,7 +15566,9 @@ execution. @cindex @code{:session}, src header argument The @code{:session} header argument starts a session for an interpreted -language where state is preserved. By default, a session is not started. +language. All code block of this langage is executed into the same +interpreter process, the state of the session being preserved as long as Emacs +runs. By default, a session is not started. @itemize @bullet @item @code{none} @@ -15574,9 +15576,9 @@ The default. Each block is evaluated in its own session. The session is not preserved after the evaluation. @item @code{other} Any other string passed to the @code{:session} header argument will give the -session a name. All blocks with the same session name share the same -session. Using different session name enables concurrent sessions (even for -the same interpreted language). E.g., @code{:session mysession}. +session a name (possibly empty). All blocks with the same session name share +the same session. Using different session name enables concurrent sessions +(for the same interpreted language). E.g., @code{:session mysession} or @code{:session}. @end itemize @node noweb ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Second proposal for ":session" doc 2014-12-07 10:51 [PATCH] Second proposal for ":session" doc Thierry Pellé @ 2014-12-10 21:58 ` Aaron Ecay 2014-12-11 7:46 ` abonnements 0 siblings, 1 reply; 3+ messages in thread From: Aaron Ecay @ 2014-12-10 21:58 UTC (permalink / raw) To: abonnements, emacs-orgmode Hi Thierry, 2014ko abenudak 7an, Thierry Pellé-ek idatzi zuen: > > Hi, here is a proposal for some change on the ":session" header doc. > > Comments are welcome! > Thierry > > > diff --git a/doc/org.texi b/doc/org.texi > index c1e84d4..45e177e 100644 > --- a/doc/org.texi > +++ b/doc/org.texi > @@ -15566,7 +15566,9 @@ execution. > @cindex @code{:session}, src header argument > > The @code{:session} header argument starts a session for an interpreted > -language where state is preserved. By default, a session is not started. > +language. All code block of this langage is executed into the same ^ ^^ ^^^^ s are by > +interpreter process, the state of the session being preserved as long as Emacs ^ ^^^^^ Start a new sentence here, and change to is > +runs. By default, a session is not started. On a substantive note, “as long as Emacs runs” is not quite accurate – it’s until the interpreter process exits, which could happen because the user kills it, it crashes, a piece of code which is executed tells it to exit, ... > > @itemize @bullet > @item @code{none} > @@ -15574,9 +15576,9 @@ The default. Each block is evaluated in its own session. The session is > not preserved after the evaluation. > @item @code{other} > Any other string passed to the @code{:session} header argument will give the > -session a name. All blocks with the same session name share the same > -session. Using different session name enables concurrent sessions (even for > -the same interpreted language). E.g., @code{:session mysession}. > +session a name (possibly empty). All blocks with the same session name share I think something should be said like “If the session name is empty, a default name based on the block’s language will be used.” The session name also becomes the interpreter process’s buffer name, and leaving :session empty does not generate a buffer named “” (the empty string). (It’s also a perverse but true fact that if you specify the same session name for two blocks of different languages, they will both send their code to the same interpreter process. But for two blocks in different languages with an empty :session, they will each use their language’s default name.) > +the same session. Using different session name enables concurrent sessions > +(for the same interpreted language). E.g., @code{:session mysession} or @code{:session}. > @end itemize > > @node noweb Thanks, -- Aaron Ecay PhD candidate, Linguistics University of Pennsylvania ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Second proposal for ":session" doc 2014-12-10 21:58 ` Aaron Ecay @ 2014-12-11 7:46 ` abonnements 0 siblings, 0 replies; 3+ messages in thread From: abonnements @ 2014-12-11 7:46 UTC (permalink / raw) To: emacs-orgmode Hello thanks for this. > ^ ^^ ^^^ Sorry, but my English needs to be improved, but my French is not even better :-D > "...it’s until the interpreter process exit..." I will use your reformulation; I know just a little about the background or the internals. > “If the session name is empty, a default name based on the block’s language will be used.” Same as previous, I din't know that. Thanks. Le 10/12/2014 22:58, Aaron Ecay a écrit : > Hi Thierry, > > 2014ko abenudak 7an, Thierry Pellé-ek idatzi zuen: >> Hi, here is a proposal for some change on the ":session" header doc. >> >> Comments are welcome! >> Thierry >> >> >> diff --git a/doc/org.texi b/doc/org.texi >> index c1e84d4..45e177e 100644 >> --- a/doc/org.texi >> +++ b/doc/org.texi >> @@ -15566,7 +15566,9 @@ execution. >> @cindex @code{:session}, src header argument >> >> The @code{:session} header argument starts a session for an interpreted >> -language where state is preserved. By default, a session is not started. >> +language. All code block of this langage is executed into the same > ^ ^^ ^^^^ > s are by >> +interpreter process, the state of the session being preserved as long as Emacs > ^ ^^^^^ > Start a new sentence here, and change to is >> +runs. By default, a session is not started. > On a substantive note, “as long as Emacs runs” is not quite accurate – > it’s until the interpreter process exits, which could happen because the > user kills it, it crashes, a piece of code which is executed tells it to > exit, ... > >> >> @itemize @bullet >> @item @code{none} >> @@ -15574,9 +15576,9 @@ The default. Each block is evaluated in its own session. The session is >> not preserved after the evaluation. >> @item @code{other} >> Any other string passed to the @code{:session} header argument will give the >> -session a name. All blocks with the same session name share the same >> -session. Using different session name enables concurrent sessions (even for >> -the same interpreted language). E.g., @code{:session mysession}. >> +session a name (possibly empty). All blocks with the same session name share > I think something should be said like “If the session name is empty, a > default name based on the block’s language will be used.” The session > name also becomes the interpreter process’s buffer name, and leaving > :session empty does not generate a buffer named “” (the empty string). > > (It’s also a perverse but true fact that if you specify the same session > name for two blocks of different languages, they will both send their > code to the same interpreter process. But for two blocks in different > languages with an empty :session, they will each use their language’s > default name.) > >> +the same session. Using different session name enables concurrent sessions >> +(for the same interpreted language). E.g., @code{:session mysession} or @code{:session}. >> @end itemize >> >> @node noweb > Thanks, > ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-12-11 7:46 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2014-12-07 10:51 [PATCH] Second proposal for ":session" doc Thierry Pellé 2014-12-10 21:58 ` Aaron Ecay 2014-12-11 7:46 ` abonnements
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).