Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
UserConfig
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jiří Kalvoda
UserConfig
Commits
fb961ca0
Commit
fb961ca0
authored
1 year ago
by
Jiří Kalvoda
Browse files
Options
Downloads
Patches
Plain Diff
VM waydroid-run
parent
bc86e272
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
vm/init-waydroid.sh
+8
-0
8 additions, 0 deletions
vm/init-waydroid.sh
vm/waydroid-run.py
+38
-0
38 additions, 0 deletions
vm/waydroid-run.py
with
46 additions
and
0 deletions
vm/init-waydroid.sh
0 → 100755
+
8
−
0
View file @
fb961ca0
#!/bin/bash
cd
"
$(
dirname
"
$0
"
)
"
.
../userconfig-lib.sh
install_begin
confln waydroid-run.py ~/bin/ E
install_ok
This diff is collapsed.
Click to expand it.
vm/waydroid-run.py
0 → 100644
+
38
−
0
View file @
fb961ca0
#!/bin/python3
import
os
,
sys
,
subprocess
import
time
,
select
import
select
app_name
=
sys
.
argv
[
1
]
if
len
(
sys
.
argv
)
>=
2
else
None
session
=
None
def
init
():
global
session
session
=
subprocess
.
Popen
([
"
waydroid
"
,
"
session
"
,
"
start
"
],
stderr
=
subprocess
.
PIPE
)
time
.
sleep
(
0.1
)
p
=
subprocess
.
run
([
"
waydroid
"
,
"
show-full-ui
"
])
def
clean
():
subprocess
.
run
([
"
waydroid
"
,
"
session
"
,
"
stop
"
])
session
.
communicate
()
init
()
while
True
:
poll
=
select
.
poll
()
poll
.
register
(
session
.
stderr
.
fileno
(),
select
.
POLLIN
)
poll
.
register
(
sys
.
stdin
.
fileno
(),
select
.
POLLIN
)
for
fd
,
event
in
poll
.
poll
():
if
fd
==
sys
.
stdin
.
fileno
():
inp
=
input
()
print
(
"
STDIN
"
,
inp
)
if
inp
==
"
reload
"
:
clean
()
init
()
if
fd
==
session
.
stderr
.
fileno
():
print
(
"
SESSION
"
)
l
=
session
.
stderr
.
readline
().
strip
().
decode
(
"
utf-8
"
)
print
(
l
)
if
l
.
endswith
(
"
Android with user 0 is ready
"
):
if
app_name
:
p
=
subprocess
.
run
([
"
waydroid
"
,
"
app
"
,
"
launch
"
,
app_name
])
p
=
subprocess
.
run
([
"
waydroid
"
,
"
show-full-ui
"
])
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment