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(build): fix progress of log #3665

Merged
merged 3 commits into from
Nov 14, 2024
Merged

chore(build): fix progress of log #3665

merged 3 commits into from
Nov 14, 2024

Conversation

EdamAme-x
Copy link
Contributor

Before
Removing private fields(0/170): dist\types\types.d.ts

After
Removing private fields(1/170): dist\types\types.d.ts

Progress should start at 1

Copy link

codecov bot commented Nov 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.70%. Comparing base (d405215) to head (89542df).
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3665   +/-   ##
=======================================
  Coverage   91.70%   91.70%           
=======================================
  Files         159      159           
  Lines       10145    10145           
  Branches     2868     2831   -37     
=======================================
  Hits         9303     9303           
  Misses        840      840           
  Partials        2        2           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@yusukebe
Copy link
Member

Hi @EdamAme-x

Indeed, we can fix it. How about this implementation?

diff --git a/build/build.ts b/build/build.ts
index 34285bb7..7e31934e 100644
--- a/build/build.ts
+++ b/build/build.ts
@@ -102,7 +102,7 @@ const dtsEntries = glob.globSync('./dist/types/**/*.d.ts')
 const writer = stdout.writer()
 writer.write('\n')
 let lastOutputLength = 0
-for (let i = 0; i < dtsEntries.length; i++) {
+for (let i = 1; i < dtsEntries.length + 1; i++) {
   const entry = dtsEntries[i]

   const message = `Removing private fields(${i}/${dtsEntries.length}): ${entry}`

@EdamAme-x
Copy link
Contributor Author

EdamAme-x commented Nov 13, 2024

okay, I'll try

@EdamAme-x
Copy link
Contributor Author

I was try it, I think the code is a little redundant.

for (let i = 1; i < dtsEntries.length + 1; i++) {
  const entry = dtsEntries[i - 1]

Copy link
Member

@yusukebe yusukebe left a comment

Choose a reason for hiding this comment

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

LGTM!

@yusukebe
Copy link
Member

@EdamAme-x

You are right. My code was bad. Thanks!

@yusukebe yusukebe merged commit 082862b into honojs:main Nov 14, 2024
16 checks passed
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