Feature request: allow sorting to be configured globally
I am a heavy user of the hcloud-cli. However, I really don't like the default sorting by server-id, and would prefer sorting by age (see #417 where I request adding a computed "age" column) or name.
Currently, I always type hcloud server list -s name to sort by name.
since the -s flag is part of the list subcommand and not the hcloud base command, I cannot simply alias hcloud-"hcloud -s name" in my shell to default the sorting to "by name".
I think this could be implemented as part of the configuration toml.
I would expect the following behavior:
| config file | flag | result |
|---|---|---|
| not-set | not-set | sort by id (default) |
| not-set | set | sort by flag value |
| set | not-set | sort by config value |
| set | set | sort by flag value |
I would also volunteer to implement this myself and submit a PR, but I wanted to gauge interest first, before putting in some work and having the PR rejected.
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.
@apricote bump
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.
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.
Feature was implemented in #795 - see my comment here: https://github.com/hetznercloud/cli/pull/421#issuecomment-2220279864 Since the feature is now implemented I will close this issue as completed. Thanks for your suggestion!