diff --git a/.github/workflows/check-licenses.yaml b/.github/workflows/check-licenses.yaml new file mode 100644 index 0000000..dac590a --- /dev/null +++ b/.github/workflows/check-licenses.yaml @@ -0,0 +1,41 @@ +name: Check Licenses +on: + pull_request: + types: + - opened + - synchronize + # Labels are needed to handle external contributors + - labeled + - unlabeled + paths: + # Self + - ".github/workflows/check-licenses.yaml" + # JS/TS Ecosystem + - "**/package.json" + - "**/pnpm-lock.yaml" + - "**/package-lock.json" + +jobs: + default: + permissions: + contents: read + pull-requests: write + uses: saleor/saleor-internal-actions/.github/workflows/run-license-check.yaml@v1 + with: + # List of ecosystems to scan. + ecosystems: >- + javascript + # Grant rules (https://github.com/anchore/grant/blob/4362dc22cf5ea9baeccfa59b2863879afe0c30d7/README.md#usage) + rules: | + # Explicitly allow LGPL as "*GPL*" rule will cause to reject them otherwise. + - pattern: "*lgpl*" + name: "allow-lgpl" + mode: "allow" + reason: "LGPL is allowed." + - pattern: "*gpl*" + name: "deny-gpl" + mode: "deny" + reason: "GPL licenses are not compatible with BSD-3-Clause" + - pattern: "*proprietary*" + name: "deny-proprietary" + mode: "deny" diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..9415b33 --- /dev/null +++ b/LICENSE @@ -0,0 +1,29 @@ +BSD 3-Clause License + +Copyright (c) 2024-2025, Saleor Commerce +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/package.json b/package.json index 2a7ca1c..b5ca146 100644 --- a/package.json +++ b/package.json @@ -2,6 +2,7 @@ "name": "example-auth-nextjs-pages-router", "version": "0.1.0", "private": true, + "license": "BSD-3-Clause", "scripts": { "dev": "next dev", "build": "next build",