Jump to content

vitor

Staff
  • Posts

    8,471
  • Joined

  • Last visited

  • Days Won

    706

Posts posted by vitor

  1. Connect the Hotkey to a Dispatch Key Combo Output that performs a ⌘C, thus getting the current selection to the clipboard with that information. Do note that what’s stored in Clipboard History is plain text, so if you change to another item and back, it will have lost the formatting. If you have Alfred Preferences → Features → Clipboard History → Merging turned on, you may need to add a short delay so it doesn’t append to the previous entry.

  2. Welcome @Mark Reeves,

     

    Please add your exact installed versions of Alfred, macOS, and KeePassXC.

     

    Alfred doesn’t have a reason to switch your app if you’re opening it with the regular method, because all Alfred does is ask macOS to open the app. By the time the app opens, Alfred is no longer involved. But maybe you have a workflow which opens the app and then does something else, or a trigger somehow activated by some combination of characters, or something of the like. Note also that there are many people who use both apps, but this is the first time I remember seeing the error, so there’s also the possibility that some third thing on your machine is causing the problem. The next step is to figure out the reproduction steps exactly, which is why knowing the versions is imperative.


    For example, what I’d recommend you do next is launch KeePassXC but not start typing your password. See if it switches then. If it doesn’t, that’s another clue. Then start typing your password slowly. Does it always switch back after two characters, or is it after a set amount of time, or something else? Those are the kind of things to be on the look out for to find the exact issue.

  3. Not Action in Alfred, but Universal Action. You use it as the trigger, not as the result.

     

    To the conversation above, the Is File? Automation Task is not meant to check if a random string is a file, it checks if an existing path is a file as opposed to a folder. To check if a given path exists you could use the File Conditional. But Universal Actions, as per @Stephen_C’s suggestion, are what I’d recommend too. That way you don’t have to worry about checking what the type is, Alfred does it for you.

  4. 15 hours ago, andy4222 said:

    the system clipboard has the image/file

     

    It has a reference to the file, which Notes is interpreting and embedding. You can verify this by deleting the file after copying it. It won’t be embedded in the note.
      
    The example from Safari is one where you copied the image data itself. Which is why it says 3.0MB, that’s how much space it is taking. To save the image data to the clipboard, there’s an Automation Task for that. Or like @Stephen_C pointed out, you can open the image in Preview, then copy the image data there. This is standard behaviour which was not modified.

     

    Either way, from the behaviour you’re seeing you appear to have turned off Alfred Preferences → Features → Clipboard History → History → Keep File Lists.

  5. On 3/9/2024 at 2:16 PM, LeifJP said:

    I'm using a Mac M1 running macOS 14.4 with Python installed via Homebrew

     

    Use the system Python, otherwise your virtual environment will break when that Python is updated.

     

    On 3/9/2024 at 2:16 PM, LeifJP said:
    url={query}

     

    Always prefer with input as argv over with input as {query}.

     

    On 3/9/2024 at 2:16 PM, LeifJP said:
    # deactivate the virtual environment
    deactivate

     

    Not harmful but not strictly necessary since it does not affect the rest of the script. Depending on how slow that action is, you may notice a speed increase by not including that.

     

    On 3/9/2024 at 2:16 PM, LeifJP said:

    another way to approach this issue?

     

    Another way to include a Python package with a workflow is to use the --target option and set PYTHONPATH. StackOverflow has other options. Make sure to install with /usr/bin/python3 so packages are built with the system python.

  6. Welcome @DED,

     

    When reporting issues, please include your exact installed versions of:

    • The Workflow.
    • Alfred.
    • macOS.

    In addition to:

    • The debugger output. Perform the failing action, click “Copy” on the top right and paste it here.
    • Details on what you did, what happened, and what you expected to happen.

    That information is crucial to understand what could be going on.

     

    Same thing for any other workflow you’re having trouble with. Also, make sure to look in the Alfred Gallery as well, as workflows which are no longer maintained may have alternatives there.

  7. Fetch one result at a time and use the rerun key from the JSON to rerun the code. Keep track of what you have using environment variables, which you can set and read back. There is an example workflow with a counter which you can access from the + in the workflows list.

×
×
  • Create New...