From 04bf3352b97bb611c4ee08a8742ae5556352db19 Mon Sep 17 00:00:00 2001 From: Brian Pilati Date: Tue, 12 Aug 2025 16:03:54 -0500 Subject: [PATCH 1/2] feat(readme): Updates to the readme to verify 1 review security --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/README.md b/README.md index c7b0ec463..5c1e249ec 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,30 @@ tests are run locally. The output is displayed. The `.github` folder contains the following: 1. The test run "counter" scripts + .github/scripts 2. The "counter" file + .github/counter 3. The github action work flow scripts + .github/workflows 4. The github PR templates + .github/pull_request_template.md + +## Local pipeline + +The local pipeline pipeline is managed via husky + +1. The pre-commit requirements are: + - linting on the staged files passes + - .husky/pre-commit +2. The pre-push requirements are: + - All tests pass + - Test coverage is met + +## Volta + +OSF uses volta (https://volta.sh/) to manage node and npm versions inside of the repository + +## Commitlint + +OSF use commitlint (https://www.npmjs.com/package/commitlint) to standardize the commit messages. +Please review the commitlint conventions (@commitlint/config-conventional/README.md) From bda15540a8db8cd410b9d71ff73691f801cc682e Mon Sep 17 00:00:00 2001 From: Brian Pilati Date: Tue, 12 Aug 2025 16:45:34 -0500 Subject: [PATCH 2/2] feat(updates): Updates to some files to continue the pipeline testing --- .github/counter/counter.test.display.js | 2 +- .github/counter/counter.test.increment.js | 2 +- .github/scripts/check-coverage-thresholds.js | 1 - README.md | 4 ++-- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/counter/counter.test.display.js b/.github/counter/counter.test.display.js index 82e419e2f..211e45a8a 100644 --- a/.github/counter/counter.test.display.js +++ b/.github/counter/counter.test.display.js @@ -11,7 +11,7 @@ try { current = parseInt(content, 10) || 0; } - console.info(`\n\nTests ran: ${current}\n\n`); + console.info(`\n\nTotal test runs: ${current}\n\n`); } catch (err) { console.error('Error updating counter:', err.message); } diff --git a/.github/counter/counter.test.increment.js b/.github/counter/counter.test.increment.js index fc96bd95b..6685a236b 100644 --- a/.github/counter/counter.test.increment.js +++ b/.github/counter/counter.test.increment.js @@ -16,7 +16,7 @@ try { // Write back fs.writeFileSync(filePath, String(updated)); - console.info(`\n\nCounter updated: ${current} → ${updated}\n\n`); + console.info(`\n\nTest run counter updated: ${current} → ${updated}\n\n`); } catch (err) { console.error('Error updating counter:', err.message); } diff --git a/.github/scripts/check-coverage-thresholds.js b/.github/scripts/check-coverage-thresholds.js index 3847bafd5..6eb7a39e7 100644 --- a/.github/scripts/check-coverage-thresholds.js +++ b/.github/scripts/check-coverage-thresholds.js @@ -42,7 +42,6 @@ for (const key of ['branches', 'functions', 'lines', 'statements']) { if (failed) { const stars = '*'.repeat(warnMessage.length + 8); execSync('clear', { stdio: 'inherit' }); - console.log(warnMessage.length); console.log('\n\nCongratulations! You have successfully run the coverage check and added tests.'); console.log('\n\nThe jest.config.js file is not insync with your new test additions.'); console.log('Please update the coverage thresholds in jest.config.js.'); diff --git a/README.md b/README.md index 5c1e249ec..fdfe192a5 100644 --- a/README.md +++ b/README.md @@ -28,9 +28,9 @@ tests are run locally. The output is displayed. The `.github` folder contains the following: 1. The test run "counter" scripts - .github/scripts -2. The "counter" file .github/counter +2. Script needed for the deployment process + .github/scripts 3. The github action work flow scripts .github/workflows 4. The github PR templates