From 68b3771277880deb4f553db6e5c06626d5c92550 Mon Sep 17 00:00:00 2001 From: Jonah <47046556+jwbonner@users.noreply.github.com> Date: Sun, 15 Oct 2023 23:33:20 -0400 Subject: [PATCH] Fix build failure related to copyright text --- builderConfig.js | 9 ++++++++- package.json | 1 + rollup.config.mjs | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/builderConfig.js b/builderConfig.js index 300a2498..2683fc31 100644 --- a/builderConfig.js +++ b/builderConfig.js @@ -1,9 +1,16 @@ +const fs = require("fs"); + module.exports = () => { const isWpilib = process.env.ASCOPE_DISTRIBUTOR === "WPILIB"; + const package = JSON.parse( + fs.readFileSync("package.json", { + encoding: "utf-8" + }) + ); return { productName: isWpilib ? "AdvantageScope (WPILib)" : "AdvantageScope", appId: "org.littletonrobotics.advantagescope", - copyright: "Copyright © 2021-2023 FRC 6328", + copyright: package.copyright, npmRebuild: false, publish: [], afterSign: "notarize.js", diff --git a/package.json b/package.json index 023db048..810cb9b8 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,7 @@ "productName": "AdvantageScope", "version": "2.3.0", "description": "Robot telemetry application for FRC", + "copyright": "Copyright © 2021-2023 FRC 6328", "author": { "name": "FRC 6328", "email": "info@littletonrobotics.org", diff --git a/rollup.config.mjs b/rollup.config.mjs index 25b8be3d..d9fea119 100644 --- a/rollup.config.mjs +++ b/rollup.config.mjs @@ -42,7 +42,7 @@ function bundle(input, output, isMain, external = []) { fs.readFileSync("package.json", { encoding: "utf-8" }) - ).build.copyright + ).copyright } }), replaceRegEx({