packages feed

microlens-process 0.1.0.2 → 0.1.0.3

raw patch · 4 files changed

+38/−13 lines, 4 filesdep ~doctestdep ~microlensdep ~processPVP: minor bump suggested

API additions: PVP suggests at least a minor version bump

Dependency ranges changed: doctest, microlens, process

API changes (from Hackage documentation)

+ System.Process.Microlens: createnewconsole :: Lens' CreateProcess Bool

Files

CHANGELOG.md view
@@ -1,5 +1,10 @@ # Revision history for microlens-process +## 0.1.0.2++GHC versions < 710 fail because applicative is not in base. Explicit import+added where needed+ ## 0.1.0.1  Fix the cabal version
microlens-process.cabal view
@@ -4,7 +4,7 @@ -- http://haskell.org/cabal/users-guide/  name:                microlens-process-version:             0.1.0.2+version:             0.1.0.3 synopsis:            Micro-optics for the process library description:    'microlens-process' is a set of multi-purpose optics and convenience@@ -43,7 +43,7 @@   build-depends:       base       >= 4.0      && < 5                      , filepath   >= 1.0      && < 1.5                      , microlens  >= 0.4.11   && < 0.4.12-                     , process    >= 1.5      && < 1.7+                     , process    >= 1.3      && < 1.7    hs-source-dirs:      src   default-language:    Haskell2010@@ -57,7 +57,7 @@                      , doctest           >= 0.16    && < 0.17                      , microlens         >= 0.4.11  && < 0.4.12                      , microlens-process-                     , process           >= 1.5     && < 1.7+                     , process           >= 1.3     && < 1.7    hs-source-dirs:      test   default-language:    Haskell2010
src/System/Process/Microlens.hs view
@@ -2,6 +2,7 @@ -- | -- Copyright 	: 2019 Emily Pillmore -- License	: BSD+{-# LANGUAGE CPP #-} -- -- Maintainer	: Emily Pillmore <emilypi@cohomolo.gy> -- Stability	: Experimental@@ -26,11 +27,18 @@ , closefds , creategroup , delegatectlc+#if MIN_VERSION_process(1, 3, 0) , detachconsole+, createnewconsole , newsession+#endif+#if MIN_VERSION_process(1, 4, 0) , childgroup , childuser+#endif+#if MIN_VERSION_process(1, 5, 0) , useprocessjobs+#endif   -- * Traversals , arguments   -- * Classy Lenses
src/System/Process/Microlens/CreateProcess.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE CPP #-} {-# LANGUAGE Rank2Types #-} -- | -- Module       : Sysetem.Process.Lens.CreateProcess@@ -14,9 +15,8 @@ -- Because 'CreateProcess' was created before the `_` prefix record -- name convention, some record accessors don't have an apparently -- "good" name for their corresponding lens. Those that do not are--- post-fixed with `_` i order to denote their lens status. Thankfully,--- there are 6 that meet the criteria: 'cmdspec_', 'env_', 'cwd_', 'stdin_',--- 'stdout_', and 'stderr_'.+-- post-fixed with `_`. Thankfully, there are 6 that meet the criteria:+-- 'cmdspec_', 'env_', 'cwd_', 'stdin_', 'stdout_', and 'stderr_'. -- -- We provide classy variants of what we consider the significant portions -- of 'CreateProcess' - namely, the `std_in`, `std_out`, and `std_err` entries.@@ -32,13 +32,19 @@ , stderr_ , closefds , creategroup-, createnewconsole , delegatectlc-, detachconsole , newsession+#if MIN_VERSION_process(1, 3, 0)+, detachconsole+, createnewconsole+#endif+#if MIN_VERSION_process(1, 4, 0) , childgroup , childuser+#endif+#if MIN_VERSION_process(1, 5, 0) , useprocessjobs+#endif   -- * Classy Lenses , HasStdin(..) , HasStdout(..)@@ -101,6 +107,12 @@ delegatectlc :: Lens' CreateProcess Bool delegatectlc = lens delegate_ctlc (\t b -> t { delegate_ctlc = b }) +-- | Lens into the 'new_session' entry of the 'CreateProcess' record+--+newsession :: Lens' CreateProcess Bool+newsession = lens new_session (\t b -> t { new_session = b })++#if MIN_VERSION_process(1, 3, 0) -- | Lens into the 'detach_console' entry of the 'CreateProcess' record -- detachconsole :: Lens' CreateProcess Bool@@ -110,12 +122,9 @@ -- createnewconsole :: Lens' CreateProcess Bool createnewconsole = lens create_new_console (\t b -> t { create_new_console = b })---- | Lens into the 'new_session' entry of the 'CreateProcess' record----newsession :: Lens' CreateProcess Bool-newsession = lens new_session (\t b -> t { new_session = b })+#endif +#if MIN_VERSION_process(1, 4, 0) && !WINDOWS -- | Lens into the 'child_group' entry of the 'CreateProcess' record -- childgroup :: Lens' CreateProcess (Maybe CGid)@@ -125,11 +134,14 @@ -- childuser :: Lens' CreateProcess (Maybe CUid) childuser = lens child_user (\t b -> t { child_user = b })+#endif +#if MIN_VERSION_process(1, 5, 0) -- | Lens into the 'use_process_jobs' entry of the 'CreateProcess' record -- useprocessjobs :: Lens' CreateProcess Bool useprocessjobs = lens use_process_jobs (\t b -> t { use_process_jobs = b })+#endif  -- ---------------------------------------------------------- -- -- Classes