Files
android-fs5/specs/001-android-fs5-management/tasks.md
T
Jane Alesi ad6cbf5fa4 docs: end-of-day — tasks complete, learnings, next steps
- Mark all 33 tasks complete in specs/001 tasks.md (85/85 tests passing)
- Add NEXT_STEPS.md: spec 002 completion, shellcheck, README ui docs
- Add docs/learnings/2026-03-02: BATS fixtures, UIAutomator XML parsing,
  KDE Connect graceful degradation, scrcpy headless, JSON output pattern
2026-03-02 18:33:04 +01:00

3.6 KiB

Task Breakdown: Android FS5 Device Management

Feature: 001-android-fs5-management Created: 2026-03-02 Status: Complete


Phase 1: Project Setup

  • T001 Create project skeleton: .gitignore, .env.example, README.md, lib/, tests/ dirs
  • T002 Create .env from .env.example with device serial RD51QE202392
  • T003 Verify bats-core and shellcheck available (bats --version, shellcheck --version)

Phase 2: Foundational Library (lib/)

  • T004 Create lib/output.shout_human, out_json, out_error, out_success functions
  • T005 Create lib/adb.shadb_check_device, adb_cmd, adb_get_prop, adb_shell, adb_log_op
  • T006 Create lib/adb.shadb_push, adb_pull with existence checks and --force support

Phase 3: Tests (RED phase — must fail before implementation)

  • T007 [US1] Write tests/test_status.bats — tests for status command (connected, disconnected, --json)
  • T008 [US2] Write tests/test_transfer.bats — tests for push/pull (basic, idempotent, --force, directory)
  • T009 [US3] Write tests/test_app.bats — tests for app list, app install, app uninstall
  • T010 [US4] Write tests/test_shell.bats — tests for shell command passthrough
  • T011 [US5] Write tests/test_logs.bats — tests for logs command (stream, --lines, --filter, --output)
  • T012 Verify ALL tests FAIL (RED phase confirmed) before writing fs5 entrypoint

Phase 4: Implementation — P1 User Stories

  • T013 [US1] Create fs5 entrypoint: argument parsing, --help, config loading, status command
  • T014 [US1] Implement status command: collect device props, battery, storage, format human + JSON output
  • T015 [US2] Implement push command: file existence check, transfer, idempotency guard, logging
  • T016 [US2] Implement pull command: device file check, transfer, local overwrite guard, logging
  • T017 Verify T007 + T008 tests PASS (GREEN phase for P1)

Phase 5: Implementation — P2 User Stories

  • T018 [US3] Implement app list command: parse pm list packages, filter system/user, version lookup
  • T019 [US3] Implement app install command: APK validation, adb install, package name confirmation
  • T020 [US3] Implement app uninstall command: --force guard, pm uninstall, logging
  • T021 [US4] Implement shell command: passthrough to adb shell, stdin pipe support
  • T022 Verify T009 + T010 tests PASS (GREEN phase for P2)

Phase 6: Implementation — P3 User Stories

  • T023 [US5] Implement logs command: adb logcat stream, --lines (dump mode), --filter, --output
  • T024 Verify T011 tests PASS (GREEN phase for P3)

Phase 7: Remote Control Extension (002-remote-control)

  • T025 Implement screen command via scrcpy (mirror + headless mode)
  • T026 Implement screenshot command (PNG capture, --json output)
  • T027 Implement tap / swipe / key / type input commands
  • T028 Implement launch command (start app by package name)
  • T029 Implement ocr command (tesseract-based text extraction from screenshot)
  • T030 Implement sms list / sms otp via KDE Connect CLI
  • T031 Write tests/test_remote_control.bats — screen/screenshot/tap/swipe/key/launch/ocr/sms
  • T032 Implement ui dump / ui elements / ui find / ui tap via UIAutomator XML
  • T033 Write tests/test_ui.bats — ui subcommand suite (85 tests total, all passing)

Final Status

85/85 tests passing as of 2026-03-02. All P1, P2, P3 user stories from spec 001 complete. All remote control features from spec 002 complete.