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

Command line: Invalid commands should produce syntax error #155

Closed
kanurag94 opened this issue May 8, 2020 · 3 comments
Closed

Command line: Invalid commands should produce syntax error #155

kanurag94 opened this issue May 8, 2020 · 3 comments

Comments

@kanurag94
Copy link
Member

kanurag94 commented May 8, 2020

Currently command line functionality in xaos is difficult to use, mostly since it doesn't produce any warning/error on use of wrong syntax. We should be able to start checking command syntax and produce warnings and help messages accordingly.

I am using a Ubuntu 20.04 install with Qt build from source

@kovzol kovzol changed the title Command line : Invalid commands should produce syntax error Command line: Invalid commands should produce syntax error May 9, 2020
@kovzol
Copy link
Contributor

kovzol commented May 18, 2020

I assume you mean the command line interface and also the commands that are available in the Action > Command... menu.

  1. The command line interface already exists if you enter a command that cannot be recognized. But immediately after then the whole help is shown (that can be invoked by xaos -help). I think this is not very convenient, so maybe XaoS should not show more message than like this:
h:unknown function, please enter "xaos -help" to learn more on command line options

Note that currently the first part ("h: unknown function") is working, and printed to stderr. I think this is acceptable. Also, maybe we want to avoid printing other types of debug information. I am unsure if they are only available in the DEBUG build. For a DEBUG build this is OK.
2. I confirm that there should be some error message given if the command given in via the Action > Command... menu. The error message could be somewhat the same as shown via the command line interface. So, they should be handled in a somewhat unified way.

@kovzol kovzol added the bug label May 18, 2020
@kanurag94
Copy link
Member Author

I am unsure if they are only available in the DEBUG build

Yes they are only available in DEBUG build.
I have done changes for 1 - c2bd042

I will try to work on 2 in next few days.

@kovzol
Copy link
Contributor

kovzol commented May 19, 2020

Very good, thanks!

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

No branches or pull requests

2 participants