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

yarn to bun #64

Merged
merged 4 commits into from
Feb 4, 2024
Merged

yarn to bun #64

merged 4 commits into from
Feb 4, 2024

Conversation

tktcorporation
Copy link
Owner

@tktcorporation tktcorporation commented Feb 4, 2024

Summary by CodeRabbit

  • Chores
    • WebおよびElectronアプリのビルドコマンドを「bun」セットアップに変更しました。
    • パッケージのインストールコマンドを更新しました。
  • Tests
    • リントとテストのワークフローを「bun」セットアップに更新しました。
    • 新しいグローバルパッケージを追加しました。

Copy link
Contributor

coderabbitai bot commented Feb 4, 2024

Walkthrough

プロジェクトのビルドとテストのプロセスを改善するために、Node.jsのセットアップを"Bun"に置き換え、パッケージのインストールとビルドコマンドを更新しました。また、lintとtestのワークフローを最適化し、新しいグローバルパッケージを追加しました。これらの変更は、TypeScriptの型エラーを解決し、プロジェクトの開発効率を向上させることを目指しています。

Changes

ファイル 変更サマリー
.github/wip-screenshot.yml,
.github/workflows/tag-on-push.yml,
.github/workflows/upload-build-files.yml
Node.jsのセットアップを"Bun"に置き換え、パッケージのインストールとビルドコマンドを更新
.github/workflows/lint-test.yml "setup bun"を使用するように更新、@antfu/ninciのグローバルパッケージを追加、lintとtestのコマンドをnrに変更

Assessment against linked issues

