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

🚀 Feature: Improve creation performance with create #1782

Open
2 tasks done
JoshuaKGoldberg opened this issue Dec 20, 2024 · 0 comments
Open
2 tasks done

🚀 Feature: Improve creation performance with create #1782

JoshuaKGoldberg opened this issue Dec 20, 2024 · 0 comments
Assignees
Labels
status: accepting prs Please, send a pull request to resolve this! type: feature New enhancement or request

Comments

@JoshuaKGoldberg
Copy link
Owner

JoshuaKGoldberg commented Dec 20, 2024

Bug Report Checklist

Overview

The total time to create a repository using create-typescript-app's Common preset right now is about 35 seconds. That's rather slow. I'd like to get it down much shorter.

As part of JoshuaKGoldberg/create#72, I added in rudimentary timing groups for applied scripts and requests. Here's raw data from an example run with create-typescript-app's Common preset:

┌────────────┬─────────────────────────────────────────────────┬───────────┐
│ group      │ id                                              │ time (ms) │
├────────────┼─────────────────────────────────────────────────┼───────────┤
│ 'scripts'  │ 'pnpm install'                                  │ 6239      │
│ 'scripts'  │ 'pnpm lint --fix'                               │ 2305      │
│ 'scripts'  │ 'npx -y all-contributors-cli generate'          │ 13424     │
│ 'scripts'  │ 'npx -y all-contribut ... ojectManagement,tool' │ 12355     │
│ 'scripts'  │ 'pnpm format --write'                           │ 792       │
│ 'requests' │ 'branch-protection'                             │ 149       │
│ 'requests' │ 'repository-labels'                             │ 16452     │
│ 'requests' │ 'repository-settings'                           │ 1335      │
└────────────┴─────────────────────────────────────────────────┴───────────┘

Additional Info

My initial takeaways are that:

  • npx -y all-contributors-cli commands are slow: I'd like to look into doing their work manually
  • repository-labels, running setGitHubRepositoryLabels from set-github-repository-labels, is much slower than it should be too. I'll have to look at its performance again.
    • Can its multiple API calls be joined into one?
    • Failing that, can it be parallelized more?
  • pnpm install taking >6 seconds also isn't ideal. Can I speed that up?
    • Does pnpm store add have any impact? I'm guessing no, that that would only serve to bring an even-higher install time down to the >6 seconds I'm seeing...

💖

@JoshuaKGoldberg JoshuaKGoldberg added type: feature New enhancement or request status: accepting prs Please, send a pull request to resolve this! labels Dec 20, 2024
@JoshuaKGoldberg JoshuaKGoldberg self-assigned this Dec 20, 2024
@JoshuaKGoldberg JoshuaKGoldberg transferred this issue from JoshuaKGoldberg/create Dec 20, 2024
@JoshuaKGoldberg JoshuaKGoldberg changed the title 🚀 Feature: Improve creation performance with create-typescript-app 🚀 Feature: Improve creation performance with create Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: accepting prs Please, send a pull request to resolve this! type: feature New enhancement or request
Projects
None yet
Development

No branches or pull requests

1 participant