Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "ci: making it easier to upgrade node" #14967

Merged
merged 1 commit into from
May 28, 2024

Conversation

lodmfjord
Copy link
Member

@lodmfjord lodmfjord commented May 28, 2024

Reverts #14472

Summary by CodeRabbit

  • New Features

    • Updated Node.js setup in GitHub Actions to version 18 for improved compatibility.
  • Refactor

    • Simplified conditional logic for determining revisions in GitHub Actions.
    • Updated Dockerfiles to use a specific Node.js version (18-alpine3.15) instead of variable references.
  • Chores

    • Downgraded @types/node from 20.12.12 to 20.11.4 for consistency.
    • Adjusted TypeScript configuration to target specific libraries (es2019 and esnext.array).
    • Modified GitHub Actions workflows for more efficient caching and setup processes.

@lodmfjord lodmfjord requested a review from a team as a code owner May 28, 2024 11:13
@lodmfjord lodmfjord merged commit d2ce8b8 into main May 28, 2024
7 of 10 checks passed
@lodmfjord lodmfjord deleted the revert-14472-upgrade-node-version branch May 28, 2024 11:13
Copy link
Contributor

coderabbitai bot commented May 28, 2024

Walkthrough

The overall changes focus on simplifying the GitHub Actions workflows, updating Node.js versions, and refining Docker configurations. Key updates include reorganizing conditional logic for event handling, downgrading @types/node version, adjusting TypeScript library targets, and modifying Node.js setup and caching strategies in CI/CD pipelines. Dockerfile base images are also updated to specific Node.js versions, removing the use of dynamic tags.

Changes

Files/Paths Change Summary
.github/actions/main.ts Simplified conditional logic for determining the revision based on the GitHub event type.
.github/actions/package.json Downgraded @types/node version from 20.12.12 to 20.11.4.
.github/actions/tsconfig.json Removed "esnext" from the lib property, targeting only "es2019" and "esnext.array".
.github/actions/unit-test/action.yml Updated Node.js setup from version 4 to version 2 and changed Node.js version configuration.
.github/actions/yarn.lock Reflected the downgrade of @types/node version from 20.12.12 to 20.11.4.
.github/workflows/config-values.yaml Changed actions/setup-node version from v4 to v3 and updated Node.js version specification.
.github/workflows/pullrequest.yml Updated Node.js setup versions, adjusted cache key calculations, and refined workflow steps.
.github/workflows/push.yml Removed NODE_IMAGE_TAG, updated actions/setup-node versions, and refined Docker image building.
infra/scripts/Dockerfile Changed base Node.js image to 18-alpine3.15 for runner and build stages.
scripts/ci/10_prepare-docker-deps.sh Removed NODE_IMAGE_TAG build argument from Docker build commands.
scripts/ci/Dockerfile Updated base image for deps and output-base stages to node:18-alpine3.15.

Tip

Early Access Features
  • gpt-4o model for chat

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to full the review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 9

Outside diff range and nitpick comments (4)
infra/scripts/Dockerfile (2)

Line range hint 10-10: Replace ADD with COPY for better clarity and because COPY is recommended over ADD unless you need to auto-extract a tarball.

- ADD infra/package.json infra/yarn.lock /app/infra/
- ADD infra/ /app/infra/
- ADD apps /app/apps/
- ADD libs /app/libs/
+ COPY infra/package.json infra/yarn.lock /app/infra/
+ COPY infra/ /app/infra/
+ COPY apps /app/apps/
+ COPY libs /app/libs/

Also applies to: 15-17


Line range hint 20-20: Consider consolidating multiple RUN instructions into a single layer to reduce the number of layers in the image, which can help optimize the build process.

- RUN ./node_modules/.bin/ncc build src/feature-env.ts -o /app/dist/feature-env
- RUN ./node_modules/.bin/ncc build src/secrets.ts -o /app/dist/secrets
+ RUN ./node_modules/.bin/ncc build src/feature-env.ts -o /app/dist/feature-env && \
+     ./node_modules/.bin/ncc build src/secrets.ts -o /app/dist/secrets
scripts/ci/Dockerfile (2)

Line range hint 11-17: Replace ADD with COPY for better clarity and because COPY is recommended over ADD unless you need to auto-extract a tarball.

