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

chore: refactor ci config #207

Merged
merged 1 commit into from
Dec 1, 2023
Merged

chore: refactor ci config #207

merged 1 commit into from
Dec 1, 2023

Conversation

jill64
Copy link
Owner

@jill64 jill64 commented Dec 1, 2023

Summary by CodeRabbit

  • Refactor

    • Updated ESLint configuration to use a shared Svelte TypeScript configuration.
    • Streamlined Playwright testing configuration by extending a shared configuration.
  • Chores

    • Adjusted ESLint ignores to exclude 'tests', 'demo', and 'scripts' directories.

Copy link

coderabbitai bot commented Dec 1, 2023

Walkthrough

The updates involve configuration changes for ESLint and Playwright. ESLint configurations now import custom settings from a shared package and apply them, while Playwright configurations have been simplified by extending a base configuration from another package. These changes streamline the setup process and enforce consistent coding and testing standards across projects.

Changes

File Path Change Summary
demo/eslint.config.js Imported svelteTsConfig from @jill64/eslint-config-svelte and used it to export default configuration.
eslint.config.js Added tsConfig import from @jill64/eslint-config-ts and exported a configuration array with additional ignores.
playwright.config.ts Replaced custom configuration with extendsConfig from @jill64/playwright-config.

Poem

🐇 CodeRabbit hopped along,
📝 Tweaking configs, making them strong.
🚀 With each import and spread,
🌟 The cleaner codebase was widely spread.


Tips

Chat with CodeRabbit Bot (@coderabbitai)

  • If you reply to a review comment from CodeRabbit, the bot will automatically respond.
  • To engage with CodeRabbit bot directly around the specific lines of code in the PR, mention @coderabbitai in your review comment
  • Note: Review comments are made on code diffs or files, not on the PR overview.
  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

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 a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Note: For conversation with the bot, please use the review comments on code diffs or files.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • 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/coderabbit-overrides.v2.json

@wraith-ci wraith-ci bot enabled auto-merge December 1, 2023 12:37
Copy link

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 90ef9c3
Status: ✅  Deploy successful!
Preview URL: https://4977a45f.sentry-sveltekit-cloudflare.pages.dev
Branch Preview URL: https://dev.sentry-sveltekit-cloudflare.pages.dev

View logs

@wraith-ci wraith-ci bot merged commit 4241dcb into main Dec 1, 2023
4 checks passed
@wraith-ci wraith-ci bot deleted the dev branch December 1, 2023 12:37
Copy link

@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.

Review Status

Actionable comments generated: 1

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between d8ddb50 and 90ef9c3.
Files ignored due to filter (3)
  • demo/package.json
  • package.json
  • pnpm-lock.yaml
Files selected for processing (3)
  • demo/eslint.config.js (1 hunks)
  • eslint.config.js (1 hunks)
  • playwright.config.ts (1 hunks)
Additional comments: 4
demo/eslint.config.js (1)
  • 1-4: The changes to the ESLint configuration file are correct and follow the intended refactoring to use a shared configuration package. Ensure that dependents are aware of the new linting rules and adjust their code if necessary.
playwright.config.ts (3)
  • 1-1: The import statement has been changed to use extendsConfig from @jill64/playwright-config. Verify that this package provides all the necessary configurations and is compatible with the project's requirements.

  • 5-12: The new configuration is significantly simplified and no longer includes specific settings such as testDir, fullyParallel, workers, retries, and projects. Ensure that these settings are provided by extendsConfig or are no longer required for the project.

  • 7-10: The baseURL is dynamically set based on the GITHUB_REF_NAME environment variable. Confirm that the branches are correctly set up to serve the application for this configuration to work as intended.

export default [
...tsConfig(),
{
ignores: ['tests', 'demo', 'scripts']
Copy link

Choose a reason for hiding this comment

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

The ESLint configuration property for specifying patterns to ignore should be ignorePatterns, not ignores.

-    ignores: ['tests', 'demo', 'scripts']
+    ignorePatterns: ['tests', 'demo', 'scripts']

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
ignores: ['tests', 'demo', 'scripts']
ignorePatterns: ['tests', 'demo', 'scripts']

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