Skip to content

Commit

Permalink
Automate update to third party notice file (#1508)
Browse files Browse the repository at this point in the history
- create github action to add commit with updated 3rd party notices if it's not up to date
- remove the check from circleci

J=SLAP-1505
TEST=auto

push a package.json with version different from what's listed in the 3rd party notice file and see that a automated commit is made in this pr
  • Loading branch information
yen-tt committed Aug 17, 2021
1 parent e7eb7a9 commit 244e908
Show file tree
Hide file tree
Showing 5 changed files with 352 additions and 686 deletions.
28 changes: 0 additions & 28 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,18 +116,6 @@ jobs:
command: |
sudo apt-get install -qq gettext
./.circleci/run_translation_verification.sh
# verify that the third party notices file is up to date
third_party_notices_test:
docker:
- image: circleci/node:14.5
working_directory: ~/answers
steps:
- setup-workspace
- attach_workspace:
at: ~/answers
- run:
name: Verify third party notices
command: ./.circleci/validate_third_party_notices.sh
# deploy to S3 in the root folder, overwriting the existing latest version
deploy_latest:
docker:
Expand Down Expand Up @@ -203,15 +191,11 @@ workflows:
- translation_test:
requires:
- build
- third_party_notices_test:
requires:
- build
- deploy_branch:
requires:
- unit_test
- browserstack_acceptance_test
- headless_acceptance_test
- third_party_notices_test
build_and_deploy_i18n:
jobs:
- build_i18n:
Expand All @@ -235,9 +219,6 @@ workflows:
- translation_test:
requires:
- build_i18n
- third_party_notices_test:
requires:
- build_i18n
- deploy_branch:
filters:
branches:
Expand All @@ -248,7 +229,6 @@ workflows:
- browserstack_acceptance_test
- headless_acceptance_test
- translation_test
- third_party_notices_test
- deploy_canary:
filters:
branches:
Expand All @@ -257,7 +237,6 @@ workflows:
- unit_test
- headless_acceptance_test
- browserstack_acceptance_test
- third_party_notices_test
build_and_deploy_hold:
jobs:
- build_i18n:
Expand Down Expand Up @@ -291,12 +270,6 @@ workflows:
only: /^v.*/
requires:
- build_i18n
- third_party_notices_test:
filters:
tags:
only: /^v.*/
requires:
- build_i18n
- hold:
type: approval
filters:
Expand All @@ -307,7 +280,6 @@ workflows:
- browserstack_acceptance_test
- headless_acceptance_test
- translation_test
- third_party_notices_test
- deploy_latest:
filters:
branches:
Expand Down
19 changes: 0 additions & 19 deletions .circleci/validate_third_party_notices.sh

This file was deleted.

22 changes: 22 additions & 0 deletions .github/workflows/third_party_notices_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Check Third Party Notices File

on: pull_request

jobs:
license-check:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v2
with:
node-version: 14.x
- run: npm install -g generate-license-file
- uses: actions/checkout@v2
- run: npm ci
- run: generate-license-file --input package.json --output ./THIRD-PARTY-NOTICES
- name: Update THIRD-PARTY-NOTICES
uses: EndBug/add-and-commit@v7
with:
message: "Automated update to THIRD-PARTY-NOTICES from github action's 3rd party notices check"
add: 'THIRD-PARTY-NOTICES'
push: true
default_author: github_actions
Loading

0 comments on commit 244e908

Please sign in to comment.