mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-07 13:38:49 +00:00
A previous refactoring of the CLI scripts migrated all of the CLI tools to shell to a common script, elasticsearch-cli. This approach is fine in Bash where it is easy to tear arguments apart but it doesn't work so well on Windows where quoting is insane. To avoid having to tear the arguments apart to separate the first argument to elasticsearch-cli from the remaining arguments, we instead choose a strategy where we can avoid tearing the arguments apart. To do this, we will instead pass the main class by an environment variable and then we can pass the arguments straight through. This will let us avoid awful quoting issues on Windows. This is the Windows side of that effort and the Bash side was in a previous commit.