-
-
Save danjargold/c6542e68fe3a3b46eeb0172f914641bc to your computer and use it in GitHub Desktop.
Its me again :) I checked a little bit and it seems, that the function .getFolders() gives you ALL the children, not only the immediate children. This is maybe backed with this entry: https://stackoverflow.com/questions/41741520/how-do-i-search-sub-folders-and-sub-sub-folders-in-google-drive
So I think the whole subfolder part is obsolete. I commented it out and used for excluding the getParents() function. I dont know if you are interested in further developing your script. If so, I hoped this helps.
Cheers
Linos
The code throws an error when I try to run it... it says there is a problem with line 40.
The file or folder has invalid access settings. (line 40, file "Code")
Any suggestions?
The code throws an error when I try to run it... it says there is a problem with line 40.
The file or folder has invalid access settings. (line 40, file "Code")
Any suggestions?
I commented out lines 42 and 43 and it seemed to work:
file.getSharingAccess()
file.getSharingPermission()
Code throws "Exception: The file or folder has invalid access settings." on the sharing permissions instructions. Discovering files with particular sharing permissions is the point of the code. How can the code anticipate, capture, and continue?
Hey,
Thanks a lot for this, it helped me a lot.
I've made some improvments, so it's harder to timeout when there are lots of files involved.
(it took me about 3min for 500 files instead of timing out at 6mn).
I just cached all the files in a list and flushed them all at once into the spreadsheet instead of calling the API for each files.
you can check that out here : https://github.com/moya-a/G-Drive-SharedFiles-Checker
Cheers :)
Hey thank you for that script, it is really close to what I was searching for. I cant believe, that google hasnt it build in.
I added a column with the name of the containing folder, which seemed usefull to me. Maybe you want to add this in your code? I am quite new to github, so I dont know where to add this as a pull request.
...,"Size", "Folder", "URL",...
folder.toString(),
I do have one question though. I run the script with the function listFolders as the chosen function. But it doesnt stop. What am I doing wrong? The sheet is produced and fine. Because I have only two folders yet, with around 20 files, there is no reason for it to not stop. Maybe it is because it searches in my pictures as well. Is there a fast way to exclude specific folders from the search path?