Jump to content

justnp

Member
  • Posts

    3
  • Joined

  • Last visited

justnp's Achievements

Helping Hand

Helping Hand (3/5)

0

Reputation

  1. Any way you have an active link to this? Would love to play around with it! Thanks
  2. Wow, you were right. I just assumed that it was actually zipped since it was a .zip file. By just removing the .zip from the name of the file, that allowed for me to install it while keeping all of the images intact. Thank you!
  3. Short story, I backed up my Alfred workflows in my google drive, and now when I try to download them, they all come in form of zipped files. I've read here that you can convert the .alfredworkflow.zip file back into an .alfredworkflow file which I've managed to do but when I try to install the workflow, none of the workflows have their respective pictures saved (if I tried to do this manually for ~ 40 - 50 workflows, it would take ages). Any thoughts on how to easily fix this / automate this? I've tried writing a Python script but even using the subprocess module to run bash commands messes up the workflow when trying to zip the info.plist file. I'd greatly appreciate any thoughts on this and any ideas! Even after doing this and I try to install through info.alfredworkflow, it complains and gives a message "The workflow you are trying to import is invalid." I'm honestly not sure what to do at this point. import os import subprocess # SINGLE os.chdir("...") # change to directory that contains the .alfredworkflow.zip files for f in os.listdir(os.getcwd()): if len(f.split(".alfredworkflow.zip")) == 2: path = os.getcwd() + "/" + f subprocess.run(["unzip", path, "-d", os.getcwd() + "/" + f.split(".zip")[0]]) dirs = list(filter(os.path.isdir, os.listdir(os.getcwd()))) # ZIP for folder in dirs: if len(folder.split(".alfredworkflow")) == 2: path = os.getcwd() + "/" + folder + "/info.plist" subprocess.run(["zip", path + ".zip", path]) # RENAME for folder in dirs: if len(folder.split(".alfredworkflow")) == 2: path = os.getcwd() + "/" + folder + "/info.plist.zip" subprocess.run(["mv", path, os.getcwd() + "/" + folder + "/info.alfredworkflow"])
×
×
  • Create New...