Shared Drive Permission to Print

238 views
Skip to first unread message

Don Beck

unread,
Apr 29, 2022, 10:16:04 AM4/29/22
to GAM for Google Workspace
I have a shared drive that contines hundreds of files.  The root folder has the permission for viewers to print turned on but I have discovered that some individual files in this folder have that permission turned off at the file level.  I'm looking for a command that can go thru the root folder and all it's subfolders and turn on the printing feature for all files at the file level.

James SEYMOUR

unread,
May 10, 2022, 12:08:32 AM5/10/22
to GAM for Google Workspace
Hi Don,

I tried using gam user <Manager Email Address> update teamdrive <Shared Drive ID> copyrequireswriterpermission false but that seems to just set the top level setting. Please note that for the option copyrequireswriterpermission false, false = ticked. So I think this setting needs to be set on each file, unless there is a way to set this recursively.

gam user <Manager Email Address> print filelist select teamdriveid <Shared Drive ID> fields id,name,copyrequireswriterpermission todrive will create a Google Sheet of the files in Shared Drive. I have added the name & copyrequireswriterpermission fields so that you can review the Google Sheet if needed.

gam csv gsheet <Your Email Address> <Google Sheet ID created from Above Command> <Sheet (Tab) Name> gam user <Manager Email Address> update drivefile ~id copyrequireswriterpermission false will then change all the files in the Google Sheet created above.

If you are happy with these 2 commands then you can combine together as gam user <Manager Email Address> print filelist select teamdriveid <Shared Drive ID> fields id,name,copyrequireswriterpermission | gam  csv - gam user <Manager Email Address> update drivefile ~id copyrequireswriterpermission false

This should work and do what you want, but please make sure you are happy with it before running.

Cheers

James
Reply all
Reply to author
Forward
0 new messages