Include hostname in auto-commit messages
Build / build (push) Failing after 7s

This commit is contained in:
2026-05-11 22:14:17 -04:00
parent 68a518337d
commit 820c648521
+3 -2
View File
@@ -41,7 +41,7 @@ import System.Exit (ExitCode (..))
import System.FSNotify
import System.FilePath (isAbsolute, splitDirectories, (</>))
import System.IO (hPutStrLn, stderr)
import System.Process (readProcessWithExitCode, spawnProcess)
import System.Process (readProcess, readProcessWithExitCode, spawnProcess)
-- | Configuration for a single repository to watch.
data RepoConfig = RepoConfig
@@ -268,7 +268,8 @@ gitCommitAll logger repoPath = do
(_, _, stageErr) <- runGitIn repoPath ["add", "-A"]
unless (T.null stageErr) $
logInfo logger ("git add stderr: " <> stageErr)
runGitIn repoPath ["commit", "-m", "converge: auto-commit"]
hostname <- init <$> readProcess "hostname" [] ""
runGitIn repoPath ["commit", "-m", "converge: auto-commit from " <> hostname]
-- | Pull from the configured remote and branch.
gitPull :: RepoConfig -> IO (ExitCode, Text, Text)