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

Add option to specify executable file name #999

Merged

Conversation

shadowspawn
Copy link
Collaborator

@shadowspawn shadowspawn commented Jul 20, 2019

Builds on #854 to add command option for specifying executable file name, and overriding default name construction.

  • change option name to executableFile
  • lookup executableFile for alias and default executable too
  • check for javascript file extensions for executableFile and keep behaviour consistent
  • added to README

(Includes latest commits in master, pulled in when merging #854.)

abetomo and others added 8 commits August 29, 2018 16:53
Because there was a major upgrade.
Node.js 6 is EOL.
I get the following error in a library that does not support Node.js 6.

```
node_modules/eslint/lib/cli-engine/cli-engine.js:257
        ...calculateStatsPerFile(messages)
        ^^^
```
- add to README
- rename option
- include support for executableFile for alias and default command
- consistent use of node to launch javascript files
@shadowspawn
Copy link
Collaborator Author

Example call for interested readers:

  .command("init", "prepare project for first use", { executableFile: "myInit.js" })

Copy link
Collaborator

@abetomo abetomo left a comment

Choose a reason for hiding this comment

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

Thank you.

@shadowspawn shadowspawn merged commit 831d52f into tj:release/3.0.0 Jul 23, 2019
@shadowspawn shadowspawn added the pending release Merged into a branch for a future release, but not released yet label Jul 23, 2019
@shadowspawn
Copy link
Collaborator Author

Available now as a prerelease. See #1001

@shadowspawn shadowspawn deleted the feature/specifyExecutableFile branch July 27, 2019 07:40
@shadowspawn
Copy link
Collaborator Author

@shadowspawn shadowspawn removed the pending release Merged into a branch for a future release, but not released yet label Aug 12, 2019
@CaptainQuirk
Copy link

CaptainQuirk commented Aug 22, 2019

Hi there !

Could it be that you forgot to update the typescript definition for the option object passed to the command function ?

from typings/index.d.ts, line 279

interface CommandOptions {
    noHelp?: boolean;
    isDefault?: boolean;
}

@shadowspawn
Copy link
Collaborator Author

Drat! Thanks @CaptainQuirk, I'll fix that.

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

Successfully merging this pull request may close these issues.

None yet

3 participants