I want to get access to the files in the Google Drive's "Shared with me" directory.
In the Colab python notebook the following commands:
import os
from google.colab import drive
drive.mount('/content/drive')
!ls "/content/drive/My Drive"
work well for "My Drive" directory however
!ls "/content/drive/My Drive"
fails with
FileNotFoundError: [Errno 2] No such file or directory:
I am aware of the fact that I can add the folder to my drive manually and proceed (as mentioned in here), but I would like to have direct access to the shared folders for lets say I might need to automate the work with files that are shared with me real time.
I am also aware that same/similar problem exist with other cloud platforms like "OneDrive".
The questions are:
- if there is no straightforward way of doing it, is there at least a workaround?
- do the people I share my code with get access to my drive too?
ls "/content/drive/My Drive"
doesn't look like a valid python statement – Naomanaomils "/content/drive/My Drive"
have an exclamation mark before it, since we are in a notebook context? – Vietnam