- ADD package.json yarn.lock .yarnrc.yml ./
- ADD apps/native/app/package.json ./apps/native/app/
+ COPY package.json yarn.lock .yarnrc.yml ./
+ COPY apps/native/app/package.json ./apps/native/app/

Line range hint 19-19: Use the --progress=dot:giga option with wget to enable a more compact progress bar.

- RUN wget -O /tmp/jq-linux64 https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
+ RUN wget --progress=dot:giga -O /tmp/jq-linux64 https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
Review Details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits Files that changed from the base of the PR and between 3527664 and 4ac3999.
Files selected for processing (11)
  • .github/actions/main.ts (1 hunks)
  • .github/actions/package.json (1 hunks)
  • .github/actions/tsconfig.json (1 hunks)
  • .github/actions/unit-test/action.yml (1 hunks)
  • .github/actions/yarn.lock (2 hunks)
  • .github/workflows/config-values.yaml (2 hunks)
  • .github/workflows/pullrequest.yml (8 hunks)
  • .github/workflows/push.yml (14 hunks)
  • infra/scripts/Dockerfile (1 hunks)
  • scripts/ci/10_prepare-docker-deps.sh (2 hunks)
  • scripts/ci/Dockerfile (2 hunks)
Files skipped from review due to trivial changes (3)
  • .github/actions/package.json
  • .github/workflows/config-values.yaml
  • scripts/ci/10_prepare-docker-deps.sh
Additional Context Used
Biome (12)
.github/actions/main.ts (12)

8-8: Forbidden non-null assertion.


8-8: Forbidden non-null assertion.


17-17: Forbidden non-null assertion.


18-18: Forbidden non-null assertion.


19-19: Forbidden non-null assertion.


20-20: Forbidden non-null assertion.


26-26: Forbidden non-null assertion.


27-27: Forbidden non-null assertion.


28-28: Forbidden non-null assertion.


32-32: Do not use template literals if interpolation and special-character handling are not needed.


4-6: All these imports are only used as types.


8-8: This let declares a variable that is only assigned once.

Hadolint (30)
infra/scripts/Dockerfile (10)

4: Pin versions in apk add. Instead of apk add <package> use apk add <package>=<version>


4: Use the --no-cache switch to avoid the need to use --update and remove /var/cache/apk/* when done installing packages


10: Use COPY instead of ADD for files and folders


11: COPY to a relative destination without WORKDIR set.


15: Use COPY instead of ADD for files and folders


16: Use COPY instead of ADD for files and folders


17: Use COPY instead of ADD for files and folders


20: Multiple consecutive RUN instructions. Consider consolidation.


25: COPY to a relative destination without WORKDIR set.


26: COPY to a relative destination without WORKDIR set.

scripts/ci/Dockerfile (20)

6: Pin versions in apk add. Instead of apk add <package> use apk add <package>=<version>


6: Use the --no-cache switch to avoid the need to use --update and remove /var/cache/apk/* when done installing packages


11: Use COPY instead of ADD for files and folders


12: Use COPY instead of ADD for files and folders


14: Pin versions in apk add. Instead of apk add <package> use apk add <package>=<version>


15: yarn cache clean missing after yarn install was run.


19: Avoid use of wget without progress bar. Use wget --progress=dot:giga <url>. Or consider using -q or -nv (shorthands for --quiet or --no-verbose).


24: Use COPY instead of ADD for files and folders


56: Pin versions in npm. Instead of npm install <package> use npm install <package>@<version>


100: Pin versions in apk add. Instead of apk add <package> use apk add <package>=<version>


100: Use the --no-cache switch to avoid the need to use --update and remove /var/cache/apk/* when done installing packages


104: Use COPY instead of ADD for files and folders


105: Use COPY instead of ADD for files and folders


106: Use COPY instead of ADD for files and folders


113: Multiple consecutive RUN instructions. Consider consolidation.


113: Pin versions in npm. Instead of npm install <package> use npm install <package>@<version>


132: Avoid additional packages by specifying --no-install-recommends


132: Pin versions in apt get install. Instead of apt-get install <package> use apt-get install <package>=<version>


144: Use COPY instead of ADD for files and folders


165: COPY to a relative destination without WORKDIR set.

Path-based Instructions (1)
scripts/ci/Dockerfile (1)

Pattern scripts/**/*: "Confirm that the code adheres to the following:

  • Script efficiency, readability, and maintainability.
  • Usage of environmental variables and configuration files for flexibility.
  • Integration with NX workspace utilities and commands."
