Jump to content

Google Drive — List File Stream contents from Google Drive


Recommended Posts

5 hours ago, Le Tien said:

Tks you for your feedback, but when workflow cache file, will it affect writing GB to my SSD?

 

In any normal case, no. But nobody else can say how it will perform with your Google Drive.

Link to comment
  • 2 weeks later...

Hey @vitor thanks again for the awesome work. I have a weird situation. At some point G Drive probably had issues mounting the volume at /Volumes/Google\ Drive path and now it mounts them at random path like this: 

1051332217_CleanShot2022-01-26at16_31.53@2x.thumb.png.ec8de809a5dbe95efaf00c9eb22ecc32.png

 

I did have an orphan /Volumes/Google\ Drive folder, which I force deleted but after Google Drive restart it would still mount to that weird location. At I have a hunch the id in that string is actually changing form time to time 🤦

 

Now, when I point the workflow (using the variable) to the symlink at ~/Google\ Drive it would report that it works but in reality it skips the whole thing cause you have symlinks skipped here:

1899845035_CleanShot2022-01-26at16_34.17@2x.thumb.png.9a4c8c21e1d66f0a53e7b0d18a8c506b.png

 

Any chance this may become a workflow option or is there a reason I am missing for symlinks to be skipped all the time?

Link to comment
1 hour ago, mishamsk said:

is there a reason I am missing for symlinks to be skipped all the time?

 

It's the simplest way to handle them, tbh. If you process symlinks, you need logic and a bunch of memory to avoid any loops (i.e. a symlink that points to one of its own parent directories). There isn't really a good way to handle them, imo. Different users want them to be handled in different ways.

 

It sounds like you need to fix Google Drive, though: It seems unlikely that using the workflow is the only time you'll have issues with unstable GD paths.

Link to comment
23 hours ago, deanishe said:

 

It's the simplest way to handle them, tbh. If you process symlinks, you need logic and a bunch of memory to avoid any loops (i.e. a symlink that points to one of its own parent directories). There isn't really a good way to handle them, imo. Different users want them to be handled in different ways.

Does G Drive creates symlinks within its cache? DIdn't know that...

 

Quote

It sounds like you need to fix Google Drive, though: It seems unlikely that using the workflow is the only time you'll have issues with unstable GD paths.

You are right of course. But I am not hopeful when it comes to Google support. Didn't even bother trying to ask them how to fix that and why did it happen. Haven't noticed any problems besides alfred so far...

Link to comment

Hi Vitor, thank you so much for your work!

I'm not exactly an expert, but following your guide, I was able to have everything up and running.

 

I just need help now because it look like Alfred is looking for files only on My Drive folder. I share various folders (Shared drives) and if I try to to a search, they don't seem to be included.

 

Can you please give me an advice? Thank you so much

Link to comment

Hi,

 

I just downloaded the latest version of Alfred, Latest version of the workflow, lastest version of MacOS Monterey, all updated/uploaded yesterday.

 

When I run the :gdlaunchd I have in the notification the following message : "Google Drive Path Does not Exist".

 

From What I understood in previous posts, I need to change the path to google drive. Should I do it in the workflow or directly in the mac ?

 

Can you please let me know how can I fix it ?

 

I Have Only 1 google Drive synchronised with my mac, splitted in "personal drive" and "share drive". My Mac is in French.

 

Thanks,

Link to comment

Welcome @DomS,

 

3 hours ago, DomS said:

latest version of Alfred, Latest version of the workflow, lastest version of MacOS Monterey, all updated/uploaded yesterday.

 

Never say “latest” but always the exact version. With “latest” we don’t know if you mean the latest beta or stable version, nor do we know if you’re really on the newest version. You may think you’re up to date but be mistaken, or might be a version behind because the auto-update hasn’t kicked yet, or we may be on what we think is the latest version but isn’t, or a multitude of other reasons. “Latest” also makes it difficult for people who face the same issue later on and find the conversation, as they’ll have no idea if their version matches the one in the report.

 

3 hours ago, DomS said:

I need to change the path to google drive. Should I do it in the workflow or directly in the mac ?

 

That is covered in the second post, with links.

Link to comment

HI Vitor,

 

Ok Sorry for that.

I did what was suggested in the second post. I paste the outcome below. I seems that it gives you the exact version of every app/workflow/macOS version, (if not let me now).

 

When I look at the results, and compare what I have in my mac, it seems that I need to change the patch in the workflow as I want Alfred to look into my "shared drive" and not my "personal drive". When I check the "my information" folder I have this path : smb://localhost/Google Drive/Drive partagés/company_name this is the folder that I want Alfred to analyse.

 

Should I change in the Workflow ?

thanks for your support.

 

### Workflow version
2022.6

