2

With Google File Stream, you can right-click on a given file/directory in Finder and click "copy link to clipboard" from the contextual menu. Is it possible to recreate this programmatically, given the file's path?

My end goal is to create an Alfred workflow, so solutions involving bash/zsh, applescript, or python would all work.

I'm imagining something that looks kind of like filename | getfilepath...

Rafa Guillermo
  • 14,474
  • 3
  • 18
  • 54
  • Is the `pyperclip` module not suitable for this? It only handles plain text according to the documentation (https://pypi.org/project/pyperclip/) but it's compatible with both python 2 and python 3. If you're on MacOS it will utilise `pbcopy` and `pbpaste` but it doesn't need additional modules in Windows. – Rafa Guillermo Jun 21 '19 at 14:36
  • sorry – been away from SO for a bit. that would work fine, but the missing piece is still how to access _the google link itself_ (either in python or bash)... – defenestrated Aug 19 '19 at 19:53

0 Answers0