diff options
| author | Ben Sima <ben@bensima.com> | 2025-11-26 08:24:21 -0500 |
|---|---|---|
| committer | Ben Sima <ben@bensima.com> | 2025-11-26 08:24:21 -0500 |
| commit | fdc00295da1e3575b28acab0a8aacfae85613f2b (patch) | |
| tree | 2926675802b5c5c58b716a5025c417ea8ccc4940 /Omni/Jr.hs | |
| parent | 852697390bff12101f87602da16797d893d4f962 (diff) | |
Remove git-tracked task references from hooks and docs
- Remove task sync from pre-commit hook - Remove task import from
post-merge and post-checkout hooks - Remove merge driver config from
post-checkout - Remove merge-driver command from jr - Update Task
README for SQLite storage - Delete outdated WORKER_AGENT_GUIDE.md
Amp-Thread-ID:
https://ampcode.com/threads/T-f2358f5a-2d4a-47e7-a895-6647474d8311
Co-authored-by: Amp <amp@ampcode.com>
Diffstat (limited to 'Omni/Jr.hs')
| -rw-r--r-- | Omni/Jr.hs | 32 |
1 files changed, 0 insertions, 32 deletions
@@ -24,7 +24,6 @@ import qualified Omni.Test as Test import qualified System.Console.Docopt as Docopt import qualified System.Directory as Directory import System.Environment (withArgs) -import qualified System.Environment as Env import qualified System.Exit as Exit import System.FilePath (takeFileName) import qualified System.IO as IO @@ -53,7 +52,6 @@ Usage: jr web [--port=PORT] jr review [<task-id>] [--auto] jr loop [--delay=SECONDS] - jr merge-driver <ours> <theirs> jr test jr (-h | --help) @@ -63,7 +61,6 @@ Commands: web Start the web UI server review Review a completed task (show diff, accept/reject) loop Run autonomous work+review loop - merge-driver Internal git merge driver Options: -h --help Show this help @@ -117,37 +114,8 @@ move args Just d -> fromMaybe 5 (readMaybe d) Nothing -> 5 runLoop delay - | args `Cli.has` Cli.command "merge-driver" = mergeDriver args | otherwise = putText (str <| Docopt.usage help) -mergeDriver :: Cli.Arguments -> IO () -mergeDriver args = do - ours <- getArgOrExit args (Cli.argument "ours") - theirs <- getArgOrExit args (Cli.argument "theirs") - - -- Set TASK_DB_PATH to ours (the file git provided as the current version) - -- Since we are no longer using git-tracked tasks.jsonl, this merge driver logic needs rethinking. - -- If the merge driver is called, it means git found a conflict in .tasks/tasks.jsonl, but we deleted it. - -- So this code might be dead, or we might be dealing with legacy files during a rebase. - -- For now, we'll keep the logic but be aware it's likely unused. - Env.setEnv "TASK_DB_PATH" ours - -- TaskCore.importTasks theirs - -- Task.importTasks theirs - - -- We need to call task import via CLI or library. - -- Omni.Task.importTasks IS NOT EXPOSED. - -- But we can call Task.main - withArgs ["import", "-i", theirs] Task.main - Exit.exitSuccess - -getArgOrExit :: Cli.Arguments -> Docopt.Option -> IO String -getArgOrExit args opt = - case Cli.getArg args opt of - Just val -> pure val - Nothing -> do - putText <| "Error: Missing required argument " <> Text.pack (show opt) - Exit.exitFailure - -- | Run the autonomous loop: work -> review -> repeat runLoop :: Int -> IO () runLoop delaySec = do |
