Config...ursesUI(3pm)

πŸ“¦
version 1.107 Β· 4 versions
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ NAME ✨

Config::Model::CursesUI β€” bestie, it's a whole Curses interface so you can edit config data in a terminal and feel like a hacker πŸ’…

(it's Config...ursesUI(3pm), from the User Contributed Perl Documentation, in case you were wondering 🫢)


🌸 SYNOPSIS 🌸

use Config::Model ;
use Config::Model::CursesUI ;

my $model = Config::Model -> new ;

my $inst = $model->instance (
   root_class_name => 'XXX',
   instance_name   => 'yyy'
);

# create dialog
my $dialog = Config::Model::CursesUI-> new () ;

# start never returns
$dialog->start($model) ;

okay so look at that last comment. start never returns. Not "usually", not "eventually" β€” never. It's giving hotel California, no cap. 😭


πŸ¦‹ DESCRIPTION πŸ¦‹

So basically this class hands you a Curses::UI interface on top of config data that's being managed by Config::Model. Iconic. Gorgeous. Terminal-based. ✨

IMPORTANT: the literal second your CursesUI object exists, STDOUT and STDERR are being managed by the Curses interface. Which means all your print and warn calls will not work as expected. fr fr. They're not gonna do the thing you think they're gonna do. Consider yourself warned, bestie πŸ’€

πŸŽ€ CONSTRUCTOR πŸŽ€

The constructor accepts the following parameters:

  • load β€” a subroutine ref holding the code that loads the configuration data out of the configuration files. This one may override the loading mechanism that the model specified with Config::Model::AutoRead. Heads up: this sub gets called without any arguments. Zero. Nada. 🫢
  • store β€” a subroutine ref holding the code that stores the configuration data into the configuration files. This one may override the writing mechanism the model specified with Config::Model::AutoRead. And same deal: called without any arguments. πŸ‘‘

πŸ‘‘ AUTHOR πŸ‘‘

Dominique Dumont, (ddumont at cpan dot org)


🌈 LICENSE 🌈

Copyright (c) 2007-2009,2011,2017 Dominique Dumont.

This file is part of Config-Model.

Config-Model is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

Config-Model is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with Config-Model; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA


πŸ’œ SEE ALSO πŸ’œ

  • Config::Model
  • Config::Model::ObjTreeScanner
  • Curses::UI
  • Curses

and that's the whole page, bestie!! 🌸 this gem is from perl v5.36.0, dated 2022-12-11 β€” go forth and edit your configs in a cursed little terminal window, you absolute main character πŸ’–βœ¨