2024-04-26 21:10:58 +00:00
|
|
|
#! /usr/bin/env python3
|
|
|
|
|
2024-04-26 21:16:11 +00:00
|
|
|
import os
|
2024-04-26 21:10:58 +00:00
|
|
|
import sys
|
|
|
|
|
2024-04-26 19:58:35 +00:00
|
|
|
import cd
|
|
|
|
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
2024-04-26 21:55:20 +00:00
|
|
|
command, *arguments = sys.argv
|
2024-04-26 21:10:58 +00:00
|
|
|
command = os.path.basename(command)
|
2024-04-26 21:24:46 +00:00
|
|
|
if command == '__main__.py':
|
2024-05-30 22:29:12 +00:00
|
|
|
cd.set_ssh()
|
2024-04-26 21:24:46 +00:00
|
|
|
cd.install_commands(__file__)
|
|
|
|
else:
|
2024-04-26 21:55:20 +00:00
|
|
|
command = command.replace('-', '_')
|
|
|
|
function = getattr(cd, command)
|
|
|
|
function(*arguments)
|