Additional comments not posted (8)
.github/actions/tsconfig.json (1)

15-15: Change in TypeScript configuration aligns with the objective to simplify and stabilize the build environment.

.github/actions/main.ts (1)

11-29: Simplified conditional logic for determining the revision based on the GitHub event type aligns with the PR's objective to simplify logic.

.github/actions/unit-test/action.yml (1)

39-41: Updated Node.js version and setup-node action version to ensure consistency across workflows.

Verification successful

The verification confirms that the Node.js version '18' is consistently used across multiple workflow files, including .github/workflows/push.yml, .github/workflows/pullrequest.yml, and .github/workflows/config-values.yaml.

  • .github/workflows/push.yml
  • .github/workflows/pullrequest.yml
  • .github/workflows/config-values.yaml
Scripts Executed

The following scripts were executed for the analysis:


Script:

#!/bin/bash
# Description: Verify that the Node.js version is consistent across all workflow files.

# Test: Search for Node.js version across workflows. Expect: Consistent version.
rg --type yaml $'node-version: \\'18\\''

Length of output: 237



Script:

#!/bin/bash
# Description: Verify that the Node.js version is consistent across all workflow files.

# Test: Search for Node.js version across workflows. Expect: Consistent version.
rg --type yaml 'node-version: .?18'

Length of output: 37



Script:

#!/bin/bash
# Description: Verify all instances of Node.js version across workflow files.

# Test: Search for all 'node-version' entries in YAML files to check for inconsistencies.
rg --type yaml 'node-version:'

Length of output: 30



Script:

#!/bin/bash
# Description: List all YAML files in the repository to manually inspect for 'node-version' entries.

# List all YAML files in the repository.
fd --type f --extension yaml

Length of output: 3027



Script:

#!/bin/bash
# Description: Verify all instances of Node.js version in GitHub Actions workflow files.

# Search for all 'node-version' entries in the .github/workflows directory.
rg --type yaml 'node-version:' .github/workflows

Length of output: 853

.github/workflows/push.yml (3)

369-369: Ensure the script 10_prepare-docker-deps.sh is optimized for performance and error handling.

Verification successful

The script 10_prepare-docker-deps.sh is well-optimized for performance and includes robust error handling mechanisms.

  • The use of set -euxo pipefail ensures that the script exits on errors, treats unset variables as errors, and fails on any command in a pipeline.
  • The script employs Docker buildx with caching, which enhances performance by reusing previously built layers.
Scripts Executed

The following scripts were executed for the analysis:


Script:

#!/bin/bash
# Description: Check the contents of the script for performance and error handling practices.

# Test: Display the script content. Expect: Proper error handling and performance optimizations.
cat scripts/ci/10_prepare-docker-deps.sh

Length of output: 693


604-606: Review the use of run-in-parallel.sh for building Docker images to ensure it handles errors and parallel execution correctly.

Also applies to: 608-612

Verification successful

The run-in-parallel.sh script correctly handles errors and parallel execution:

  • It uses set -euo pipefail to ensure strict error handling.
  • It utilizes parallel with the --halt soon,fail=1 option to stop all jobs if one fails, ensuring robust parallel execution.
Scripts Executed

The following scripts were executed for the analysis:


Script:

#!/bin/bash
# Description: Check the script for error handling and parallel execution capabilities.

# Test: Display the script content. Expect: Proper error handling and support for parallel execution.
cat scripts/ci/run-in-parallel.sh

Length of output: 620


451-453: Confirm that the Node.js version '18' is appropriate for all test jobs.

.github/actions/yarn.lock (2)

1613-1618: The downgrade of @types/node to 20.11.4 and the associated dependency updates are correctly reflected.


1718-1718: The version of @types/node is consistently set to 20.11.4 across the file, aligning with the revert objective.

Comment on lines +518 to +520
- uses: actions/setup-node@v3
with:
node-version: '18'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicate actions/setup-node steps detected. Consider merging them to simplify the workflow.

- - uses: actions/setup-node@v3
-   with:
-     node-version: '18'
-   if: steps.gather.outcome == 'success'
- - uses: actions/setup-node@v3
-   with:
-     node-version: '18'
-   if: steps.gather.outcome == 'success'
+ - uses: actions/setup-node@v3
+   with:
+     node-version: '18'
+   if: steps.gather.outcome == 'success'

