]> Creatis software - cpPlugins.git/blob - appli/bash/cpPlugins_ExecuteWorkspace.cxx
Third-party installers updated.
[cpPlugins.git] / appli / bash / cpPlugins_ExecuteWorkspace.cxx
1 #include <iostream>
2 #include <set>
3 #include <string>
4 #include <vector>
5 #include <cpPlugins_Config.h>
6
7 int main( int argc, char* argv[] )
8 {
9   if( argc == 1 )
10   {
11     std::cout << "Usage: " << argv[ 0 ] << " workspace args" << std::endl;
12     return( 1 );
13
14   } // fi
15   std::set< std::string > parameters;
16   std::set< std::string > plugins;
17
18   // Read arguments
19   std::string ws_file = argv[ 1 ];
20   for( unsigned int i = 2; i < argc; ++i )
21   {
22     std::vector< std::string > tokens;
23     cpPlugins::TokenizeString( tokens, argv[ i ], "=" );
24     if( tokens.size( ) < 2 )
25       continue;
26     if     ( tokens[ 0 ] == "pl" ) plugins.insert( tokens[ 1 ] );
27     else if( tokens[ 0 ] == "pa" ) parameters.insert( tokens[ 1 ] );
28
29   } // rof
30   return( 0 );
31 }
32
33 // eof - $RCSfile$