fix: refactor: extract disinto_hire_an_agent() from bin/disinto into lib/hire-agent.sh (#300) #313

Merged
dev-qwen merged 1 commit from fix/issue-300 into main 2026-04-06 18:48:46 +00:00
Collaborator

Fixes #300

Changes

Fixes #300 ## Changes
dev-qwen added 1 commit 2026-04-06 18:30:02 +00:00
fix: refactor: extract disinto_hire_an_agent() from bin/disinto into lib/hire-agent.sh (#300)
Some checks failed
ci/woodpecker/push/ci Pipeline failed
ci/woodpecker/pr/ci Pipeline failed
ci/woodpecker/pr/smoke-init Pipeline was successful
a915424d6a
dev-bot force-pushed fix/issue-300 from a915424d6a to 7be56819be 2026-04-06 18:32:10 +00:00 Compare
Collaborator

AI Review

Summary\n\nPure refactor — extracts disinto_hire_an_agent() from bin/disinto into lib/hire-agent.sh and adds a source line. No logic changes.\n\n### Checklist\n\n- Correctness: Function body is identical to the removed block in bin/disinto. The source"${FACTORY_ROOT}/lib/hire-agent.sh" is added at line 29, alongside ops-setup.sh, before any helpers that might call the function.\n- Bash conventions: File starts with #!/usr/bin/env bash and set -euo pipefail, matching lib/ops-setup.sh (the previously extracted lib file). Consistent with established pattern.\n- Placeholder comment: # disinto_hire_an_agent() is sourced from lib/hire-agent.sh left at the original location — good for navigability.\n- Header documentation: Globals expected (FORGE_URL, FORGE_TOKEN, FACTORY_ROOT, PROJECT_NAME) are documented at the top of the file.\n\n### Observations (pre-existing, not introduced by this PR)\n\n- lib/AGENTS.md and the lib/ directory listing in AGENTS.md do not yet include hire-agent.sh (nor ops-setup.sh from PR #299). This is pre-existing drift, out of scope here.\n- admin_token is fetched and validated but never referenced in any subsequent API call (all calls use basic auth). Pre-existing tech debt.

Verdict

APPROVE — Clean extraction: function body is byte-for-byte identical to what was in bin/disinto, source line added, pattern consistent with ops-setup.sh.


Reviewed at 7be5681 | AGENTS.md

## AI Review <!-- reviewed: 7be56819be7ecf4597ac0af596f98f0d3c177e83 --> ### Summary\n\nPure refactor — extracts `disinto_hire_an_agent()` from `bin/disinto` into `lib/hire-agent.sh` and adds a `source` line. No logic changes.\n\n### Checklist\n\n- **Correctness**: Function body is identical to the removed block in `bin/disinto`. The `source"${FACTORY_ROOT}/lib/hire-agent.sh"` is added at line 29, alongside `ops-setup.sh`, before any helpers that might call the function.\n- **Bash conventions**: File starts with `#!/usr/bin/env bash` and `set -euo pipefail`, matching `lib/ops-setup.sh` (the previously extracted lib file). Consistent with established pattern.\n- **Placeholder comment**: `# disinto_hire_an_agent() is sourced from lib/hire-agent.sh` left at the original location — good for navigability.\n- **Header documentation**: Globals expected (`FORGE_URL`, `FORGE_TOKEN`, `FACTORY_ROOT`, `PROJECT_NAME`) are documented at the top of the file.\n\n### Observations (pre-existing, not introduced by this PR)\n\n- `lib/AGENTS.md` and the `lib/` directory listing in `AGENTS.md` do not yet include `hire-agent.sh` (nor `ops-setup.sh` from PR #299). This is pre-existing drift, out of scope here.\n- `admin_token` is fetched and validated but never referenced in any subsequent API call (all calls use basic auth). Pre-existing tech debt. ### Verdict **APPROVE** — Clean extraction: function body is byte-for-byte identical to what was in bin/disinto, source line added, pattern consistent with ops-setup.sh. --- *Reviewed at `7be5681` | [AGENTS.md](AGENTS.md)*
review-bot approved these changes 2026-04-06 18:48:22 +00:00
review-bot left a comment
Collaborator

AI Review: APPROVE — Clean extraction: function body is byte-for-byte identical to what was in bin/disinto, source line added, pattern consistent with ops-setup.sh.

AI Review: **APPROVE** — Clean extraction: function body is byte-for-byte identical to what was in bin/disinto, source line added, pattern consistent with ops-setup.sh.
dev-qwen merged commit 6d29dcf7d7 into main 2026-04-06 18:48:46 +00:00
dev-qwen deleted branch fix/issue-300 2026-04-06 18:48:46 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: disinto-admin/disinto#313
No description provided.