bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Request: Emacs configuration file locations needs upgrade


From: Jari Aalto+mail.emacs
Subject: Request: Emacs configuration file locations needs upgrade
Date: 02 Jan 2001 04:35:32 +0200
User-agent: Gnus/5.090001 (Oort Gnus v0.01) Emacs/20.6 (i386-*-windows98.1998)

    I have posted this few years back, but got no response, so I''m
    requesting this feature again.
    
    In current Emacs lisp package system, every and each package 
    defines where it stores the location of its configuration files.
    The names of he configuration files are also chosen as the
    packages see it fit.

    The most common location for configuration files seems to be root 
    directory, under $HOME and with name dot-something, like

        ~/.emacs.bmk        bookmark.el
        ~/.emacs-bkmrks     bookmark.el
        ~/.completion       completion.el
        ~/.saves.*          startup.el
        ~/.viper            viper.el
        ~/.mosaicpid        browse-url.el
        ~/.grail            browse-url.el
        ~/.emacs-flc        fast-lock.el
        ~/.ispell_lisp      ispell.el
        ~/.newsrc           paths.el
        ~/.ph-options       ph.el
        ~/.bdfcache.el      ps-bdf.el
        ~/.emacs_args       resume.el
        ~/.emacs-places     saveplace.el
        ~/.shadows          shadowfiles.el
        ~/.strokes          strokes.el
        ~/.emacs_<SHELL>    dirtrack.el
        ~/.emacs-octave     octave-inf
        ~/.authinfo         Gnus
        ~/.gnus             Gnus
    
        ..
        and so on

I find lot of problems with this:

    #1 There is not sense in these file names.

        The files should always start with word "emacs" is they 
        are meant to use in Emacs lisp packages. Unless the file
        is shared with other programs like ~/.mailrc naturally.


    #2  It should be possible to specify location of these files

        There is no centralised way to put all Emacs configuration files
        into seprate directory like ~/elisp/conf and keep it under
        version control

    #3  It should be possible to specify use PREFIX for all
        these file names

        Instead of using dot-files, user may prefer to have just simple
        word "emacs-PACKAGE" in front of all relevant configuation files.

    #4  It should be possible to specify use POSTFIX for all
        these file names

        User's may want to have all files compressed by default or like
        the de facto extension .el for all lisp files.

What to do instead:

    Emacs should offer a function interface to the configuration
    files, which all package developers use. The functions
    would generate the default name and the location for the filename.
    User configurable variables would control the directory, PREFIX
    and POSTFIX for the files.

        (defvar config-file-directory "~/")
        (defvar config-file-prefix    "emacs-")
        (defvar config-file-postfix   ".el") 

        .. functions to deal with configuration files. Then the
        .. package writes uses:        

        (config-file-name "gnus" "newsrc")
                          |
                          Package who requests config file

        (config-file-list "gnus")
        
        --> Would return all configuration files registered
            for package Gnus. (cached names from calls to
            config-file-list)


        (config-file-name "gnus" "authinfo")


        --> ~/emacs-gnus-newsrc
        --> ~/emacs-gnus-authinfo


    It would then be easy for users to change the location and other
    preferences as needed globally to Emacs:

        (require 'jka-compr)

        (defvar config-file-directory "~/elisp/config")
        (defvar config-file-prefix    "emacs-")
        (defvar config-file-postfix   ".el.gz") 
        

        (config-file-name "gnus" "newsrc")
        (config-file-name "gnus" "authinfo")


        --> ~/elisp/config/emacs-gnus-newsrc
        --> ~/elisp/config//emacs-gnus-authinfo

    And have the files out of the ROOT directory, tracked by CVS/RCS other
    version control software

    The current situation is very difficult, and annoying because
    there is no discipline, and you have to look every packages'
    way of doing the configuration. 

    Jari



reply via email to

[Prev in Thread] Current Thread [Next in Thread]