User Tools

Site Tools


en:user_advanced:command_line_building

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:user_advanced:command_line_building [2018/03/13 00:57] kjdonen:user_advanced:command_line_building [2023/03/13 01:46] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +
 +
 +
 ====== Command Line Building ====== ====== Command Line Building ======
 It is possible to create and build collections directly from the command line. This It is possible to create and build collections directly from the command line. This
Line 22: Line 25:
 ==== Set up Greenstone environment ==== ==== Set up Greenstone environment ====
  
-To begin, you will need to open a terminal window, and set up the Greenstone environment. In the terminal, change directory to the greenstone top level folder.+To begin, you will need to open a terminal window (see [[#opening_a_terminal_on_windows | below]]), and set up the Greenstone environment. In the terminal, change directory to the greenstone top level folder.
 Run the following command to setup the environment: Run the following command to setup the environment:
  
Line 80: Line 83:
 This is the process of converting the original documents, which might be a mixture of file types, into a standardised XML based format - the Greenstone archive format. Original source documents live in the import folder of a collection, while the archive documents live in the archives folder.   This is the process of converting the original documents, which might be a mixture of file types, into a standardised XML based format - the Greenstone archive format. Original source documents live in the import folder of a collection, while the archive documents live in the archives folder.  
  
-The command to import a collection is ''import.pl''. Type ''perl S import.pl'' at the prompt to get a list of all the options for the import program, or view them [[script_options#import.pl|here]].+The command to import a collection is ''import.pl''. Type ''perl -S import.pl'' at the prompt to get a list of all the options for the import program, or view them [[script_options#import.pl|here]].
  
 ^Greenstone version^Import command^ ^Greenstone version^Import command^
-|2|perl S import.pl <collname>+|2|perl -S import.pl <collname>
-|3|perl S import.pl -site localsite <collname>|+|3|perl -S import.pl -site localsite <collname>|
  
 As before, you need to put in your own collection name, and change the site name if you are using a custom greenstone3 site. As before, you need to put in your own collection name, and change the site name if you are using a custom greenstone3 site.
Line 98: Line 101:
  
 The next phase is to “build” the collection, which creates all the indexes and databases that make the collection work.  The next phase is to “build” the collection, which creates all the indexes and databases that make the collection work. 
-Type ''perl S buildcol.pl'' at the command prompt for a list of collection-building options, which are also listed [[script_options#buildcol.pl|here]]. +Type ''perl -S buildcol.pl'' at the command prompt for a list of collection-building options, which are also listed [[script_options#buildcol.pl|here]]. 
 For now, stick to the defaults by typing For now, stick to the defaults by typing
  
 ^Greenstone version^Build command^ ^Greenstone version^Build command^
-|2|perl S buildcol.pl <collname>+|2|perl -S buildcol.pl <collname>
-|3|perl S buildcol.pl -site localsite <collname>|+|3|perl -S buildcol.pl -site localsite <collname>|
  
 Again, don't worry about the “progress report” text that scrolls past. Again, don't worry about the “progress report” text that scrolls past.
Line 115: Line 118:
  
 ^Greenstone version^Activate command^ ^Greenstone version^Activate command^
-|2|perl S activate.pl <collname>+|2|perl -S activate.pl <collname>
-|3|perl S activate.pl -site localsite <collname>|+|3|perl -S activate.pl -site localsite <collname>|
  
 Or manually: Or manually:
Line 133: Line 136:
 ==== Create a collection ==== ==== Create a collection ====
  
-To create the ''skeleton'' of a collection we use mkcol.pl. This creates all the folders the collection needs, and sets up a default configuration.  Typing ''perl S mkcol.pl'' will provide +To create the ''skeleton'' of a collection we use mkcol.pl. This creates all the folders the collection needs, and sets up a default configuration.  Typing ''perl -S mkcol.pl'' will provide 
 the full list of options, which you can also view [[script_options#mkcol.pl|here]].  the full list of options, which you can also view [[script_options#mkcol.pl|here]]. 
  
Line 146: Line 149:
  
 ^Greenstone version^mkcol command^ ^Greenstone version^mkcol command^
-|2|perl -S mkcol.pl creator [email protected] <collname>+|2|perl -S mkcol.pl -creator [email protected] <collname>
-|3|perl -S mkcol.pl -site localsite creator [email protected] <collname>|+|3|perl -S mkcol.pl -site localsite -creator [email protected] <collname>|
  
  
Line 201: Line 204:
 (like [[en:user_advanced:command_line_download|downloading]] documents). You can take a look at (like [[en:user_advanced:command_line_download|downloading]] documents). You can take a look at
  the [[script_options|scripts and their options]] to get an idea of what else is available.  the [[script_options|scripts and their options]] to get an idea of what else is available.
- 
  
en/user_advanced/command_line_building.1520902675.txt.gz · Last modified: 2018/03/13 00:57 by kjdon