Comments (9)
@thetechnick Can you have a look?
from cli.
How to reproduce:
- use windows 10 with git bash
- ssh to a linux machine with installed zsh and golang-1.9
- install hcloud lib via
go get
and configure the autocompletion for zsh - create and use a hcloud context
- try to create a new server
hcloud server create --name xyz.xyz --ssh-key
now try to autocomplete the sshkey
Result:
_handle_flag:27: bad math expression: illegal character: ^[
from cli.
FWIW - this seems to be of no issue on macOS 10.13.3 with zsh 5.4.2 (x86_64-apple-darwin17.3.0)
/ "Oh-My-Zsh".
from cli.
I can reproduce this on Linux with zsh 5.3.1. The culprit seem to be these lines:
# keep flag value with flagname as flaghash
# flaghash variable is an associative array which is only supported in bash > 3.
if [[ -z "${BASH_VERSION}" || "${BASH_VERSINFO[0]}" -gt 3 ]]; then
if [ -n "${flagvalue}" ] ; then
flaghash[${flagname}]=${flagvalue}
elif [ -n "${words[ $((c+1)) ]}" ] ; then
flaghash[${flagname}]=${words[ $((c+1)) ]}
else
flaghash[${flagname}]="true" # pad "true" for bool flag
fi
fi
It doesn't seem like the flaghash
is used anywhere. It is set here but never read. I just removed those lines and the error went away.
from cli.
Ups. What did just happen. Why does it say "joto unassigned thetechnick a minute ago"? I didn't do anything like that and don't think I can even do that...
from cli.
This issue has been marked as stale because it has not had recent activity. The bot will close the issue if no further action occurs.
from cli.
Does that mean that this comment will "unstale" it?
from cli.
If it helps, I have a similar (the same?) issue directly on Linux with zsh 5.8 (x86_64-debian-linux-gnu)
I'm using the workaround for antigen described in #239 .
Error message when pressing tab after:
hcloud server create --image debian-10 --ssh-key
is
hcloud server create --image debian-10 --ssh-key __hcloud_handle_flag:31: bad math expression: illegal character: ^[
from cli.
Closed with #239
from cli.
Related Issues (20)
- Introspection: Print associated project HOT 3
- rdns settings not propagated if set using hcloud-cli HOT 1
- mitchellh/gon is unmaintained, consider moving to bearer/gon HOT 2
- FR: move snapshots HOT 1
- Make firewall describe JSON output compatible with firewall create or replace-rules rules-file expected input HOT 1
- firewall --rules-file does not accept firewall/get output HOT 2
- Introduce delete subcommand to `hcloud all` HOT 3
- Add the project name to the hcloud cmd "all" HOT 2
- Improve error message when required argument is not set HOT 2
- Primary IP assignee ID is null in API response but 0 in JSON output HOT 1
- Update Loadbalancer SSL Certificate HOT 4
- Improve commands help messages
- Please enable yaml output for server reset-password HOT 6
- Adding firewall rule fails with version v1.43.0 HOT 3
- enabling rescue mode using CLI HOT 1
- alias lb for load-balancer HOT 2
- hcloud server ssh <server> [command] is broken HOT 1
- `--port` option is missing from usage of the `firewall {add,delete}-rule` commands HOT 2
- Allow to set health check options in `hcloud load-balancer add-service`
- Example firewall rules json doesn't work HOT 1
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 cli.