rails_stats icon indicating copy to clipboard operation
rails_stats copied to clipboard

[#30] Explicitly set format as text for `Bundler::Stats::CLI` on `ConsoleFormatter`.

Open ruyrocha opened this issue 6 months ago • 1 comments

Closes #30

  • [x] Add an entry to CHANGELOG.md that links to this PR under the "main (unreleased)" heading.

Description:

Bundler::Stats::CLI was failing to display console output, and now it's fixed by setting the format as text.

I will abide by the code of conduct.

ruyrocha avatar Jun 14 '25 15:06 ruyrocha

main branch

 ~/G/rails_stats (main)> bundle exec rake stats\[points,stdout\]

Directory: /home/ruy/GitHub/rails_stats/points

Could not find command "stats[points,stdout]".
 ~/G/rails_stats (main) [1]>

this branch

 ~/G/rails_stats (hotfix/console-formatter)> bundle exec rake stats\[points,stdout\]

Directory: /home/ruy/GitHub/rails_stats/points

The dependency `bundler` wasn't found. It may not be present in your Gemfile.lock. This often happens when a dependency isn't installed on your platform.
The dependency `bundler` wasn't found. It may not be present in your Gemfile.lock. This often happens when a dependency isn't installed on your platform.
+-----------------------|------------|----------------+
|                  Name | Total Deps | 1st Level Deps |
+-----------------------|------------|----------------+
|     simplecov-console | 8          | 3              |
|               codecov | 4          | 1              |
|           rails_stats | 4          | 2              |
|             simplecov | 3          | 3              |
|       minitest-around | 1          | 1              |
|               bundler | 0          | 0              |
|                byebug | 0          | 0              |
|              minitest | 0          | 0              |
| minitest-spec-context | 0          | 0              |
+-----------------------|------------|----------------+

      Declared Gems   9
         Total Gems   18
  Unpinned Versions   6
        Github Refs   0

+----------------------+---------+---------+---------+---------+---------+-----+-------+
| Name                 | Files   | Lines   |     LOC | Classes | Methods | M/C | LOC/M |
+----------------------+---------+---------+---------+---------+---------+-----+-------+
| Channels             |       2 |       8 |       8 |       2 |       0 |   0 |     0 |
| Configuration        |      21 |     431 |     160 |       1 |       0 |   0 |     0 |
| Controller Tests     |       5 |     856 |     684 |       0 |       0 |   0 |     0 |
| Controllers          |      15 |     591 |     502 |      15 |      69 |   4 |     5 |
| Feature Tests        |      10 |    1392 |    1063 |       0 |       1 |   0 |  1061 |
| Helper Tests         |       1 |      10 |       9 |       0 |       0 |   0 |     0 |
| Helpers              |       6 |     126 |     103 |       0 |      17 |   0 |     4 |
| Javascripts          |       8 |     294 |     225 |       0 |      18 |   0 |    10 |
| Jobs                 |       1 |       2 |       2 |       1 |       0 |   0 |     0 |
| Madmins              |       5 |     124 |      54 |       5 |       4 |   0 |    11 |
| Mailers              |       1 |       4 |       4 |       1 |       0 |   0 |     0 |
| Model Tests          |       6 |     362 |     294 |       0 |       1 |   0 |   292 |
| Models               |       8 |     245 |     188 |       8 |      30 |   3 |     4 |
| Policies             |       6 |      84 |      65 |       7 |      14 |   2 |     2 |
| Policy Tests         |       1 |      37 |      29 |       0 |       0 |   0 |     0 |
| Spec Support         |      10 |     343 |     180 |       0 |       6 |   0 |    28 |
+----------------------+---------+---------+---------+---------+---------+-----+-------+
| Code                 |      73 |    1909 |    1311 |      40 |     152 |   3 |     6 |
| Tests                |      33 |    3000 |    2259 |       0 |       8 |   0 |   280 |
| Total                |     106 |    4909 |    3570 |      40 |     160 |   4 |    20 |
+----------------------+---------+---------+---------+---------+---------+-----+-------+
  Code LOC: 1311     Test LOC: 2259     Code to Test Ratio: 1:1.7  Files: 106

  Polymorphic models count: 0 polymorphic associations
  Schema Stats: 6 `create_table` calls in schema.rb
 ~/G/rails_stats (hotfix/console-formatter)>

ruyrocha avatar Jun 14 '25 15:06 ruyrocha