Skip to content

scanoss/ado-code-scan

Repository files navigation

Azure DevOps Code Scan Task

The SCANOSS Code Scan task enhances your software development process by automatically scanning your code for security vulnerabilities and license compliance with configurable policies.

Usage

Installation Instructions

To install the SCANOSS Code Scan task, please consult the Visual Studio Marketplace guide here.

Detailed Information

For more detailed usage instructions, please refer to the OVERVIEW.md document.

Development Guide

This guide provides step-by-step instructions for deploying a new package for your project. Ensure all steps are followed to maintain version consistency and successful deployment.

Prerequisites

  • Node.js: Ensure Node.js and npm are installed.
  • Azure DevOps Extension Tool (tfx): Install the TFS cross-platform command-line interface (tfx).
  • jq: Install jq for JSON processing.

Installation

Run the following command to install the project dependencies:

make install

Tests

Before building the app, run test suites.

make test

Publish

Development

Update Version for Publishing

To streamline the app versioning process for development:

  1. Update the version in the package.json file.

Building the App for Development

To build the app for a development environment:

make package_dev

macOS (ARM64) Building for Development

For macOS users with ARM64 architecture, run the following command:

make package_dev_mac_arm64

For more details see the following issue.

Publish the App to Development

  1. Generate a publishing token. For instructions on how to generate the token, refer to Publish from the Command Line.

  2. Publish the app using the following command:

tfx extension publish --manifest-globs vss-extension-dev.json --publisher SCANOSS --token $MSFT_PERSONAL_ACCESS_TOKEN

Production

Update Version for Publishing

  1. Ensure that the version in the package.json file is updated.

  2. Build the app with the following command:

make upgrade_version

Build the App for Production

To build the app for the production environment, run:

make package

Publish the App to Production

  1. Generate a publishing token. For instructions on how to generate the token, refer to Publish from the Command Line.

  2. Publish the app using the following command:

tfx extension publish --manifest-globs vss-extension.json vss-extension-release.json --publisher SCANOSS --token $MSFT_PERSONAL_ACCESS_TOKEN