Config-Model

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

      * generate doc in a reproducible way by using "sort keys". This should
        fix Debian problem with unreproducible build found on libconfig-model-dpkg-perl
        and libconfig-model-itself-perl
    * dist.ini: use free.fr address instead of cpan.org to avoid problems with
      automated release e-mail

2.065 2015-01-06

  Bug fixes:
    * Value: avoid undef warning when creating error message
    * Node: Must load override class to be able to use it...

  New (small) feature:
    * Value: warning or error message defined in a model can contain
	  a $_ to show the bad value to user

2.064 2014-12-04

  A small change for this release:
  
    * Version 2.062 added the possibility to override the Perl class
      implementing a configuration node by adding a class parameter in a
      place that is confusing. This release fix this bug: this optional
      override class is now declared at the top of a configuration class.

2.063 2014-11-28

  Bug fix release:
    * GenClassPod: use Exporter instead of Exporter::Lite.
    * adapted contrib/bash_completion for cme-old

2.062 2014-11-23

  Big change for this release:
    * cme command is no longer delivered with this distribution. cme
      is now delivered by App::Cme distribution.

  To help the transition, this distribution delivers cme-old. You can
  use this command until App::Cme is available in CPAN (next few days)
  or if you find bugs in the new cme command (which now uses App::Cmd).

  Other incompatible changes:
	* old config-edit command is now really gone
	* cme extensions are obsolete. Extension mechanism is now provided
	  by App::Cmd

  New feature:
    * The Perl class used to implement node, list and hash
	  configuration element can be overridden using a new 'class'
	  parameter. The Perl class passed to this parameter must inherit
	  Config::Model::Node, or Config::Model::HashId or Config::Model::ListId.

  Bug fixes:
    * Value: skip notification if migrate yields an empty value
    * Model: use logger for tracing legacy translation

2.061 2014-09-23

  Bug fix release:

  * ValueComputer: leave $@ and $! alone in formula.
    Also skip variables like '$ foo'

