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

CLI make and gen have different default behaviors #145

Closed
stephengoldbaum opened this issue Sep 3, 2020 · 1 comment · Fixed by #150
Closed

CLI make and gen have different default behaviors #145

stephengoldbaum opened this issue Sep 3, 2020 · 1 comment · Fixed by #150
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@stephengoldbaum
Copy link
Member

Running moprhir-elm make relies on the morphir.json configuration file by default. Running morphir-elm gen defaults to expecting a pipe and takes the configuration file as an optional argument. It should probably match the make command for consistency and leave the piping as an option.

@AttilaMihaly
Copy link
Member

There are two JSON files at play here:

  • The morphir.json that morphir-elm make expects is a descriptor that the Elm frontend uses to be able to find the Elm sources and to add extra package information.
  • The JSON that morphir-elm make outputs and morphir-elm gen expects as input is the Morphir IR. They use stdout/stdin by default and they have -o and -i options to specify the a file if that's what the user prefers.

Considering the above I think the behavior is consistent but I understand how it can be confusing. To simplify I suggest removing the stdout/stdin path and make the -o/-i options required. I'll also add note to the docs to further clarify the purpose of each JSON.

@AttilaMihaly AttilaMihaly self-assigned this Sep 3, 2020
@AttilaMihaly AttilaMihaly added documentation Improvements or additions to documentation enhancement New feature or request labels Sep 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants