Skip to content

feat(cli): Add CLI commands for LicenseDB sync operations#3772

Open
ADITYA-CODE-SOURCE wants to merge 4 commits intoeclipse-sw360:mainfrom
ADITYA-CODE-SOURCE:fix/issue-3771-licensedb-cli
Open

feat(cli): Add CLI commands for LicenseDB sync operations#3772
ADITYA-CODE-SOURCE wants to merge 4 commits intoeclipse-sw360:mainfrom
ADITYA-CODE-SOURCE:fix/issue-3771-licensedb-cli

Conversation

@ADITYA-CODE-SOURCE
Copy link
Contributor

Summary

Add command line interface tool for LicenseDB sync operations as part of GSoC 2026 project.

Changes Made

  • Created new module: sw360-client-cli
  • Created LicenseDbCli class with following commands:
    • --test-connection: Test connection to LicenseDB
    • --sync: Trigger license sync from LicenseDB
    • --status: Get current sync status
    • --help: Show help message

Usage

# Build the CLI
mvn install -pl clients/client-cli

# Test connection
java -jar clients/client-cli/target/sw360-client-cli.jar --test-connection

# Trigger sync
java -jar clients/client-cli/target/sw360-client-cli.jar --sync

# Check status
java -jar clients/client-cli/target/sw360-client-cli.jar --status

Issue

Fixes #3771

How To Test

  1. Configure LicenseDB in sw360.properties
  2. Build the CLI module: mvn install -pl clients/client-cli
  3. Run the CLI commands:
    • Test connection: --test-connection
    • Trigger sync: --sync
    • Check status: --status

Checklist

  • All related issues are referenced in commit messages and in PR
  • License headers added to new files

Add command line interface tool for LicenseDB sync operations:
- New module: sw360-client-cli
- New class: LicenseDbCli with commands:
  * --test-connection: Test connection to LicenseDB
  * --sync: Trigger license sync from LicenseDB
  * --status: Get current sync status
  * --help: Show help message

This implements GSoC 2026 project requirement to adapt existing
CLI workflows to use LicenseDB integration.

Fixes eclipse-sw360#3771
@ADITYA-CODE-SOURCE ADITYA-CODE-SOURCE force-pushed the fix/issue-3771-licensedb-cli branch from 9fdac1a to afdcf1d Compare February 27, 2026 15:10
The CLI functionality is already available via SW360LicenseClient
in PR eclipse-sw360#3768. Reverting this module to ensure CI passes.

Fixes eclipse-sw360#3771 (functionality provided by PR eclipse-sw360#3768)
@GMishx GMishx added needs code review needs general test This is general testing, meaning that there is no org specific issue to check for labels Mar 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs code review needs general test This is general testing, meaning that there is no org specific issue to check for

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Add CLI commands for LicenseDB sync operations

2 participants