Repository navigation
Conversation
Add -s auto-complete option.
rom1v
reviewed
Oct 7, 2022
rom1v
left a comment
Collaborator
There was a problem hiding this comment.
Awesome, thank you. ð
Could you also add it to the zsh completion script?
| ;; | ||
| -s|--serial) | ||
| # Use 'adb devices' to list serial numbers. | ||
| COMPREPLY=($(compgen -W "$(adb devices | awk '/(device|recovery|sideload)$/{print $1}')" -- ${cur} ) ) |
Collaborator
There was a problem hiding this comment.
I think that scrcpy may not work in recovery or sideload state, so maybe adb devices |awk '/device$/{print $1}' is sufficient.
since scrcpy don't work in sideload and recovery options, I've removed them.
rom1v
reviewed
Oct 7, 2022
| -s|--serial) | ||
| # Use 'adb devices' to list serial numbers. | ||
| COMPREPLY=($(compgen -W "$(adb devices | awk '/(device|recovery|sideload)$/{print $1}')" -- ${cur} ) ) | ||
| COMPREPLY=($(compgen -W "$(adb devices | awk '/device$/{print $1}')" -- ${cur} ) ) |
Collaborator
There was a problem hiding this comment.
Also, if the ADB environment variable is set, this adb should be used instead.
"${ADB:-adb}" devices | awk âĶ
rom1v
pushed a commit
that referenced
this pull request
Oct 7, 2022
Add -s autocompletion for zsh
Contributor
Author
|
Ok. I've added a similar solution to the zsh completion. :) |
rom1v
pushed a commit
that referenced
this pull request
Oct 12, 2022
rom1v
pushed a commit
that referenced
this pull request
Oct 12, 2022
rom1v
pushed a commit
that referenced
this pull request
Oct 12, 2022
Collaborator
|
Thank you ð I rebased your commits onto
I pushed to branch |
Contributor
Author
|
Checked. Many thanks ð :) |
Collaborator
|
Thanks ð Merged into |
Linux4
pushed a commit
to Linux4/scrcpy
that referenced
this pull request
Sep 5, 2025
scrcpy v1.25 Changes since v1.24: - Adapt copy-paste internals for Android 13 (Genymobile#3497) - Add support for high-precision scrolling (Genymobile#3363, Genymobile#3369) - Add desktop entry files for Linux (Genymobile#295, Genymobile#296, Genymobile#748, Genymobile#1636, Genymobile#3351) - Add bash and zsh autocompletion for -s/--serial (Genymobile#3522, Genymobile#3523) - Use current adb port (if any) for --tcpip (Genymobile#3591, Genymobile#3592) - Add fallback to get display information on some devices (Genymobile#3416, Genymobile#3573) - Fix click behavior when --forward-all-clicks is set (Genymobile#3568, Genymobile#3579) - Fix support for non-ASCII characters in window title (Genymobile#2932, Genymobile#3547) - Fix getDisplayIds() crash on some versions of Android 13 beta (Genymobile#3446) - Upgrade platform-tools to 33.0.3 (adb) in Windows releases - Upgrade FFmpeg to 5.1.2 in Windows 64-bit releases - Upgrade SDL to 2.26.1 in Windows releases - Various technical fixes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add -s auto-complete option.
Commented at the following issue: #3522