{"id":23282773,"url":"https://github.com/itsallcode/openfasttrace-gradle","last_synced_at":"2025-08-19T21:04:39.874Z","repository":{"id":16285755,"uuid":"79667933","full_name":"itsallcode/openfasttrace-gradle","owner":"itsallcode","description":"Gradle plugin for OpenFastTrace (https://github.com/itsallcode/openfasttrace)","archived":false,"fork":false,"pushed_at":"2025-08-03T07:40:35.000Z","size":849,"stargazers_count":5,"open_issues_count":1,"forks_count":2,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-08-03T09:12:23.221Z","etag":null,"topics":["gradle","gradle-plugin","javascript","openfasttrace","openfasttrack","quality-assurance","requirements-management","requirements-tracing"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/itsallcode.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-01-21T19:32:07.000Z","updated_at":"2025-08-03T07:38:13.000Z","dependencies_parsed_at":"2023-12-02T07:30:08.571Z","dependency_job_id":"b604a1f7-4230-4cd5-a6e2-b4f6b98d6251","html_url":"https://github.com/itsallcode/openfasttrace-gradle","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/itsallcode/openfasttrace-gradle","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsallcode%2Fopenfasttrace-gradle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsallcode%2Fopenfasttrace-gradle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsallcode%2Fopenfasttrace-gradle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsallcode%2Fopenfasttrace-gradle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/itsallcode","download_url":"https://codeload.github.com/itsallcode/openfasttrace-gradle/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsallcode%2Fopenfasttrace-gradle/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271222790,"owners_count":24721540,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-19T02:00:09.176Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gradle","gradle-plugin","javascript","openfasttrace","openfasttrack","quality-assurance","requirements-management","requirements-tracing"],"created_at":"2024-12-20T00:29:38.198Z","updated_at":"2025-08-19T21:04:39.861Z","avatar_url":"https://github.com/itsallcode.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# openfasttrace-gradle\nGradle plugin for the requirement tracing suite [OpenFastTrace](https://github.com/itsallcode/openfasttrace).\n\n## Project Information\n\n[![Java CI with Gradle](https://github.com/itsallcode/openfasttrace-gradle/workflows/Java%20CI%20with%20Gradle/badge.svg)](https://github.com/itsallcode/openfasttrace-gradle/actions?query=workflow%3A%22Java+CI+with+Gradle%22)\n[![Sonarcloud Quality Gate](https://sonarcloud.io/api/project_badges/measure?project=org.itsallcode%3Aopenfasttrace-gradle\u0026metric=alert_status)](https://sonarcloud.io/dashboard?id=org.itsallcode%3Aopenfasttrace-gradle)\n[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=org.itsallcode%3Aopenfasttrace-gradle\u0026metric=coverage)](https://sonarcloud.io/dashboard?id=org.itsallcode%3Aopenfasttrace-gradle)\n\n* [Blog](https://blog.itsallcode.org/)\n* [Changelog](CHANGELOG.md)\n* [Contributing guide](CONTRIBUTING.md)\n* [OpenFastTrace stories](https://github.com/itsallcode/openfasttrace/wiki/OFT-Stories)\n\n## Usage\n\n1. Preconditions: Java 17 and Gradle 8.6\n1. Add plugin [`org.itsallcode.openfasttrace`](https://plugins.gradle.org/plugin/org.itsallcode.openfasttrace) to your project:\n\n    ```groovy\n    plugins {\n      id \"org.itsallcode.openfasttrace\" version \"3.1.0\"\n    }\n    ```\n\n1. Configure your project, see [examples](https://github.com/itsallcode/openfasttrace-gradle/tree/main/example-projects)\n1. Run\n\n    ```sh\n    ./gradlew traceRequirements\n    ```\n\n1. Report is written to `build/reports/tracing.txt` by default.\n\n### General Configuration\n\n```groovy\nrequirementTracing {\n  failBuild = true\n  inputDirectories = files('custom-dir')\n  reportFile = file('build/custom-report.txt')\n  reportFormat = 'plain'\n  reportVerbosity = 'failure_details'\n  detailsSectionDisplay = 'collapse'\n  filteredArtifactTypes = [\"req\", \"dsn\"]\n}\n```\n\nYou can configure the following properties:\n\n* `failBuild`: Fail build when tracing finds any issues (default: `true`)\n* `inputDirectories`: Files or directories to import\n* `reportFile`: Path to the report file\n* `reportFormat`: Format of the report\n  * `plain` - Plain Text (default)\n  * `html` - HTML\n* `reportVerbosity`: Report verbosity\n  * `quiet` - no output (in case only the return code is used)\n  * `minimal` - display ok or not ok\n  * `summary` - display only the summary, not individual specification items\n  * `failures` - list of defect specification items\n  * `failure_summaries` - list of summaries for defect specification items\n  * `failure_details` - summaries and details for defect specification items (default)\n  * `all` - summaries and details for all specification items\n* `detailsSectionDisplay`: Initial display status of the details section in the HTML report\n  * `collapse` - hide details (default)\n  * `expand` - show details\n* `filteredArtifactTypes`: Use only the listed artifact types during tracing\n\n### Configuring the Short Tag Importer\n\nThe short tag importer allows omitting artifact type and the covered artifact type. Optionally you can add a prefix to the item name, e.g. a common module name.\n\n```groovy\nrequirementTracing {\n  tags {\n    tag {\n      paths = fileTree(dir: 'src/').include '*.impl.*'\n      coveredItemNamePrefix = 'prefix'\n      tagArtifactType = 'impl'\n      coveredItemArtifactType = 'dsn'\n    }\n    tag {\n      paths = fileTree(dir: 'src/').include '*.test.*'\n      tagArtifactType = 'utest'\n      coveredItemArtifactType = 'dsn'\n    }\n  }\n}\n```\n\nAs a benefit the tags are much shorter and contain only the name and revision:\n\n```java\n// [[tagname:1]]\n```\n\nSee [multi-project/sub1](https://github.com/itsallcode/openfasttrace-gradle/tree/main/example-projects/multi-project/sub1) for a basic example.\n\n### Sharing Requirements\n\nIn bigger setups you might want to share requirements between multiple projects.\n\nExample: The Software Architecture Design project `swad` contains overall requirements that must be fulfilled by projects `component-a` and `component-b`.\n\n1. The `swad` project publishes its requirements as a zip file `swad-req` to a Maven repository.\n1. Both components import these requirements and cover them in their Software Detailed Design (swdd).\n1. Both components publish their requirements as artefacts `component-a-req` and `component-b-req` to the shared Maven repository.\n1. A regular job check that all requirements from `swad` are covered by tracing `swad-req`, `component-a-req` and `component-b-req`.\n\n#### Publishing Requirements to a Maven Repository\n\nIf you want to publish requirements to a Maven repository you can use the following configuration in your `build.gradle`:\n\n```groovy\nplugins {\n  id 'org.itsallcode.openfasttrace'\n  id 'maven-publish'\n}\n\nrequirementTracing {\n  inputDirectories = files('doc')\n}\n\ntask requirementsZip(type: Zip, dependsOn: collectRequirements) {\n from collectRequirements.outputFile\n into '/'\n}\n\npublishing {\n  publications {\n    maven(MavenPublication) {\n      artifact requirementsZip\n    }\n  }\n}\n```\n\nSee [publish-config](https://github.com/itsallcode/openfasttrace-gradle/tree/main/example-projects/publish-config) for a basic example.\n\n#### Importing External Requirements\n\nYou can import requirements from another project using the `importedRequirements` configuration. The requirements must be published to a repository as a zip file and can be referenced using the usual gradle dependency syntax:\n\n```groovy\nrepositories {\n  maven {\n    url \"http://repo.example.com/maven2\"\n  }\n}\nrequirementTracing {\n  importedRequirements = ['com.example:swad:1.0.0@zip']\n}\n```\n\nSee [dependency-config](https://github.com/itsallcode/openfasttrace-gradle/tree/main/example-projects/dependency-config) for a basic example.\n\n## Development\n\n```sh\ngit clone https://github.com/itsallcode/openfasttrace-gradle.git\ncd openfasttrace-gradle\n./gradlew check\n# Test report: build/reports/tests/index.html\n```\n\n### Use `openfasttrace` from Source\n\nTo use `openfasttrace` from source during development:\n\n1. Clone https://github.com/itsallcode/openfasttrace to `../openfasttrace`\n1. Create file `gradle.properties` with the following content:\n\n    ```properties\n    oftSourceDir = ../openfasttrace\n    ```\n\n### Check if dependencies are up-to-date\n\n```sh\n./gradlew dependencyUpdates\n```\n\n### Check dependencies for vulnerabilities\n\n```sh\n./gradlew ossIndexAudit\n```\n\n### Run sonar analysis\n\n```sh\n./gradlew clean sonar --info -Dsonar.token=[token]\n```\n\n### Publish to `plugins.gradle.org`\n\n#### Preparations\n\n1. Checkout the `main` branch, create a new branch.\n2. Update version number in `build.gradle` and `README.md`.\n3. Add changes in new version to `CHANGELOG.md`.\n4. Commit and push changes.\n5. Create a new pull request, have it reviewed and merged to `main`.\n\n#### Perform the Release\n\n1. Start the release workflow\n  * Run command `gh workflow run release.yml --repo itsallcode/openfasttrace-gradle --ref main`\n  * or go to [GitHub Actions](https://github.com/itsallcode/openfasttrace-gradle/actions/workflows/release.yml) and start the `release.yml` workflow on branch `main`.\n2. Update title and description of the newly created [GitHub release](https://github.com/itsallcode/openfasttrace-gradle/releases).\n3. Plugin will be published at https://plugins.gradle.org/m2/org/itsallcode/openfasttrace/org.itsallcode.openfasttrace.gradle.plugin/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitsallcode%2Fopenfasttrace-gradle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fitsallcode%2Fopenfasttrace-gradle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitsallcode%2Fopenfasttrace-gradle/lists"}