Skip to content

feat: registerTask support order#709

Merged
XGHeaven merged 1 commit intonextfrom
feat/support-task-order
Mar 25, 2026
Merged

feat: registerTask support order#709
XGHeaven merged 1 commit intonextfrom
feat/support-task-order

Conversation

@XGHeaven
Copy link
Copy Markdown
Collaborator

No description provided.

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new bot commented Mar 24, 2026

More templates

@ice/create-pkg

npm i https://pkg.pr.new/ice-lab/icepkg/@ice/create-pkg@709

ice-npm-utils

npm i https://pkg.pr.new/ice-lab/icepkg/ice-npm-utils@709

@ice/pkg

npm i https://pkg.pr.new/ice-lab/icepkg/@ice/pkg@709

@ice/pkg-plugin-jsx-plus

npm i https://pkg.pr.new/ice-lab/icepkg/@ice/pkg-plugin-jsx-plus@709

@ice/pkg-plugin-mf

npm i https://pkg.pr.new/ice-lab/icepkg/@ice/pkg-plugin-mf@709

commit: 7ecd3bc

@XGHeaven XGHeaven mentioned this pull request Mar 24, 2026
28 tasks
@XGHeaven XGHeaven force-pushed the feat/support-task-order branch from 46012d6 to 7b4fb72 Compare March 25, 2026 04:21
@XGHeaven XGHeaven requested a review from Copilot March 25, 2026 08:05
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds a global task ordering mechanism so tasks registered via registerTask can run in pre/builtin/normal/post phases, and ensures built-in tasks are treated as builtin during execution.

Changes:

  • Add TaskOrder and order?: TaskOrder to task config typings.
  • Introduce sortBuildTasksByOrder helper and apply it in getTaskRunners.
  • Update built-in task registration to assign order: 'builtin', plus add unit tests for ordering.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
packages/pkg/src/types.ts Adds TaskOrder and order to task configuration types.
packages/pkg/src/helpers/taskOrder.ts New helper to sort build tasks by the global order.
packages/pkg/src/helpers/getTaskRunners.ts Sorts tasks before creating runners to honor global ordering.
packages/pkg/src/core/register.ts Marks built-in registered tasks as builtin order.
packages/pkg/tests/helpers/getTaskRunners.test.ts Adds unit tests for sortBuildTasksByOrder.
.changeset/fair-items-help.md Declares a minor release for the new feature.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@XGHeaven XGHeaven force-pushed the feat/support-task-order branch from 7ecd3bc to 829e8a3 Compare March 25, 2026 13:11
@XGHeaven XGHeaven merged commit f6caa58 into next Mar 25, 2026
2 of 3 checks passed
@XGHeaven XGHeaven deleted the feat/support-task-order branch March 25, 2026 13:12
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.

2 participants