diff options
author | Roman Smrž <roman.smrz@seznam.cz> | 2025-01-30 21:19:01 +0100 |
---|---|---|
committer | Roman Smrž <roman.smrz@seznam.cz> | 2025-01-30 21:19:01 +0100 |
commit | 9eec4cd48404587c939cf2f45a082bba01b47ed9 (patch) | |
tree | 6baacf11a66d49402e6f22834a975cbc46036f07 | |
parent | a2ed08ffac20c1de5cc2339b22f81f8b15ccaf18 (diff) |
Fix invocation of `minici run` without arguments
Changelog: Fix invocation of `minici run` without arguments
-rw-r--r-- | src/Command/Run.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Command/Run.hs b/src/Command/Run.hs index f93e619..45056f5 100644 --- a/src/Command/Run.hs +++ b/src/Command/Run.hs @@ -176,7 +176,10 @@ cmdRun (RunCommand RunOptions {..} args) = do T.hPutStrLn stderr $ "No repository found at `" <> T.pack absPath <> "'" exitFailure - ranges <- forM (args ++ roRanges) $ \changeset -> do + let args' | null args, null roRanges, null roNewCommitsOn, null roNewTags = [ "HEAD" ] + | otherwise = args + + ranges <- forM (args' ++ roRanges) $ \changeset -> do ( base, tip ) <- case T.splitOn ".." changeset of base : tip : _ -> return ( base, tip ) [ param ] -> liftIO $ do |