src/Doc/System/Sessions.thy
changeset 69811 18f61ce86425
parent 69755 2fc85ce1f557
child 69854 cc0b3e177b49
equal deleted inserted replaced
69810:a23d6ff31f79 69811:18f61ce86425
   143   structure of the \<open>files\<close> is preserved, which allows to reconstruct the
   143   structure of the \<open>files\<close> is preserved, which allows to reconstruct the
   144   original directory hierarchy of \<open>base_dir\<close>. The default \<open>base_dir\<close> is
   144   original directory hierarchy of \<open>base_dir\<close>. The default \<open>base_dir\<close> is
   145   \<^verbatim>\<open>document\<close> within the session root directory.
   145   \<^verbatim>\<open>document\<close> within the session root directory.
   146 
   146 
   147   \<^descr> \isakeyword{export_files}~\<open>(\<close>\isakeyword{in}~\<open>target_dir) [number]
   147   \<^descr> \isakeyword{export_files}~\<open>(\<close>\isakeyword{in}~\<open>target_dir) [number]
   148   patterns\<close> writes theory exports to the file-system: the \<open>target_dir\<close>
   148   patterns\<close> specifies theory exports that may get written to the file-system,
   149   specification is relative to the session root directory; its default is
   149   e.g. via @{tool_ref build} with option \<^verbatim>\<open>-e\<close> (\secref{sec:tool-build}). The
   150   \<^verbatim>\<open>export\<close>. Exports are selected via \<open>patterns\<close> as in @{tool_ref export}
   150   \<open>target_dir\<close> specification is relative to the session root directory; its
   151   (\secref{sec:tool-export}). The number given in brackets (default: 0)
   151   default is \<^verbatim>\<open>export\<close>. Exports are selected via \<open>patterns\<close> as in @{tool_ref
   152   specifies elements that should be pruned from each name: it allows to reduce
   152   export} (\secref{sec:tool-export}). The number given in brackets (default:
   153   the resulting directory hierarchy at the danger of overwriting files due to
   153   0) specifies elements that should be pruned from each name: it allows to
   154   loss of uniqueness.
   154   reduce the resulting directory hierarchy at the danger of overwriting files
       
   155   due to loss of uniqueness.
   155 \<close>
   156 \<close>
   156 
   157 
   157 
   158 
   158 subsubsection \<open>Examples\<close>
   159 subsubsection \<open>Examples\<close>
   159 
   160 
   286     -X NAME      exclude sessions from group NAME and all descendants
   287     -X NAME      exclude sessions from group NAME and all descendants
   287     -a           select all sessions
   288     -a           select all sessions
   288     -b           build heap images
   289     -b           build heap images
   289     -c           clean build
   290     -c           clean build
   290     -d DIR       include session directory
   291     -d DIR       include session directory
       
   292     -e           export files from session specification into file-system
   291     -f           fresh build
   293     -f           fresh build
   292     -g NAME      select session group NAME
   294     -g NAME      select session group NAME
   293     -j INT       maximum number of parallel jobs (default 1)
   295     -j INT       maximum number of parallel jobs (default 1)
   294     -k KEYWORD   check theory sources for conflicts with proposed keywords
   296     -k KEYWORD   check theory sources for conflicts with proposed keywords
   295     -l           list session source files
   297     -l           list session source files
   370   of sessions, as required for other sessions to continue later on.
   372   of sessions, as required for other sessions to continue later on.
   371 
   373 
   372   \<^medskip>
   374   \<^medskip>
   373   Option \<^verbatim>\<open>-c\<close> cleans the selected sessions (all descendants wrt.\ the session
   375   Option \<^verbatim>\<open>-c\<close> cleans the selected sessions (all descendants wrt.\ the session
   374   parent or import graph) before performing the specified build operation.
   376   parent or import graph) before performing the specified build operation.
       
   377 
       
   378   \<^medskip>
       
   379   Option \<^verbatim>\<open>-e\<close> executes the \isakeyword{export_files} directives from the ROOT
       
   380   specification of all explicitly selected sessions: the status of the session
       
   381   build database needs to be OK, but the session could have been built
       
   382   earlier. Using \isakeyword{export_files}, a session may serve as abstract
       
   383   interface for add-on build artefacts, but these are only materialized on
       
   384   explicit request: without option \<^verbatim>\<open>-e\<close> there is no effect on the physical
       
   385   file-system yet.
   375 
   386 
   376   \<^medskip>
   387   \<^medskip>
   377   Option \<^verbatim>\<open>-f\<close> forces a fresh build of all selected sessions and their
   388   Option \<^verbatim>\<open>-f\<close> forces a fresh build of all selected sessions and their
   378   requirements.
   389   requirements.
   379 
   390