libretro / libretro/RetroArch

Allow multiple --appendconfig options in command line

Open
#17,221 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
14.1k
Forks
2.2k
Avg merge
7h 35m
Merged PRs (30d)
51

Description

Description

If --appendconfig is used multiple times, only the last one takes effect; others are silently ignored.

This is fine if you're just invoking it directly; separate the configs you want with | and it works. But if you have something like this:

$ alias retroarch='retroarch --appendconfig=myconfig.cfg'
$ retroarch --appendconfig=myotherconfig.cfg

Only myotherconfig.cfg is loaded. The problem is obvious in that example, but it becomes much less so if, say, your distro ships a retroarch wrapper script that uses --appendconfig to apply distro-specific defaults, or if you're managing a family games library and want to use --appendconfig to make sure that shared save files and whatnot get stored in the right places.

Expected behavior

Ideally, all config files specified in any --appendconfig are loaded, in the order in which they appear. Failing that, an obvious error message saying that --appendconfig is only allowed once; that would at least have saved me a solid hour of debugging.

Actual behavior

retroarch appears to run without problems, but all uses of --appendconfig except the first are silently ignored.

Version/Commit

1.18.0.

Environment information
  • OS: nixos

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate RetroArch's command-line parsing for --appendconfig and first reproduce the issue with two options. Verify that all specified config files are loaded in appearance order and that earlier options are no longer silently ignored.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.