Commandline options clash

We have a submission of a Language Server Protocol for Alloy. There is also a draft for a shell version of alloy. And the current code has a SimpleCLI, SimpleGUI, and the WorkerEngine already. All these classes want to interpret the command line.

I want to propose a standard for the command line interface so that we can easily and consistently dispatch to the proper subsystem.

The basic structure would become:

    alloy [base-option]+ <sub> [sub-option]+

The base-option would be able to set all the current preferences like solver, fonts, sizes, debug, logging, etc. The sub options would be specific for any of the sub modules.

For example,

  alloy -d gui                       # start the GUI in debug mode
  alloy --fontsize 16 lsp       # start the language server with 16pixel font
  alloy worker                      # start the worker
  alloy version                     # show the version
  alloy --solver minisat shell 

This will be slightly different from the old command lines. Does anybody think this will be a problem?

I didn’t know there was an old command line. Can someone tell me how to access it?
Would the CLI allow you to issue commands like “alloy run p for 10” and “alloy check a for 5 X” — as you would from within an Alloy model? That would be very useful.

Well, if you did not find it so far you can wait until we get a chance to clean it up :slight_smile:

I didn’t even know we had a command line.