Each Semmle project defines a code base to build and index for Semmle analysis. Initially, a project only consists of a subdirectory of the
odasa/projects directory, containing all files associated with the project, and a
project configuration file. The
project file contains the information used to access a copy of your source and build the code base. This information is used to generate a snapshot of your code for you to analyze. For further information about projects, see Project.
Before you can create a new project, you need to know the following information about your code base:
- How to access the source code repository – Semmle Core requires read-only access to the repository.
- How to build or compile the project – Semmle Core analyzes the code base as a system and so must know how the various elements are built or compiled.
Basic project creation using
You can create a project using two different commands:
createProject. In most cases, the
bootstrap tool is the recommended method for creating a new project. The
bootstrap command launches an interactive project creation process, which prompts you to define:
- Basic project details – define the name of the project and the language of the code base.
- Source code extraction method – define the type and location of the repository used. Optionally, define a specific code version to analyze.
- Build method for the code base – define the build location and build method for compiled languages..
When you have defined the configuration of the project, you are then prompted to decide if you would like to add a snapshot of your code and to start analysis immediately.
The following tutorials step you through the process of using the
bootstrap tool for a variety of languages:
- Tutorial: Basic project creation (C/C++)
- Tutorial: Basic project creation (C#)
- Tutorial: Basic project creation (COBOL)
- Tutorial: Basic project creation (Go)
- Tutorial: Basic project creation (Java)
- Tutorial: Basic project creation (Python)
For examples of advanced project creation, where other methods may be more appropriate see, Advanced project creation.