Ticket #1677 (new enhancement)
[METATICKET] Package-friendly configuration system (".d" support for rpm/deb based systems)
Reported by: | vlisivka | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | Future Releases |
Component: | mc-core | Version: | 4.7.0-pre3 |
Keywords: | Cc: | gavenkoa@… | |
Blocked By: | Blocking: | #1984, #2772, #2948, #3030 | |
Branch state: | no branch | Votes for changeset: |
Description (last modified by andrew_b) (diff)
Currently, mc requires to edit .ini files to add new plugin to MC VFS. After upgrade, all changes to these files will be lost.
The same problem is related to syntax highlighting files.
To solve that problem, ".d" pattern should be supported by MC configuration system. See example of .d-pattern implemented in C in attachment.
Attachments
Change History
Changed 15 years ago by vlisivka
- Attachment dot_dir_list.c added
comment:2 Changed 15 years ago by andrew_b
- Description modified (diff)
- Blocking 1909 removed
- Blocked By 1909 added
- Summary changed from Package-friendly configuration system (".d" support for rpm/deb based systems) to [METATICKET] Package-friendly configuration system (".d" support for rpm/deb based systems)
comment:5 Changed 13 years ago by andrew_b
- Branch state set to no branch
- Milestone changed from 4.7 to Future Releases
comment:9 Changed 10 years ago by gavenkoa
- Blocking 3030 added
(In #3030) Seems that include or source or import keyword help.
Another way - use /xxx.d/ directory and load files on name order (NN-xxxx patterns) see #1677. This look more promising.
But before do this it is necessary define read priority order or conflict resolution strategy (in documentation). See arguments in #3191.
comment:10 Changed 10 years ago by gavenkoa
- Blocking 1984, 2772, 2948 added
- Blocked By 1984, 2772 removed
I gather related to /xxx.d/NN-xxxx issues. Don't miss priority issues when user want to use defined classes (#2773) or have conflicting entries (#3191).
Main reason to implement this enhancement is to give users ability to redefine system preferences. They are mostly fine but require little tweaks. With /xxx.d/NN-xxxx and symlink like:
$ ln -s /etc/mc/mc.ext ~/.config/mc/mc.ext.d/50-systemwide $ ln -s /usr/share/mc/syntax/Syntax ~/.config/mc/syntax.d/50-systemwide $ ln -s /etc/mc/mcedit.menu ~/.config/mc/mcedit/menu.d/50-systemwide $ ln -s /etc/mc/mc.menu ~/.config/mc/50-systemwide
user automatically get config updates with MC update, no need to reintegrate tweaks.
I see /usr/lib/mc/ext.d/XXX.sh and /usr/lib/mc/extfs.d/XXX already present in MC distribution.
Example of .d-pattern support