RepoPilotOpen in app →

simulot/immich-go

An alternative to the immich-CLI command that doesn't depend on nodejs installation. It tries its best for importing google photos takeout archives.

Healthy

Healthy across the board

weakest axis
Use as dependencyConcerns

copyleft license (AGPL-3.0) — review compatibility

Fork & modifyHealthy

Has a license, tests, and CI — clean foundation to fork and modify.

Learn fromHealthy

Documented and popular — useful reference codebase to read through.

Deploy as-isHealthy

No critical CVEs, sane security posture — runnable as-is.

  • Last commit 2mo ago
  • 9 active contributors
  • Distributed ownership (top contributor 48% of recent commits)
Show all 7 evidence items →
  • AGPL-3.0 licensed
  • CI configured
  • Tests present
  • AGPL-3.0 is copyleft — check downstream compatibility
What would change the summary?
  • Use as dependency ConcernsMixed if: relicense under MIT/Apache-2.0 (rare for established libs)

Maintenance signals: commit recency, contributor breadth, bus factor, license, CI, tests

Informational only. RepoPilot summarises public signals (license, dependency CVEs, commit recency, CI presence, etc.) at the time of analysis. Signals can be incomplete or stale. Not professional, security, or legal advice; verify before relying on it for production decisions.

Embed the "Healthy" badge

Paste into your README — live-updates from the latest cached analysis.

