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

Allow user to specify alternate config file with --config flag. #176

Merged
merged 3 commits into from
Feb 23, 2025

Conversation

bit101
Copy link
Contributor

@bit101 bit101 commented Jan 28, 2025

Use case:

Sometimes I want to use my laptop keyboard to control M8. Other times I want to use an external keypad I've set up to mimic a hardware M8. This allows me to have two different configs and choose which one to use when I run m8c.

./m8c - runs with the default config, config.ini

./m8c --config config-keypad.ini - runs the alternate config specified.

Notes:

  • The alternate confg(s) are expected to be in the same config path as the default one.
  • If a user specifies a config that does not exist, it will be created with a default config, which they can then edit.

@laamaa
Copy link
Owner

laamaa commented Feb 23, 2025

Looks useful, thanks! Would you mind editing the README.md too to document this flag?

@bit101
Copy link
Contributor Author

bit101 commented Feb 23, 2025

Sure! I also noticed a TODO comment in the code for something similar to this. I can remove that too.

@bit101
Copy link
Contributor Author

bit101 commented Feb 23, 2025

Updated readme and removed comment.

@laamaa laamaa merged commit cc4321d into laamaa:main Feb 23, 2025
5 checks passed
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 this pull request may close these issues.

2 participants