Your message dated Sat, 12 Feb 2022 21:58:04 -0700 with message-id <[email protected]> and subject line Re: Bug#860328: time: Feature request: Beep at finish has caused the Debian Bug report #860328, regarding time: Feature request: Beep at finish to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 860328: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=860328 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: time Version: 1.7-25.1+b1 Severity: wishlist Dear Maintainer, I haven't found the upstream maintainer, so I report to Debian. It would be very useful to beep when the command finishes. time is often used to run a long running command. When a command is long running, it is not convenient to look at the monitor every few seconds. The user need to be notified by a beep. So please add an option to beep at end. -- System Information: Debian Release: 9.0 APT prefers testing APT policy: (990, 'testing'), (500, 'stable-updates'), (500, 'unstable'), (500, 'stable') Architecture: i386 (i686) Kernel: Linux 4.9.0-2-686-pae (SMP w/8 CPU cores) Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Init: systemd (via /run/systemd/system) Versions of packages time depends on: ii libc6 2.24-9 time recommends no packages. time suggests no packages. -- no debconf information
--- End Message ---
--- Begin Message ---Victor Porton wrote: > I haven't found the upstream maintainer, so I report to Debian. Unfortunately the upstream project GNU time didn't really have a maintainer for a long time. And then though it does now have one that I consider very good he hasn't been working on time much of late. However if one wishes to make upstream reports they are appreciated and they may be made by mailing to the bug-time AT gnu DOT org mailing list address as noted on the upstream page. https://www.gnu.org/software/time/ > It would be very useful to beep when the command finishes. > > time is often used to run a long running command. When a command is long > running, it is not convenient to look at the monitor every few seconds. > The user need to be notified by a beep. > > So please add an option to beep at end. Very similar to Bug#860327 this is something the user is much better equipped to do if desired. There are several different mechanisms available to do this. This is one simple brute force way. /usr/bin/time sleep 2; printf "\a" Or /usr/bin/time sleep 2; beep # if installed The TIME environment variable may be used for this purpose. Here is a simple example to add a beep at the end using the POSIX time format. env TIME="real %e\nuser %U\nsys %S$(printf "\a")" /usr/bin/time sleep 2 Or the default GNU time format. env TIME="%Uuser %Ssystem %Eelapsed %PCPU (%Xavgtext+%Davgdata %Mmaxresident)k\n%Iinputs+%Ooutputs (%Fmajor+%Rminor)pagefaults %Wswaps$(printf "\a")" /usr/bin/time sleep 2 Note that printf is a shell builtin for most shells and will not invoke another process for command substitution as it might otherwise appear. Bash users may use the bashism $'\a' to specify the bell character if they wish. env TIME="real %e\nuser %U\nsys %S"$'\a' /usr/bin/time sleep 2 For my example I set it on the command line but of course setting that in the environment and exporting it would make it available for every invocation of GNU time. Here I am using 'printf' which is standard to print an "alert" character also known as the bell. man 1 printf \a alert (BEL) Of course any format other than the POSIX wished may be used but this was simple for the example. Also it is possible to do this using PROMPT_COMMAND or PS1 too. This will emit a beep after every command prompt. PROMPT_COMMAND='printf "\a"' Or PS1="$PS1$(printf "\a")" Either of those do about the same thing. But that may be very much too aggressive on the beeps that anyone would want. I am mostly just mentioning it because there are many ways to do this same thing. Also I should mention that whether a user's terminal actually produces a audible sound beep is dependent upon the system configuration. These days it might be disabled by default. I had to test using the visible bell feature of screen in order to verify the above. man ascii 007 7 07 BEL '\a' (bell) Traditionally a terminal would produce a beep if the bell character was sent to the terminal. Ensuring that is out of scope for time. See also the "beep" program. Bob
--- End Message ---