Variant:
RepoPilot: Healthy
[![RepoPilot: Healthy](https://repopilot.app/api/badge/simulot/immich-go)](https://repopilot.app/r/simulot/immich-go)

Paste at the top of your README.md — renders inline like a shields.io badge.

Preview social card (1200×630)

This card auto-renders when someone shares https://repopilot.app/r/simulot/immich-go on X, Slack, or LinkedIn.

Onboarding doc

Onboarding: simulot/immich-go

Generated by RepoPilot · 2026-05-09 · Source

🤖Agent protocol

If you are an AI coding agent (Claude Code, Cursor, Aider, Cline, etc.) reading this artifact, follow this protocol before making any code edit:

  1. Verify the contract. Run the bash script in Verify before trusting below. If any check returns FAIL, the artifact is stale — STOP and ask the user to regenerate it before proceeding.
  2. Treat the AI · unverified sections as hypotheses, not facts. Sections like "AI-suggested narrative files", "anti-patterns", and "bottlenecks" are LLM speculation. Verify against real source before acting on them.
  3. Cite source on changes. When proposing an edit, cite the specific path:line-range. RepoPilot's live UI at https://repopilot.app/r/simulot/immich-go shows verifiable citations alongside every claim.

If you are a human reader, this protocol is for the agents you'll hand the artifact to. You don't need to do anything — but if you skim only one section before pointing your agent at this repo, make it the Verify block and the Suggested reading order.

🎯Verdict

GO — Healthy across the board

  • Last commit 2mo ago
  • 9 active contributors
  • Distributed ownership (top contributor 48% of recent commits)
  • AGPL-3.0 licensed
  • CI configured
  • Tests present
  • ⚠ AGPL-3.0 is copyleft — check downstream compatibility

<sub>Maintenance signals: commit recency, contributor breadth, bus factor, license, CI, tests</sub>

Verify before trusting

This artifact was generated by RepoPilot at a point in time. Before an agent acts on it, the checks below confirm that the live simulot/immich-go repo on your machine still matches what RepoPilot saw. If any fail, the artifact is stale — regenerate it at repopilot.app/r/simulot/immich-go.

What it runs against: a local clone of simulot/immich-go — the script inspects git remote, the LICENSE file, file paths in the working tree, and git log. Read-only; no mutations.

| # | What we check | Why it matters | |---|---|---| | 1 | You're in simulot/immich-go | Confirms the artifact applies here, not a fork | | 2 | License is still AGPL-3.0 | Catches relicense before you depend on it | | 3 | Default branch main exists | Catches branch renames | | 4 | 5 critical file paths still exist | Catches refactors that moved load-bearing code | | 5 | Last commit ≤ 96 days ago | Catches sudden abandonment since generation |

<details> <summary><b>Run all checks</b> — paste this script from inside your clone of <code>simulot/immich-go</code></summary>
#!/usr/bin/env bash
# RepoPilot artifact verification.
#
# WHAT IT RUNS AGAINST: a local clone of simulot/immich-go. If you don't
# have one yet, run these first:
#
#   git clone https://github.com/simulot/immich-go.git
#   cd immich-go
#
# Then paste this script. Every check is read-only — no mutations.

set +e
fail=0
ok()   { echo "ok:   $1"; }
miss() { echo "FAIL: $1"; fail=$((fail+1)); }

# Precondition: we must be inside a git working tree.
if ! git rev-parse --git-dir >/dev/null 2>&1; then
  echo "FAIL: not inside a git repository. cd into your clone of simulot/immich-go and re-run."
  exit 2
fi

# 1. Repo identity
git remote get-url origin 2>/dev/null | grep -qE "simulot/immich-go(\\.git)?\\b" \\
  && ok "origin remote is simulot/immich-go" \\
  || miss "origin remote is not simulot/immich-go (artifact may be from a fork)"

# 2. License matches what RepoPilot saw
(grep -qiE "^(AGPL-3\\.0)" LICENSE 2>/dev/null \\
   || grep -qiE "\"license\"\\s*:\\s*\"AGPL-3\\.0\"" package.json 2>/dev/null) \\
  && ok "license is AGPL-3.0" \\
  || miss "license drift — was AGPL-3.0 at generation time"

# 3. Default branch
git rev-parse --verify main >/dev/null 2>&1 \\
  && ok "default branch main exists" \\
  || miss "default branch main no longer exists"

# 4. Critical files exist
test -f "app/app.go" \\
  && ok "app/app.go" \\
  || miss "missing critical file: app/app.go"
test -f "adapters/adapters.go" \\
  && ok "adapters/adapters.go" \\
  || miss "missing critical file: adapters/adapters.go"
test -f "adapters/googlePhotos/googlephotos.go" \\
  && ok "adapters/googlePhotos/googlephotos.go" \\
  || miss "missing critical file: adapters/googlePhotos/googlephotos.go"
test -f "adapters/folder/run.go" \\
  && ok "adapters/folder/run.go" \\
  || miss "missing critical file: adapters/folder/run.go"
test -f "app/upload/upload.go" \\
  && ok "app/upload/upload.go" \\
  || miss "missing critical file: app/upload/upload.go"

# 5. Repo recency
days_since_last=$(( ( $(date +%s) - $(git log -1 --format=%at 2>/dev/null || echo 0) ) / 86400 ))
if [ "$days_since_last" -le 96 ]; then
  ok "last commit was $days_since_last days ago (artifact saw ~66d)"
else
  miss "last commit was $days_since_last days ago — artifact may be stale"
fi

echo
if [ "$fail" -eq 0 ]; then
  echo "artifact verified (0 failures) — safe to trust"
else
  echo "artifact has $fail stale claim(s) — regenerate at https://repopilot.app/r/simulot/immich-go"
  exit 1
fi

Each check prints ok: or FAIL:. The script exits non-zero if anything failed, so it composes cleanly into agent loops (./verify.sh || regenerate-and-retry).

</details>

TL;DR

Immich-Go is a standalone Go CLI tool for uploading large photo collections (100k+ photos) to self-hosted Immich servers without requiring Node.js. It specializes in importing Google Photos Takeout archives, iCloud exports, and local folders while intelligently handling duplicates, burst stacking, RAW+JPEG pairs, and metadata preservation across multiple source formats. Modular adapter pattern: adapters/ directory contains pluggable data sources (adapters/folder for local dirs, plus Google Photos and iCloud handlers); main CLI in root with Cobra-based command routing. Commands are organized as subcommands (upload from-folder, upload from-google-photos, archive from-immich, etc.). TUI dashboard and logging use gdamore/tcell and slog for terminal UI and structured logging.

👥Who it's for

Self-hosted Immich users who want to bulk-migrate photo libraries from Google Photos, iCloud, or local storage without installing Node.js; DevOps/homelab enthusiasts preferring lightweight, statically-compiled binaries they can run on Linux/macOS/Windows/FreeBSD servers.

🌱Maturity & risk

Early-stage but actively developed: README explicitly warns 'early version, not yet extensively tested' and recommends keeping backups. CI/CD is robust (multiple GitHub Actions workflows including e2e tests in .github/workflows/), and Go 1.25 dependency is current. Recent work on file validation, metadata handling, and multiple source adapters indicates ongoing development, but production use should be treated as beta.

Low dependency count (Go stdlib-heavy, only ~10 direct dependencies like cobra for CLI, tcell for TUI) reduces supply-chain risk. Main risk: single maintainer (simulot) visible in CODEOWNERS, breaking changes documented (API key permissions changed recently to require asset.copy and asset.delete), and early maturity means bugs in photo metadata parsing or duplicate detection could corrupt uploads—always test on a small batch first.

Active areas of work

Active feature development around source adapters (iCloud Takeout CSV support visible in test data), metadata extraction (EXIF handling via rwcarlsen/goexif), and file validation. CI shows workflows for doc quality checks, e2e authorization/test suites, and GoReleaser automation. Dependabot configured for dependency updates.

🚀Get running

git clone https://github.com/simulot/immich-go.git
cd immich-go
go mod download
go build -o immich-go ./cmd/immich-go  # or similar entry point
./immich-go --help

Daily commands:

# Help and version
./immich-go --help

# Upload from local folder
./immich-go upload from-folder --server=http://localhost:2283 --api-key=YOUR_KEY /path/to/photos

# Upload Google Takeout
./immich-go upload from-google-photos --server=http://localhost:2283 --api-key=YOUR_KEY ~/Downloads/takeout-*.zip

# Archive from Immich server
./immich-go archive from-immich --from-server=http://localhost:2283 --from-api-key=YOUR_KEY --write-to-folder=/archive

🗺️Map of the codebase

  • app/app.go — Main application entry point; initializes all commands, adapters, and orchestrates the upload workflow—every contributor must understand the app lifecycle here
  • adapters/adapters.go — Core abstraction defining the Adapter interface that all source backends (Google Photos, folder, iCloud, etc.) implement—essential to understand before adding a new source
  • adapters/googlePhotos/googlephotos.go — Implements Google Photos takeout parsing logic; the primary use case and most complex adapter—load-bearing for the project's raison d'être
  • adapters/folder/run.go — Generic folder/file traversal and metadata extraction logic used across multiple adapters; critical for handling EXIF, JSON sidecars, and date inference
  • app/upload/upload.go — Upload orchestration engine; manages concurrency, duplicate detection, batch submission, and error handling—the performance bottleneck
  • app/client.go — HTTP client abstraction for Immich API communication; handles authentication, retries, and rate limiting—interface to the server
  • go.mod — Dependency manifest; Go 1.25 with key imports like cobra, tcell, imaging—defines runtime constraints

🛠️How to make changes

Add a New Photo Source Adapter

  1. Create a new folder under adapters/, e.g., adapters/mysource/ (adapters/mysource/mysource.go)
  2. Implement the Adapter interface (Download, Cat, Stat methods) defined in adapters/adapters.go (adapters/adapters.go)
  3. Create a CLI command file (e.g., mysourceCli.go) that accepts --server, --api-key, and source-specific flags; follow the pattern in adapters/folder/folderCli.go (adapters/mysource/mysourceCli.go)
  4. Register the command in app/app.go by adding it to the rootCmd's subcommands (app/app.go)
  5. Extract metadata (dates, EXIF, JSON sidecars) and yield Photo objects; see adapters/folder/readFolder.go for reference (adapters/mysource/run.go)
  6. Add unit tests in adapters/mysource/mysource_test.go and sample test data in adapters/mysource/DATA/ (adapters/mysource/mysource_test.go)

Add Support for a New Metadata Format

  1. Examine the existing JSON parsers in adapters/googlePhotos/json.go and adapters/folder/run.go (adapters/googlePhotos/json.go)
  2. Create a new unmarshalling function or extend an existing adapter's metadata extraction logic (adapters/folder/run.go)
  3. Infer or extract EXIF fields (date taken, GPS, etc.) and populate the Photo struct fields (PhotoTakenAt, Latitude, Longitude) (adapters/folder/run.go)
  4. Add tests with sample metadata files in the adapter's DATA/ subdirectory (adapters/folder/DATA)

Implement a New Deduplication or Filtering Strategy

  1. Review the current duplicate detection in adapters/shared/bannedFiles.go (adapters/shared/bannedFiles.go)
  2. Add new filter logic to the Photo processing pipeline in app/upload/upload.go (before batch assembly) (app/upload/upload.go)
  3. Implement hash computation or comparison logic (e.g., perceptual hashing, filename matching) in a new file under app/upload/ (app/upload/dedup.go)
  4. Add unit tests to validate the filter against realistic photo sets (app/upload/dedup_test.go)

Enhance Error Handling & Reporting

  1. Review current error logging in app/log.go and adapters/googlePhotos/logs.go (app/log.go)
  2. Add detailed error wrapping in the upload loop (app/upload/upload.go) or adapter run methods (app/upload/upload.go)
  3. Emit structured logs with context (file path, photo ID, error code) using slog (app/log.go)
  4. Test error paths with malformed inputs in TEST_DATA and add regression tests (app/upload/TEST_DATA)

🔧Why these technologies

  • Go 1.25 — Single static binary with no runtime dependencies (no Node.js or Docker required); excellent concurrency primitives (goroutines) for parallel uploads; cross-platform compilation (Windows, macOS, Linux, FreeBSD)
  • Cobra (CLI framework) — Structured command routing and flag parsing; supports nested subcommands (upload from-folder, upload from-google-photos, etc.) and global options (--server, --api-key)
  • tcell & tview (TUI widgets) — Terminal UI for real-time progress bars and status reporting without external dependencies; responsive and cross-platform
  • goexif (EXIF parsing) — Lightweight EXIF metadata extraction from photos; used to infer PhotoTakenAt when JSON sidecars unavailable
  • Adapter Pattern — Pluggable source backends (Google Photos, folder, iCloud, Immich) with a uniform interface; allows independent development and testing of each source

⚖️Trade-offs already made

  • Stream-based photo processing instead of loading all metadata into memory
    • Why: Handle 100,000+ photos without exhausting RAM; necessary for large takeout archives on modest hardware
    • Consequence: Cannot easily re-order or globally deduplicate across the entire set before upload; deduplication is per-batch or per-adapter

🪤Traps & gotchas

Immich API key permissions: Must include asset.read, asset.create, asset.copy, and asset.delete scopes—older keys without asset.copy/asset.delete will fail silently. Takeout format variance: Google Photos Takeout ZIP structure varies by export date/settings; the tool attempts recovery but malformed JSONs can cause skips. EXIF dependency: Files without EXIF data fall back to filesystem timestamps; Immich server timezone settings affect final photo dates. Burst photo stacking: Requires precise filename matching patterns (Motion photos detected by MOV+JPG pairs); mismatched naming bypasses stacking. No atomic uploads: Network interruptions mid-upload may leave partial assets; always verify after large imports. TUI vs headless: Some workflows require interactive terminal (TCells); piped/redirected output disables TUI.

🏗️Architecture

💡Concepts to learn

  • Burst Photo Stacking — Immich-Go detects and groups rapid-fire camera shots (burst mode) to reduce clutter; understanding how filename/timestamp patterns trigger grouping is critical for avoiding duplicate-detection false positives
  • EXIF Metadata Extraction — The tool uses rwcarlsen/goexif to parse camera capture timestamps and location data from JPEG headers; missing or corrupt EXIF causes fallback to filesystem timestamps, affecting photo ordering in Immich
  • Adapter Pattern (Pluggable Data Sources) — Immich-Go's architecture uses adapters to support multiple source formats (Google Takeout, iCloud, local folders) interchangeably; adding a new source means implementing a single interface
  • Duplicate Detection / Content Hashing — The tool must distinguish legitimate duplicate imports (same photo uploaded twice) from legitimate copies (same RAW + JPEG pair); hashing strategy affects re-import safety
  • RAW + JPEG Pairing — Professional cameras export RAW + JPEG for the same shot; Immich-Go must detect and associate these pairs (.raw + .jpg same basename) to avoid storing redundant files
  • Static Binary Cross-Compilation — Go's ability to compile a single stateless binary for Windows/macOS/Linux/FreeBSD (via GoReleaser) is immich-go's core distribution advantage over Node.js CLI tools; no runtime dependencies required
  • Takeout Archive Format Variance — Google Photos Takeout exports differ based on export date, account region, and settings (JSON vs CSV metadata, folder structure); immich-go must handle multiple format versions gracefully

🪄PR ideas

To work on one of these in Claude Code or Cursor, paste: Implement the "<title>" PR idea from CLAUDE.md, working through the checklist as the task list.

Add comprehensive unit tests for adapters/googlePhotos/matchers.go

The googlePhotos adapter has critical matching logic (matchers.go) that determines how photos are deduplicated and grouped, but the test file matchers.go is marked as .nogo (disabled). Given the complexity of matching Google Takeout exports with various metadata formats, this is a high-risk area where bugs could cause data loss or incorrect imports. Adding proper unit tests would catch regressions and improve reliability for the largest user base.

  • [ ] Rename adapters/googlePhotos/matcher_test.go from .nogo to _test.go
  • [ ] Write test cases covering: exact hash matching, filename-based matching, EXIF date matching, and JSON metadata matching
  • [ ] Add edge cases: missing EXIF, duplicate filenames, timezone handling in dates
  • [ ] Run tests with 'go test ./adapters/googlePhotos' and ensure >80% coverage on matchers.go

Add integration tests for iCloud takeout import (adapters/folder/icloud.go)

The iCloud takeout import feature (icloud.go) parses CSV metadata files and photo details, but there are currently no test files for this adapter. The test data structure already exists (adapters/folder/DATA/icloud-takeout with sample CSVs and photos), making this a perfect candidate for readable integration tests. This will prevent regressions as the iCloud format evolves.

  • [ ] Create adapters/folder/icloud_test.go with TestParsePhotoDetailsCSV and TestParseAlbumsCSV
  • [ ] Write tests using the existing test data in adapters/folder/DATA/icloud-takeout/
  • [ ] Test parsing of 'Photo Details-1.csv' and album CSV files with special characters (e.g., 'Spécial album.csv')
  • [ ] Add tests for edge cases: missing files, malformed CSV, missing photo files referenced in CSV

Add E2E test for folder adapter with real Immich server (adapters/folder/run.go)

While e2e-tests.yml and e2e-authorize.yml workflows exist, they appear to focus on googlePhotos adapter. The folder adapter (adapters/folder/) handles multiple import scenarios (local folders, ZIP archives, iCloud/Picasa metadata) but lacks dedicated E2E coverage. Adding a workflow that tests uploading a mixed folder structure would catch integration issues with the Immich API and improve confidence in the most flexible import path.

  • [ ] Create .github/workflows/e2e-folder-adapter.yml that starts an Immich test container
  • [ ] Add test data fixture: adapters/folder/DATA/e2e-test/ with mixed photos (EXIF, no EXIF, burst sequences, RAW+JPEG pairs)
  • [ ] Write test script that runs 'immich-go upload from-folder' and verifies: correct photo count, metadata preserved, duplicates detected
  • [ ] Verify test passes in CI on PR merges (reference .github/workflows/e2e-tests.yml pattern)

🌿Good first issues

  • Add missing test coverage for adapters/folder/folderCli.go file traversal edge cases (symlinks, permission denied, empty folders) matching the pattern of existing e2e tests in .github/workflows/e2e-tests.yml
  • Implement CSV validation for iCloud Takeout imports (test data exists in adapters/folder/DATA/icloud-takeout/) but parsing logic appears incomplete—add safeguards for malformed Photo Details-*.csv files
  • Document the banned-files filtering patterns in docs/technical.md with concrete examples for common photo library clutter (.Spotlight-V100/, Lightroom Catalog/) and add integration tests to verify exclusion logic

Top contributors

Click to expand

📝Recent commits

Click to expand
  • cc928ed — Merge pull request #1300 from marianwolf/main (simulot)
  • d717789 — update archive bash command in readme (marianwolf)
  • d274f81 — Merge pull request #1260 from rob518183:patch-1 (simulot)
  • 3e5ee70 — Update archive.md (rob518183)
  • 2e5607a — Merge pull request #1231 from simulot/dependabot/github_actions/actions/github-script-8 (simulot)
  • 720fd5a — Merge pull request #1230 from simulot/dependabot/github_actions/actions/setup-node-6 (simulot)
  • 3fe9218 — Merge pull request #1229 from simulot/dependabot/github_actions/actions/checkout-6 (simulot)
  • 6cfb85f — chore(deps): bump actions/checkout from 4 to 6 (dependabot[bot])
  • eaf6d44 — Merge pull request #1228 from simulot/dependabot/github_actions/actions/upload-artifact-5 (simulot)
  • 6bbcad6 — Merge pull request #1227 from simulot/dependabot/github_actions/actions/setup-go-6 (simulot)

🔒Security observations

  • High · Outdated Cryptography Dependency — go.mod - golang.org/x/crypto v0.45.0. The project uses golang.org/x/crypto v0.45.0, which is outdated. Current versions of Go crypto libraries should be kept up-to-date to receive security patches for newly discovered vulnerabilities in cryptographic implementations. Fix: Update golang.org/x/crypto to the latest stable version. Run 'go get -u golang.org/x/crypto' and test thoroughly.
  • High · Outdated SSH/SFTP Library — go.mod - github.com/melbahja/goph v1.4.0 and github.com/pkg/sftp v1.13.10. The project uses github.com/melbahja/goph v1.4.0 for SSH operations and github.com/pkg/sftp v1.13.10. These versions are outdated and may contain known security vulnerabilities in SSH connection handling and file transfer operations. Fix: Update both dependencies to their latest versions. Check for breaking changes and update code accordingly. Consider using golang.org/x/crypto/ssh directly if goph is unmaintained.
  • Medium · Potential Hardcoded Configuration in Environment Files — github.com/joho/godotenv dependency and typical .env file usage. The presence of '.env' file patterns and godotenv dependency suggests the application loads environment variables from files. If .env files contain credentials or API keys and are accidentally committed, this poses a security risk. Fix: Ensure .env files are listed in .gitignore. Use environment-specific configurations. Never commit .env files with sensitive data. Use secret management tools in production (e.g., HashiCorp Vault, cloud provider secrets).
  • Medium · Outdated Go Version — go.mod - go 1.25. The project specifies 'go 1.25' which appears to be a future/invalid version as of the knowledge cutoff. This may indicate version mismatch issues or misconfiguration that could lead to security patches not being applied correctly. Fix: Verify and use a stable, currently-supported Go version (e.g., 1.23.x). Ensure CI/CD pipelines use the same version. Check golang.org/dl for current releases.
  • Medium · Dependency Version Pins Missing Patch Updates — go.mod - Multiple dependencies without explicit patch versions. Several dependencies use minor-level version pins (e.g., v0.12.1, v1.6.0) without patch specifications. This could miss critical security patches released in patch versions. Fix: Regularly run 'go get -u' to update dependencies. Implement automated dependency checking with tools like Dependabot (already present in .github/dependabot.yml - verify it's configured correctly).
  • Medium · XML Processing Library Without Known Security Review — go.mod - github.com/clbanning/mxj/v2 v2.7.0. The project uses github.com/clbanning/mxj/v2 v2.7.0 for XML processing. Verify this library is regularly maintained and doesn't have XXE (XML External Entity) vulnerabilities or other XML parsing issues. Fix: Review the library's security history and maintenance status. Ensure XML parsing is configured securely (disable external entities). Consider alternatives if the library is unmaintained.
  • Low · TUI Library Security Considerations — go.mod - github.com/rivo/tview v0.42.0. The project uses github.com/rivo/tview for terminal UI. While generally safe, terminal-based applications can have input handling vulnerabilities if user input is not properly sanitized before use in system commands. Fix: Audit user input handling in TUI components. Ensure all user input is validated and sanitized before being passed to system commands or file operations.
  • Low · Indirect Dependency on Outdated YAML Parser — go.. The project includes gopkg.in/yaml/v3 v3.0.4 as an indirect dependency, which appears to be an older, deprecated package path. The direct dependency is gopkg.in/yaml.v3 v3.0.1. Fix: undefined

LLM-derived; treat as a starting point, not a security audit.


Generated by RepoPilot. Verdict based on maintenance signals — see the live page for receipts. Re-run on a new commit to refresh.

Healthy signals · simulot/immich-go — RepoPilot