Tutorial 2 - Working with Packages

Note

Before you start:

  • Permission to add Packages.

  • Scanning requires the ScanCode.io integration (ScanCode.io).

  • Importing from the PurlDB requires the PurlDB integration (PurlDB).

  • Importing from a CSV requires a staff account.

Sign in to DejaCode.

Add a Package from a Download URL

Select Packages from the main menu bar.

Get the download URL of a publicly available package; for example, select one of the releases at https://github.com/cli/cli/tags and copy its download URL.

Click the green Add Package button and paste the download URL that you copied into the text box. Click the green Add button.

DejaCode presents the new Package.

  • Refresh your browser page to see the Scan tab.

  • Explore the scan results.

  • Select values to apply to the new Package definition, such as one or more licenses, a Copyright statement, and a Primary language.

  • Click the Set values to Package button.

  • Review, and optionally modify, the values in the modal dialog.

  • Click the Set values button.

  • Review the updated Package definition.

  • Click the Edit icon (the pencil) next to the Package name.

  • Make suitable changes to the Package definition; for example, enter text in the Description field.

  • Click the Update Package button.

  • Review the updated Package definition.

Create a Package using the data entry form

Select Packages from the main menu bar.

Select the Add Package form option from the green Add Package dropdown. Enter the values that you know, you can refer to Package model for details about each field.

Note

A Filename or a Package URL (type + name) is required. The other fields are optional.

Keep the checked default to “Automatically collect the SHA1, MD5, and Size using the Download URL and apply them to the package definition.”

Click the Add Package button.

Note

DejaCode validates your entry, creates the package, applies automatic updates, and submits a scan request to ScanCode.io if you have that enabled.

Review and edit your new package.

Import a Package to DejaCode from the PurlDB

Select PurlDB from the Integrations section of the side menu.

Use the Filters button to enter filtering or sorting criteria. For example, select Release date (descending) to see recent data. Click on the Identifier of an interesting package.

Review the data defined for the package. Click the green Create Package button.

Review and edit the new DejaCode Package definition. Click the Add Package button. DejaCode validates the entry, creates the package, and applies automatic updates.

Review and edit your new package.

Import Package Definitions from a CSV

Select Packages from the main menu bar.

Select the Import packages option from the green Add Package dropdown.

Click the Download import template button. DejaCode uses your browser to download a file named package_import_template.csv. Open that file in a spreadsheet editor (such as Excel) and save it with a meaningful name that describes the data you intend to import.

Enter the values for one or more packages into the CSV. You can get additional help for each field by clicking the Show/hide Supported Columns option on the Import form in DejaCode. Save your package import CSV.

Use the Browse… button near the bottom of the Import form to select your CSV and click the blue Upload button to import the data to DejaCode.

DejaCode validates your data. Review the results and correct your CSV as needed. Click the blue Import button to create the new packages in DejaCode.

Review the results of the Import presented by DejaCode. Optionally edit and update the new package(s). Optionally add the new package(s) to a Product using the Add to Product button.

Improve Package Data by Scanning

Select Packages from the main menu bar.

Identify and select a Package that needs to be improved. On the Scan tab, click the Submit Scan Request button.

Optionally follow the progress of the Scan by selecting Scans from the Integrations section of the side menu.

Open or refresh the Package form when the Scan is completed. Review the results on the Scan tab, select data to apply to the Package definition, modify that data as needed, and click the Set values button to save the updates.

Optionally click the Download Scan results button on the Scan tab to export a JSON-formatted file with the detailed scan results. You can view that file in a readable format using a browser such as Firefox.

Continue refining and reviewing your packages.

In Tutorial 3 - Working with Reports, we’ll go further!