Hello community, here is the log from the commit of package ghc-brick for openSUSE:Factory checked in at 2020-07-21 15:50:08 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/ghc-brick (Old) and /work/SRC/openSUSE:Factory/.ghc-brick.new.3592 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-brick" Tue Jul 21 15:50:08 2020 rev:2 rq:822044 version:0.55 Changes: -------- --- /work/SRC/openSUSE:Factory/ghc-brick/ghc-brick.changes 2020-06-19 16:58:54.739811606 +0200 +++ /work/SRC/openSUSE:Factory/.ghc-brick.new.3592/ghc-brick.changes 2020-07-21 15:52:58.132484339 +0200 @@ -1,0 +2,17 @@ +Fri Jul 10 02:00:27 UTC 2020 - [email protected] + +- Update brick to version 0.55. + 0.55 + ---- + + Package changes: + * Increased lower bound on `vty` dependency to 5.29. + + Bug fixes: + * `customMain` now restores the initial terminal input state on + shutdown. This means that changes to the input state flags in the last + `suspendAndResume` before program exit are no longer propagated to the + end user's terminal environment (which could lead to broken or garbled + terminal I/O). + +------------------------------------------------------------------- Old: ---- brick-0.54.tar.gz New: ---- brick-0.55.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ ghc-brick.spec ++++++ --- /var/tmp/diff_new_pack.MRNP2F/_old 2020-07-21 15:53:01.128487982 +0200 +++ /var/tmp/diff_new_pack.MRNP2F/_new 2020-07-21 15:53:01.132487987 +0200 @@ -19,7 +19,7 @@ %global pkg_name brick %bcond_with tests Name: ghc-%{pkg_name} -Version: 0.54 +Version: 0.55 Release: 0 Summary: A declarative terminal user interface library License: BSD-3-Clause ++++++ brick-0.54.tar.gz -> brick-0.55.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/brick-0.54/CHANGELOG.md new/brick-0.55/CHANGELOG.md --- old/brick-0.54/CHANGELOG.md 2001-09-09 03:46:40.000000000 +0200 +++ new/brick-0.55/CHANGELOG.md 2001-09-09 03:46:40.000000000 +0200 @@ -2,6 +2,19 @@ Brick changelog --------------- +0.55 +---- + +Package changes: + * Increased lower bound on `vty` dependency to 5.29. + +Bug fixes: + * `customMain` now restores the initial terminal input state on + shutdown. This means that changes to the input state flags in the last + `suspendAndResume` before program exit are no longer propagated to the + end user's terminal environment (which could lead to broken or garbled + terminal I/O). + 0.54 ---- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/brick-0.54/README.md new/brick-0.55/README.md --- old/brick-0.54/README.md 2001-09-09 03:46:40.000000000 +0200 +++ new/brick-0.55/README.md 2001-09-09 03:46:40.000000000 +0200 @@ -62,6 +62,7 @@ * [`sudoku-tui`](https://github.com/evanrelf/sudoku-tui), a Sudoku implementation * [`summoner-tui`](https://github.com/kowainik/summoner/tree/master/summoner-tui), an interactive frontend to the Summoner tool * [`wrapping-editor`](https://github.com/ta0kira/wrapping-editor), an embeddable editor with support for Brick + * [`git-brunch`](https://github.com/andys8/git-brunch), a git branch checkout utility These third-party packages also extend `brick`: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/brick-0.54/brick.cabal new/brick-0.55/brick.cabal --- old/brick-0.54/brick.cabal 2001-09-09 03:46:40.000000000 +0200 +++ new/brick-0.55/brick.cabal 2001-09-09 03:46:40.000000000 +0200 @@ -1,5 +1,5 @@ name: brick -version: 0.54 +version: 0.55 synopsis: A declarative terminal user interface library description: Write terminal user interfaces (TUIs) painlessly with 'brick'! You @@ -114,7 +114,7 @@ Brick.Widgets.Internal build-depends: base <= 4.14.0.0, - vty >= 5.24, + vty >= 5.29, transformers, data-clist >= 0.1, directory >= 1.2.5.0, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/brick-0.54/src/Brick/Main.hs new/brick-0.55/src/Brick/Main.hs --- old/brick-0.54/src/Brick/Main.hs 2001-09-09 03:46:40.000000000 +0200 +++ new/brick-0.55/src/Brick/Main.hs 2001-09-09 03:46:40.000000000 +0200 @@ -75,6 +75,8 @@ , nextEvent , mkVty , defaultConfig + , restoreInputState + , inputIface ) import Graphics.Vty.Attributes (defAttr) @@ -202,6 +204,10 @@ -- | The custom event loop entry point to use when the simpler ones -- don't permit enough control. Returns the final application state -- after the application halts. +-- +-- Note that this function guarantees that the terminal input state +-- prior to the first Vty initialization is the terminal input state +-- that is restored on shutdown (regardless of exceptions). customMain :: (Ord n) => Vty -- ^ The initial Vty handle to use. @@ -221,8 +227,13 @@ -- ^ The initial application state. -> IO s customMain initialVty buildVty mUserChan app initialAppState = do + let restoreInitialState = restoreInputState $ inputIface initialVty + (s, vty) <- customMainWithVty initialVty buildVty mUserChan app initialAppState + `E.catch` (\(e::E.SomeException) -> restoreInitialState >> E.throw e) + shutdown vty + restoreInitialState return s -- | Like 'customMain', except the last 'Vty' handle used by the @@ -526,5 +537,10 @@ -- specified action. When it returns an application state value, restore -- the terminal state, empty the rendering cache, redraw the application -- from the new state, and resume the event loop. +-- +-- Note that any changes made to the terminal's input state are ignored +-- when Brick resumes execution and are not preserved in the final +-- terminal input state after the Brick application returns the terminal +-- to the user. suspendAndResume :: IO s -> EventM n (Next s) suspendAndResume = return . SuspendAndResume
