Skip to content

Commit

Permalink
build(reporter): Move all Web-App reporter projects to plugin projects
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastian Schuberth <[email protected]>
  • Loading branch information
sschuberth committed Apr 25, 2023
1 parent 67c2cf2 commit 31cdeea
Show file tree
Hide file tree
Showing 108 changed files with 520 additions and 74 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ integrations/jenkins/Jenkinsfile
**/build/
!docker/build
**/out/
reporter-web-app/node_modules/
plugins/reporters/web-app-template/node_modules/

# Ignore the logos as we do not need them to run ORT.
logos/
Expand Down
10 changes: 5 additions & 5 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,18 @@ scanner/src/test/assets/*.json text eol=lf
scanner/src/test/assets/scanoss/filesToScan/*.kt text eol=lf

# Use Unix line endings for JavaScript source code to avoid problems with eslint.
reporter-web-app/**/*.js text eol=lf
plugins/reporters/web-app-template/**/*.js text eol=lf

# Use Unix line endings for SPDX license texts for consistency across platforms.
utils/spdx/src/main/resources/exceptions/* text eol=lf
utils/spdx/src/main/resources/licenserefs/* text eol=lf
utils/spdx/src/main/resources/licenses/* text eol=lf

# Fix GitHub language statistics, see https://github.com/github/linguist#using-gitattributes.
reporter-web-app/public/index.html linguist-generated=true
utils/spdx/src/main/resources/exceptions/* linguist-detectable=false
utils/spdx/src/main/resources/licenserefs/* linguist-detectable=false
utils/spdx/src/main/resources/licenses/* linguist-detectable=false
plugins/reporters/web-app-template/public/index.html linguist-generated=true
utils/spdx/src/main/resources/exceptions/* linguist-detectable=false
utils/spdx/src/main/resources/licenserefs/* linguist-detectable=false
utils/spdx/src/main/resources/licenses/* linguist-detectable=false

# Use Unix line endings for the expected control file of a Debian package.
utils/common/src/test/assets/control-expected.txt text eol=lf
Expand Down
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
/**/*Sw360* @oss-review-toolkit/kotlin-devs @bs-ondem @oheger-bosch
/advisor/ @oss-review-toolkit/kotlin-devs @MarcelBochtler @oheger-bosch
/clients/fossid-webapp/ @oss-review-toolkit/kotlin-devs @nnobelis
/reporter-web-app/ @tsteenbe
/plugins/reporters/web-app-template/ @tsteenbe
/spdx-utils/src/main/ @oss-review-toolkit/core-devs
/LICENSE @oss-review-toolkit/core-devs
14 changes: 7 additions & 7 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ jobs:
- name: Build all classes
uses: gradle/gradle-build-action@v2
with:
arguments: --scan classes -x :reporter-web-app:yarnBuild
build-reporter-web-app:
arguments: --scan classes -x :plugins:reporters:web-app-template:yarnBuild
build-web-app-reporter:
needs: build
runs-on: ubuntu-22.04
steps:
Expand All @@ -41,10 +41,10 @@ jobs:
with:
distribution: temurin
java-version: 17
- name: Build the reporter-web-app
- name: Build the web-app-reporter
uses: gradle/gradle-build-action@v2
with:
arguments: --scan :reporter-web-app:yarnBuild
arguments: --scan :plugins:reporters:web-app-template:yarnBuild
codeql-analysis:
needs: build
runs-on: ubuntu-22.04
Expand All @@ -66,7 +66,7 @@ jobs:
- name: Build all classes
uses: gradle/gradle-build-action@v2
with:
arguments: -Dorg.gradle.jvmargs=-Xmx1g classes -x :reporter-web-app:yarnBuild
arguments: -Dorg.gradle.jvmargs=-Xmx1g classes -x :plugins:reporters:web-app-template:yarnBuild
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
test:
Expand All @@ -83,13 +83,13 @@ jobs:
- name: Run unit tests
uses: gradle/gradle-build-action@v2
with:
arguments: --scan test jacocoTestReport -x :reporter-web-app:yarnBuild
arguments: --scan test jacocoTestReport -x :plugins:reporters:web-app-template:yarnBuild
- name: Upload code coverage data
uses: codecov/codecov-action@v3
with:
flags: test
funTest-non-docker:
needs: build-reporter-web-app
needs: build-web-app-reporter
runs-on: ubuntu-22.04
steps:
- name: Install required tools
Expand Down
2 changes: 1 addition & 1 deletion .ort.yml
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ curations:
reason: "DOCUMENTATION_OF"
comment: >-
Documentation contains examples mentioning various licenses.
- path: "reporter-web-app/public/index.html"
- path: "plugins/reporters/web-app-template/public/index.html"
concluded_license: "Apache-2.0"
reason: "DATA_OF"
comment: >-
Expand Down
2 changes: 1 addition & 1 deletion .reuse/dep5
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Files: logos/*
Copyright: 2017 The ORT Project Authors (see <https://github.com/oss-review-toolkit/ort/blob/main/NOTICE>)
License: Apache-2.0

Files: reporter-web-app/*
Files: plugins/reporters/web-app-template/*
Copyright: 2017 The ORT Project Authors (see <https://github.com/oss-review-toolkit/ort/blob/main/NOTICE>)
License: Apache-2.0

Expand Down
5 changes: 2 additions & 3 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ allprojects {
subprojects {
version = rootProject.version

val nonJavaProjects = listOf("reporter-web-app", "package-curation-providers", "package-managers", "reporters")
val nonJavaProjects = listOf("package-curation-providers", "package-managers", "reporters", "web-app-template")
if (name in nonJavaProjects) return@subprojects

// Apply core plugins.
Expand Down Expand Up @@ -512,8 +512,7 @@ val copyrightExcludedPaths = listOf(
"plugins/reporters/asciidoc/src/main/resources/templates/freemarker_implicit.ftl",
"plugins/reporters/freemarker/src/main/resources/templates/freemarker_implicit.ftl",
"plugins/reporters/static-html/src/main/resources/prismjs/",
"reporter-web-app/yarn.lock",
"reporter/src/main/resources/META_INF/",
"plugins/reporters/web-app-template/yarn.lock",
"resources/META-INF/",
"resources/exceptions/",
"resources/licenses/",
Expand Down
2 changes: 2 additions & 0 deletions plugins/reporters/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,14 @@ dependencies {
api(project(":plugins:reporters:asciidoc-reporter"))
api(project(":plugins:reporters:ctrlx-reporter"))
api(project(":plugins:reporters:cyclonedx-reporter"))
api(project(":plugins:reporters:evaluated-model-reporter"))
api(project(":plugins:reporters:fossid-reporter"))
api(project(":plugins:reporters:freemarker-reporter"))
api(project(":plugins:reporters:gitlab-reporter"))
api(project(":plugins:reporters:opossum-reporter"))
api(project(":plugins:reporters:spdx-reporter"))
api(project(":plugins:reporters:static-html-reporter"))
api(project(":plugins:reporters:web-app-reporter"))
}

configure<PublishingExtension> {
Expand Down
39 changes: 39 additions & 0 deletions plugins/reporters/evaluated-model/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/*
* Copyright (C) 2023 The ORT Project Authors (see <https://github.com/oss-review-toolkit/ort/blob/main/NOTICE>)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* SPDX-License-Identifier: Apache-2.0
* License-Filename: LICENSE
*/

plugins {
// Apply core plugins.
`java-library`
}

dependencies {
api(project(":model"))
api(project(":reporter"))
api(project(":utils:spdx-utils"))

api(libs.jacksonAnnotations)
api(libs.jacksonDatabind)

implementation(project(":utils:ort-utils"))

implementation(libs.jacksonCore)
implementation(libs.jacksonDataformatYaml)

funTestImplementation(testFixtures(project(":reporter")))
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import io.kotest.core.TestConfiguration
import io.kotest.core.spec.style.WordSpec
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

/**
* Wrapper class for copyright statements. Allows Jackson to generate IDs for them when storing them in a separate list
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonIdentityInfo
import com.fasterxml.jackson.annotation.JsonInclude
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonInclude

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

/**
* The possible types of an [EvaluatedFinding].
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonIdentityReference
import com.fasterxml.jackson.annotation.JsonInclude
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

/**
* The possible types of an [EvaluatedIssue].
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonIdentityInfo
import com.fasterxml.jackson.annotation.JsonIdentityReference
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import org.ossreviewtoolkit.model.AdvisorResult
import org.ossreviewtoolkit.model.CuratedPackage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import java.io.File

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonIdentityReference
import com.fasterxml.jackson.annotation.JsonInclude
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

/**
* The path to a [dependency][pkg] used by the [EvaluatedModel]. It is defined by the [project] and [scope] that contain
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonInclude

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonInclude

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonInclude

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonInclude

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.JsonInclude
import com.fasterxml.jackson.annotation.JsonInclude.Include
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import java.net.URI

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.databind.Module
import com.fasterxml.jackson.databind.PropertyName
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

/**
* Wrapper class for license identifiers. Allows Jackson to generate IDs for them when storing them in a separate list
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import java.time.Instant

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import java.time.Instant

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* License-Filename: LICENSE
*/

package org.ossreviewtoolkit.reporter.reporters.evaluatedmodel
package org.ossreviewtoolkit.plugins.reporters.evaluatedmodel

import com.fasterxml.jackson.annotation.ObjectIdGenerator
import com.fasterxml.jackson.annotation.ObjectIdGenerators
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
org.ossreviewtoolkit.plugins.reporters.evaluatedmodel.EvaluatedModelReporter
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ This directory contains the code for Web App report generated by the ORT reporte

## Available Commands

In the `reporter-web-app` directory, you can run:
In the `web-app-template` directory, you can run:

### `yarn build`

Expand Down
File renamed without changes.
Loading

0 comments on commit 31cdeea

Please sign in to comment.