| OLD | NEW |
| 1 # Copyright 2015 The LUCI Authors. All rights reserved. | 1 # Copyright 2015 The LUCI Authors. All rights reserved. |
| 2 # Use of this source code is governed by the Apache v2.0 license that can be | 2 # Use of this source code is governed under the Apache License, Version 2.0 |
| 3 # found in the LICENSE file. | 3 # that can be found in the LICENSE file. |
| 4 | 4 |
| 5 """GNU/Linux specific utility functions.""" | 5 """GNU/Linux specific utility functions.""" |
| 6 | 6 |
| 7 import os | 7 import os |
| 8 import pipes | 8 import pipes |
| 9 import platform | 9 import platform |
| 10 import re | 10 import re |
| 11 import shlex | 11 import shlex |
| 12 import subprocess | 12 import subprocess |
| 13 | 13 |
| (...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 'Type=Application\n' | 303 'Type=Application\n' |
| 304 'Name=%(name)s\n' | 304 'Name=%(name)s\n' |
| 305 'Exec=%(cmd)s\n' | 305 'Exec=%(cmd)s\n' |
| 306 'Hidden=false\n' | 306 'Hidden=false\n' |
| 307 'NoDisplay=false\n' | 307 'NoDisplay=false\n' |
| 308 'Comment=Created by os_utilities.py in swarming_bot.zip\n' | 308 'Comment=Created by os_utilities.py in swarming_bot.zip\n' |
| 309 'X-GNOME-Autostart-enabled=true\n') % { | 309 'X-GNOME-Autostart-enabled=true\n') % { |
| 310 'cmd': ' '.join(pipes.quote(c) for c in command), | 310 'cmd': ' '.join(pipes.quote(c) for c in command), |
| 311 'name': name, | 311 'name': name, |
| 312 } | 312 } |
| OLD | NEW |