aboutsummaryrefslogtreecommitdiff
path: root/contrib/bsddialog/bsdconfig/console
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/bsddialog/bsdconfig/console')
-rw-r--r--contrib/bsddialog/bsdconfig/console/INDEX70
-rw-r--r--contrib/bsddialog/bsdconfig/console/Makefile11
-rw-r--r--contrib/bsddialog/bsdconfig/console/Makefile.depend11
-rw-r--r--contrib/bsddialog/bsdconfig/console/USAGE37
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/console146
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/font193
-rw-r--r--contrib/bsddialog/bsdconfig/console/include/Makefile6
-rw-r--r--contrib/bsddialog/bsdconfig/console/include/Makefile.depend11
-rw-r--r--contrib/bsddialog/bsdconfig/console/include/messages.subr270
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/keymap338
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/repeat143
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/saver195
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/screenmap155
-rwxr-xr-xcontrib/bsddialog/bsdconfig/console/ttys207
14 files changed, 0 insertions, 1793 deletions
diff --git a/contrib/bsddialog/bsdconfig/console/INDEX b/contrib/bsddialog/bsdconfig/console/INDEX
deleted file mode 100644
index e298f340e63c..000000000000
--- a/contrib/bsddialog/bsdconfig/console/INDEX
+++ /dev/null
@@ -1,70 +0,0 @@
-# Copyright (c) 2012 Ron McDowell
-# Copyright (c) 2012-2015 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-
-#
-# Title that will be shown in the bsdconfig menu.
-#
-menu_title="Console"
-
-#
-# A short descriptive line shown at the bottom of the bsdconfig menu. keep it
-# short because any line longer than the terminal width will be truncated.
-#
-menu_help="Customize system console behavior"
-
-#
-# Two-part variable that defines an action to take when `keyword' is passed on
-# a bsdconfig command line. Variable takes the form "keyword|command" and
-# multiple occurrences of the variable (with different `keyword's, or different
-# `keyword's AND `command's) are allowed. If `command' begins with a '/' then
-# the full path to the program is needed. If `command' begins with anything
-# else it is a path relative to the directory this INDEX file is in. `keyword'
-# can be i18n'ed but `command' is the name of a script.
-#
-menu_selection="console|console"
-menu_selection="vt_font|font"
-menu_selection="vt_keymap|keymap"
-menu_selection="vt_repeat|repeat"
-menu_selection="vt_saver|saver"
-menu_selection="vt_screenmap|screenmap"
-menu_selection="vt_ttys|ttys"
-# For backward compatibility
-menu_selection="syscons_font|font"
-menu_selection="syscons_keymap|keymap"
-menu_selection="syscons_repeat|repeat"
-menu_selection="syscons_saver|saver"
-menu_selection="syscons_screenmap|screenmap"
-menu_selection="syscons_ttys|ttys"
-
-#
-# ------------ Items below this line do NOT need i18n translation ------------
-#
-# Name of the program to be run when this menu choice is selected. If it begins
-# with a '/' then the full path to the program is needed. If it begins with
-# anything else it is a path relative to the directory this INDEX file is in.
-#
-menu_program="console"
diff --git a/contrib/bsddialog/bsdconfig/console/Makefile b/contrib/bsddialog/bsdconfig/console/Makefile
deleted file mode 100644
index bcb2ebd44185..000000000000
--- a/contrib/bsddialog/bsdconfig/console/Makefile
+++ /dev/null
@@ -1,11 +0,0 @@
-# $FreeBSD$
-
-SUBDIR= include
-
-FILESDIR= ${LIBEXECDIR}/bsdconfig/080.console
-FILES= INDEX USAGE
-
-SCRIPTSDIR= ${FILESDIR}
-SCRIPTS= console font keymap repeat saver screenmap ttys
-
-.include <bsd.prog.mk>
diff --git a/contrib/bsddialog/bsdconfig/console/Makefile.depend b/contrib/bsddialog/bsdconfig/console/Makefile.depend
deleted file mode 100644
index f80275d86ab1..000000000000
--- a/contrib/bsddialog/bsdconfig/console/Makefile.depend
+++ /dev/null
@@ -1,11 +0,0 @@
-# $FreeBSD$
-# Autogenerated - do NOT edit!
-
-DIRDEPS = \
-
-
-.include <dirdeps.mk>
-
-.if ${DEP_RELDIR} == ${_DEP_RELDIR}
-# local dependencies - needed for -jN in clean tree
-.endif
diff --git a/contrib/bsddialog/bsdconfig/console/USAGE b/contrib/bsddialog/bsdconfig/console/USAGE
deleted file mode 100644
index a06d8af24928..000000000000
--- a/contrib/bsddialog/bsdconfig/console/USAGE
+++ /dev/null
@@ -1,37 +0,0 @@
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-
-Usage: bsdconfig @PROGRAM_NAME@ [OPTIONS]
-
-OPTIONS:
- -d Provide lots of debugging info on standard-out when running.
- -D file Send debugging info to file. If file begins with a plus-sign
- debug info is sent to both standard-out and file (minus the
- leading plus).
- -h Print this usage statement and exit.
- -S Secure X11 mode (implies `-X'). As root, always prompt-for
- and validate sudo(8) username/password before starting.
- -X Use Xdialog(1) in place of dialog(1).
diff --git a/contrib/bsddialog/bsdconfig/console/console b/contrib/bsddialog/bsdconfig/console/console
deleted file mode 100755
index cfa44bee1abc..000000000000
--- a/contrib/bsddialog/bsdconfig/console/console
+++ /dev/null
@@ -1,146 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_console_menu_text"
- local menu_list="
- 'X $msg_exit' '$msg_exit_this_menu'
- '2 $msg_font' '$msg_choose_alternate_screen_font'
- '3 $msg_keymap' '$msg_choose_alternate_keyboard_map'
- '4 $msg_repeat' '$msg_set_repeat_rate'
- '5 $msg_saver' '$msg_configure_screen_saver'
- '6 $msg_screenmap' '$msg_choose_alternate_screenmap'
- '7 $msg_ttys' '$msg_choose_console_terminal_type'
- " # END-QUOTE
- local defaultitem= # Calculated below
- local hline="$hline_configure_system_console_settings"
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- # Obtain default-item from previously stored selection
- f_dialog_default_fetch defaultitem
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --default-item \"\$defaultitem\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_data_sanitize menu_choice
- f_dialog_menutag_store "$menu_choice"
- f_dialog_default_store "$menu_choice"
- return $retval
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_configuration"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-while :; do
- dialog_menu_main || f_die
- f_dialog_menutag_fetch mtag
-
- command=
- case "$mtag" in
- "X $msg_exit") break ;;
- "2 $msg_font") command=font ;; # Choose alternate screen font
- "3 $msg_keymap") command=keymap ;; # Choose alt. keyboard map
- "4 $msg_repeat") command=repeat ;; # Set key repeat rate
- "5 $msg_saver") command=saver ;; # Configure the screen saver
- "6 $msg_screenmap") command=screenmap ;; # Choose alternate screenmap
- "7 $msg_ttys") command=ttys ;; # Choose console terminal type
- esac
-
- if [ "$command" ]; then
- $BSDCFG_LIBE/$APP_DIR/$command ${USE_XDIALOG:+-X}
- else
- f_die 1 "$msg_unknown_console_menu_selection"
- fi
-done
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################
diff --git a/contrib/bsddialog/bsdconfig/console/font b/contrib/bsddialog/bsdconfig/console/font
deleted file mode 100755
index ce16730dd258..000000000000
--- a/contrib/bsddialog/bsdconfig/console/font
+++ /dev/null
@@ -1,193 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-f_include $BSDCFG_SHARE/sysrc.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_font_menu_text"
- local menu_list="
- '1 $msg_none' '$msg_use_hardware_default_font'
- '2 $msg_ibm_437' '$msg_ibm_437_desc'
- '3 $msg_ibm_850' '$msg_ibm_850_desc'
- '4 $msg_ibm_865' '$msg_ibm_865_desc'
- '5 $msg_ibm_866' '$msg_ibm_866_desc'
- '6 $msg_ibm_866u' '$msg_ibm_866u_desc'
- '7 $msg_ibm_1251' '$msg_ibm_1251_desc'
- '8 $msg_iso_8859_1' '$msg_iso_8859_1_desc'
- '9 $msg_iso_8859_2' '$msg_iso_8859_2_desc'
- 'a $msg_iso_8859_4' '$msg_iso_8859_4_desc'
- 'b $msg_iso_8859_7' '$msg_iso_8859_7_desc'
- 'c $msg_iso_8859_8' '$msg_iso_8859_8_desc'
- 'd $msg_iso_8859_15' '$msg_iso_8859_15_desc'
- 'e $msg_swiss' '$msg_swiss_desc'
- " # END-QUOTE
- local defaultitem= # Calculated below
- local hline="$hline_choose_a_font"
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- case "$( f_sysrc_get font8x8 )" in
- [Nn][Oo]|'') defaultitem="1 $msg_none" ;;
- cp437-8x8) defaultitem="2 $msg_ibm_437" ;;
- cp850-8x8) defaultitem="3 $msg_ibm_850" ;;
- cp865-8x8) defaultitem="4 $msg_ibm_865" ;;
- cp866-8x8) defaultitem="5 $msg_ibm_866" ;;
- cp866u-8x8) defaultitem="6 $msg_ibm_866u" ;;
- cp1251-8x8) defaultitem="7 $msg_ibm_1251" ;;
- iso-8x8) defaultitem="8 $msg_iso_8859_1" ;;
- iso02-8x8) defaultitem="9 $msg_iso_8859_2" ;;
- iso04-8x8) defaultitem="a $msg_iso_8859_4" ;;
- iso07-8x8) defaultitem="b $msg_iso_8859_7" ;;
- iso08-8x8) defaultitem="c $msg_iso_8859_8" ;;
- iso15-8x8) defaultitem="d $msg_iso_8859_15" ;;
- swiss-8x8) defaultitem="e $msg_swiss" ;;
- esac
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --default-item \"\$defaultitem\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_menutag_store -s "$menu_choice"
- return $retval
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_font"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-dialog_menu_main || f_die
-f_dialog_menutag_fetch mtag
-
-f8= f14= f16= mc_start=
-case "$mtag" in
-"1 $msg_none") # Use hardware default font
- f8="NO" f14="NO" f16="NO" ;;
-"2 $msg_ibm_437") # English and others, VGA default
- f8="cp437-8x8" f14="cp437-8x14" f16="cp437-8x16" ;;
-"3 $msg_ibm_850") # Western Europe, IBM encoding
- f8="cp850-8x8" f14="cp850-8x14" f16="cp850-8x16" ;;
-"4 $msg_ibm_865") # Norwegian, IBM encoding
- f8="cp865-8x8" f14="cp865-8x14" f16="cp865-8x16" ;;
-"5 $msg_ibm_866") # Russian, IBM encoding (use with KOI8-R screenmap)
- f8="cp866-8x8" f14="cp866-8x14" f16="cp866b-8x16" mc_start="3" ;;
-"6 $msg_ibm_866u") # Ukrainian, IBM encoding (use w/ KOI8-U screenmap)
- f8="cp866u-8x8" f14="cp866u-8x14" f16="cp866u-8x16" mc_start="3" ;;
-"7 $msg_ibm_1251") # Cyrillic, MS Windows encoding
- f8="cp1251-8x8" f14="cp1251-8x14" f16="cp1251-8x16" mc_start="3" ;;
-"8 $msg_iso_8859_1") # Western Europe, ISO encoding
- f8="iso-8x8" f14="iso-8x14" f16="iso-8x16" ;;
-"9 $msg_iso_8859_2") # Eastern Europe, ISO encoding
- f8="iso02-8x8" f14="iso02-8x14" f16="iso02-8x16" ;;
-"a $msg_iso_8859_4") # Baltic, ISO encoding
- f8="iso04-8x8" f14="iso04-8x14" f16="iso04-8x16" ;;
-"b $msg_iso_8859_7") # Greek, ISO encoding
- f8="iso07-8x8" f14="iso07-8x14" f16="iso07-8x16" ;;
-"c $msg_iso_8859_8") # Hebrew, ISO encoding
- f8="iso08-8x8" f14="iso08-8x14" f16="iso08-8x16" ;;
-"d $msg_iso_8859_15") # Europe, ISO encoding
- f8="iso15-8x8" f14="iso15-8x14" f16="iso15-8x16" ;;
-"e $msg_swiss") # English, better resolution
- f8="swiss-8x8" f14="NO" f16="swiss-8x16" ;;
-esac
-
-[ "$f8" -a "$f14" -a "$f16" ] || f_die 1 "$msg_unknown_font_selection"
-
-f_eval_catch "$0" f_sysrc_set 'f_sysrc_set font8x8 "%s"' "$f8" || f_die
-f_eval_catch "$0" f_sysrc_set 'f_sysrc_set font8x14 "%s"' "$f14" || f_die
-f_eval_catch "$0" f_sysrc_set 'f_sysrc_set font8x16 "%s"' "$f16" || f_die
-
-if [ "$mc_start" ]; then
- f_eval_catch "$0" f_sysrc_set \
- 'f_sysrc_set mousechar_start "%s"' "$mc_start" || f_die
-else
- f_eval_catch "$0" f_sysrc_delete \
- 'f_sysrc_delete mousechar_start' || f_die
-fi
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################
diff --git a/contrib/bsddialog/bsdconfig/console/include/Makefile b/contrib/bsddialog/bsdconfig/console/include/Makefile
deleted file mode 100644
index 52cb0be9c6e8..000000000000
--- a/contrib/bsddialog/bsdconfig/console/include/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-# $FreeBSD$
-
-FILESDIR= ${LIBEXECDIR}/bsdconfig/080.console/include
-FILES= messages.subr
-
-.include <bsd.prog.mk>
diff --git a/contrib/bsddialog/bsdconfig/console/include/Makefile.depend b/contrib/bsddialog/bsdconfig/console/include/Makefile.depend
deleted file mode 100644
index f80275d86ab1..000000000000
--- a/contrib/bsddialog/bsdconfig/console/include/Makefile.depend
+++ /dev/null
@@ -1,11 +0,0 @@
-# $FreeBSD$
-# Autogenerated - do NOT edit!
-
-DIRDEPS = \
-
-
-.include <dirdeps.mk>
-
-.if ${DEP_RELDIR} == ${_DEP_RELDIR}
-# local dependencies - needed for -jN in clean tree
-.endif
diff --git a/contrib/bsddialog/bsdconfig/console/include/messages.subr b/contrib/bsddialog/bsdconfig/console/include/messages.subr
deleted file mode 100644
index 295f3e302db8..000000000000
--- a/contrib/bsddialog/bsdconfig/console/include/messages.subr
+++ /dev/null
@@ -1,270 +0,0 @@
-# Copyright (c) 2012 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-
-hline_choose_a_font="Choose a font"
-hline_choose_a_keyboard_map="Choose a keyboard map"
-hline_choose_a_keyboard_repeat_rate="Choose a keyboard repeat rate"
-hline_choose_a_screen_map="Choose a screen map"
-hline_choose_a_screen_saver="Choose a nifty-looking screen saver"
-hline_choose_a_terminal_type="Choose a terminal type"
-hline_configure_system_console_settings="Configure your system console settings"
-msg_beastie="Beastie"
-msg_beastie_desc="\"BSD Daemon\" animated screen saver (graphics)"
-msg_belgian="Belgian"
-msg_belgian_desc="Belgian ISO keymap"
-msg_blank="Blank"
-msg_blank_desc="Blank screen"
-msg_brazil_cp850="Brazil CP850"
-msg_brazil_cp850_desc="Brazil CP850 keymap"
-msg_brazil_iso="Brazil ISO"
-msg_brazil_iso_accent="Brazil ISO (accent)"
-msg_brazil_iso_accent_desc="Brazil ISO keymap (accent keys)"
-msg_brazil_iso_desc="Brazil ISO keymap"
-msg_bulgarian_bds="Bulgarian BDS"
-msg_bulgarian_bds_desc="Bulgarian BDS keymap"
-msg_bulgarian_phonetic="Bulgarian Phonetic"
-msg_bulgarian_phonetic_desc="Bulgarian Phonetic keymap"
-msg_cancel="Cancel"
-msg_central_european_iso="Central European ISO"
-msg_central_european_iso_desc="Central European ISO keymap"
-msg_choose_alternate_keyboard_map="Choose an alternate keyboard map"
-msg_choose_alternate_screen_font="Choose an alternate screen font"
-msg_choose_alternate_screenmap="Choose an alternate screenmap"
-msg_choose_console_terminal_type="Choose console terminal type"
-msg_configure_screen_saver="Configure the screen saver"
-msg_console_menu_text="The system console driver for FreeBSD has a number of configuration\noptions which may be set according to your preference.\n\nWhen you are done setting configuration options, select Cancel."
-msg_croatian_iso="Croation ISO"
-msg_croatian_iso_desc="Croation ISO keymap"
-msg_czech_iso_accent="Czech ISO (accent)"
-msg_czech_iso_accent_desc="Czech ISO keymap (accent keys)"
-msg_daemon="Daemon"
-msg_daemon_desc="\"BSD Daemon\" animated screen saver (text)"
-msg_danish_cp865="Danish CP865"
-msg_danish_cp865_desc="Danish Code Page 865 keymap"
-msg_danish_iso="Danish ISO"
-msg_danish_iso_desc="Danish ISO keymap"
-msg_default="Default"
-msg_default_desc="Use default keyboard repeat rate"
-msg_dragon="Dragon"
-msg_dragon_desc="Dragon screensaver (graphics)"
-msg_enter_timeout_period="Enter time-out period in seconds for screen saver"
-msg_estonian_cp850="Estonian CP850"
-msg_estonian_cp850_desc="Estonian Code Page 850 keymap"
-msg_estonian_iso="Estonian ISO"
-msg_estonian_iso_15="Estonian ISO 15"
-msg_estonian_iso_15_desc="Estonian ISO 8859-15 keymap"
-msg_estonian_iso_desc="Estonian ISO keymap"
-msg_exit="Exit"
-msg_exit_this_menu="Exit this menu"
-msg_fade="Fade"
-msg_fade_desc="Fade out effect screen saver"
-msg_fast="Fast"
-msg_fast_desc="Fast keyboard repeat rate"
-msg_finnish_cp850="Finnish CP850"
-msg_finnish_cp850_desc="Finnish Code Page 850 keymap"
-msg_finnish_iso="Finnish ISO"
-msg_finnish_iso_desc="Finnish ISO keymap"
-msg_fire="Fire"
-msg_fire_desc="Flames effect screen saver"
-msg_font="Font"
-msg_font_menu_text="Most PC hardware defaults to displaying characters in the\nIBM 437 character set. However, in the Unix world, this\ncharacter set is very rarely used. Most Western European\ncountries, for example, prefer ISO 8859-1.\nAmerican users won't notice the difference since the bottom half\nof all these charactersets is ANSI anyway. However, they might\nwant to load a font anyway to use the 30- or 50-line displays.\nIf your hardware is capable of downloading a new display font,\nyou can select the appropriate font below."
-msg_french_iso="French ISO"
-msg_french_iso_accent="French ISO (accent)"
-msg_french_iso_accent_desc="French ISO keymap (accent keys)"
-msg_french_iso_desc="French ISO keymap"
-msg_french_iso_macbook="French ISO/Macbook"
-msg_french_iso_macbook_desc="French ISO keymap on macbook"
-msg_german_cp850="German CP850"
-msg_german_cp850_desc="German Code Page 850 keymap"
-msg_german_iso="German ISO"
-msg_german_iso_desc="German ISO keymap"
-msg_greek_101="Greek 101"
-msg_greek_101_desc="Greek ISO keymap (101 keys)"
-msg_greek_104="Greek 104"
-msg_greek_104_desc="Greek ISO keymap (104 keys)"
-msg_greek_elot="Greek ELOT"
-msg_greek_elot_desc="Greek ISO keymap (ELOT 1000)"
-msg_green="Green"
-msg_green_desc="\"Green\" power saving mode (if supported by monitor)"
-msg_hungarian_101="Hungarian 101"
-msg_hungarian_101_desc="Hungarian ISO keymap (101 key)"
-msg_hungarian_102="Hungarian 102"
-msg_hungarian_102_desc="Hungarian ISO keymap (102 key)"
-msg_ibm_1251="IBM 1251"
-msg_ibm_1251_desc="Cyrillic, MS Windows encoding"
-msg_ibm_437="IBM 437"
-msg_ibm_437_desc="English and others, VGA default"
-msg_ibm_437_vga_default="IBM437 (VGA default)"
-msg_ibm_850="IBM 850"
-msg_ibm_850_desc="Western Europe, IBM encoding"
-msg_ibm_865="IBM 865"
-msg_ibm_865_desc="Norwegian, IBM encoding"
-msg_ibm_866="IBM 866"
-msg_ibm_866_desc="Russian, IBM encoding (use with KOI8-R screenmap)"
-msg_ibm_866u="IBM 866u"
-msg_ibm_866u_desc="Ukrainian, IBM encoding (use with KOI8-U screenmap)"
-msg_icelandic="Icelandic"
-msg_icelandic_accent="Icelandic (accent)"
-msg_icelandic_accent_desc="Icelandic ISO keymap (accent keys)"
-msg_icelandic_desc="Icelandic ISO keymap"
-msg_iso_8859_15="ISO 8859-15"
-msg_iso_8859_15_desc="Europe, ISO encoding"
-msg_iso_8859_1="ISO 8859-1"
-msg_iso_8859_1_desc="Western Europe, ISO encoding"
-msg_iso_8859_1_to_ibm437="ISO 8859-1 to IBM437"
-msg_iso_8859_1_to_ibm437_desc="W-Europe ISO 8859-1 to IBM 437 screenmap"
-msg_iso_8859_2="ISO 8859-2"
-msg_iso_8859_2_desc="Eastern Europe, ISO encoding"
-msg_iso_8859_4="ISO 8859-4"
-msg_iso_8859_4_desc="Baltic, ISO encoding"
-msg_iso_8859_7="ISO 8859-7"
-msg_iso_8859_7_desc="Greek, ISO encoding"
-msg_iso_8859_7_to_ibm437="ISO 8859-7 to IBM437"
-msg_iso_8859_7_to_ibm437_desc="Greek ISO 8859-1 to IBM 437 screenmap"
-msg_iso_8859_8="ISO 8859-8"
-msg_iso_8859_8_desc="Hebrew, ISO encoding"
-msg_italian="Italian"
-msg_italian_desc="Italian ISO keymap"
-msg_japanese_106="Japanese 106"
-msg_japanese_106_desc="Japanese 106 keymap"
-msg_keymap="Keymap"
-msg_keymap_menu_text="The system console driver for FreeBSD defaults to a standard\n\"US\" keyboard map. Users may wish to choose one of the\nother keymaps below."
-msg_koi8_r="KOI8-R"
-msg_koi8_r_to_ibm866="KOI8-R to IBM866"
-msg_koi8_r_to_ibm866_desc="Russian KOI8-R to IBM 866 screenmap"
-msg_koi8_u="KOI8-U"
-msg_koi8_u_to_ibm866u="KOI8-U to IBM866u"
-msg_koi8_u_to_ibm866u_desc="Ukrainian KOI8-U to IBM 866u screenmap"
-msg_latin_american="Latin American"
-msg_latin_american_accent="Latin American (accent)"
-msg_latin_american_accent_desc="Latin American ISO keymap (accent keys)"
-msg_latin_american_desc="Latin American ISO keymap"
-msg_logo="Logo"
-msg_logo_desc="FreeBSD \"logo\" animated screen saver (graphics)"
-msg_none="None"
-msg_none_saver_desc="Disable the screensaver"
-msg_none_screenmap_desc="No screenmap, don'\''t touch font"
-msg_none_ttys_desc="Don'\''t touch anything"
-msg_normal="Normal"
-msg_normal_desc="\"Normal\" keyboard repeat rate"
-msg_norway_iso="Norway ISO"
-msg_norway_iso_desc="Norwegian ISO keymap"
-msg_ok="OK"
-msg_polish_iso="Polish ISO"
-msg_polish_iso_desc="Polish ISO keymap"
-msg_portuguese="Portuguese"
-msg_portuguese_accent="Portuguese (accent)"
-msg_portuguese_accent_desc="Portuguese ISO keymap (accent keys)"
-msg_portuguese_desc="Portuguese ISO keymap"
-msg_rain="Rain"
-msg_rain_desc="Rain drops screen saver"
-msg_repeat="Repeat"
-msg_repeat_menu_text="This menu allows you to set the speed at which keys repeat\nwhen held down."
-msg_russia_koi8_r="Russia KOI8-R"
-msg_russia_koi8_r_desc="Russia KOI8-R keymap"
-msg_saver="Saver"
-msg_saver_menu_text="By default, the console driver will not attempt to do anything\nspecial with your screen when it's idle. If you expect to leave your\nmonitor switched on and idle for long periods of time then you should\nprobably enable one of these screen savers to prevent burn-in."
-msg_screenmap="Screenmap"
-msg_screenmap_menu_text="Unless you load a specific font, most PC hardware defaults to\ndisplaying characters in the IBM 437 character set. However,\nin the Unix world, this character set is very rarely used. Most\nWestern European countries, for example, prefer ISO 8859-1.\nAmerican users won't notice the difference since the bottom half\nof all these character sets is ANSI anyway.\nIf your hardware is capable of downloading a new display font,\nyou should probably choose that option. However, for hardware\nwhere this is not possible (e.g. monochrome adapters), a screen\nmap will give you the best approximation that your hardware can\ndisplay at all."
-msg_set_repeat_rate="Set the rate at which keys repeat"
-msg_slovak="Slovak"
-msg_slovak_desc="Slovak ISO keymap"
-msg_slovenian="Slovenian"
-msg_slovenian_desc="Slovenian ISO keymap"
-msg_slow="Slow"
-msg_slow_desc="Slow keyboard repeat rate"
-msg_snake="Snake"
-msg_snake_desc="Draw a FreeBSD \"snake\" on your screen"
-msg_spanish="Spanish"
-msg_spanish_accent="Spanish (accent)"
-msg_spanish_accent_desc="Spanish ISO keymap (accent keys)"
-msg_spanish_desc="Spanish ISO keymap"
-msg_star="Star"
-msg_star_desc="A \"twinkling stars\" effect"
-msg_swedish_cp850="Swedish CP850"
-msg_swedish_cp850_desc="Swedish Code Page 850 keymap"
-msg_swedish_iso="Swedish ISO"
-msg_swedish_iso_desc="Swedish ISO keymap"
-msg_swiss="SWISS"
-msg_swiss_desc="English, better resolution"
-msg_swiss_french_cp850="Swiss French CP850"
-msg_swiss_french_cp850_desc="Swiss French Code Page 850 keymap"
-msg_swiss_french_iso="Swiss French ISO"
-msg_swiss_french_iso_accent="Swiss French ISO (accent)"
-msg_swiss_french_iso_accent_desc="Swiss French ISO keymap (accent keys)"
-msg_swiss_french_iso_desc="Swiss French ISO keymap"
-msg_swiss_german_cp850="Swiss German CP850"
-msg_swiss_german_cp850_desc="Swiss German Code Page 850 keymap"
-msg_swiss_german_iso="Swiss German ISO"
-msg_swiss_german_iso_accent="Swiss German ISO (accent)"
-msg_swiss_german_iso_accent_desc="Swiss German ISO keymap (accent keys)"
-msg_swiss_german_iso_desc="Swiss German ISO keymap"
-msg_system_console_configuration="System Console Configuration"
-msg_system_console_font="System Console Font"
-msg_system_console_keyboard_repeat_rate="System Console Keyboard Repeat Rate"
-msg_system_console_keymap="System Console Keymap"
-msg_system_console_screen_saver="System Console Screen Saver"
-msg_system_console_screenmap="System Console Screenmap"
-msg_system_console_terminal_type="System Console Terminal Type"
-msg_timeout="Timeout"
-msg_timeout_desc="Set the screen saver timeout interval"
-msg_ttys="Ttys"
-msg_ttys_menu_text="For various console encodings, a corresponding terminal type\nmust be chosen in /etc/ttys.\n\nWARNING: For compatibility reasons, only entries starting with\nttyv and terminal types starting with cons[0-9] can be changed\nvia this menu."
-msg_uk_cp850="UK CP850"
-msg_uk_cp850_desc="UK Code Page 850 keymap"
-msg_uk_iso="UK ISO"
-msg_uk_iso_desc="UK ISO keymap"
-msg_ukrainian_koi8_u="Ukranian KOI8-U"
-msg_ukrainian_koi8_u_desc="Ukranian KOI8-U keymap"
-msg_ukrainian_koi8_u_koi8_r="Ukranian KOI8-U+KOI8-R"
-msg_ukrainian_koi8_u_koi8_r_desc="Ukranian KOI8-U+KOI8-R keymap (alter)"
-msg_unknown_console_menu_selection="Unknown console menu selection"
-msg_unknown_font_selection="Unknown font selection"
-msg_unknown_keymap="Unknown keymap"
-msg_unknown_repeat_rate="Unknown repeat rate"
-msg_unknown_saver="Unknown saver"
-msg_unknown_screenmap_selection="Unknown screenmap selection"
-msg_us_ascii="US-ASCII"
-msg_us_ascii_to_ibm327="US-ASCII to IBM437"
-msg_us_ascii_to_ibm327_desc="US-ASCII to IBM 437 screenmap"
-msg_usa_capslock_ctrl="USA CapsLock->Ctrl"
-msg_usa_capslock_ctrl_desc="US standard (Caps as L-Control)"
-msg_usa_dvorak="USA Dvorak"
-msg_usa_dvorak_desc="US Dvorak keymap"
-msg_usa_dvorak_left="USA Dvorak (left)"
-msg_usa_dvorak_left_desc="US left handed Dvorak keymap"
-msg_usa_dvorak_right="USA Dvorak (right)"
-msg_usa_dvorak_right_desc="US right handed Dvorak keymap"
-msg_usa_emacs="USA Emacs"
-msg_usa_emacs_desc="US standard optimized for EMACS"
-msg_usa_iso="USA ISO"
-msg_usa_iso_desc="US ISO keymap"
-msg_usa_unix="USA UNIX"
-msg_usa_unix_desc="US traditional UNIX-workstation"
-msg_use_hardware_default_font="Use hardware default font"
-msg_value_required="Value Required"
-msg_warp="Warp"
-msg_warp_desc="A \"stars warping\" effect"
diff --git a/contrib/bsddialog/bsdconfig/console/keymap b/contrib/bsddialog/bsdconfig/console/keymap
deleted file mode 100755
index 28c0500cf8ac..000000000000
--- a/contrib/bsddialog/bsdconfig/console/keymap
+++ /dev/null
@@ -1,338 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-f_include $BSDCFG_SHARE/sysrc.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ CONFIGURATION
-
-#
-# List of keymap names
-#
-KEYMAP_NAMES="
- belgian brazil_cp850 brazil_iso
- brazil_iso_accent bulgarian_bds bulgarian_phonetic
- central_european_iso croatian_iso czech_iso_accent
- danish_cp865 danish_iso estonian_cp850
- estonian_iso estonian_iso_15 finnish_cp850
- finnish_iso french_iso french_iso_accent
- french_iso_macbook german_cp850 german_iso
- greek_101 greek_104 greek_elot
- hungarian_101 hungarian_102 icelandic
- icelandic_accent italian japanese_106
- latin_american latin_american_accent norway_iso
- polish_iso portuguese portuguese_accent
- russia_koi8_r slovak slovenian
- spanish spanish_accent swedish_cp850
- swedish_iso swiss_french_cp850 swiss_french_iso
- swiss_french_iso_accent swiss_german_cp850 swiss_german_iso
- swiss_german_iso_accent uk_cp850 uk_iso
- ukrainian_koi8_u ukrainian_koi8_u_koi8_r usa_capslock_ctrl
- usa_dvorak usa_dvorak_left usa_dvorak_right
- usa_emacs usa_iso usa_unix
-" # END-QUOTE
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_keymap_menu_text"
- local menu_list defaultitem= # Calculated below
- local hline="$hline_choose_a_keyboard_map"
-
- #
- # Export variables for awk(1) ENVIRON visibility
- #
- local name
- for name in $KEYMAP_NAMES; do
- export msg_$name msg_${name}_desc
- done
-
- #
- # Generate a sorted list of keymaps. If the first letter of the keymap
- # name is unique (case-insensitive) then it is used as the tag to allow
- # the user to jump to that entry.
- #
- menu_list=$(
- for name in $KEYMAP_NAMES; do
- eval echo \"\$msg_$name\" msg_$name
- done | sort | awk 'BEGIN { prefix = "" }
- {
- cur_prefix = tolower(substr(ENVIRON[$NF], 1, 1))
- printf "'\''"
- if ( prefix != cur_prefix )
- prefix = cur_prefix
- else
- printf " "
- printf "%s'\'' '\''%s'\''\n",
- ENVIRON[$NF], ENVIRON[$NF"_desc"]
- }'
- )
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- case "$( f_sysrc_get keymap )" in
- be.iso) defaultitem="$msg_belgian" ;;
- br275.cp850) defaultitem="$msg_brazil_cp850" ;;
- br275.iso) defaultitem="$msg_brazil_iso" ;;
- br275.iso.acc) defaultitem="$msg_brazil_iso_accent" ;;
- bg.bds.ctrlcaps) defaultitem="$msg_bulgarian_bds" ;;
- bg.phonetic.ctrlcaps) defaultitem="$msg_bulgarian_phonetic" ;;
- ce.iso2) defaultitem="$msg_central_european_iso" ;;
- hr.iso) defaultitem="$msg_croatian_iso" ;;
- cs.latin2.qwertz) defaultitem="$msg_czech_iso_accent" ;;
- danish.cp865) defaultitem="$msg_danish_cp865" ;;
- danish.iso) defaultitem="$msg_danish_iso" ;;
- estonian.cp850) defaultitem="$msg_estonian_cp850" ;;
- estonian.iso) defaultitem="$msg_estonian_iso" ;;
- estonian.iso15) defaultitem="$msg_estonian_iso_15" ;;
- finnish.cp850) defaultitem="$msg_finnish_cp850" ;;
- finnish.iso) defaultitem="$msg_finnish_iso" ;;
- fr.iso) defaultitem="$msg_french_iso" ;;
- fr.iso.acc) defaultitem="$msg_french_iso_accent" ;;
- fr.macbook.acc) defaultitem="$msg_french_iso_macbook" ;;
- german.cp850) defaultitem="$msg_german_cp850" ;;
- german.iso) defaultitem="$msg_german_iso" ;;
- gr.us101.acc) defaultitem="$msg_greek_101" ;;
- el.iso07) defaultitem="$msg_greek_104" ;;
- gr.elot.acc) defaultitem="$msg_greek_elot" ;;
- hu.iso2.101keys) defaultitem="$msg_hungarian_101" ;;
- hu.iso2.102keys) defaultitem="$msg_hungarian_102" ;;
- icelandic.iso) defaultitem="$msg_icelandic" ;;
- icelandic.iso.acc) defaultitem="$msg_icelandic_accent" ;;
- it.iso) defaultitem="$msg_italian" ;;
- jp.106) defaultitem="$msg_japanese_106" ;;
- latinamerican) defaultitem="$msg_latin_american" ;;
- latinamerican.iso.acc) defaultitem="$msg_latin_american_accent" ;;
- norwegian.iso) defaultitem="$msg_norway_iso" ;;
- pl_PL.ISO8859-2) defaultitem="$msg_polish_iso" ;;
- pt.iso) defaultitem="$msg_portuguese" ;;
- pt.iso.acc) defaultitem="$msg_portuguese_accent" ;;
- ru.koi8-r) defaultitem="$msg_russia_koi8_r" ;;
- sk.iso2) defaultitem="$msg_slovak" ;;
- si.iso) defaultitem="$msg_slovenian" ;;
- spanish.iso) defaultitem="$msg_spanish" ;;
- spanish.iso.acc) defaultitem="$msg_spanish_accent" ;;
- swedish.cp850) defaultitem="$msg_swedish_cp850" ;;
- swedish.iso) defaultitem="$msg_swedish_iso" ;;
- swissfrench.cp850) defaultitem="$msg_swiss_french_cp850" ;;
- swissfrench.iso) defaultitem="$msg_swiss_french_iso" ;;
- swissfrench.iso.acc) defaultitem="$msg_swiss_french_iso_accent" ;;
- swissgerman.cp850) defaultitem="$msg_swiss_german_cp850" ;;
- swissgerman.iso) defaultitem="$msg_swiss_german_iso" ;;
- swissgerman.iso.acc) defaultitem="$msg_swiss_german_iso_accent" ;;
- uk.cp850) defaultitem="$msg_uk_cp850" ;;
- uk.iso) defaultitem="$msg_uk_iso" ;;
- ua.koi8-u) defaultitem="$msg_ukrainian_koi8_u" ;;
- ua.koi8-u.shift.alt) defaultitem="$msg_ukrainian_koi8_u_koi8_r" ;;
- us.ctrl) defaultitem="$msg_usa_capslock_ctrl" ;;
- us.pc-ctrl) defaultitem="$msg_usa_capslock_ctrl" ;;
- us.dvorak) defaultitem="$msg_usa_dvorak" ;;
- us.dvorakl) defaultitem="$msg_usa_dvorak_left" ;;
- us.dvorakr) defaultitem="$msg_usa_dvorak_right" ;;
- us.emacs) defaultitem="$msg_usa_emacs" ;;
- us.iso) defaultitem="$msg_usa_iso" ;;
- us.unix) defaultitem="$msg_usa_unix" ;;
- esac
-
- # The defaultitem may have to be indented to match the menu_list
- if [ "$defaultitem" ]; then
- ( eval set -- $menu_list
- while [ $# -gt 0 ]; do
- [ "$defaultitem" = "$1" ] && break
- [ " $defaultitem" = "$1" ] && exit 0
- shift 2 # tag/item
- done
- exit 1 # No modification needed
- ) && defaultitem=" $defaultitem"
- fi
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --default-item \"\$defaultitem\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_menutag_store -s "$menu_choice"
- return $retval
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_keymap"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-while :; do
- dialog_menu_main || f_die
- f_dialog_menutag_fetch mtag
-
- #
- # Reverse the users choice into the variable name
- #
- keymap_name=
- mtag="${mtag# }" # remove single leading-space if-present
- for name in $KEYMAP_NAMES; do
- debug= f_getvar msg_$name msg
- [ "$msg" = "$mtag" ] && keymap_name="$name" break
- done
-
- [ "$keymap_name" ] || continue
-
- keymap_to_set=
- case "$keymap_name" in
- belgian) keymap_to_set="be.iso" ;;
- brazil_cp850) keymap_to_set="br275.cp850" ;;
- brazil_iso) keymap_to_set="br275.iso" ;;
- brazil_iso_accent) keymap_to_set="br275.iso.acc" ;;
- bulgarian_bds) keymap_to_set="bg.bds.ctrlcaps" ;;
- bulgarian_phonetic) keymap_to_set="bg.phonetic.ctrlcaps" ;;
- central_european_iso) keymap_to_set="ce.iso2" ;;
- croatian_iso) keymap_to_set="hr.iso" ;;
- czech_iso_accent) keymap_to_set="cs.latin2.qwertz" ;;
- danish_cp865) keymap_to_set="danish.cp865" ;;
- danish_iso) keymap_to_set="danish.iso" ;;
- estonian_cp850) keymap_to_set="estonian.cp850" ;;
- estonian_iso) keymap_to_set="estonian.iso" ;;
- estonian_iso_15) keymap_to_set="estonian.iso15" ;;
- finnish_cp850) keymap_to_set="finnish.cp850" ;;
- finnish_iso) keymap_to_set="finnish.iso" ;;
- french_iso) keymap_to_set="fr.iso" ;;
- french_iso_accent) keymap_to_set="fr.iso.acc" ;;
- french_iso_macbook) keymap_to_set="fr.macbook.acc" ;;
- german_cp850) keymap_to_set="german.cp850" ;;
- german_iso) keymap_to_set="german.iso" ;;
- greek_101) keymap_to_set="gr.us101.acc" ;;
- greek_104) keymap_to_set="el.iso07" ;;
- greek_elot) keymap_to_set="gr.elot.acc" ;;
- hungarian_101) keymap_to_set="hu.iso2.101keys" ;;
- hungarian_102) keymap_to_set="hu.iso2.102keys" ;;
- icelandic) keymap_to_set="icelandic.iso" ;;
- icelandic_accent) keymap_to_set="icelandic.iso.acc" ;;
- italian) keymap_to_set="it.iso" ;;
- japanese_106) keymap_to_set="jp.106" ;;
- latin_american) keymap_to_set="latinamerican" ;;
- latin_american_accent) keymap_to_set="latinamerican.iso.acc" ;;
- norway_iso) keymap_to_set="norwegian.iso" ;;
- polish_iso) keymap_to_set="pl_PL.ISO8859-2" ;;
- portuguese) keymap_to_set="pt.iso" ;;
- portuguese_accent) keymap_to_set="pt.iso.acc" ;;
- russia_koi8_r) keymap_to_set="ru.koi8-r" ;;
- slovak) keymap_to_set="sk.iso2" ;;
- slovenian) keymap_to_set="si.iso" ;;
- spanish) keymap_to_set="spanish.iso" ;;
- spanish_accent) keymap_to_set="spanish.iso.acc" ;;
- swedish_cp850) keymap_to_set="swedish.cp850" ;;
- swedish_iso) keymap_to_set="swedish.iso" ;;
- swiss_french_cp850) keymap_to_set="swissfrench.cp850" ;;
- swiss_french_iso) keymap_to_set="swissfrench.iso" ;;
- swiss_french_iso_accent) keymap_to_set="swissfrench.iso.acc" ;;
- swiss_german_cp850) keymap_to_set="swissgerman.cp850" ;;
- swiss_german_iso) keymap_to_set="swissgerman.iso" ;;
- swiss_german_iso_accent) keymap_to_set="swissgerman.iso.acc" ;;
- uk_cp850) keymap_to_set="uk.cp850" ;;
- uk_iso) keymap_to_set="uk.iso" ;;
- ukrainian_koi8_u) keymap_to_set="ua.koi8-u" ;;
- ukrainian_koi8_u_koi8_r) keymap_to_set="ua.koi8-u.shift.alt" ;;
- usa_capslock_ctrl)
- case "$( sysctl -n kern.vty )" in
- vt) keymap_to_set="us.ctrl" ;;
- *) keymap_to_set="us.pc-ctrl" ;;
- esac
- ;;
- usa_dvorak) keymap_to_set="us.dvorak" ;;
- usa_dvorak_left) keymap_to_set="us.dvorakl" ;;
- usa_dvorak_right) keymap_to_set="us.dvorakr" ;;
- usa_emacs) keymap_to_set="us.emacs" ;;
- usa_iso) keymap_to_set="us.iso" ;;
- usa_unix) keymap_to_set="us.unix" ;;
- esac
-
- if [ "$keymap_to_set" ]; then
- f_eval_catch "$0" f_sysrc_set \
- 'f_sysrc_set keymap "%s"' "$keymap_to_set" || f_die
- break
- else
- f_die 1 "$msg_unknown_keymap"
- fi
-done
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################
diff --git a/contrib/bsddialog/bsdconfig/console/repeat b/contrib/bsddialog/bsdconfig/console/repeat
deleted file mode 100755
index ff000234dc74..000000000000
--- a/contrib/bsddialog/bsdconfig/console/repeat
+++ /dev/null
@@ -1,143 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-f_include $BSDCFG_SHARE/sysrc.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_repeat_menu_text"
- local menu_list="
- '$msg_default' '$msg_default_desc'
- '$msg_slow' '$msg_slow_desc'
- '$msg_normal' '$msg_normal_desc'
- '$msg_fast' '$msg_fast_desc'
- " # END-QUOTE
- local defaultitem= # Calculated below
- local hline="$hline_choose_a_keyboard_repeat_rate"
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- case "$( f_sysrc_get keyrate )" in
- [Nn][Oo]|'') defaultitem="$msg_default" ;;
- slow) defaultitem="$msg_slow" ;;
- normal) defaultitem="$msg_normal" ;;
- fast) defaultitem="$msg_fast" ;;
- esac
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --default-item \"\$defaultitem\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_menutag_store -s "$menu_choice"
- return $retval
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_keyboard_repeat_rate"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-dialog_menu_main || f_die
-f_dialog_menutag_fetch mtag
-
-repeat_rate_to_set=
-case "$mtag" in
-"$msg_default") repeat_rate_to_set="NO" ;; # Use default repeat rate
-"$msg_slow") repeat_rate_to_set="slow" ;; # Slow keyboard repeat rate
-"$msg_normal") repeat_rate_to_set="normal" ;; # "Normal" keyboard repeat rate
-"$msg_fast") repeat_rate_to_set="fast" ;; # Fast keyboard repeat rate
-esac
-
-if [ "$repeat_rate_to_set" ]; then
- f_eval_catch "$0" f_sysrc_set \
- 'f_sysrc_set keyrate "%s"' "$repeat_rate_to_set" || f_die
- break
-else
- f_die 1 "$msg_unknown_repeat_rate"
-fi
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################
diff --git a/contrib/bsddialog/bsdconfig/console/saver b/contrib/bsddialog/bsdconfig/console/saver
deleted file mode 100755
index 0df487c9583d..000000000000
--- a/contrib/bsddialog/bsdconfig/console/saver
+++ /dev/null
@@ -1,195 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-f_include $BSDCFG_SHARE/sysrc.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_saver_menu_text"
- local menu_list="
- '1 $msg_none' '$msg_none_saver_desc'
- '2 $msg_blank' '$msg_blank_desc'
- '3 $msg_beastie' '$msg_beastie_desc'
- '4 $msg_daemon' '$msg_daemon_desc'
- '5 $msg_dragon' '$msg_dragon_desc'
- '6 $msg_fade' '$msg_fade_desc'
- '7 $msg_fire' '$msg_fire_desc'
- '8 $msg_green' '$msg_green_desc'
- '9 $msg_logo' '$msg_logo_desc'
- 'a $msg_rain' '$msg_rain_desc'
- 'b $msg_snake' '$msg_snake_desc'
- 'c $msg_star' '$msg_star_desc'
- 'd $msg_warp' '$msg_warp_desc'
- '$msg_timeout' '$msg_timeout_desc'
- " # END-QUOTE
- local defaultitem= # Calculated below
- local hline="$hline_choose_a_screen_saver"
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- case "$( f_sysrc_get saver )" in
- [Nn][Oo]|'') defaultitem="1 $msg_none" ;;
- blank) defaultitem="2 $msg_blank" ;;
- beastie) defaultitem="3 $msg_beastie" ;;
- daemon) defaultitem="4 $msg_daemon" ;;
- dragon) defaultitem="5 $msg_dragon" ;;
- fade) defaultitem="6 $msg_fade" ;;
- fire) defaultitem="7 $msg_fire" ;;
- green) defaultitem="8 $msg_green" ;;
- logo) defaultitem="9 $msg_logo" ;;
- rain) defaultitem="a $msg_rain" ;;
- snake) defaultitem="b $msg_snake" ;;
- star) defaultitem="c $msg_star" ;;
- warp) defaultitem="d $msg_warp" ;;
- esac
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --default-item \"\$defaultitem\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_menutag_store -s "$menu_choice"
- return $retval
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_screen_saver"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-dialog_menu_main || f_die
-f_dialog_menutag_fetch mtag
-
-case "$mtag" in
-"$msg_timeout") # Set the screen saver timeout interval
- f_dialog_title "$msg_value_required"
- f_dialog_input blanktime "$msg_enter_timeout_period" \
- "$( f_sysrc_get blanktime )" &&
- f_eval_catch "$0" f_sysrc_set \
- 'f_sysrc_set blanktime "%s"' "$blanktime" || f_die
- f_dialog_title_restore
- exit $SUCCESS
-esac
-
-saver_to_set=
-case "$mtag" in
-"1 $msg_none") # Disable the screensaver
- saver_to_set="NO" ;;
-"2 $msg_blank") # Simply blank the screen
- saver_to_set="blank" ;;
-"3 $msg_beastie") # "BSD Daemon" animated screen saver (graphics)
- saver_to_set="beastie" ;;
-"4 $msg_daemon") # "BSD Daemon" animated screen saver (text)
- saver_to_set="daemon" ;;
-"5 $msg_dragon") # Dragon screensaver (graphics)
- saver_to_set="dragon" ;;
-"6 $msg_fade") # Fade out effect screen saver
- saver_to_set="fade" ;;
-"7 $msg_fire") # Flames effect screen saver
- saver_to_set="fire" ;;
-"8 $msg_green") # "Green" power saving mode (if supported by monitor)
- saver_to_set="green" ;;
-"9 $msg_logo") # FreeBSD "logo" animated screen saver (graphics)
- saver_to_set="logo" ;;
-"a $msg_rain") # Rain drops screen saver
- saver_to_set="rain" ;;
-"b $msg_snake") # Draw a FreeBSD "snake" on your screen
- saver_to_set="snake" ;;
-"c $msg_star") # A "twinkling stars" effect
- saver_to_set="star" ;;
-"d $msg_warp") # A "stars warping" effect
- saver_to_set="warp" ;;
-esac
-
-if [ "$saver_to_set" ]; then
- f_eval_catch "$0" f_sysrc_set \
- 'f_sysrc_set saver "%s"' "$saver_to_set" || f_die
- break
-else
- f_die 1 "$msg_unknown_saver"
-fi
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################
diff --git a/contrib/bsddialog/bsdconfig/console/screenmap b/contrib/bsddialog/bsdconfig/console/screenmap
deleted file mode 100755
index 5bf5bd872da0..000000000000
--- a/contrib/bsddialog/bsdconfig/console/screenmap
+++ /dev/null
@@ -1,155 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-f_include $BSDCFG_SHARE/sysrc.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_screenmap_menu_text"
- local menu_list="
- '1 $msg_none' '$msg_none_screenmap_desc'
- '2 $msg_iso_8859_1_to_ibm437' '$msg_iso_8859_1_to_ibm437_desc'
- '3 $msg_iso_8859_7_to_ibm437' '$msg_iso_8859_7_to_ibm437_desc'
- '4 $msg_us_ascii_to_ibm327' '$msg_us_ascii_to_ibm327_desc'
- '5 $msg_koi8_r_to_ibm866' '$msg_koi8_r_to_ibm866_desc'
- '6 $msg_koi8_u_to_ibm866u' '$msg_koi8_u_to_ibm866u_desc'
- " # END-QUOTE
- local defaultitem= # Calculated below
- local hline="$hline_choose_a_screen_map"
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- case "$( f_sysrc_get scrnmap )" in
- [Nn][Oo]|'') defaultitem="1 $msg_none" ;;
- iso-8859-1_to_cp437) defaultitem="2 $msg_iso_8859_1_to_ibm437" ;;
- iso-8859-7_to_cp437) defaultitem="3 $msg_iso_8859_7_to_ibm437" ;;
- us-ascii_to_cp437) defaultitem="4 $msg_us_ascii_to_ibm327" ;;
- koi8-r2cp866) defaultitem="5 $msg_koi8_r_to_ibm866" ;;
- koi8-u2cp866u) defaultitem="6 $msg_koi8_u_to_ibm866u" ;;
- esac
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --default-item \"\$defaultitem\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_menutag_store -s "$menu_choice"
- return $retval
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_screenmap"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-dialog_menu_main || f_die
-f_dialog_menutag_fetch mtag
-
-scrnmap_to_set=
-case "$mtag" in
-"1 $msg_none") # No screenmap, don't touch font
- scrnmap_to_set="NO" ;;
-"2 $msg_iso_8859_1_to_ibm437") # W-Europe ISO 8859-1 to IBM 437 scrnmap
- scrnmap_to_set="iso-8859-1_to_cp437" ;;
-"3 $msg_iso_8859_7_to_ibm437") # Greek ISO 8859-7 to IBM 437 screenmap
- scrnmap_to_set="iso-8859-7_to_cp437" ;;
-"4 $msg_us_ascii_to_ibm327") # US-ASCII to IBM 437 screenmap
- scrnmap_to_set="us-ascii_to_cp437" ;;
-"5 $msg_koi8_r_to_ibm866") # Russian KOI8-R to IBM 866 screenmap
- scrnmap_to_set="koi8-r2cp866" ;;
-"6 $msg_koi8_u_to_ibm866u") # Ukrainian KOI8-U to IBM 866u screenmap
- scrnmap_to_set="koi8-u2cp866u" ;;
-esac
-
-if [ "$scrnmap_to_set" ]; then
- f_eval_catch "$0" f_sysrc_set \
- 'f_sysrc_set scrnmap "%s"' "$scrnmap_to_set" || f_die
- break
-else
- f_die 1 "$msg_unknown_screenmap_selection"
-fi
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################
diff --git a/contrib/bsddialog/bsdconfig/console/ttys b/contrib/bsddialog/bsdconfig/console/ttys
deleted file mode 100755
index 54dcb66bdd99..000000000000
--- a/contrib/bsddialog/bsdconfig/console/ttys
+++ /dev/null
@@ -1,207 +0,0 @@
-#!/bin/sh
-#-
-# Copyright (c) 2012-2013 Devin Teske
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# $FreeBSD$
-#
-############################################################ INCLUDES
-
-BSDCFG_SHARE="/usr/share/bsdconfig"
-. $BSDCFG_SHARE/common.subr || exit 1
-f_dprintf "%s: loading includes..." "$0"
-f_include $BSDCFG_SHARE/dialog.subr
-f_include $BSDCFG_SHARE/mustberoot.subr
-f_include $BSDCFG_SHARE/sysrc.subr
-
-BSDCFG_LIBE="/usr/libexec/bsdconfig" APP_DIR="080.console"
-f_include_lang $BSDCFG_LIBE/$APP_DIR/include/messages.subr
-
-f_index_menusel_keyword $BSDCFG_LIBE/$APP_DIR/INDEX "$pgm" ipgm &&
- pgm="${ipgm:-$pgm}"
-
-############################################################ CONFIGURATION
-
-#
-# Location of ttys(5)
-#
-ETC_TTYS=/etc/ttys
-
-############################################################ FUNCTIONS
-
-# dialog_menu_main
-#
-# Display the dialog(1)-based application main menu.
-#
-dialog_menu_main()
-{
- local prompt="$msg_ttys_menu_text"
- local menu_list="
- '1 $msg_none' '$msg_none_ttys_desc'
- '2 $msg_ibm_437_vga_default' 'cons25'
- '3 $msg_iso_8859_1' 'cons25l1'
- '4 $msg_iso_8859_2' 'cons25l2'
- '5 $msg_iso_8859_7' 'cons25l7'
- '6 $msg_koi8_r' 'cons25r'
- '7 $msg_koi8_u' 'cons25u'
- '8 $msg_us_ascii' 'cons25w'
- " # END-QUOTE
- local hline="$hline_choose_a_terminal_type"
-
- local height width rows
- eval f_dialog_menu_size height width rows \
- \"\$DIALOG_TITLE\" \
- \"\$DIALOG_BACKTITLE\" \
- \"\$prompt\" \
- \"\$hline\" \
- $menu_list
-
- local menu_choice
- menu_choice=$( eval $DIALOG \
- --title \"\$DIALOG_TITLE\" \
- --backtitle \"\$DIALOG_BACKTITLE\" \
- --hline \"\$hline\" \
- --ok-label \"\$msg_ok\" \
- --cancel-label \"\$msg_cancel\" \
- --menu \"\$prompt\" \
- $height $width $rows \
- $menu_list \
- 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- )
- local retval=$?
- f_dialog_menutag_store -s "$menu_choice"
-
- if [ $retval -eq $DIALOG_OK ]; then
- local item
- item=$( eval f_dialog_menutag2item \
- \"\$menu_choice\" $menu_list )
- f_dialog_menuitem_store "$item"
- fi
-
- return $retval
-}
-
-# ttys_set_type $consterm
-#
-# Set terminal type of `ttyv*' and `cons[0-9]' entries in ttys(5) to $consterm.
-#
-ttys_set_type()
-{
- local funcname=ttys_set_type
- local consterm="$1" err
-
- #
- # Create new temporary file to write our ttys(5) update with new types.
- #
- local tmpfile
- f_eval_catch -k tmpfile $funcname mktemp 'mktemp -t "%s"' "$pgm" ||
- return $FAILURE
-
- #
- # Fixup permissions and ownership (mktemp(1) creates the temporary file
- # with 0600 permissions -- change the permissions and ownership to
- # match ttys(5) before we write it out and mv(1) it into place).
- #
- local mode owner
- f_eval_catch -dk mode $funcname stat \
- 'stat -f "%%#Lp" "%s"' "$ETC_TTYS" || mode=0644
- f_eval_catch -dk owner $funcname stat \
- 'stat -f "%%u:%%g" "%s"' "$ETC_TTYS" || owner="root:wheel"
- f_eval_catch -d $funcname chmod 'chmod "%s" "%s"' "$mode" "$tmpfile"
- f_eval_catch -d $funcname chown 'chown "%s" "%s"' "$owner" "$tmpfile"
-
- #
- # Operate on ttys(5), replacing only the types of `ttyv*' and
- # `cons[0-9]' terminals with the new type.
- #
- if ! err=$( awk -v consterm="$consterm" '
- BEGIN {
- }
- {
- # "Skip" blank-lines, lines containing only whitespace, and
- # lines containing only a comment or whitespace-then-comment.
- #
- if ( $0 ~ /^[[:space:]]*(#|$)/ ) { print; next }
-
- # "Skip" terminal types other than those supported
- #
- if ( $1 !~ /^(ttyv.*|cons[0-9])$/ ) { print; next }
-
- # Change the terminal type to the new value
- #
- match($0, /[[:alnum:]\.\+-_]+[[:space:]]+(on|off).*$/)
- if ( ! RSTART ) { print; next }
- left = substr($0, 0, RSTART - 1)
- match($0, /[[:space:]]+(on|off).*$/)
- right = substr($0, RSTART)
- printf "%s%s%s\n", left, consterm, right
- }
- ' "$ETC_TTYS" > "$tmpfile" 2>&1 ); then
- f_dialog_msgbox "$err"
- return $FAILURE
- fi
- f_eval_catch $funcname mv 'mv -f "%s" "%s"' "$tmpfile" "$ETC_TTYS" ||
- return $FAILURE
-
- return $SUCCESS
-}
-
-############################################################ MAIN
-
-# Incorporate rc-file if it exists
-[ -f "$HOME/.bsdconfigrc" ] && f_include "$HOME/.bsdconfigrc"
-
-#
-# Process command-line arguments
-#
-while getopts h$GETOPTS_STDARGS flag; do
- case "$flag" in
- h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm" ;;
- esac
-done
-shift $(( $OPTIND - 1 ))
-
-#
-# Initialize
-#
-f_dialog_title "$msg_system_console_terminal_type"
-f_dialog_backtitle "${ipgm:+bsdconfig }$pgm"
-f_mustberoot_init
-
-#
-# Launch application main menu
-#
-dialog_menu_main || f_die
-f_dialog_menutag_fetch mtag
-
-[ "$mtag" = "1 $msg_none" ] && exit $SUCCESS
-
-f_dialog_menuitem_fetch consterm
-ttys_set_type "$consterm" || f_die
-
-exit $SUCCESS
-
-################################################################################
-# END
-################################################################################