89luca89 / 89luca89/distrobox

[compatibility] v2 `distrobox enter` command lacks handling for the v1 `-e/--` option

Ouverte
#2,127 7 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Go
Étoiles
13k
Forks
541
Merge moyen
20 h 47 min
PR mergées (30 j)
4

Description

because of #2084, I downloaded a v2 binary.

today, I find out the `enter` subcommand parses the command line differently from v1, and this breaks my vscode extension, which makes heavy use of `distrobox enter` to execute commands in guest containers.

here's one example of the problems I encountered today:

```sh
nerditation@localhost:~> # v1
nerditation@localhost:~> distrobox-enter --name tumbleweed -- bash -c "ldd --version 2>&1"
ldd (GNU libc) 2.42
Copyright (C) 2024 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.
nerditation@localhost:~> # v2
nerditation@localhost:~> distrobox enter --name tumbleweed -- bash -c "ldd --version 2>&1"
ldd: missing file arguments
Try `ldd --help' for more information.
```

if I remove the `--`, v2 works, but v1 breaks.

I understand this could be a deliberate design change, not a bug. I'm ok to make my extension behave differently based on the version of `distrobox` if necessary.

can someone please clarify what's the official policy for backward compatibility in terms of command line flags?

btw, I downloaded the binary from the `2.0.0-rc.1` artifacts on the github release page, but the `--version` command line option prints `1.0.0`, which is incorrect apparently.

thanks.

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.