20
849
Fork
You've already forked fuzzel
83

config: add support for file-based configuration #122

Manually merged
dnkl merged 23 commits from config into master 2022年04月22日 19:58:52 +02:00
Owner
Copy link

This adds the boiler plate code necessary to handle file-based configurations:

  • Lookup fuzzel.ini in XDG_CONFIG_HOME or XDG_CONFIG_DIRS
  • Recognize valid option names
  • Command line arguments override both defaults, and options set in fuzzel.ini
  • Minor updates to existing API, only what was necessary to get things to compile

(削除) NOTE: does not yet work - values aren't (yet) loaded from the conf file. See TODO below. (削除ここまで)

This should now be ready for testing. See the bundled fuzzel.ini for available options.

TODO:

  • Clean up APIs. Most objects should just take a pointer to a conf struct, instead of all their options as individual arguments
  • Actually parse option values
  • Documentation
  • Changelog
  • Add --config=PATH command line option

Closes #3

This adds the boiler plate code necessary to handle file-based configurations: * Lookup `fuzzel.ini` in `XDG_CONFIG_HOME` or `XDG_CONFIG_DIRS` * Recognize valid option names * Command line arguments override both defaults, and options set in `fuzzel.ini` * Minor updates to existing API, only what was necessary to get things to compile ~~**NOTE**: does not yet work - values aren't (yet) loaded from the conf file. See TODO below.~~ This should now be ready for testing. See the bundled `fuzzel.ini` for available options. **TODO**: * [x] Clean up APIs. Most objects should just take a pointer to a conf struct, instead of all their options as individual arguments * [x] Actually parse option **values** * [x] Documentation * [x] Changelog * [x] Add `--config=PATH` command line option Closes #3
dnkl force-pushed config from 640e73bc20
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
to 5c529f851e
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
2022年04月12日 14:20:51 +02:00
Compare
dnkl force-pushed config from 1067a64c25
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
to c2baa4ddf2
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
2022年04月18日 18:33:10 +02:00
Compare
dnkl force-pushed config from 6c86cb6c1c
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
to f294f6c5f5
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
2022年04月19日 17:23:36 +02:00
Compare
dnkl changed title from (削除) WIP: config: add support for file-based configuration (削除ここまで) to config: add support for file-based configuration 2022年04月19日 20:40:17 +02:00
dnkl force-pushed config from 0c2428670d
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
to 2d30a7de65
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
2022年04月20日 18:21:37 +02:00
Compare
dnkl manually merged commit 9ce5e729dd into master 2022年04月22日 19:58:52 +02:00
Collaborator
Copy link

This is a great feature, thanks.

The one part of my wrapper script that doesn't translate is: --terminal "$TERMINAL -e".

This could be addressed by setting terminal to default to "$TERMINAL -e if $TERMINAL is set".

This is a great feature, thanks. The one part of my wrapper script that doesn't translate is: `--terminal "$TERMINAL -e"`. This could be addressed by setting terminal to default to "`$TERMINAL -e` if $TERMINAL is set".
Author
Owner
Copy link

This could be addressed by setting terminal to default to "$TERMINAL -e if $TERMINAL is set".

Like this: #156 ?

> This could be addressed by setting terminal to default to "$TERMINAL -e if $TERMINAL is set". Like this: https://codeberg.org/dnkl/fuzzel/pulls/156 ?
Sign in to join this conversation.
No reviewers
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
dnkl/fuzzel!122
Reference in a new issue
dnkl/fuzzel
No description provided.
Delete branch "config"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?