Omahub
← All plugins
S

Mirror Android

by Sumiran Dahal

Mirror an Android phone or tablet with scrcpy, over USB or WiFi

Security review

No obvious issues detected

Deterministic scan — not a security guarantee

None
Risk level
None
Analyzed commit
033794d
Scanned
1 month ago

No potentially dangerous behavior detected in the analyzed commit.

Automated analysis only — not a security guarantee.

AI advisory review

No obvious issues detected

Language-model assessment · ~deepseek/deepseek-v4-flash-latest — advisory only

Low
AI risk level
Low
Recommendation
install
Model
~deepseek/deepseek-v4-flash-latest
Analyzed commit
033794d
Reviewed
1 month ago

Manual review corroborates the deterministic scan: the plugin is a straightforward adb/scrcpy wrapper, user-supplied addresses and codes are passed as argv and quoted in the helper, and I found no obfuscation, credential theft, persistence, or destructive commands. The only noteworthy issue is the helper writing scrcpy output to a fixed, predictable /tmp path, which is a minor local-file risk on multiuser systems rather than a sign of malicious code.

  • bin/mirror-phone redirects scrcpy output to /tmp/mirror-phone.log; on a multiuser machine a local attacker could pre-create that path as a symlink and cause a user-writable file to be truncated when the plugin runs. Using $XDG_RUNTIME_DIR or mktemp would remove this issue.
How this check works

This review combines the deterministic scan (the rule-based results above) with an independent look at the plugin's code by a language model. The model reads a trimmed sample of the repository's files, the manifest, and the README, then gives a plain-language risk level and a recommendation: install (no notable danger), review (look closer first), or avoid (clearly dangerous).

It runs on the same analyzed commit as the deterministic scan and is strictly advisory — it is not a security guarantee and never blocks a plugin by itself. A human moderator still reviews plugins before they are listed.

AI advisory only — automated analysis, not a security guarantee.

Install
$ omarchy plugin add https://github.com/sumdahl/omarchy-plugin-mirror-android --enable
System #Hyprland #quickshell #system

Mirror Android

A bar widget for Omarchy 4 that mirrors an Android phone or tablet as a normal, resizable floating window — over USB or Wi-Fi — without ever touching a terminal.

Click the bar icon to open the panel: pick a mirror profile, pair and connect a device wirelessly, or tune quality/audio/screen-off settings, all from one popup.

Mirror Android popover

Features

  • Three mirror profiles — Mirror (USB), Mirror (Tablet, higher resolution + audio), Mirror (WiFi) — each disabled until a matching device is actually detected.
  • In-panel wireless pairing. Pair and connect to an Android 11+ Wireless Debugging device directly from the panel — no adb pair/adb connect typing. The last successful connect address is remembered for next time.
  • Live status. Connection state polls every 2 seconds while the panel is open, so plugging in a device updates the buttons immediately — no closing and reopening the panel.
  • Configurable quality. A Battery/Balanced/High preset scales resolution, bitrate, and frame rate together across all three profiles, plus independent Audio and Turn-screen-off-while-mirroring toggles — all persisted.
  • Native Hyprland behavior. The mirrored window floats, centers, and resizes like any other window — press F11 inside it to toggle fullscreen.

Install

omarchy plugin add https://github.com/sumdahl/omarchy-plugin-mirror-android.git --enable

Pick a bar section when prompted (right is the default). Then enable it later, move it, or change its position from Omarchy menu → Setup → Bar.

Remove

omarchy plugin remove sumiran.mirror-android

That deletes ~/.config/omarchy/plugins/sumiran.mirror-android/ and drops the widget from the bar. Nothing outside the plugin's own directory and its own shell.json bar entry is touched.

Requirements

  • Omarchy 4 (Quickshell-based shell) on Hyprland
  • scrcpy — not bundled, install with:
    omarchy pkg add scrcpy
    
  • android-tools (adb) — usually already present on Omarchy; if not:
    omarchy pkg add android-tools
    
  • An Android device with USB debugging (and, for wireless, Wireless Debugging) enabled in Developer options

How it works

Every action runs through one bundled script, bin/mirror-phone, which:

  1. Parses adb devices -l to detect connected USB/wireless devices and their state (ready, unauthorized, offline).
  2. On Pair/Connect, shells out to adb pair/adb connect with the address and code entered in the panel — arguments are passed as an argument array, never interpolated into a shell string, so typed input can't be interpreted as shell syntax.
  3. On Mirror, launches scrcpy detached (setsid ... &) with a flag set built from the chosen profile and the persisted Quality/Audio/Screen-off settings, so the panel never blocks for the length of a mirroring session.

Recommended: float the mirrored window

This plugin doesn't modify your Hyprland config automatically. Without a window rule, scrcpy's window may tile like any other window instead of floating. Add this to ~/.config/hypr/hyprland.lua for a floating, centered, freely resizable mirror window instead:

o.window({ class = "^(scrcpy)$" }, { float = true, size = { 420, 900 }, center = true })