Skip to content

Openverse is a search engine for openly-licensed media. This monorepo includes all application code.

πŸ”„ Synced file(s) with WordPress/openverse (#564)

Dhruv Bhanushali2a0c18023a6a
diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml
index 2531da890..53b788157 100644
--- a/.github/release-drafter.yml
+++ b/.github/release-drafter.yml
@@ -1,27 +1,27 @@
# Configuration for the release-drafter action
# See docs here: https://github.com/marketplace/actions/release-drafter
-name-template: 'v$RESOLVED_VERSION'
-tag-template: 'v$RESOLVED_VERSION'
+name-template: "v$RESOLVED_VERSION"
+tag-template: "v$RESOLVED_VERSION"
categories:
- - title: 'New Features'
- label: '🌟 goal: addition'
- - title: 'Improvements'
- label: '✨ goal: improvement'
- - title: 'Internal Improvements'
- label: 'πŸ€– aspect: dx'
- - title: 'Bug Fixes'
- label: 'πŸ›  goal: fix'
-change-template: '- $TITLE: #$NUMBER by @$AUTHOR'
+ - title: New Features
+ label: "🌟 goal: addition"
+ - title: Improvements
+ label: "✨ goal: improvement"
+ - title: Internal Improvements
+ label: "πŸ€– aspect: dx"
+ - title: Bug Fixes
+ label: "πŸ›  goal: fix"
+change-template: "- $TITLE: #$NUMBER by @$AUTHOR"
version-resolver:
major:
labels:
- - 'major'
+ - major
minor:
labels:
- - 'minor'
+ - minor
patch:
labels:
- - 'patch'
+ - patch
default: patch
template: |
$CHANGES
diff --git a/.github/workflows-disabled/project-automation.yml b/.github/workflows-disabled/project-automation.yml
deleted file mode 100644
index 5fe24c746..000000000
--- a/.github/workflows-disabled/project-automation.yml
+++ /dev/null
@@ -1,25 +0,0 @@
-name: 'Project Board Automation'
-on:
- issues:
- types: [opened]
- pull_request:
- types: [opened]
-jobs:
- join_issue_pr_to_project:
- runs-on: ubuntu-latest
- steps:
- - name: 'Automate adding issues to Backlog'
- uses: docker://takanabe/github-actions-automate-projects:v0.0.1
- if: github.event_name == 'issues'
- env:
- GITHUB_TOKEN: ${{ secrets.ADMIN_GITHUB_TOKEN }}
- GITHUB_PROJECT_URL: https://github.com/orgs/creativecommons/projects/10
- GITHUB_PROJECT_COLUMN_NAME: 'Pending Review'
- - name: 'Automate adding PRs to Active Sprint'
- uses: docker://takanabe/github-actions-automate-projects:v0.0.1
- if: github.event_name == 'pull_request'
- continue-on-error: true
- env:
- GITHUB_TOKEN: ${{ secrets.ADMIN_GITHUB_TOKEN }}
- GITHUB_PROJECT_URL: https://github.com/orgs/WordPress/projects/3
- GITHUB_PROJECT_COLUMN_NAME: 'In Progress'
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yml
similarity index 98%
rename from .github/workflows/build.yaml
rename to .github/workflows/build.yml
index 7186bb4c7..fdf44c500 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yml
@@ -6,7 +6,7 @@ name: build
on:
release:
types:
- - 'prereleased'
+ - "prereleased"
env:
AWS_REGION: ${{ secrets.AWS_REGION }}
AWS_ACCOUNT_ID: ${{ secrets.AWS_ACCOUNT_ID }}
@@ -48,5 +48,3 @@ jobs:
tags: ${{ steps.metadata.outputs.tags }}
labels: ${{ steps.metadata.outputs.labels }}
push: true
-
-
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index e0521f82d..105764661 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -20,7 +20,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v1
with:
- node-version: '16.13.0'
+ node-version: "16.13.0"
- name: Cache Node.js modules
uses: actions/cache@v2
diff --git a/.github/workflows/new_issues.yml b/.github/workflows/new_issues.yml
index 0b0deb30c..ddeaae3b5 100644
--- a/.github/workflows/new_issues.yml
+++ b/.github/workflows/new_issues.yml
@@ -4,16 +4,16 @@ name: New issue automation
on:
issues:
types:
- - opened
+ - opened
jobs:
add_issue:
name: Add new issue
runs-on: ubuntu-latest
steps:
- - name: Add issue to "Backlog"
- uses: alex-page/[email protected]
- with:
- project: Openverse
- column: Backlog
- repo-token: ${{ secrets.ACCESS_TOKEN }}
+ - name: Add issue to "Backlog"
+ uses: alex-page/[email protected]
+ with:
+ project: Openverse
+ column: Backlog
+ repo-token: ${{ secrets.ACCESS_TOKEN }}
diff --git a/.github/workflows/new_prs.yml b/.github/workflows/new_prs.yml
index b1d32d0d1..98e27ceb9 100644
--- a/.github/workflows/new_prs.yml
+++ b/.github/workflows/new_prs.yml
@@ -4,9 +4,9 @@ name: New PR automation
on:
pull_request_target:
types:
- - opened
- - converted_to_draft
- - ready_for_review
+ - opened
+ - converted_to_draft
+ - ready_for_review
jobs:
add_draft:
@@ -14,21 +14,21 @@ jobs:
if: ${{ github.event.pull_request.draft }}
runs-on: ubuntu-latest
steps:
- - name: Add PR to "In progress"
- uses: alex-page/[email protected]
- with:
- project: Openverse PRs
- column: In progress
- repo-token: ${{ secrets.ACCESS_TOKEN }}
+ - name: Add PR to "In progress"
+ uses: alex-page/[email protected]
+ with:
+ project: Openverse PRs
+ column: In progress
+ repo-token: ${{ secrets.ACCESS_TOKEN }}
add_ready:
name: Add ready PR
if: ${{ !github.event.pull_request.draft }}
runs-on: ubuntu-latest
steps:
- - name: Add PR to "Needs review"
- uses: alex-page/[email protected]
- with:
- project: Openverse PRs
- column: Needs review
- repo-token: ${{ secrets.ACCESS_TOKEN }}
+ - name: Add PR to "Needs review"
+ uses: alex-page/[email protected]
+ with:
+ project: Openverse PRs
+ column: Needs review
+ repo-token: ${{ secrets.ACCESS_TOKEN }}
diff --git a/.github/workflows/pr_label_check.yml b/.github/workflows/pr_label_check.yml
index a01b96e69..9951bae5b 100644
--- a/.github/workflows/pr_label_check.yml
+++ b/.github/workflows/pr_label_check.yml
@@ -4,36 +4,36 @@ name: PR label check
on:
pull_request:
types:
- - opened
- - edited
- - labeled
- - unlabeled
- - synchronize
+ - opened
+ - edited
+ - labeled
+ - unlabeled
+ - synchronize
jobs:
check_aspect_label:
name: Check aspect label
runs-on: ubuntu-latest
steps:
- - name: Check aspect label
- uses: sugarshin/[email protected]
- with:
- required_oneof: 'πŸ’» aspect: code,πŸ“„ aspect: text,πŸ€– aspect: dx,πŸ•Ή aspect: interface,♿️ aspect: a11y'
+ - name: Check aspect label
+ uses: sugarshin/[email protected]
+ with:
+ required_oneof: "πŸ’» aspect: code,πŸ“„ aspect: text,πŸ€– aspect: dx,πŸ•Ή aspect: interface,♿️ aspect: a11y"
check_goal_label:
name: Check goal label
runs-on: ubuntu-latest
steps:
- - name: Check goal label
- uses: sugarshin/[email protected]
- with:
- required_oneof: '🌟 goal: addition,πŸ›  goal: fix,✨ goal: improvement,🧰 goal: internal improvement'
+ - name: Check goal label
+ uses: sugarshin/[email protected]
+ with:
+ required_oneof: "🌟 goal: addition,πŸ›  goal: fix,✨ goal: improvement,🧰 goal: internal improvement"
check_priority_label:
name: Check priority label
runs-on: ubuntu-latest
steps:
- - name: Check priority label
- uses: sugarshin/[email protected]
- with:
- required_oneof: '🟩 priority: low,🟨 priority: medium,🟧 priority: high,πŸŸ₯ priority: critical'
+ - name: Check priority label
+ uses: sugarshin/[email protected]
+ with:
+ required_oneof: "🟩 priority: low,🟨 priority: medium,🟧 priority: high,πŸŸ₯ priority: critical"
diff --git a/.github/workflows/pr_ping.yml b/.github/workflows/pr_ping.yml
index e34a1d6d7..500dfecd3 100644
--- a/.github/workflows/pr_ping.yml
+++ b/.github/workflows/pr_ping.yml
@@ -4,8 +4,8 @@ name: New PR notification
on:
pull_request_target:
types:
- - opened
- - ready_for_review
+ - opened
+ - ready_for_review
jobs:
send_message:
@@ -22,23 +22,23 @@ jobs:
pr_author: ${{ github.event.pull_request.user.login }}
pr_repo: ${{ github.event.pull_request.base.repo.full_name }}
steps:
- - name: Send notification for new PR
- if: github.event.action == 'opened'
- env:
- pr_status: ${{ github.event.pull_request.draft && ' draft ' || ' ' }}
- pr_icon: ${{ github.event.pull_request.draft && ':pr-draft:' || ':pull-request:' }}
- run: |
- curl \
- $slack_url \
- -X POST \
- -H 'Content-Type: application/json' \
- -d '{"text":"New'"$pr_status"'PR opened by '"$pr_author"' in '"$pr_repo"': #'"$pr_number"' - '"$pr_title"'","blocks":[{"type":"section","text":{"type":"mrkdwn","text":"'"$pr_icon"' New'"$pr_status"'PR opened by *'"$pr_author"'* in `'"$pr_repo"'`:\n<'"$pr_url"'|#'"$pr_number"' - '"$pr_title"'>"}}]}'
+ - name: Send notification for new PR
+ if: github.event.action == 'opened'
+ env:
+ pr_status: ${{ github.event.pull_request.draft && ' draft ' || ' ' }}
+ pr_icon: ${{ github.event.pull_request.draft && ':pr-draft:' || ':pull-request:' }}
+ run: |
+ curl \
+ $slack_url \
+ -X POST \
+ -H 'Content-Type: application/json' \
+ -d '{"text":"New'"$pr_status"'PR opened by '"$pr_author"' in '"$pr_repo"': #'"$pr_number"' - '"$pr_title"'","blocks":[{"type":"section","text":{"type":"mrkdwn","text":"'"$pr_icon"' New'"$pr_status"'PR opened by *'"$pr_author"'* in `'"$pr_repo"'`:\n<'"$pr_url"'|#'"$pr_number"' - '"$pr_title"'>"}}]}'
- - name: Send notification for PR marked ready
- if: github.event.action == 'ready_for_review'
- run: |
- curl \
- $slack_url \
- -X POST \
- -H 'Content-Type: application/json' \
- -d '{"text":"PR by '"$pr_author"' in '"$pr_repo"' marked ready for review: #'"$pr_number"' - '"$pr_title"'","blocks":[{"type":"section","text":{"type":"mrkdwn","text":":pull-request: PR by *'"$pr_author"'* in `'"$pr_repo"'` marked ready for review:\n<'"$pr_url"'|#'"$pr_number"' - '"$pr_title"'>"}}]}'
+ - name: Send notification for PR marked ready
+ if: github.event.action == 'ready_for_review'
+ run: |
+ curl \
+ $slack_url \
+ -X POST \
+ -H 'Content-Type: application/json' \
+ -d '{"text":"PR by '"$pr_author"' in '"$pr_repo"' marked ready for review: #'"$pr_number"' - '"$pr_title"'","blocks":[{"type":"section","text":{"type":"mrkdwn","text":":pull-request: PR by *'"$pr_author"'* in `'"$pr_repo"'` marked ready for review:\n<'"$pr_url"'|#'"$pr_number"' - '"$pr_title"'>"}}]}'
diff --git a/.prettierignore b/.prettierignore
index e009982af..b50963707 100644
--- a/.prettierignore
+++ b/.prettierignore
@@ -1,4 +1,4 @@
-.github
+.github/**/*.md
dist
test/unit/coverage
.nuxt
diff --git a/docker-compose.yml b/docker-compose.yml
index f0726c720..c504c20e2 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -1,11 +1,11 @@
-version: '3'
+version: "3"
services:
web:
build:
context: .
target: dev
ports:
- - '8443:8443'
+ - "8443:8443"
environment:
# HOST is necessary for Nuxt + Docker
HOST: 0.0.0.0
diff --git a/prettier.config.js b/prettier.config.js
index a30b698cf..3b7bc476b 100644
--- a/prettier.config.js
+++ b/prettier.config.js
@@ -4,4 +4,12 @@ module.exports = {
semi: false,
singleQuote: true,
vueIndentScriptAndStyle: false,
+ overrides: [
+ {
+ files: '*.yml',
+ options: {
+ singleQuote: false,
+ },
+ },
+ ],
}