### Alfred version
4.6.2

### macOS version
12.2

### Workflow environment variables
Dict {
    ignore_list = 
    result_limit = 50
    google_drive_path = /Volumes/GoogleDrive/My Drive
}

### Google drive paths
Does NOT Exist: /Volumes/GoogleDrive/My Drive

### Cache dir
Files NOT present

### Cache file
Does NOT exist

### Temporary cache
Does NOT exist

### Build progress
NOT running

### Launchd job
NOT loaded
NOT installed
 

Link to comment

Hi Vitor,

It seems that it works.

thanks,

 

PS : A tips / comments. when I first started Alfred, notification was switch off. I was not understanding why I did not have any notifications ...

think to switch on notification, perhaps it can help others.

Link to comment
20 minutes ago, DomS said:

think to switch on notification, perhaps it can help others


I cannot force notifications on users, nor would I want to. Permissions for notifications is something you have to control yourself, and that is a good thing.

Link to comment

Hi Vitor,

 

Thanks for this amazing workflow!

 

I have a question.

I'm aware that it has been only tested with Google Drive,

but does it depend on any Google Drive-specific things, or do you think it will work with other virtual or network drives in general?

Link to comment
9 hours ago, Rooter said:

do you think it will work with other virtual or network drives in general?


I know it does and that there are people using it like that. As long as you can see the files in the Finder, they should be accessible via this Workflow, just change the directory.

 

But like you pointed out, this was made with one specific case in mind. It is optimised for that and is not guaranteed with anything else, because I haven’t tested every other provider.

Link to comment
12 hours ago, vitor said:


I know it does and that there are people using it like that. As long as you can see the files in the Finder, they should be accessible via this Workflow, just change the directory.

 

But like you pointed out, this was made with one specific case in mind. It is optimised for that and is not guaranteed with anything else, because I haven’t tested every other provider.

 

That sounds great. Thanks for the reply!

Link to comment

I'm having the same problem that others are - but I haven't seen a good answer or one that's helpful for those of us who don't know how to do anything in Github or whatever.

 

This works well for your personal Google MyDrive...but it's not pulling up ANY of the folders or files that are in my Google Shared Drives - which is what I need for work.

 

Has anyone figured out how to do this?

Link to comment

Welcome @adamwc,

 

As far as I’m aware, that question has been successfully answered every time it has been asked. You don’t need to do anything on GitHub. The method is covered in both the first and second posts. Both are incredibly short.


See the post from February 4 for an even shorter explanation. If you don’t know how to change that value, the second paragraph from the second post on this thread explains it.

Edited by vitor
Link to comment

Hi I have an error “Cache not found” after i installed it .
I removed it and reinstalled , relaunched :gdlaunchd and rebuild cache (which said cache rebuilt instantly, which is strange). I really would love to use this workflow. 
Any ideas?

Edited by alvint
Link to comment

### Workflow version
2022.7

### Alfred version
4.6.3

### macOS version
12.2.1

### Workflow environment variables
Dict {
    ignore_list = 
    result_limit = 50
    google_drive_path = /Volumes/GoogleDrive
}

### Google drive paths
Exists: /Volumes/GoogleDrive
200M
72349 paths

### Cache dir
Files NOT present

### Cache file
Does NOT exist

### Temporary cache
Does NOT exist

### Build progress
NOT running

### Launchd job
Loaded: -    0    com.alfredapp.launchd.googledrivecache
Installed


This is the diagnostic report.
I also got this error when I try to launch rebuild 

image.png.976dba0d416bcb04c9e537e52eb2dbb3.png

Link to comment
27 minutes ago, alvint said:

I also got this error when I try to launch rebuild

 

Uncertain how that happened (are you using Maestral, per chance?) but that needs fixing.


Right-click the Workflow in Alfred’s Preferences and “Open in Terminal”. Then execute the following:


chmod +x gd rebuild_cache


Then try again.

Link to comment

 

 

çI am getting these. Even terminating and restarting :gdlaunchd had the unable to run task error.image.png.32e4dafed3af823eb33c323a8a5fe562.pngimage.thumb.png.e88b5498d355a74d3e0b3da34ac95e21.png

 

Latest diagnostic here:

 

### Workflow version
2022.7

### Alfred version
4.6.3

### macOS version
12.2.1

### Workflow environment variables
Dict {
    ignore_list = 
    result_limit = 50
    google_drive_path = /Volumes/GoogleDrive
}

### Google drive paths
Exists: /Volumes/GoogleDrive
121M
72349 paths

### Cache dir
Files NOT present

### Cache file
Does NOT exist

### Temporary cache
Does NOT exist

### Build progress
NOT running

### Launchd job
Loaded: -    0    com.alfredapp.launchd.googledrivecache
Installed
 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...