add support for Drive shortcut creation

This commit is contained in:
Jay Lee
2020-10-09 10:31:21 -04:00
parent 146db31cb5
commit 07c57d4197
2 changed files with 17 additions and 11 deletions

View File

@ -3543,6 +3543,10 @@ def getDriveFileAttribute(i, body, parameters, myarg, update=False):
else:
controlflow.invalid_argument_exit(
restriction, f'gam <users> {operation} drivefile')
elif myarg == 'shortcut':
body['mimeType'] = MIMETYPE_GA_SHORTCUT
body['shortcutDetails'] = {'targetId': sys.argv[i+1]}
i += 2
else:
controlflow.invalid_argument_exit(
myarg, f"gam <users> {operation} drivefile")