Also applies to: 523-525

Committable suggestion was skipped due low confidence.

Comment on lines +280 to +284
PACKAGE_JSON_HASH=$(cat package.json | jq '{resolutions,dependencies,devDependencies}' | sha1sum -t | cut -f1 -d" ")
echo "PACKAGE_JSON_HASH: $PACKAGE_JSON_HASH"
export NODE_MODULES_HASH=${{ runner.os }}-${{ hashFiles('yarn.lock') }}-$PACKAGE_JSON_HASH
echo "NODE_MODULES_HASH: $NODE_MODULES_HASH"
echo "node-modules-hash=$NODE_MODULES_HASH" >> $GITHUB_OUTPUT
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Optimize the calculation of NODE_MODULES_HASH by using a more efficient hashing mechanism.

- PACKAGE_JSON_HASH=$(cat package.json | jq '{resolutions,dependencies,devDependencies}' | sha1sum -t | cut -f1 -d" ")
- export NODE_MODULES_HASH=${{ runner.os }}-${{ hashFiles('yarn.lock') }}-$PACKAGE_JSON_HASH
+ export NODE_MODULES_HASH=${{ runner.os }}-${{ hashFiles('package.json', 'yarn.lock') }}

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
PACKAGE_JSON_HASH=$(cat package.json | jq '{resolutions,dependencies,devDependencies}' | sha1sum -t | cut -f1 -d" ")
echo "PACKAGE_JSON_HASH: $PACKAGE_JSON_HASH"
export NODE_MODULES_HASH=${{ runner.os }}-${{ hashFiles('yarn.lock') }}-$PACKAGE_JSON_HASH
echo "NODE_MODULES_HASH: $NODE_MODULES_HASH"
echo "node-modules-hash=$NODE_MODULES_HASH" >> $GITHUB_OUTPUT
export NODE_MODULES_HASH=${{ runner.os }}-${{ hashFiles('package.json', 'yarn.lock') }}
echo "NODE_MODULES_HASH: $NODE_MODULES_HASH"
echo "node-modules-hash=$NODE_MODULES_HASH" >> $GITHUB_OUTPUT

Comment on lines +171 to +173
- uses: actions/setup-node@v3
with:
node-version-file: 'package.json'
node-version: '18.8.0'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tip

Codebase Verification

Ensure consistent Node.js version across all workflow jobs.

  • The following files have inconsistent Node.js versions:
    • .github/workflows/push.yml
    • .github/workflows/pullrequest.yml

Please update all instances to use the same Node.js version, preferably 18.8.0.

Analysis chain

Ensure the Node.js version is consistent across all workflow jobs.

Scripts Executed

The following scripts were executed for the analysis:


Script:

#!/bin/bash
# Description: Verify that all instances of `actions/setup-node` use the same Node.js version.

