Get the command from the name of a script.
(path)
| 8 | IS_GITHUB_ACTIONS = bool(os.environ.get('GITHUB_ACTIONS')) |
| 9 | |
| 10 | def get_cmd(path): |
| 11 | """Get the command from the name of a script.""" |
| 12 | dname, fname = basename(dirname(path)), splitext(basename(path))[0] |
| 13 | if dname in ('devel', 'fix', 'gui', 'modtools'): |
| 14 | return dname + '/' + fname |
| 15 | return fname |
| 16 | |
| 17 | |
| 18 | def print_error(message, filename, line=None): |