metaonly module xdc.tools.repoman.Main |
![](../../../Arrow_up.png) |
Command implementation
This tool creates and manages package repositories. It displays
information about archived packages, extracts archived packages,
extracts repositories from bundles and deletes packages from
repositories.
[
more ... ]
metaonly module Main { ...
instance: ...
XDCscript usage |
meta-domain |
var Main = xdc.useModule('xdc.tools.repoman.Main');
module-wide constants & types
module-wide config parameters
'-t [-v] [-p pathname] [packagename...|packagefile...]',
'-n [-v] [-p pathname] [packagename...|packagefile...]',
'-x [-v] [-D] [-R] [-F] [-r destrepo] [-p path] packagename...|packagefile...',
'-x [-v] [-D] [-R] [-F] [-r destrepo] [-p path] -b bundlerepository [packagename...] bundleFile',
'-d [-v] [-F] [-r destrepo] packagename...',
'-c [-v] [-F] [--providerId] [-r destrepo] [-p pathname] packagename...',
'--rsave -f file [-p searchpath] repository...',
'--rrestore -f file [-p searchpath] [index-spec]',
'--rcreate -f file [-p searchpath] [index-spec] destrepository...',
'[-F] --providerId providerId [repository...]'
];
module-wide functions
per-instance config parameters
per-instance functions
metaonly module Main inherits ICmd {
module-wide constants & types
};
};
};
};
};
module-wide config parameters
'-t [-v] [-p pathname] [packagename...|packagefile...]',
'-n [-v] [-p pathname] [packagename...|packagefile...]',
'-x [-v] [-D] [-R] [-F] [-r destrepo] [-p path] packagename...|packagefile...',
'-x [-v] [-D] [-R] [-F] [-r destrepo] [-p path] -b bundlerepository [packagename...] bundleFile',
'-d [-v] [-F] [-r destrepo] packagename...',
'-c [-v] [-F] [--providerId] [-r destrepo] [-p pathname] packagename...',
'--rsave -f file [-p searchpath] repository...',
'--rrestore -f file [-p searchpath] [index-spec]',
'--rcreate -f file [-p searchpath] [index-spec] destrepository...',
'[-F] --providerId providerId [repository...]'
];
module-wide functions
instance:
per-instance config parameters
per-instance functions
}
DETAILS
This tool creates and manages package repositories. It displays
information about archived packages, extracts archived packages,
extracts repositories from bundles and deletes packages from
repositories.
Information about archived packages can be displayed with
the '-t' and '-n' options. The '-p' argument is used to
specify a directory in which to search. If the '-p' arg is omitted,
the current directory is searched. Specific packages can searched
for by specifying one or more package names, or one or more package
archives at the end of the command line. If no packages are specified,
information on all packages found in the search directory will be
displayed.
Archived packages can be extracted to a repository with the '-x'
option. '-x -D' will extract dependent packages, too. '-x -R' will
recursively extract dependent packages. If any of the packages in
the specified package list are not compatible, the operation will
be aborted. '-F' can be used to force all packages to be extracted,
regardles of compatibility. The '-p' arg is used to specify a
directory to search in. If not specified, the current directory will
be searched. The '-x' option also extracts a repository or packages
from a bundle. In this case, the last argument specifies the bundle
from which to extract the repository. The repository to be extracted
is specified with the '-b' arg. If just packages are to be extracted,
one or more package names should follow the name of the repository
that they should be extracted from.
Packages can be deleted from a repository with '-d'. If the package
has any subdirectores that contain packages, they will be left intact.
After the package is deleted, if the package has no subdirectories
with packages, empty directories that are part of the fully qualified
package will be deleted, too.
Packages can be copied between repositories with '-c'. If the package
being copied already exists in the destination repository, it will be
deleted prior to being replaced.
The '-r' argument specifies a destination repository. If '-r' is
omitted, the repository of the current package is used. If there is
no current package, the current directory is used.
When a package name is given, it can be specified in full, such as
'ti.platforms.sim6xxx', or the wildcard characters '*' and '?' may be
used, as in 'ti.platforms.*' or 'ti.catalog.c??00'. A version/key can
also be attached to a package name in the following manner:
'ti.platforms.c6000[1,0,0,0,313835]'. A prefix of the full version/key
may also be used: 'ti.platforms.c6000[1,0]'.
If a package name has multiple matches either with or without a
version/key specified, the most recent will be selected. Wildcards may
also be used when naming a package archive file.
EXAMPLES
xs xdc.tools.repoman -t
- Displays all info on all archived packages in the current directory
xs xdc.tools.repoman -t -p C:\xdc-o19\exports
- Displays all info on all archived packages in C:\xdc-o19\exports
xs xdc.tools.repoman -t -p C:\xdc-o19\exports ti.platforms.*
- Displays all info on archived packages whose names begin with
ti.platforms. in C:\xdc-o19\exports
xs xdc.tools.repoman -t -p C:\xdc-o19\exports ti_platforms*.tar
- Displays all info on packages in files that match ti_platforms*.tar
in C:\xdc-o19\exports
xs xdc.tools.repoman -t -p C:\xdc-o19\exports ti.catalog.c6000 ti.catalog.sim6xxx
- Displays all info on archived packages ti.catalog.c6000 and
ti.catalog.sim6xxx in C:\xdc-o19\exports
xs xdc.tools.repoman -x
- Extracts all archived packages in the current directory to the current
repository
xs xdc.tools.repoman -x -r C:\myrepo\packages -p C:\exports
- Extracts all archived packages in C:\exports to C:\myrepo\packages
repository
xs xdc.tools.repoman -x -r C:\myrepo\packages -p C:\exports ti.catalog.*
- Extracts packages matching ti.catalog.* from c:\exports to
c:\myrepo\packages
xs xdc.tools.repoman -x -r C:\myrepo\packages C:\exports\ti_catalog*.tar
- Extracts packages from files matching C:\exports\ti_catalog*.tar
to c:\myrepo\packages
xs xdc.tools.repoman -x -r C:\myrepo\packages C:\exports\ti_catalog*.tar
- Extracts packages from files matching C:\exports\ti_catalog*.tar
to c:\myrepo\packages
xs xdc.tools.repoman -x -R -r C:\myrepo -p C:\xdc-o19\exports ti.platforms.sim6xxx
- Extracts the package ti.platforms.sim6xxx and all recursively
dependent packages from C:\xdc-o19\exports to C:\myrepo
xs xdc.tools.repoman -x -r C:\ -b packages C:\exports\xdc_core.tar.gz
- Extracts the repository 'packages' from bundle
C:\exports\xdc_core.tar.gz to C:\
xs xdc.tools.repoman -x -r C:\myrepo -b examples ti.xdais.dm.examples.videnc1_copy
C:\xdais_6_24.tar.gz
- Extracts the package ti.xdais.dm.examples.videnc1_copy from repository
'examples' in bundle
C:\xdais_6_24.tar.gz to C:\myrepo
xs xdc.tools.repoman -c -r C:\destdir\packages -p C:\srcdir\packages ti.catalog.c6000
- Copies the package ti.catalog.c6000 from C:\srcdir\packages to
C:\destdir\packages
xs xdc.tools.repoman --rsave -f c:/repoinfo.rmn -p c:/pkgarchives;c:/testpkgs c:/myrepo
- Saves package information for repository c:/myrepo to file c:/repoinfo.rmn.
Also saves the search path c:/pkgarchives;c:/testpkgs
xs xdc.tools.repoman --rrestore -f c:/repoinfo.rmn -p c:/pkgarchives;c:/testpkgs
- Restores all of the packages in the repository referenced in
c:/repoinfo.rmn. Uses the search path c:/pkgarchives;c:/testpkgs to find
and copy packages. Will create the repository if it doesn't exist.
xs xdc.tools.repoman --rcreate -f c:/repoinfo.rmn -p
c:/pkgarchives;c:/testpkgs c:/mynewrepo
- Creates the new repository c:/mynewrepo from the repository referenced in
the file c:/repoinfo.rmn. Uses the search path c:/pkgarchives;c:/testpkgs
to find and copy packages. If successful, the newly created repository
will be identical to its predecessor referenced in c:/repoinfo.rmn.
xs xdc.tools.repoman --providerId my_codec_engine c:/codec_engine_2_23/mypackages
- Assigns the providerId attribute in c:/codec_engine_2_23/mypackages/.repo.xml
the value my_codec_engine. If c:/codec_engine_2_23/mypackages/.repo.xml does not
exist, it will be created.
struct Main.NameResults |
![](../../../Arrow_up.png) |
XDCscript usage |
meta-domain |
var obj = new Main.NameResults;
// array of PkgName structures
struct Main.Pkg |
![](../../../Arrow_up.png) |
XDCscript usage |
meta-domain |
var obj = new Main.Pkg;
obj.name = String ...
obj.file = String ...
obj.release = String ...
obj.label = String ...
obj.version = String ...
obj.date = String ...
obj.buildable = String ...
obj.reqs = String[] ...
obj.refs = String[] ...
struct Main.PkgName |
![](../../../Arrow_up.png) |
XDCscript usage |
meta-domain |
var obj = new Main.PkgName;
obj.name = String ...
struct Main.Repo |
![](../../../Arrow_up.png) |
represents a repository in a bundle
XDCscript usage |
meta-domain |
var obj = new Main.Repo;
obj.name = String ...
obj.pkg = String[] ...
struct Main.Results |
![](../../../Arrow_up.png) |
XDCscript usage |
meta-domain |
var obj = new Main.Results;
obj.repository = String ...
obj.providerId = String ...
obj.producerId = String ...
obj.writable = Bool ...
// array of package info structures
config Main.usage // module-wide |
![](../../../Arrow_up.png) |
Usage for this command
XDCscript usage |
meta-domain |
Main.usage = String[] [
'-t [-v] [-p pathname] [packagename...|packagefile...]',
'-n [-v] [-p pathname] [packagename...|packagefile...]',
'-x [-v] [-D] [-R] [-F] [-r destrepo] [-p path] packagename...|packagefile...',
'-x [-v] [-D] [-R] [-F] [-r destrepo] [-p path] -b bundlerepository [packagename...] bundleFile',
'-d [-v] [-F] [-r destrepo] packagename...',
'-c [-v] [-F] [--providerId] [-r destrepo] [-p pathname] packagename...',
'--rsave -f file [-p searchpath] repository...',
'--rrestore -f file [-p searchpath] [index-spec]',
'--rcreate -f file [-p searchpath] [index-spec] destrepository...',
'[-F] --providerId providerId [repository...]'
];
Main.exec( ) // module-wide |
![](../../../Arrow_up.png) |
'xs' script entry point
XDCscript usage |
meta-domain |
Main.exec( Any args ) returns Any
Main.main( ) // module-wide |
![](../../../Arrow_up.png) |
'xs' shell entry point
XDCscript usage |
meta-domain |
Main.main( Any args ) returns Any
per-instance config parameters |
![](../../../Arrow_up.png) |
XDCscript usage |
meta-domain |
var params = new Main.Params;
// Instance config-params object
params.arrFlag = Bool false;
// Return an array of strings
params.bundleRepositoryArg = String null;
// Bundle repository arg
params.copyFlag = Bool false;
// Copy package(s)
params.deleteFlag = Bool false;
// Delete package(s)
params.dependentFlag = Bool false;
// Include package dependencies
params.extractFlag = Bool false;
// Extract package(s)
params.fileArg = String null;
// file arg to save/restore repository
params.forceFlag = Bool false;
// Force incompatible packages
params.infoFlag = Bool false;
// Display package info
params.namesFlag = Bool false;
// Display package names only
params.pathArg = String null;
// Path arg
params.provIdArg = String null;
// providerId for a repository
params.rcreateFlag = Bool false;
// Create one or more repositories from information in file
params.recursiveDepFlag = Bool false;
// Recursive include package dependencies
params.repositoryArg = String null;
// Repository arg
params.rrestoreFlag = Bool false;
// Restore one or more repositories from information in file
params.rsaveFlag = Bool false;
// Save a repository's information to file
params.verboseFlag = Bool false;
// Print informative messages during execution
params.xmlFlag = Bool false;
// Return a Results struct as XML
config Main.arrFlag // per-instance |
![](../../../Arrow_up.png) |
Return an array of strings
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.arrFlag = Bool false;
config Main.bundleRepositoryArg // per-instance |
![](../../../Arrow_up.png) |
Bundle repository arg
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.bundleRepositoryArg = String null;
config Main.copyFlag // per-instance |
![](../../../Arrow_up.png) |
Copy package(s)
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.copyFlag = Bool false;
config Main.deleteFlag // per-instance |
![](../../../Arrow_up.png) |
Delete package(s)
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.deleteFlag = Bool false;
config Main.dependentFlag // per-instance |
![](../../../Arrow_up.png) |
Include package dependencies
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.dependentFlag = Bool false;
config Main.extractFlag // per-instance |
![](../../../Arrow_up.png) |
Extract package(s)
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.extractFlag = Bool false;
config Main.fileArg // per-instance |
![](../../../Arrow_up.png) |
file arg to save/restore repository
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.fileArg = String null;
config Main.forceFlag // per-instance |
![](../../../Arrow_up.png) |
Force incompatible packages
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.forceFlag = Bool false;
config Main.infoFlag // per-instance |
![](../../../Arrow_up.png) |
Display package info
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.infoFlag = Bool false;
config Main.namesFlag // per-instance |
![](../../../Arrow_up.png) |
Display package names only
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.namesFlag = Bool false;
config Main.pathArg // per-instance |
![](../../../Arrow_up.png) |
Path arg
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.pathArg = String null;
config Main.provIdArg // per-instance |
![](../../../Arrow_up.png) |
providerId for a repository
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.provIdArg = String null;
config Main.rcreateFlag // per-instance |
![](../../../Arrow_up.png) |
Create one or more repositories from information in file
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.rcreateFlag = Bool false;
config Main.recursiveDepFlag // per-instance |
![](../../../Arrow_up.png) |
Recursive include package dependencies
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.recursiveDepFlag = Bool false;
config Main.repositoryArg // per-instance |
![](../../../Arrow_up.png) |
Repository arg
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.repositoryArg = String null;
config Main.rrestoreFlag // per-instance |
![](../../../Arrow_up.png) |
Restore one or more repositories from information in file
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.rrestoreFlag = Bool false;
config Main.rsaveFlag // per-instance |
![](../../../Arrow_up.png) |
Save a repository's information to file
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.rsaveFlag = Bool false;
config Main.verboseFlag // per-instance |
![](../../../Arrow_up.png) |
Print informative messages during execution
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.verboseFlag = Bool false;
config Main.xmlFlag // per-instance |
![](../../../Arrow_up.png) |
Return a Results struct as XML
XDCscript usage |
meta-domain |
var params = new Main.Params;
...
params.xmlFlag = Bool false;
Main.run( ) // per-instance |
![](../../../Arrow_up.png) |
Underlying implementation
XDCscript usage |
meta-domain |
generated on Fri, 25 Jun 2010 00:01:21 GMT