radiumsoftware / iridium

MIT License
128 stars 18 forks source link

Cryptic output of bin/iridium (Hydrogen/Thor issue?) #39

Open ahx opened 11 years ago

ahx commented 11 years ago

I am new to iridium, so i tried to run the iridium command, but the output looks a bit cryptic:

iridium [master]$ b ./bin/iridium Tasks: iridium Iridium::CLI ARGS # Run jslint on some files iridium Iridium::CLI ARGS # Executes tests iridium Iridium::CLI ARGS # Compile assets for deployment iridium Iridium::CLI ARGS # Start a preview server iridium generate NAME ARGS # run the given generator iridium help [TASK] # Describe available tasks or one specific task

The last two commands look fine, but the first four seem to miss the command name.

ghedamat commented 11 years ago

+1 for this :)

george commented 11 years ago

The generate command comes directly from hydrogen: https://github.com/radiumsoftware/hydrogen/blob/master/lib/hydrogen/cli.rb#L18

And the help command comes from Thor: https://github.com/erikhuda/thor/blob/87dc98c6e2c183c9b1f867c6c8e1b62ede5242bc/lib/thor.rb#L469

which might explain why they produce the correct help text.

The other, problematic help texts appear to be from commands that go through Hydrogen::CLI.add_subcommands!. So it would appear as if this issue is with hydrogen and not iridium.

Does that sound like an accurate assessment? If so, I'll start looking at the hydrogen code.

ahawkins commented 11 years ago

The other, problematic help texts appear to be from commands that go through Hydrogen::CLI.add_subcommands!. So it would appear as if this issue is with hydrogen and not iridium.

This sounds like a fair assessment. I don't know if this is still a problem on thor master. There have been changes (by me) to thor to make iridium work. I've never used the built in help command so I've never been exposed to this.