File: run

package info (click to toggle)
scrcpy 3.3.4-1
  • links: PTS, VCS
  • area: contrib
  • in suites: sid
  • size: 2,832 kB
  • sloc: ansic: 22,489; java: 10,142; sh: 953; xml: 94; makefile: 30
file content (25 lines) | stat: -rwxr-xr-x 562 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/usr/bin/env bash
# Run scrcpy generated in the specified BUILDDIR.
#
# This provides the same feature as "ninja run", except that it is possible to
# pass arguments to scrcpy.
#
# Syntax: ./run BUILDDIR <scrcpy options ...>
if [[ $# = 0 ]]
then
    echo "Syntax: $0 BUILDDIR <scrcpy options>" >&2
    exit 1
fi

BUILDDIR="$1"
shift

if [[ ! -d "$BUILDDIR" ]]
then
    echo "The build dir \"$BUILDDIR\" does not exist." >&2
    exit 1
fi

SCRCPY_ICON_PATH="app/data/icon.png" \
SCRCPY_SERVER_PATH="$BUILDDIR/server/scrcpy-server" \
"$BUILDDIR/app/scrcpy" "$@"