-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
BUILD(shared): build CLI11 into shared target #6243
base: master
Are you sure you want to change the base?
Conversation
Just started working on this. There are two questions I already have:
|
Probably interesting for this as well: CLI11 does not permit single args that have more than one character |
Also I am having difficulties getting |
It looks like neither flags nor descriptions are currently translated. I would say translating the flags itself is not something we want. Translating the descriptions would make sense, but it would require to wrap all descriptions into
I would say yes, except when you encounter something that could potentially break servers or their automation. In that case we should look at that again in particular. But, let's also have input from @Krzmbrzl for that |
I'd say most of these are breaking since single dash is forbidden for multicharacter options. And on server side, most of the options are. |
b085481
to
275f275
Compare
Flags should definitely not be translated. Their description don't need to be translated either imo - though this is open for discussion. Maybe omitting translation for now and then looking into that once requested would be an OK approach?
Yes - I think CLI11 doesn't even support non standard flags 👀
That might very well be the case - on Windows Mumble essentially never gets started from a command line.
The description is currently translated - which is a massive PITA if you ask me as the help text is translated in its entirety. |
Thank you, yeah, this confirms what I figured. So this whole MR will basically be a breaking change for anyone using the CLI in automation. Unless we add some kind of mapping layer that will sort of “up cast” the old parameters to the new system. Is that something we should go for to smooth out the transition or do we just roll with the break, since the jump from 1.4 to 1.5 would be a somewhat good opportunity to refactor / re-think the CLI. |
I would roll with the break as I don't think maintaining support for non-standard flags makes sense for the future, so eventually we'll have to make a break (or keep the mess of manual option handling that we currently have) 🤔
This PR won't be part of 1.5 anymore, but 1.6 will do equally fine :) |
19349a6
to
12dd794
Compare
3rdparty/CLI11
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should stick to tagged releases of CLI11 - the latest of these would be https://github.com/CLIUtils/CLI11/releases/tag/v2.3.2 as of this writing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Submodule should be put at head of tag now
src/CMakeLists.txt
Outdated
@@ -234,6 +234,8 @@ else() | |||
endif() | |||
endif() | |||
|
|||
target_link_libraries(shared PUBLIC CLI11::CLI11) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the dependency to the client and the server explicitly - the shared
target really should only have dependencies for the shared code and not dependencies that both components happen to create in their own code respectively.
src/murmur/main.cpp
Outdated
#include <boost/logic/tribool.hpp> | ||
#include <boost/optional/optional_io.hpp> | ||
#include <boost/tuple/tuple_io.hpp> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If possible, I would like to stick to std-types. If that would make things a lot more complicated, stick to using Boost though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried using std types and experienced some issues since they are not always available depending on which target system is built. Yeah boost is quite expensive to compile, I agree - not using them would be better. I'll try to see if I can remove them after things work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
std-types should always present. You only have to check to stick to std types included in up to cpp14 as that's the current standard we are using.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sadly, std::optional is not avalable in cpp14 afaik. I'll try to find another solution.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but an empty string will do equally fine for indicating that the INI file has not been specified :)
225e3f4
to
74a1803
Compare
What is the state on this? |
Hi — sorry, I kinda forgot about this. |
74a1803
to
5b718a0
Compare
Nice :) |
My time is sadly quite limited at the moment, and I don't know for sure when I could get around to it. I can try to look at it again in a few weeks (motivation is there), but no idea when you want this to be done :D |
Since this will not make it as a backport in 1.5.x, there is a lot of time left until we need this :D So you can take your time. I just wanted to make sure this was not entirely abandoned |
Implements #6063
Checks