FOSSology
Advancing open source analysis and development

Using FOSSology from the Command Line (0.6.1)

For release 1.0 FOSSology has only 1 command line interface. This interface is used to upload 1 or more archives into the DataBase. After the upload has been scheduled, the UI is used to track when the job(s) will be completed and to view the folders created by the upload. See the man page below for details.

cp2foss: load one or more files or archives into the fossology DB.


cp2foss: load one or more files or archives into the fossology DB.


SYNOPSIS

cp2foss [-h] {-p <folder-path> -n <folder-name> -a <path-to-archive> -d ``description'' | [-f <file-of-parameters>]} [-A]


DESCRIPTION

cp2foss (copy to foss) will load a single file or tar'ed archive into the folder specificed by -n, under the folder-path specified with -p. The folder-path and folder-name do not need to exist. cp2foss will create them as needed.

If more than a single archive needs to be loaded, a file of input parameters can be supplied using the -f option. If the -f option is used all of the other options are ignored.

Options

-A

Turn on alpha-folders. Default is off. When large amounts of archives are loaded, navigating through all the folders can be difficult. This option will group packages under alpha folders based on the 1st letter of the package name. For example, your folder path is ProjX/pass1, and the folder name is abcd. Using alpha-folders the package abcd would end up under a folder path ProjX/pass/a-c/abcd.

-a path-to-archive

Fully qualified path to the archive to load

-d 'description'

A short meaningful description the captures what the folder will hold. Description must be quoted with either single or double (``) quotes.

-n folder-name

The folder name that will be used to store the archive in the date-base. Only one upload into a file folder is allowed to avoid storing dulicate uploads. The file folder is checked to see if it has been uploaded into. If it has, no other uploads are allowed into that file folder.

Use different folder paths or folder names to upload the same archive multiple times. The underlying data will not be duplicated, it will be reused by the application software. This helps preserve disk space.

-p folder-path

The name of the folder-path that will hold the folder_name specified with -n. The folder path does not have to exist. It will be created as needed.

-f file-of-input-parameters

file-of-input-parameters is a file that contains the parameters needed to load an archive. Typical usage is to load multiple archives. For example, a file with the contents:

     -p Mysrcs -n foo -a /tmp/mysrcs/foo.c -d "the foo program"
     -p Mysrcs -n bar -a /tmp/mysrcs/bar.c -d "the bar program"
     -p Othersrc -n randy /tmp/other/randy -d 'somebodies randy program'

The above file would load 3 archives, foo.c, bar.c and randy. Folders Mysrcs and Othersrc would be created if they did not exist. folders for foo bar and randy would be placed under the parent folders. Mysrcs/foo, Mysrcs/bar, Othersrc/randy.


EXAMPLES

cp2foss -p Mom -n son -d 'sonny program, for cher' -a /pub/archive/sonny

Would load the archive called sonny in the folder son under the folder path Mom.

cp2foss -f /pub/lotsOarchives

Would read the file /pub/lotsOarchives and process each line. If there were no errors, each archive specified in each line would be uploaded into the data-base.


AUTHOR

Mark Donohoe for the Hewlett-Packard Company


SEE ALSO

 
0.6.1/using_fossology_from_the_command_line.txt · Last modified: 2008/04/01 11:58 by danger

Copyright (C) 2007-2008 Hewlett-Packard Development Company, L.P.
FOSSology Project documentation is licensed under the GNU Free Documentation License Version 1.2
Recent changes RSS feed Valid XHTML 1.0 Valid CSS Driven by DokuWiki