Overview
| Comment: | Fixed some pylint warnings |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
0fda55579ae3f9b9befbd14b83d03654 |
| User & Date: | vitus on 2016-04-05 13:37:15.979 |
| Other Links: | manifest | tags |
Context
|
2016-04-07
| ||
| 13:53 | Written autostart command check-in: 1d444062a8 user: vitus tags: trunk | |
|
2016-04-05
| ||
| 13:37 | Fixed some pylint warnings check-in: 0fda55579a user: vitus tags: trunk | |
|
2016-03-24
| ||
| 07:34 | Added sendkey command check-in: 50904ddda0 user: vitus tags: trunk | |
Changes
Modified vws
from [ef68b74609]
to [047d8f3ad1].
1 2 3 | 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 26 27 28 29 30 | - - + | #!/usr/bin/python """ vws - script to control QEMU/KVM virtual workstations """ # pylint: disable=bad-builtin |
| ︙ | |||
356 357 358 359 360 361 362 | 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 | - - + + |
print >>sys.stderr, "No sound recording in progress"
sys.exit(1)
else:
print send_command(options.sock, "stopcapture " + match.group(1))
def cmd_sendkey(options):
""" vws sendkey """
|
| ︙ | |||
507 508 509 510 511 512 513 | 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 | - + |
-device usb-redir,chardev=usbredirchardev1,id=usbredirdev1 \\
-daemonize -pidfile pid
"""
def cmd_create(parsed_args):
""" vws create - create new VM """
BADSIZE = "Invalid size of %s specifed %s. Should have K, M or G suffix"
|
| ︙ | |||
543 544 545 546 547 548 549 | 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 | - + |
print >>sys.stderr, ("No such bridge %s. Available ones %s" %
(parsed_args.net, ", ".join(bridges)))
sys.exit(1)
options["net"] = ("-net nic,macaddr=%s -net bridge,br=%s" %
(macaddr, parsed_args.net))
else:
options["net"] = "-net nic,macaddr=%s -net user" % (macaddr,)
|
| ︙ | |||
576 577 578 579 580 581 582 | 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 | - + |
"something on the way")
sys.exit(1)
# Creating directory for VM
os.makedirs(machinedir, dirmode)
driveopts = {"interface":parsed_args.diskif, "image":drivename}
if parsed_args.install:
install_image = os.path.abspath(parsed_args.install)
|
| ︙ | |||
715 716 717 718 719 720 721 | 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 | - + |
# Screenshoits and recording
p = new_command(cmds, 'screenshot', help='take a screenshot')
p.add_argument('filename', help='PPM image filename to write screenshot to')
p = new_command(cmds, 'record', help='Record audio output from VM')
p.add_argument('filename', help='wav file to record autdio to')
new_command(cmds, 'stoprecord', help='stop recording audio')
p = new_command(cmds, 'sendkey', help='Send a keystroke to VM')
|
| ︙ |