Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions .github/workflows/pull-request-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,53 @@ name: Pull Request Check
on: [pull_request]

jobs:
check-che-extensions-licenses:
runs-on: ubuntu-22.04
if: ${{ github.base_ref == 'main' }}
steps:
- name: Checkout che-code source code
uses: actions/checkout@v4
- name: Check che-activity-tracker dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-activity-tracker:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-api dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-api:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-commands dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-commands:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-github-authentication dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-github-authentication:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-port dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-port:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-remote dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-remote:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-resource-monitor dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-resource-monitor:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check
- name: Check che-terminal dependencies usage restrictions
run: |
docker run --rm -t \
-v $PWD/code/extensions/che-terminal:/workspace/project \
quay.io/che-incubator/dash-licenses:next --check

check-artifacts:
runs-on: ubuntu-22.04
steps:
Expand Down
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,32 @@ For a main branch:
$ git diff upstream-code/main main:code
```

## License Check for Eclipse Che extensions
License check tools work for the next extensions:
1. `che-activity-tracker`
2. `che-api`
3. `che-commands`
4. `che-github-authentication`
5. `che-port`
6. `che-remote`
7. `che-resource-monitor`
8. `che-terminal`

Dependencies usage restrictions could be checked with the `license:check` command. Example for `che-api`:

```bash
$ npm --prefix code/extensions/che-api run license:generate
```
This command will check the dependencies used in the `che-api` extension and generate a report with the following files:
- `prod.md` with the list of production dependencies;
- `dev.md` which contains only build and test dependencies;
- `problems.md` will be created if some dependencies are not covered with the referenced IP request(CQ).

These files wil be in the `code/extensions/che-api/.deps` directory.

**Note**: Detailed information on how to create the required CQs with
[clearlydefined](https://clearlydefined.io/) can be found [here](https://docs.clearlydefined.io/docs/get-involved/adding-sources).

## Fixing the [`rebase-insiders`](https://github.com/che-incubator/che-code/actions/workflows/rebase-insiders.yml) Workflow?
Upstream VS Code changes may bring a breakage to Che-Code. In this case, the [`rebase-insiders`](https://github.com/che-incubator/che-code/actions/workflows/rebase-insiders.yml) Workflow run is failed. To fix it, follow the steps below:
1. Checkout to a new branch, e.g.`fix-rebase`.
Expand Down
4 changes: 4 additions & 0 deletions code/extensions/che-activity-tracker/.deps/EXCLUDED/dev.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
This file contains a manual contribution to .deps/dev.md and it's needed because eclipse/dash-licenses does not deal with work-with CQs (more see https://github.com/eclipse/dash-licenses/issues/13)

| Packages | Resolved CQs |
| --- | --- |
5 changes: 5 additions & 0 deletions code/extensions/che-activity-tracker/.deps/EXCLUDED/prod.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This file lists dependencies that do not need CQs or auto-detection does not work due to a bug in https://github.com/eclipse/dash-licenses

| Packages | Resolved CQs |
| --- | --- |

344 changes: 344 additions & 0 deletions code/extensions/che-activity-tracker/.deps/dev.md

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions code/extensions/che-activity-tracker/.deps/prod.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Production dependencies

| Packages | License | Resolved CQs |
| --- | --- | --- |
3 changes: 2 additions & 1 deletion code/extensions/che-activity-tracker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
"watch": "gulp watch-extension:che-activity-tracker",
"vscode:prepublish": "npm run compile",
"test": "jest",
"lint:fix": "eslint --fix --cache=true --no-error-on-unmatched-pattern=true \"{src,tests}/**/*.{ts,tsx}\""
"lint:fix": "eslint --fix --cache=true --no-error-on-unmatched-pattern=true \"{src,tests}/**/*.{ts,tsx}\"",
"license:generate": "podman run --rm -t -v $PWD:/workspace/project quay.io/che-incubator/dash-licenses:next"
},
"devDependencies": {
"@types/fs-extra": "^9.0.13",
Expand Down
4 changes: 4 additions & 0 deletions code/extensions/che-api/.deps/EXCLUDED/dev.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
This file contains a manual contribution to .deps/dev.md and it's needed because eclipse/dash-licenses does not deal with work-with CQs (more see https://github.com/eclipse/dash-licenses/issues/13)

| Packages | Resolved CQs |
| --- | --- |
6 changes: 6 additions & 0 deletions code/extensions/che-api/.deps/EXCLUDED/prod.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
This file lists dependencies that do not need CQs or auto-detection does not work due to a bug in https://github.com/eclipse/dash-licenses

| Packages | Resolved CQs |
| --- | --- |
| `@devfile/api@2.3.0-1738854228` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@devfile/api/2.3.0-1738854228) |
| `jsep@1.3.9` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/-/jsep/1.3.9) |
Loading