Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package entr for openSUSE:Factory checked in at 2021-03-02 12:33:42 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/entr (Old) and /work/SRC/openSUSE:Factory/.entr.new.2378 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "entr" Tue Mar 2 12:33:42 2021 rev:9 rq:875801 version:4.8 Changes: -------- --- /work/SRC/openSUSE:Factory/entr/entr.changes 2021-01-30 13:57:49.754403314 +0100 +++ /work/SRC/openSUSE:Factory/.entr.new.2378/entr.changes 2021-03-02 12:45:30.148357892 +0100 @@ -1,0 +2,9 @@ +Sun Feb 28 12:49:02 UTC 2021 - Martin Hauke <mar...@gmx.de> + +- Update to version 4.8 + * Set a maximum of 2^19 watches to guard against absurd file + open limits on MacOS. + * Use control sequences to clear the display and specify '-c' + twice to erase the scrollback buffer. + +------------------------------------------------------------------- Old: ---- entr-4.7.tar.gz entr-4.7.tar.gz.sig New: ---- entr-4.8.tar.gz entr-4.8.tar.gz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ entr.spec ++++++ --- /var/tmp/diff_new_pack.GuqZZV/_old 2021-03-02 12:45:30.660358335 +0100 +++ /var/tmp/diff_new_pack.GuqZZV/_new 2021-03-02 12:45:30.664358338 +0100 @@ -18,7 +18,7 @@ Name: entr -Version: 4.7 +Version: 4.8 Release: 0 Summary: A utility for running arbitrary commands when files change License: ISC ++++++ entr-4.7.tar.gz -> entr-4.8.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/entr-4.7/Makefile.bsd new/entr-4.8/Makefile.bsd --- old/entr-4.7/Makefile.bsd 2021-01-29 15:36:21.000000000 +0100 +++ new/entr-4.8/Makefile.bsd 2021-02-26 21:02:29.000000000 +0100 @@ -1,6 +1,6 @@ PREFIX ?= /usr/local MANPREFIX ?= ${PREFIX}/man -RELEASE = 4.7 +RELEASE = 4.8 CPPFLAGS += -DRELEASE=\"${RELEASE}\" all: versioncheck entr diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/entr-4.7/NEWS new/entr-4.8/NEWS --- old/entr-4.7/NEWS 2021-01-29 15:36:21.000000000 +0100 +++ new/entr-4.8/NEWS 2021-02-26 21:02:29.000000000 +0100 @@ -1,5 +1,12 @@ = Release History +== 4.8: February 26, 2021 + + - Set a maximum of 2^19 watches to guard against absurd file open limits on + MacOS + - Use control sequences to clear the display and specify '-c' twice to erase + the scrollback buffer + == 4.7: January 29, 2021 - Use system file descriptor limits when max_user_watches is not accessible diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/entr-4.7/entr.1 new/entr-4.8/entr.1 --- old/entr-4.7/entr.1 2021-01-29 15:36:21.000000000 +0100 +++ new/entr-4.8/entr.1 2021-02-26 21:02:29.000000000 +0100 @@ -13,7 +13,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd January 02, 2021 +.Dd February 18, 2021 .Dt ENTR 1 .Os .Sh NAME @@ -47,11 +47,10 @@ .Fl r flag. .It Fl c -Execute -.Pa /usr/bin/clear -before invoking the +Clear the screen before invoking the .Ar utility specified on the command line. +Specify twice to erase the scrollback buffer. .It Fl d Track the directories of regular files provided as input and exit if a new file is added. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/entr-4.7/entr.c new/entr-4.8/entr.c --- old/entr-4.7/entr.c 2021-01-29 15:36:21.000000000 +0100 +++ new/entr-4.8/entr.c 2021-02-26 21:02:29.000000000 +0100 @@ -114,6 +114,7 @@ int n_files; int i; struct kevent evSet; + long open_max; if ((*test_runner_main)) return(test_runner_main(argc, argv)); @@ -164,13 +165,20 @@ max_watches = (rlim_t)fs_sysctl(INOTIFY_MAX_USER_WATCHES); if(max_watches > 0) { rl.rlim_cur = max_watches; + open_max = max_watches; goto rlim_set; } #endif /* raise soft limit */ - rl.rlim_cur = min((rlim_t)sysconf(_SC_OPEN_MAX), rl.rlim_max); + open_max = min(sysconf(_SC_OPEN_MAX), (long)rl.rlim_max); + if (open_max == -1) + err(1, "_SC_OPEN_MAX"); + + open_max = min(524288, open_max); /* guard against unrealistic replies */ + + rl.rlim_cur = (rlim_t)open_max; if (setrlimit(RLIMIT_NOFILE, &rl) != 0) - err(1, "setrlimit cannot set rlim_cur to %d", (int)rl.rlim_cur); + err(1, "setrlimit cannot set rlim_cur to %ld", open_max); rlim_set: @@ -181,7 +189,7 @@ setenv("SHELL", "/bin/sh", 0); /* sequential scan may depend on a 0 at the end */ - files = calloc(rl.rlim_cur+1, sizeof(WatchFile *)); + files = calloc(open_max+1, sizeof(WatchFile *)); if ((kq = kqueue()) == -1) err(1, "cannot create kqueue"); @@ -191,13 +199,13 @@ usage(); /* read input and populate watch list, skipping non-regular files */ - n_files = process_input(stdin, files, rl.rlim_cur); + n_files = process_input(stdin, files, open_max); if (n_files == 0) errx(1, "No regular files to watch"); if (n_files == -1) errx(1, "Too many files listed; the hard limit for your login" - " class is %d. Please consult" - " http://eradman.com/entrproject/limits.html", (int)rl.rlim_cur); + " class is %ld. Please consult" + " http://eradman.com/entrproject/limits.html", open_max); for (i=0; i<n_files; i++) watch_file(kq, files[i]); @@ -365,7 +373,7 @@ aggressive_opt = 1; break; case 'c': - clear_opt = 1; + clear_opt = clear_opt ? 2 : 1; break; case 'd': dirwatch_opt = 1; @@ -454,8 +462,16 @@ err(1, "can't fork"); if (pid == 0) { + /* 2J - erase the entire display + * 3J - clear scrollback buffer + * H - set cursor position to the default + */ if (clear_opt == 1) - system("/usr/bin/clear"); + printf("\033[2J\033[H"); + if (clear_opt == 2) + printf("\033[2J\033[3J\033[H"); + fflush(stdout); + /* Set process group so subprocess can be signaled */ if (restart_opt == 1) { setpgid(0, getpid()); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/entr-4.7/entr_spec.c new/entr-4.8/entr_spec.c --- old/entr-4.7/entr_spec.c 2021-01-29 15:36:21.000000000 +0100 +++ new/entr-4.8/entr_spec.c 2021-02-26 21:02:29.000000000 +0100 @@ -798,6 +798,19 @@ } /* + * Parse command line arguments with the clear scrollback option + */ +int set_options_08() { + int argv_offset; + char *argv[] = { "entr", "-cc", "echo", NULL }; + + argv_offset = set_options(argv); + + ok(clear_opt == 2); + return 0; +} + +/* * In restart mode the first action should be to start the server */ int watch_fd_restart_01() { @@ -957,6 +970,7 @@ run(set_options_05); run(set_options_06); run(set_options_07); + run(set_options_08); run(watch_fd_restart_01); run(watch_fd_restart_02); run(run_utility_01);