目標 対応されたか 説明
FSWatcherrefunrefプロパティが足りない型エラーの解決 (#15714) プルリクエストの説明では直接的にこの問題に言及していませんが、ビルドプロセスの変更が間接的に影響を与える可能性があります。

Poem

🐇 Bunに乗り換えて、
コードは軽やかに跳ねる。
エラーは遠く、過去のものに、
新しい朝が、開発者に微笑む。 🌅

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-tests for this file.
  • 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 tests 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 from git and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit tests.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

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

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

CodeRabbit Discord Community

Join our Discord Community to get help, request features, and share feedback.

@tktcorporation tktcorporation merged commit 12a457f into main Feb 4, 2024
1 check passed
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.

Review Status

Actionable comments generated: 13

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between 83295f4 and 8e8c775.
Files ignored due to path filters (4)
  • Screenshot.jpg is excluded by: !**/*.jpg
  • package.json is excluded by: !**/*.json
  • tsconfig.json is excluded by: !**/*.json
  • yarn.lock is excluded by: !**/*.lock
Files selected for processing (4)
  • .github/wip-screenshot.yml (1 hunks)
  • .github/workflows/lint-test.yml (1 hunks)
  • .github/workflows/tag-on-push.yml (1 hunks)
  • .github/workflows/upload-build-files.yml (1 hunks)
Additional comments: 4
.github/workflows/lint-test.yml (1)
  • 14-15: setup bun の使用に切り替えられましたが、oven-sh/setup-bun@v1 のバージョン指定が正しいか確認してください。最新かつ安定したバージョンを使用することが推奨されます。
.github/workflows/tag-on-push.yml (1)
  • 18-19: setup bun の使用に切り替えられましたが、oven-sh/setup-bun@v1 のバージョン指定が最適かどうかを確認してください。最新かつ安定したバージョンの使用を確認することが重要です。
.github/workflows/upload-build-files.yml (1)
  • 25-26: setup bun の使用に切り替えられましたが、oven-sh/setup-bun@v1 のバージョン指定が最適かどうかを確認してください。最新かつ安定したバージョンの使用を確認することが重要です。
.github/wip-screenshot.yml (1)
  • 17-18: setup bun の使用に切り替えられましたが、oven-sh/setup-bun@v1 のバージョン指定が最適かどうかを確認してください。最新かつ安定したバージョンの使用を確認することが重要です。

- name: setup bun
uses: oven-sh/setup-bun@v1

- run: npm i -g @antfu/ni
Copy link
Contributor

Choose a reason for hiding this comment

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

npm i -g @antfu/ni の実行は、Bun を使用しているプロジェクトで npm コマンドを直接使用するのは一貫性がなく、混乱を招く可能性があります。bun install @antfu/ni または ni 自体の Bun によるサポートを確認してください。

- name: install dependencies
run: yarn install --frozen-lockfile
run: nci
Copy link
Contributor

Choose a reason for hiding this comment

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

依存関係のインストールに nci を使用することは、antfu/ni を介して異なるパッケージマネージャー間でのコマンドの抽象化を意図していますが、Bun で直接 bun install を使用することが推奨されます。nci の使用は冗長かもしれません。


- name: lint
run: yarn lint && yarn type-check
run: nr lint && nr type-check
Copy link
Contributor

Choose a reason for hiding this comment

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

Lint と型チェックのコマンドが nr lint && nr type-check に更新されました。nr コマンドの使用は antfu/ni に依存していますが、これらのタスクに Bun のネイティブコマンドを使用することも検討してください。また、コマンドの実行に失敗した場合にビルドが停止するように、&& の代わりに ; を使用することを検討してください。


- name: test
run: yarn test
run: nr test
Copy link
Contributor

Choose a reason for hiding this comment

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

テストコマンドが nr test に更新されました。ここでも、Bun のネイティブコマンドの使用を検討するか、antfu/ni を介したコマンドの抽象化が適切かどうかを再評価してください。

- name: setup bun
uses: oven-sh/setup-bun@v1

- run: npm i -g @antfu/ni
Copy link
Contributor

Choose a reason for hiding this comment

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

npm i -g @antfu/ni の実行は、Bun を使用しているプロジェクトで npm コマンドを直接使用することの一貫性の欠如を示しています。bun install @antfu/ni または ni の Bun によるサポートを確認してください。


- name: Install dependencies
run: yarn install --frozen-lockfile
run: nci
Copy link
Contributor

Choose a reason for hiding this comment

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

依存関係のインストールに nci を使用することは、antfu/ni を介して異なるパッケージマネージャー間でのコマンドの抽象化を意図していますが、Bun で直接 bun install を使用することが推奨されます。nci の使用は冗長かもしれません。


- name: Build Electron app
run: yarn dist
run: nr dist
Copy link
Contributor

Choose a reason for hiding this comment

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

Electron アプリのビルドコマンドが nr dist に更新されました。ここでも、Bun のネイティブコマンドの使用を検討するか、antfu/ni を介したコマンドの抽象化が適切かどうかを再評価してください。

- name: setup bun
uses: oven-sh/setup-bun@v1

- run: npm i -g @antfu/ni
Copy link
Contributor

Choose a reason for hiding this comment

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

npm i -g @antfu/ni の実行は、Bun を使用しているプロジェクトで npm コマンドを直接使用することの一貫性の欠如を示しています。bun install @antfu/ni または ni の Bun によるサポートを確認してください。


- name: Install dependencies
run: yarn install --frozen-lockfile
run: nci
Copy link
Contributor

Choose a reason for hiding this comment

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

依存関係のインストールに nci を使用することは、antfu/ni を介して異なるパッケージマネージャー間でのコマンドの抽象化を意図していますが、Bun で直接 bun install を使用することが推奨されます。nci の使用は冗長かもしれません。


- name: Start web app (example using Vite)
run: yarn dev &
run: nr dev &
Copy link
Contributor

Choose a reason for hiding this comment

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

Web アプリを起動するコマンドが nr dev & に更新されました。nr コマンドの使用は antfu/ni に依存していますが、このタスクに Bun のネイティブコマンドを使用することも検討してください。また、バックグラウンドで実行する場合は、適切なリソース管理を確認してください。

tktcorporation added a commit that referenced this pull request Feb 4, 2024
This reverts commit 12a457f, reversing
changes made to 83295f4.
@tktcorporation tktcorporation mentioned this pull request Feb 4, 2024
Merged
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.

type error | Type 'FSWatcher' is missing the following properties from type 'FSWatcher': ref, unref
1 participant