2.060 2014-08-19

  Bug fix release:

    * value.t: avoid smoke test failures
    * Avoid new perl 5.20 warning (Debian #758320)
    * Value: improved notify change message (computed vs preset vs default)
    * fix pod doc in cme (RT 97605, Debian #756433)
    * depends directly on YAML, not YAML::Any which will be deprecated

2.059 2014-06-29

  New features:

    * cme:
      + added shell command as a shortcut to 'cme edit -ui shell'.
	    E.g 'cme shell ssh' to edit ssh_config through a shell like UI
      + add :@ and :.sort sub command for ordered hash.
        E.g.: "cme modify  dpkg-control ~~ 'binary:~/.*/ Depends:.sort' -save"
        or "cme modify dpkg-copyright ~~ 'Files:.sort' -save "
    * Config::Model::Value: added warn_if parameter

  Bug fixes:

    * cme shell mode:
      * fix or add completion for several commands
      * added shell style pattern match to ll and ls command (e.g 'ls foo*')
    * remove version req from use YAML::Any 0.303 (resolve issues with
      Debian FTBS)
    * Value: fix crash when default value raises a warning and code fix
      returns undef.

2.058 2014-06-19

    Bug fix release

    * cme: modify cryptic user message about "Fixing stuff"
    * Value: tweak migrate_value to always return something, even undef.
      This fixes 'cme check dpkg-copyright' crash (thanks gregoa)
    * Loader: fix pod doc about list operators
    * AnyThing: avoid undef warning that breaks test on freebsd perl 5.10.1

2.057 2014-06-12

  New features:

    * Config::Model: initialise log4perl during construction
    * Value: added file and dir value type. A warning is issued when file
      or dir is not found.

  Other bug fixes:

    * Shortens long index to limit the length of warning and error messages
    * Value: fix check done during apply_fixes...
    * ObjTreeScanner: tolerate deprecated experience parameter.

2.056 2014-05-18

Changes  view on Meta::CPAN

	Other Changes:
    * added bash_completion snippet associated to a model. This will be useful
 	  for dpkg-patch model
    * C::M::Lister: skip backup files when listing available applications
	* replace File::Slurp with Path::Tiny in yaml backend test and gen-class-pod
      (RT #95692). (which changes the dependencies)
    * replaced Path::Class with Path::Tiny dependency

2.055 2014-05-02

    This release removes all code related to asynchronous stores.  This code was
    buggy. Making this work correctly would require re-writing most of
    Config::Model.

    * Config::Model::Value:
      * added deprecation warning about callback parameter
      * C::M::Value: removed async code
    * perltidy run on all files
    * removed dependency on namepace::autoclean
    * Removed AnyEvent dependency

2.054 2014-04-01

  Bug fix release:
    * Loader Dumper: fix quote handling (Closes Debian 743097)
    * Loader: return 'ok' after dispatching an action (avoid undef warning
      during tests)
    * cme: -save options force a save even if no semantic change was done
    * ListId: sort may trigger notify_change is elements are actually
      moved around, so 'cme modify stuff list:.sort' will save the file
      as expected.

2.053 2014-03-25

   Bug fix release:
   * Loader: fix broken list leaf assignment (like 'list:4=foo')

2.052 2014-03-23

    This release provides new functionalities to 'cme modify stuff'
    and to the shell like interface ('cme edit -ui shell stuff). See
    Config::Model::Loader doc for details:

      + added remove by value on list and hash ( :-= and :-~ )
        (Closes Debian #741453)
	  + added lots of list and hash operator usable on 'cme modify stuff'.
        E.g. :.insort :.insert_before :.insert_at :.unshift  :.push :.sort
      + handle list/hash value substitution ( e.g. list:=~s/foo/bar/ )
      * warn when trying to remove a list element with a non numeric index
      * rationalize list and hash commands: list assignment is now
        list:=a,b,c instead of list=a,b,c

	Other changes:

    * Dumper: use new syntax when dumping a list of value (i.e. list:=a,b,c)
    * Instance: don't print change if old and new value are undef

2.051 2014-03-06

    * cme: fix command like "cme modify foo ~~ <load_instructions>"
    * ValueComputer: formula with eval no longer mess with $& and ${^MATCH}
      variables used in regexp

2.050 2014-02-27

	* Restore NAME section in Config::Model::Manual::* man pages

2.049 2014-02-26

    Bug fix and minor new feature release:
    * C::M::AnyThing: added has_warning fallback method (always return 0)
	  (RT 93329)
    * C::M::Anything: added clear_annotation method

2.048 2014-02-23

    The main changes of this release are the new features of cme
    command:

      * add possibility to override config file (for appli with
        allow_config_file_override) (part of Debian #739387) if config
        file override is '-', open STDIN to read and STDOUT to write.
        This way, cme can be used as a filter.
      * added -strict option so cme exits 1 when warnings are found
        (Closes Debian #736972)
      * added -save option to force save. Useful when just reformatting
        is desired
      * modify command can apply Perl substitution (s/foo/bar) to
        configuration values

    Other changes:

    * C::M::Loader:
      * changed hash selection =~ sub-command to :~
      + added =~ subcommand to apply Perl substitution to values
    * Config::Model: load EV at compile time (Debian #738975)
    * C::M::Value: limit the number of re-try when applying fix to
      avoid deep recursion errors
    * C::M::Node: force a save when reading a deprecated parameter (RT 92639)
    * C::M::Instance: use msg parameter when listing changes
    * C::M::AnyThing: added doc for notify_change

2.047 2014-01-25

    * Value: store a good value cancels the error stored in Instance
    * Term UI:
      * list unsaved changes and propose to save on exit or quit
      * fixed "save" command
      * added 'changes' command to list unsaved changes
      * allow also delete command on leaf element
      * added reset command to set a leaf element to undef
      * allow spaces around '=' and ':'
    * tweak cme-gen-class-pod so it can be run without cme (handy for tests)
    * Model generate_doc: write file if new doc is different from old
      (don't try to be smart with timestamps)

2.046 2013-12-15

    * cme:
      + added -create option to force creation of missing configuration
        file

Changes  view on Meta::CPAN

        + New model for lcdproc: 
          The model for lcdproc (LCDd) is generated from the template 
          LCDd.conf file provided by lcdproc project. This model can be 
          generated by running Dist::Zilla (when working from Mercurial) or
          by running Build.PL (when working from Config::Model Perl 
          distribution). 
          Note to packagers: LCDd conf files are 
          (c) 1999-2011 William Ferrell and others, GPL-2. 
          Consequently, all LCDd models files (generated from LCDd.conf) are 
          (c) 1999-2011, D Dumont, William Ferrell and others, GPL-2. 
          
    * Framework changes:
        * lib/Config/Model/Backend/IniFile.pm:
        - Do not write twice leaf comments
        - handle warped_node like nodes
        * lib/Config/Model/Loader.pm:
          Do not remove first and last escaped quotes
        * Build.PL:
            Check (and may be generate) pod doc at build time 
            (on top of release time)
        * lib/Config/Model.pm:
          Fix doc generator to test correctly for time stamp 
          before re-writing docs
        * lib/Config/Model/Backend/IniFile.pm:
          When check is 'no', discard data that belongs to unavailable
          elements

1.244 2011-05-16

    * Application changes:
        * Fstab model: Prevent wrong value in fs_passno and fs_freq with 
          bound mount point
        * Dpkg: Added doc for control Architecture. Fix pod doc in DpkgSyntax 
          backend
        * Debian/Dpkg/Meta.pl: applied Debian patch fix_perl_group_filter 
          (set group_filter of debian perl team to 'etch' instead of 'lenny')
        
    * Framework changes:
        * config-edit: added -search and -narrow-search options. This options
          enable search in tree element, values and tree documentation. 
        * config-edit: cleaned up option names (always accept '-' in place of '_')
        * Config/Model/AnyThing.pm: fix location string and fix grab function

1.243 2011-05-02

    * Application changes:
        * dpkg control: bumped standard version to 3.9.2
        * dpkg: fix spelling . Closes RT# 67783 and 67784. Thanks carnil
        * dpkg control license: tweaked grammar to accept commas in license
          fields. Closes Debian #624305. Thanks Niko Tyni.
        * Dpkg/Control/Source.pl : added XS-Python-Version ans X-Python-Version
          (first steo to solve Debian #624321)
        * Debian Dpkg Meta model: package filter is computed from group-filter
          OR private policy
          
    * Framework changes:
        * reworked warp registration mechanism (Changed inherited WarpedThing into
          delegation to Warper)
        * t/debian*.t: Put back Apt::Pkg test to avoid smoke test failure
        * ValueComputer: Fixed bug to allow temporary variables and $_ in eval'ed 
          formulas

1.242 2011-04-07

    * Application changes:
        * dpkg control: added Build-Conflicts field
        * dpkg: Added model for debian/source/options and debian/clean files

    * Framework changes:
       * Value: don't perform value check when fetching standard or default value
       * Backend/Plainfile: now support list element in the form of multi line file.
         Each line of the file is a value of the list.
       * t/fuse_ui.t: skip test if lsmod cannot be used (e.g. Mandriva)
       * t/debian*.t: skip test when /etc/debian_version is not found

1.241 2011-04-07
    
    * Framework changes:
       * Build depend on Test::Differences
       * Load and grab: fix to accept '-' in element names 
       * Model.pm: Added value help and summary in generated documentation
       * DumpAsData: skip hash keys containing undef values

1.240 2011-04-05
    
    * Framework changes:
        * Most *.pm: replaced 'no Moose' by 'no Any::Moose' 
        
1.238 2011-04-05
    
    * Framework changes:
        * Build.PL: removed dead code that cause downstream pacaking problems.
        * Model.pm: fix cosmetic issue with doc generation.
        
1.237 2011-04-04
    
    * Framework changes:
        * added MouseX::NativeTraits dependency (fix RT #67196)
        * config-edit: fixed typo (fix RT #66403)
        * Value, Node, AnyId: use dclone to backup constructor parameters
        * Model: Correctly write author and copyright in doc (i.e not as ARRAY0x0...)
        * Yaml backend: fill full_dump option (did not work when set to 0)
    * Application changes:
        * dpkg control dependency: 
            - Dependency filtering mechanism uses source package name to find
              filter value in Meta. This makes more sense than using binary package
              name
              
1.236 2011-04-01
    
    * Application changes:
        * dpkg control dependency: 
          - Dependency filtering mechanism now use dpkg meta 
            package_dependency_filter value (i.e. a user parameter).
            Debian_perl package will be filtered on lenny by default
            Filter mechanism can be overriden in a package by package basis
            See Debian::Dpkg::Meta config class for details. 
          - Warn if a package is unknown.
          - Accepts version specified with dpkg variables.
        * dpkg control and copyright: warn if dh-make-perl boilerplate is found
        * dpkg control: added Package-Type parameter (Peter Pentchev)

Changes  view on Meta::CPAN

        * config-edit: Force to load all sub-models (i.e. control, copyright) of
        a top-model (err.. dpkg) when run with option -ui none

1.234 2011-02-21
    
    * factor out comment extraction: code that retrieve comments and tie it to 
      actual config data is generic. Now this is handled by 
      C::M::B::Any::associates_comments_with_data
    * factored out comment writing in C::M::B::Any::write_global_comments
      and C::M::B::Any::write_data_and_comments
    * Fix bad handling of leaf type Ini backend (Thanks Krzysztof for the notice)
    

1.233 2011-02-11
    
    * Application changes:
        * dpkg control source model: Added DM-Upload-Allowed and all Vcs-* tags defined 
        in Debian reference guide (Thanks Peter Pentchev for the patch)
          (Fix RT 65575)
        
    * Framework changes:
        * Backend Ini file: Fixed comment handling
        * All modules: Improved synopsis. You can now save them in a file and 
          have a working program
        * Remove crappy handling of comments in load_data methods. 
        * DumpAsData: Write annotations as pod in method dump_annotations_as_pod
        * Anything: load_pod_annotation load annotations from a pod document 
        * Instance write back: now correctly call all write_back when several
          nodes in model needs to be called back

1.232 2011-01-30

    * Added missing Text::Autoformat dependency

1.231 2011-01-30

    * Application changes:
        * Debian::Dependency: reworked to reduce calls to madison. Report available
          versions when unnessary version issue is found.). Source is optional.
        * dpkg control model: added forgotten Enhances and Pre-Depends. Added warnings for
          too long lines in Description (plus fixes based on Text::Autoformat). Added 
          Synopsis element to better tune warnings and fixes
    * Framework changes:
        * FuseUI: Fix undef warning. Ensure that files finish with "\n". 
          Fix bug where value 0 was shown as an empty file.
        * Added PlainFile backend (each config parameter is stored in its own file. useful for
        some dpkg data)

1.230 2011-01-21

    * Application changes:
        * Debian::Dependency: don't check debhelper
        * Debian::Copyright: removed license keyword warnings. (fix Debian #610242), lots
          of other bug fixes (including debian bug #609889 #610231)

    * Framework changes:
        * AnyId: added migrate_keys_from to migrate list or hash content 
          during updgrades.
        * ObjTreeScanner: Added node_dispatch_cb parameter to setup callback
          dedicated to specific configuration classes.
        * ValueComputer: added 'undef_is' to allow undef value in formulas. Useful for
          complex migration scenario where migration can come from several alternative parmeters.
        * FuseUI: Fix bug that disabled write in a boolean value
        
1.229 2011-01-10

        * config-edit: added -apply-fixes option
        * Value: can specify wider replace instruction by using regexp as
          key of the 'replace' parameter
        * Debian::Dpkg::Copyright: updtead to new CANDIDATE DEP-5
          specification. Copyright files written for older
          specifications are migrated to the new specification. This
          should save a lot of typing from my fellow Debian packagers.
          Feedbacks are welcome.


1.228 2011-01-09

        * Specifically require DB_File as this module is not available by default on Ubuntu
        * Skip Debian dependency tests when AptPkg::Config is not available (non Debian systems)

1.227 2011-01-07

        * Model.pm: deprecated name_match parameter in accept
          specification. The regexp should now be specified as a
          key of a hash. 
        * Value.pm: warn_if_match and warn_unless_match can speficy instructions to "fix"
          the value.
        * WizardHelper: can be set to stop on items with warnings. Added bail_out method to bail
          out cleanly from wizard helper.
        * model Debian::Dpkg::Control::Binary: Depends element specifies 
          Perl cargo class Config::Model::Debian::Dependency (see below)
        * Likewise for Debian::Dpkg::Control::Source Build-Depends*
        * Debian::Dependency: new class derived from Value to provide checks specific
          to Debian dependencies (syntax, whether a "(>= vers)" is necessary or not, ... )
        * New dependency: LWP::Simple


1.226 2010-12-08

        * config-edit: mount fuse file system in the background. (like sshfs)
        * FuseUI: Improved doc
        * C::M::Backend::Fstab: improved doc

1.225 2010-12-06

        * Build.PL: build depends on Test::Command 0.08 to avoid smoke test problems

1.224 2010-12-06

        * Node AnyId Value: get() now accepts check parameter, autoadd parameter 
        * Node AnyId: added children method
        * Added Fuse interface: configuration tree is mapped to a virtual directory. 
          Use config-edit -ui fuse -fuse_dir some/where to use. 
          Stop with 'fusermount -u some/where'
        * Recommends Fuse (to be able to use fuse user interface)
        
1.223 2010-11-28

        * Debian/Dpkg/Copyright: removed restrictions on copyright format
        * dist.ini: added build dependency on Probe::Perl (to run tests that invoke config-edit)

Changes  view on Meta::CPAN

        configuration data. bad data is discarded.

        * Value.pm : handle 'preset' mode to store values
        (fetch):accept mode parameter ( [ custom | preset |
        standard | default | non_built_in ] )

        * Loader.pm (_load_list): When loading list, empty value are
        considered as undef values. I.e 'list_a=a,,"",d' will
        load ('a',undef,'','d') to lista element

        * Instance.pm (new): added 'force_load' parameter to load
        erronueus configuration data. In this case, wrong data will be
        discarded.
        (preset_start): new. Use this method, then load configuration data
        that will be used as "preset data". You can use this feature to
        load data discovered by an automatic mechanism, like hardware
        scan.
        (preset_stop): new. Stop preset mode. Then all data entered will
        be considered as 'custom' data. These custom data can be compared
        to 'default' or 'preset' data for audit purpose
        (preset): new. Query if the instance is in 'preset' mode.

        * Dumper.pm (dump_tree): changed 'full_dump' parameter (0|1) to 
        'mode' (full | preset)
        (dump_tree): if a list contain undef values, they are dumped as
        a_list=a,b,,d. Empty values are dumped as a_list=a,b,"",d

        * CheckList.pm (store): work in preset mode
        (set_checked_list_as_hash): accept a mode parameter ([ custom |
        preset | standard | default ]) to be able to audit config data
        (fetch): idem

0.614 2007-10-19

        * Value.pm: added 'uniline' value type for string with no embedded
        newline. (no "\n")


        * Model.pm (translate_id_names): new method to translate AnyId
        parameter changes

        * AnyId.pm: Changed some parameters: follow -> follow_keys,
        allow -> allow_keys, allow_from -> allow_keys_from


        * Model.pm (translate_id_default_info): provides backward
        compatibility for AnyId parameter changes.

        * AnyId.pm: default parameter is replaced by 'default_keys' and
        'default_with_init'.

0.613 2007-09-25

        * IdElementReference.pm: Changes the API of IdElementReference so
        that API is more explicit (Like the API change for
        ValueComputer). This change is backward compatible (model
        translation)


        * ValueComputer.pm: Now compute paramater must use explicit
        parameters for compute formula, variables and replace.  Backward
        compatibility is kept by translating old compute declaration in
        Model.pm
        

        * Model.pm (include_class): permission, level and description
        parameters can also be declared within the element declaration.
        (i.e. at the same level than 'type' )
        
        * IdElementReference.pm (): A reference to a list will now take
        into account the values of the list instead of the indexes of the
        list. This makes more sense...

        * CheckList.pm: Change the name of 'default' parameter to
         'default_list' ('default' is still accepted but is deprecated)


        * WarpedNode.pm: improved synopsis in doc
        (load_data): new method (forgotten in 0.612)

        * Model.pm: -doc: added synopsis
        - inherit is deprecated in favor of include 
        - inherit_after is deprecated in favor of include_after
        - Raise an exception if an element is declared twice in a
          model (even through include mechanism: overriding an
          included element leads to confusion)

0.612 2007-07-26

        * HashId.pm : can preserve hash key order (when created with
        ordered => 1). New method to manipulate hash key order are swap,
        move_up, move_down.

        * Exception.pm :new error class  Config::Model::Exception::LoadData

        * AnyThing.pm (grab): added 'grab_non_available' parameter.

        * AnyId.pm: added "ordered" parameter to create ordered hash
        elements. I.e. hashes where the order of the keys is kept (like
        Tie::IxHash)


        * Value.pm (load_data): new method

        * Node.pm (load_data): new method
        (dump_as_data): new method 

        * Model.pm (inherit_class): added inherit_after parameter. In a
        model, the order of the elements is important. This parameter
        enable a model to inherit elements from another class and to place
        them in a specific place among the original elements.
        (load): returns the names of the class loaded by this method.

        * ListId.pm (load_data): new method

        * HashId.pm (load_data): new method

        * CheckList.pm (load_data): new method

0.611 2007-07-03

        * WarpedThing.pm: Modified the way to specify complex warped
        rules. The former way based on list of lists was confusing. Now
        you can specify boolean expressions to find the warp rule to apply.
        
        * Model.pm: Simplified config class inheritance mechanism: inherit
        all or nothing. Added translation of legacy warp parameter (based
        on list of lists) to new warp parameters (based on boolean
        expressions). So the change done in WarpedThing is backward
        compatible.
        
0.610 2007-06-06

        * Model.pm (inherit_class): Fix configuration class inheritance
        mechanism


        * Value.pm: can also warp help for enum value

0.609 2007-05-09

        * config-edit: renamed from config-model


        * examples/fstab/fstab_test.pl (produce_fstab): added curses
        interface example (need to install Config::Model::CursesUI to
        work)


        * config-model: added possibility to use the curses interface
        provided by Config::Model::CursesUI (if this one is installed)

        * ValueComputer.pm: Modified so compute may return an undef value
        if one of the variable (extracted from the configuration data) of
        the formula is undefined. In other word, propagate undef instead
        of croaking.

        * Searcher.pm: Lots of bug fixes
        (get_searchable_elements): new method
        (prepare): new method. Search is now done in 3 moves: create the
        searcher object, prepare the search, and run the search

        * Value.pm: removed unique_value parameter which was a bad idea
        for a check list implementation. Moved reference handling into new
        IdElementReference class

        * IdElementReference.pm: New class extracted from Value object so
        reference can be used also by CheckList

        * CheckList.pm: re-wrote as a "check_list" type and not a "list"
        type


        * Instance.pm (reset_config): new method
        (searcher): renamed search_element to
        searcher. searcher retunrs a Config::Model::Searcher object.
        
        * AnyThing.pm (searcher): renamed search_element to
        searcher. searcher retunrs a Config::Model::Searcher object.

        * AnyId.pm (copy): new method to deep-copy the content of a hash
        or id element.


        * Value.pm: moved out reference facility in
        Config::Model::IdElementReference


        * Value.pm (fetch_no_check): new method

0.608 2007-02-23

        * ObjTreeScanner.pm: Clarified call-back names.

0.607 2007-01-12

        * t/term_ui.t: Changed tests to try to load Term::ReadLine and
        skip tests if Term::ReadLine cannot be loaded.

0.606 2007-01-11

        * config-model: Corrected wrong doc for options.

        * Describe.pm: Small cosmetic changes in output.

0.605 2007-01-08

        * config-model: Now uses Log::Log4perl. (Still need to use
        Log4perl for all *.pm files though). Now write config files back.
        Added option to read and write config in test directories.

        * *.pm: Changed e-mail address to reduce spam.

        * *.pm: Small bug and doc fixes.
        



( run in 1.407 second using v1.01-cache-2.11-cpan-d7f47b0818f )