jlgtx Posted December 20, 2022 Share Posted December 20, 2022 Quote That would require a huge database and essentially replicating a mini Spotlight. That's sort of exactly what this page claims that this plugin does. It's the very reason I spent the money to purchase Alfred in the first place. At the time, this was the only way to get any kind of Finder-level indexing of DFS. But now Google Drive has better Spotlight support than Alfred... Link to comment
vitor Posted December 20, 2022 Author Share Posted December 20, 2022 Have you tried the Search Scope resets (and then doing a normal search, without the workflow)? Link to comment
Henryy Posted December 27, 2022 Share Posted December 27, 2022 Hi @vitor, First of all, congratulations on the product 🙂 I was using Google Drive's workflow up until a few weeks ago, and then it stopped working for some reason. I just reinstalled the workflow, but I am unable to get it working again. I tried building the cache by hitting the option below, and also by running this command (:gdrebuildcache) in Alfred's search box. Could you let me know what else I need to do to get it working again? Thank you! Link to comment
vitor Posted December 28, 2022 Author Share Posted December 28, 2022 (edited) @Henryy Follow the steps in the second post and I’ll take a look. Edited December 28, 2022 by vitor Link to comment
vitor Posted December 28, 2022 Author Share Posted December 28, 2022 5 hours ago, Henryy said: Does NOT Exist: /Volumes/GoogleDrive Your Google Drive folder is not set correctly. Google probably updated you to the new version which changes its location. You’ll need to update it (instructions in previously linked post) for changes to continue to be detected. Link to comment
Henryy Posted December 28, 2022 Share Posted December 28, 2022 Thanks a lot, @vitor! It works again now 🙂 Link to comment
spencer Posted January 9, 2023 Share Posted January 9, 2023 Hi there — Vitor, thanks don't begin to describe my gratitude for this and the many other workflows you have created and maintain. A quick question / request on this Google Drive workflow: would it be possible to add-in fallback results to conduct a browser search on the Google drive page? That is, regardless of the query input, the last option in list of results would be "Search for {query} in browser" by dropping {query} into https://drive.google.com/drive/u/0/search?q={query} A little detail on why I think this would be helpful — my drive is comprised of a mix of files that I own and files that have been shared with me; the latter of which don't show up in my drive unless manually moved. However, searching the full google drive via browser results in the full scope being searched which helps me find files quicker. Link to comment
vitor Posted January 9, 2023 Author Share Posted January 9, 2023 Welcome @spencer, 1 hour ago, spencer said: Vitor, thanks don't begin to describe my gratitude for this and the many other workflows you have created and maintain. Thank you for the kind words! 1 hour ago, spencer said: would it be possible to add-in fallback results to conduct a browser search on the Google drive page? That makes perfect sense. When making a Google Drive search with gd or gdf one can already press ⇧↩ to search the match online. And the workflow also has Fallback Searches already, but they only do the equivalent of gd and gdf. So for consistency, I can make it so the Fallback Searches do an online search when pressing ⇧↩ as well. Like so. That version will be available to update from the Gallery soon. 1 hour ago, spencer said: A little detail on why I think this would be helpful Thank you as well for the details. Understanding the goals makes the solution more straightforward. spencer 1 Link to comment
spencer Posted January 9, 2023 Share Posted January 9, 2023 Thanks a lot, @vitor — can't believe you were able to pick that up so quick and update The ⇧↩ enabled on the Fallback Search is amazing and works exactly as I'd hoped! A follow up question on the ⇧↩ action when using gd — it appears to work only for when there's a match in the results populated via Script_filter_items. Would it be possible add a result at the end of that array that when actioned, conducts the search online? For example, if I have multiple documents in Google Drive with the word 'test' in title, it pops up the following results: However, when searching for test online, there are results that include 'test' in the document itself, or perhaps in titles of documents shared with me, etc. Therefore, by having an option accessible at the end of the search results shown, or via ⌘4 in this instance, I can quickly pop up that full view in the browser. I could of course get around this by just searching in the default Alfred bar, but my brain is trained pretty heavy on my shortcut to access the Google Drive workflow when looking for a particular document (and in the case that it's not in my drive folder, or the gd filter returns no results, I could then quickly conduct a full search online). Additionally, actioning the "Nothing Found" item in the results window with ⇧↩ doesn't appear to do anything either. Link to comment
cowansf Posted January 11, 2023 Share Posted January 11, 2023 Hi- Google Drive recently migrated all my files to 'Locations' on the Mac, apparently for compatibility. Now, the Workflow doesn't find anything and when I re-index it returns really fast- and so it seems like maybe it's not finding anything. Is there an update or do I need to reconfigure the Workflow somehow? Link to comment
vitor Posted January 11, 2023 Author Share Posted January 11, 2023 1 hour ago, cowansf said: do I need to reconfigure the Workflow somehow? Yes. The second post on the thread explains everything. Link to comment
vitor Posted January 11, 2023 Author Share Posted January 11, 2023 @spencer You can get that by setting Alfred to Intelligently show fallbacks at the end of results in Alfred Preferences → Default Results → Fallbacks. That said, I absolutely see the value in the idea. This version works like that. Consider it a trial run for the feature; a lot of people use the workflow and this can technically be achieved with the Fallback Results, so it may be removed depending on feedback. That said, even if it’s removed I see the sense in keeping it for the “Nothing found” case. Link to comment
vitor Posted January 11, 2023 Author Share Posted January 11, 2023 Updated to 2023.2.Append item at bottom of results to search online.Replace copy and move actions with Automation Tasks.General connection improvements. Link to comment
spencer Posted January 11, 2023 Share Posted January 11, 2023 1 hour ago, vitor said: This version works like that. You are a legend, @vitor — this version is perfect. I've been a powerpack user for over a decade (July 2012), and have relied on a variety of your workflows for most of that time. Thanks for all that you do and specifically thanks for the updates here! vitor 1 Link to comment
vitor Posted January 20, 2023 Author Share Posted January 20, 2023 Updated to 2023.3. Make setting drive folder required, to adapt to Google Drive rolling changes. Link to comment
JakeWright Posted January 26, 2023 Share Posted January 26, 2023 Hi, is there any way to have this workflow only index parts of my google drive? My entire google drive folder is big but I'd love to have it so only certain parts or certain folders are indexed. Thank you so much! Link to comment
vitor Posted January 26, 2023 Author Share Posted January 26, 2023 @JakeWright Edit the configuration to include only the folders you want. Link to comment
JakeWright Posted January 26, 2023 Share Posted January 26, 2023 Great, I changed the Google Drive Path to multiple subfolders instead and rebuilt the cache, thanks! Link to comment
benwhiting Posted February 6, 2023 Share Posted February 6, 2023 My Google Drive implemented a change this morning that relocated the shared folders to "Locations" within Finder. Apparently this broke the workflow, as I cannot rebuild the cache and my search will not open any formerly cached items now. It looks like perhaps this new location is being indexed by macOS, because I can find items in Spotlight now. But I changed the location in my workflow settings, and rebuild cache still isn't working. Is the Google Drive new "Locations" setup incompatible with this workflow? Link to comment
vitor Posted February 6, 2023 Author Share Posted February 6, 2023 @benwhiting Please see the debugging instructions. Two things to note regarding the indexing: The method the Google Drive app is using to show up in Spotlight is a different API. Results show up slower and they’re not added to the index with all other files. Some people have reported that with Google Drive’s switch to the macOS File Provider API, files now show under regular Alfred searches. It’s not yet clear why it’s not the same for everyone, but try that too: You may need to go into Alfred Preferences → Features → Default Results → Search Scope → Reset… (bottom right) and try some of the options. If it works, It’d be useful to know which of the settings made it work for you. Link to comment
benwhiting Posted February 6, 2023 Share Posted February 6, 2023 @vitor I added the new locations to the Alfred search scope, and after allowing some time to pass, my Drive items are now appearing in a regular Alfred file search. 👍 So I felt helpless to access files for a while when nothing was indexed, but now it looks like this might work pretty well for me... Link to comment
benwhiting Posted February 8, 2023 Share Posted February 8, 2023 The Drive update is working pretty well for me, though the frequency bias that Alfred assigns to regularly accessed items is still learning because I haven't accessed these files through normal file search before. I just wanted to say a huge thank you to you, @vitor for your work on this workflow. It was incredibly helpful to me while Google figured things out, as it allowed me to continue using Alfred for all my files, and it even helped me learn more about workflows in general so I could make small customizations. You're amazing! vitor 1 Link to comment
dam75 Posted February 10, 2023 Share Posted February 10, 2023 Hi everyone, for me, everything is broken since Drive update :gdrebuildcache fails, even with the correct Drive Path given (~/Library/CloudStorage/*****@*****.tld). it block on the gdrive_path.find.lazy.each which never returns : process last forever, I have to kill it manually ... same occurs for !gddiagnostic : it blocks on find "${google_drive_path}" | wc -l | tr -d ' \n' (If I comment this, I got a return). the Alfred File Search (so out of the workflow) is ok EXCEPT for the files in .shortcut-targets-by-id (those who are shared to me, but not on a Shared Drive). Unfortunality I've got a lot of them ... So I'm stuck with no solution for the moment. I wish Google would inform us of the changes and let us choose the version 😕 I hope that this so-fast-and-clever workflow will function again someday Link to comment
vitor Posted February 10, 2023 Author Share Posted February 10, 2023 Welcome @dam75, The workflow does work for thousands of people, I’ve never seen anyone with the errors you’re mentioning. Especially if you can’t run the diagnostic, something is quite atypical on your machine. Make sure Alfred has Full Disk Access and that you’re using the version from the Gallery. If you get the diagnostic by removing that line, then please provide that. Even incomplete information may provide a clue. Link to comment
dam75 Posted February 10, 2023 Share Posted February 10, 2023 19 minutes ago, vitor said: If you get the diagnostic by removing that line, then please provide that. Even incomplete information may provide a clue. Thank you so much for your quick answer ! Here is the diagnostic informations, with the "find" removed ^^ Yes, Alfred have a full disk access ... ### Workflow version 2023.3 ### Alfred version 5.0.6 ### macOS version 13.1 ### Architecture arm64 ### Preferences Dict { auto_refresh = false google_drive_path = /Users/xxxx/Library/CloudStorage/*****@*****.tld search_keyword = '' result_limit = 50 ignore_list = .Encrypted/ } ### Full Disk Access Granted ### Google drive path Exists: /Users/xxxx/Library/CloudStorage/*****@*****.tld paths ### 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
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now