# Test: Search for different Node.js versions. Expect: Only '18.8.0' should be used.
rg --type yaml $'actions/setup-node@v3' .github/workflows/*.yml | rg 'node-version'

Length of output: 304



Script:

#!/bin/bash
# Description: Verify that all instances of `actions/setup-node` use the same Node.js version.

# Test: Search for all instances of `node-version` in the workflow files.
rg --type yaml 'node-version' .github/workflows/*.yml

Length of output: 950

@@ -1,10 +1,9 @@
ARG DOCKER_IMAGE_REGISTRY=public.ecr.aws
ARG NODE_IMAGE_TAG
FROM ${DOCKER_IMAGE_REGISTRY}/docker/library/node:${NODE_IMAGE_TAG} as runner
FROM $DOCKER_IMAGE_REGISTRY/docker/library/node:18-alpine3.15 as runner

RUN apk add postgresql-client bash
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use the --no-cache option with apk add to avoid unnecessary cache storage.

- RUN apk add postgresql-client bash
+ RUN apk add --no-cache postgresql-client bash

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
RUN apk add postgresql-client bash
RUN apk add --no-cache postgresql-client bash

Consider pinning the version of packages installed with apk add to ensure reproducibility.

- RUN apk add postgresql-client bash
+ RUN apk add postgresql-client=<version> bash=<version>

Committable suggestion was skipped due low confidence.

`'${process.env.HEAD_REF!}'`,
`'${process.env.BASE_REF!}'`,
process.env.WORKFLOW_ID! as WorkflowID,
)

if (rev === 'rebuild') {
console.log(`Full rebuild needed`)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid using template literals when not necessary for interpolation or special characters.

- console.log(`Full rebuild needed`)
+ console.log('Full rebuild needed')

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
console.log(`Full rebuild needed`)
console.log('Full rebuild needed')

diffWeight,
git,
runner,
`'${process.env.HEAD_REF!}'`,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid using non-null assertions unless absolutely necessary as they bypass TypeScript's type safety checks.

- `'${process.env.HEAD_REF!}'`
- `'${process.env.BASE_REF!}'`
- `'${process.env.PR_REF!}'`
+ process.env.HEAD_REF ?? 'default-value'
+ process.env.BASE_REF ?? 'default-value'
+ process.env.PR_REF ?? 'default-value'

Also applies to: 18-18, 19-19, 26-26, 27-27

Committable suggestion was skipped due low confidence.

@@ -1,8 +1,7 @@
# This is a multi-stage Dockerfile which contains all CI-related operations as well as images to be deployed in production
ARG PLAYWRIGHT_VERSION
ARG DOCKER_IMAGE_REGISTRY=public.ecr.aws
ARG NODE_IMAGE_TAG
FROM ${DOCKER_IMAGE_REGISTRY}/docker/library/node:${NODE_IMAGE_TAG} as deps
FROM $DOCKER_IMAGE_REGISTRY/docker/library/node:18-alpine3.15 as deps
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider pinning the version of packages installed with apk add to ensure reproducibility.

- RUN apk add -U git
+ RUN apk add -U git=<version>

Committable suggestion was skipped due low confidence.

Comment on lines +48 to +50
- uses: actions/setup-node@v3
with:
node-version-file: 'package.json'
node-version: '18.8.0'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tip

Codebase Verification

The verification process revealed that there are multiple instances of node-version in the .github/workflows directory, with versions 18.8.0 and 18 being used. This indicates inconsistency in the Node.js versions across the workflow files.

  • .github/workflows/push.yml:

    • node-version: '18.8.0'
    • node-version: '18' (multiple instances)
  • .github/workflows/pullrequest.yml:

    • node-version: '18.8.0'
    • node-version: '18' (multiple instances)

To ensure consistency, it is recommended to standardize the Node.js version across all workflow files.

Analysis chain

Updated Node.js version and setup-node action version to ensure consistency across workflows.

Also applies to: 249-251, 310-312, 373-375, 416-418, 460-462, 509-511

Scripts Executed

The following scripts were executed for the analysis:


Script:

#!/bin/bash
# Description: Verify that the Node.js version is consistent across all workflow files.

# Test: Search for Node.js version across workflows. Expect: Consistent version.
rg --type yaml $'node-version: \\'18\\''

Length of output: 237



Script:

#!/bin/bash
# Description: Verify that the Node.js version is consistent across all workflow files.

# Test: Search for Node.js version across workflows. Expect: Consistent version.
rg --type yaml 'node-version: '\''18.8.0'\'''

Length of output: 47



Script:

#!/bin/bash
# Description: Search for all instances of `node-version` in the workflow files to identify any discrepancies.

# Test: Search for `node-version` across workflows.
rg --type yaml 'node-version'

Length of output: 29



Script:

#!/bin/bash
# Description: List all YAML files in the repository to manually inspect for `node-version`.

# List all YAML files in the repository.
fd --type f --extension yaml

Length of output: 3027



Script:

#!/bin/bash
# Description: Search for `node-version` specifically within the `.github/workflows` directory to identify any discrepancies.

# Test: Search for `node-version` in the `.github/workflows` directory.
rg --glob '.github/workflows/*.yml' 'node-version'

Length of output: 199



Script:

#!/bin/bash
# Description: List the contents of the `.github/workflows` directory and search for `node-version` within those files.

# List the contents of the `.github/workflows` directory.
echo "Contents of .github/workflows directory:"
ls .github/workflows

# Search for `node-version` within the `.github/workflows` directory.
echo "Searching for 'node-version' in .github/workflows/*.yml files:"
rg 'node-version' .github/workflows/*.yml

Length of output: 1334

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant