Comments (11)
Easy. Just put the attributes on the type and all branches will inherit them.
from argu.
Ok, that works for the EqualsAssignment but not for getting rid of the --
. Right?
from argu.
Right.
from argu.
Probably what you need is an attribute that changes the CLI parameter name generation rules, for example DropCLIDashPrefixAttribute
or CustomCLIPrefixAttribute
.
from argu.
Yes, something like that.
from argu.
Up for discussion; opine freely ;)
from argu.
Also, this https://github.com/nessos/UnionArgParser/blob/master/src/UnionArgParser/ArgInfo.fs#L278 needs a true passed in for EqualsAssignmentAttribute on the type to work.
from argu.
Sorry, not sure I got that.
from argu.
I want to put EqualsAssignmentAttribute on the type, to apply it to all union cases. This currently does not work because the optional argument to GetAttrs in that line of code needs to be true - at least. Haven't had time to check if that really fixes it.
from argu.
Ok, I see it now. Fixed.
from argu.
I pushed a nuget package containing the feature.
from argu.
Related Issues (20)
- Case insensitivity of command options names HOT 1
- Seems like Argu not works on Fsi 11.0.0.0 for F# 5.0 (VS preview 16.8.0 Preview 3.2) HOT 2
- Consistent handling of numeric decimal separators using invariant culture
- Support union names without underscores HOT 2
- Integration with IConfiguration HOT 9
- feat: subcommand specific help header? HOT 3
- Subcommands without options HOT 4
- Feature idea - Helper function for subcommand field
- Release? HOT 2
- Query: Command line argument character (I.E. "--", "/") HOT 2
- Question: attribute or possibility to customize casing of commands? HOT 2
- How to add an optional boolean flag? HOT 5
- appsetting.json and NET5 HOT 9
- `-h` short option for `--help` HOT 2
- Empty usage prevents line breaks between options HOT 1
- Expose ArguParseException or similar for use within apps HOT 2
- [Query] Is .net7 support for trimmed binaries planned? HOT 3
- ChatGpt4 proposed Argu, but as an ocaml developer, it is really hard to understand the ParseResults<Args> part HOT 3
- Make a main command optional in subcommand
- Have a positional argument as optional with main command HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from argu.