Comments (6)
Do you have an example @navidshaikh?
I asked because if I understood this request correctly, you would have the text moved to a different file or location from the command definition and have a constant in it's place in the definition.
While an interesting suggestion it would result in less readable code --- need to read text file or constant file and code for command.
I kind of like having the command into one place. I can see moving the runE(...)
function out into it's own function or even file but the command definition should include all that is needed IMO.
from client.
I asked because if I understood this request correctly, you would have the text moved to a different file or location from the command definition and have a constant in it's place in the definition.
That's correct, but in an organized manner, not like a text-file as such.
This came after suggestion from @cppforlife during a PR review.
IMO, keeping the constants part separate from definitions helps being consistent in the help/example language/grammar used across commands.
I do not have an example right now, but I plan to work on this once we have the v0.1 issues sorted.
from client.
IMO, keeping the constants part separate from definitions helps being consistent in the help/example language/grammar used across commands.
I think we should avoid separating text to the code. Separating is premature optimization IMO.
from client.
This came after suggestion from @cppforlife during a PR review.
curious which suggestion?
from client.
curious which suggestion?
@cppforlife It's for aliases, here.
from client.
Let's keep text describing flags with the flags, and command usage with the command for now. It's more readable that way.
from client.
Related Issues (20)
- Update plugin development docs HOT 5
- Can not get my broker through `kn broker list` HOT 6
- [48h Knative] KServe plugin HOT 4
- Align GVK format accepted by `--channel` flag HOT 12
- Flaky E2E test: e2e/TestDomain - create domain with TLS HOT 9
- Wrong version for kn create kafka channel HOT 7
- Add integration tests for all command usage examples in the binary HOT 6
- [48h Knative] Annotation and Label profiles HOT 1
- [48h Knative] Color output HOT 3
- [48h Knative] UX Evaluation HOT 10
- [48h Knative] Kamelet Sinks HOT 2
- [48h Knative] Command Usage Example Integration Testing POC HOT 4
- [48h Knative] Improved Logging HOT 7
- [48h Knative] Good first issues HOT 3
- Cmd `kn service wait` doesn't end on ready ksvc as expected
- CLI: `--user` option does not work as expected
- Add missing completion support for fish and PowerShell shells
- Error: fork/exec /usr/local/bin/kn-func: exec format error HOT 1
- Proposal: Fold back in client-pkg to Go submodule HOT 11
- kn service export doesn't work with traffic splits HOT 2
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 client.