Skip to content

bug: task help generation via option() doesn't work #503

Description

@Hotell

Repro

const { task, logger, option, argv } = require('just-task');

option('name', {describe: 'user name or something'});

task('blimey', 'An exclamation of surprise.', function() {
  logger.info(`blimey! ${argv().name}`);
});

Actual behaviour

Basically --help output always invokes yargs default help command.

just --help

image

just blimey --help

image

Expected behaviour

just blimey --help

Options:
  --name    user name or something                                                 [string]
  --help     Show help                                                 [boolean]
  --version  Show version number                                       [boolean]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions