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

[Regression] Too long paths #314

Closed
glensc opened this issue Dec 1, 2021 · 3 comments · Fixed by #316
Closed

[Regression] Too long paths #314

glensc opened this issue Dec 1, 2021 · 3 comments · Fixed by #316
Labels

Comments

@glensc
Copy link

glensc commented Dec 1, 2021

The text format prints soo long paths that they have to be wrapped on screen.

$ churn run src/
    ___  _   _  __  __  ____  _  _     ____  _   _  ____
   / __)( )_( )(  )(  )(  _ \( \( )___(  _ \( )_( )(  _ \
  ( (__  ) _ (  )(__)(  )   / )  ((___))___/ ) _ (  )___/
   \___)(_) (_)(______)(_)\_)(_)\_)   (__)  (_) (_)(__)

+-------------------------------------------------------------------------------------------------------+---------------+------------+-------+
| File                                                                                                  | Times Changed | Complexity | Score |
+-------------------------------------------------------------------------------------------------------+---------------+------------+-------+
| /Users/glen/OneDrive - Obfuscated for Privacy/scm/portal/project1/src/Service/UpdateFrontpageService.php  | 18            | 30         | 0.692 |
| /Users/glen/OneDrive - Obfuscated for Privacy/scm/portal/project1/src/Broadcast/Provider/Onesignal.php    | 16            | 14         | 0.342 |
| /Users/glen/OneDrive - Obfuscated for Privacy/scm/portal/project1/src/ServiceProvider/ServiceProvider.php | 26            | 5          | 0.167 |
+-------------------------------------------------------------------------------------------------------+---------------+------------+-------+

Solution: Print relative paths

In the example the common path is 66 characters:

/Users/glen/OneDrive - Obfuscated for Privacy/scm/portal/project1/
@glensc
Copy link
Author

glensc commented Dec 1, 2021

Looks like it also breaks the table formatting if joined to one line

image

@villfa
Copy link
Collaborator

villfa commented Dec 1, 2021

Hi,

Thanks for reporting this issue!

This problem has been introduced since #300.

I should come up with a solution soon.

@glensc glensc changed the title Too long paths [Regression] Too long paths Dec 1, 2021
@villfa
Copy link
Collaborator

villfa commented Dec 8, 2021

The fix has been released with Churn-PHP 1.5.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants