Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: bottles-cli run ARGS parsing(?) error #2305

Closed
psydvl opened this issue Nov 20, 2022 · 1 comment · Fixed by #2342
Closed

[Bug]: bottles-cli run ARGS parsing(?) error #2305

psydvl opened this issue Nov 20, 2022 · 1 comment · Fixed by #2342
Assignees

Comments

@psydvl
Copy link
Contributor

psydvl commented Nov 20, 2022

Describe the bug

You cannot send args started with - to bottles-cli

To Reproduce

Run any exe in any bottle with args started with -

$ flatpak run --command=bottles-cli com.usebottles.bottles -j run -b $BOTTLE -e ./x.exe --args "-hello"
usage: bottles-cli run [-h] -b BOTTLE [-e EXECUTABLE] [-a ARGS] [-p PROGRAM]
bottles-cli run: error: argument -a/--args: expected one argument

$ flatpak run --command=bottles-cli com.usebottles.bottles -j run -b $BOTTLE -e ./x.exe --args "hello"
15:10:56 (INFO) Forcing offline mode
gamemodeauto:
esync: up and running.
002c:err:wineboot:process_run_key Error running cmd L"C:\\windows\\system32\\winemenubuilder.exe -r" (2).
2022/11/20 15:11:01 Running with: [Z:\home\nixi\work\Projects\Playground\019\x.exe hello]

x.exe Details

Simple golang program built with GOOS=windows go build .

package main

import (
	"log"
	"os"
)

func main() {
	log.Println("Running with:", os.Args)
}

Package

Flatpak from Flathub

Distribution

openSUSE Tumbleweed

Troubleshooting Logs

Version: 2022.11.14
Display:
    X.org: true
    X.org (port): :0
    Wayland: true
Graphics:
    vendors:
        intel:
            vendor: intel
            envs:
                DRI_PRIME: '1'
            icd: /usr/lib/x86_64-linux-gnu/GL/vulkan/icd.d/intel_icd.x86_64.json:/usr/lib/i386-linux-gnu/GL/vulkan/icd.d/intel_icd.i686.json
    prime:
        integrated: null
        discrete: null
Kernel:
    Type: Linux
    Version: 6.0.7-1-default
Distro:
    Name: GNOME
    Version: '43'
Disk:
    Total: 4024991744
    Free: 4024852480
RAM:
    MemTotal: "8,0\_GB"
    MemAvailable: "1,9\_GB"
Bottles_envs: null

Display Protocol

Wayland

Display Backend used by Bottles

Wayland

Additional context

No response

@psydvl
Copy link
Contributor Author

psydvl commented Dec 2, 2022

Can be temporary solved escaping dash \-
For example:

$ flatpak run --command=bottles-cli com.usebottles.bottles -j run -b $BOTTLE -e ./x.exe --args "\-\-hello"
2022/12/02 21:52:43 Running with: [Z:\home\nixi\work\Projects\Playground\019\x.exe --hello]

But I expect this not to be required, because of quotes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants