From owner-svn-src-stable@freebsd.org Mon Feb 1 00:58:09 2016 Return-Path: Delivered-To: svn-src-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4632CA73550; Mon, 1 Feb 2016 00:58:09 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0131B13D0; Mon, 1 Feb 2016 00:58:08 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u110w8E8066066; Mon, 1 Feb 2016 00:58:08 GMT (envelope-from dteske@FreeBSD.org) Received: (from dteske@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u110w73S066064; Mon, 1 Feb 2016 00:58:07 GMT (envelope-from dteske@FreeBSD.org) Message-Id: <201602010058.u110w73S066064@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dteske set sender to dteske@FreeBSD.org using -f From: Devin Teske Date: Mon, 1 Feb 2016 00:58:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r295110 - stable/10/usr.bin/dpv X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 01 Feb 2016 00:58:09 -0000 Author: dteske Date: Mon Feb 1 00:58:07 2016 New Revision: 295110 URL: https://svnweb.freebsd.org/changeset/base/295110 Log: MFC revisions 294861,294863 r294861: Add `-k' for dpv(3) `keep_tite' config option r294863: Bump copyright Approved by: re (gjb) Modified: stable/10/usr.bin/dpv/dpv.1 stable/10/usr.bin/dpv/dpv.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/dpv/dpv.1 ============================================================================== --- stable/10/usr.bin/dpv/dpv.1 Mon Feb 1 00:55:15 2016 (r295109) +++ stable/10/usr.bin/dpv/dpv.1 Mon Feb 1 00:58:07 2016 (r295110) @@ -1,4 +1,4 @@ -.\" Copyright (c) 2013-2015 Devin Teske +.\" Copyright (c) 2013-2016 Devin Teske .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd Oct 22, 2015 +.Dd Jan 26, 2016 .Dt DPV 1 .Os .Sh NAME @@ -138,6 +138,11 @@ Default value is .Dq Li %'10lli bytes read @ %'9.1f bytes/sec. [%i/%i busy/wait] . This format is used when handling more than one file. +.It Fl k +Keep tite. +Prevent visually distracting initialization/exit routines for scripts running +.Xr dialog 1 +several times. .It Fl l Line mode. Read lines from input instead of bytes. .It Fl L Ar size Modified: stable/10/usr.bin/dpv/dpv.c ============================================================================== --- stable/10/usr.bin/dpv/dpv.c Mon Feb 1 00:55:15 2016 (r295109) +++ stable/10/usr.bin/dpv/dpv.c Mon Feb 1 00:58:07 2016 (r295110) @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2013-2014 Devin Teske + * Copyright (c) 2013-2016 Devin Teske * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -271,7 +271,7 @@ main(int argc, char *argv[]) * Process command-line options */ while ((ch = getopt(argc, argv, - "a:b:dDhi:I:lL:mn:No:p:P:t:TU:wx:X")) != -1) { + "a:b:dDhi:I:klL:mn:No:p:P:t:TU:wx:X")) != -1) { switch(ch) { case 'a': /* additional message text to append */ if (config->aprompt == NULL) { @@ -307,6 +307,9 @@ main(int argc, char *argv[]) case 'I': /* status line format string for many-files */ config->status_many = optarg; break; + case 'k': /* keep tite */ + config->keep_tite = TRUE; + break; case 'l': /* Line mode */ line_mode = TRUE; break; @@ -467,7 +470,8 @@ main(int argc, char *argv[]) if (dpv(config, file_list) != 0 && debug) warnx("dpv(3) returned error!?"); - end_dialog(); + if (!config->keep_tite) + end_dialog(); dpv_free(); exit(EXIT_SUCCESS);