How to shuffle PDF pages in Automator?

It seems that the usual method of shuffling pages in Automator no longer works due to updates from Apple breaking some functionality...


Previously I was using:

  • Get Specified Finder Items
  • Combine PDF Pages / Shuffling Pages
  • Move Finder Items / to specific folder
  • Rename Finder Items / append "_SHUFFLED"


But now that saved workflow returns an error:

  • The operation couldn't be completed. Command line tool returned error 127.: 127


What other options are there for shuffling PDF pages through Automator or AppleScript?

iMac 27″, macOS 12.6

Posted on May 26, 2023 07:54 AM

Reply
Question marked as Top-ranking reply

Posted on May 26, 2023 09:10 AM

I have a folder named PDF on my Desktop. I choose several multi-page PDFs from another location, and the following workflow on Ventura 13.4 produces a shuffled PDF.




The Combine PDF action worked on Monterey until Apple removed the Python 2 distribution from Monterey 12.3, thus breaking that Python scripting dependency in this Automator action. It was never fixed in subsequent updates of Monterey, there is no alternative solution, and you would need to upgrade to Ventura 13.4 to have this functionality restored in Automator. Apple replaced the Python 2 dependent functionality with a compiled Swift application in Ventura.

Similar questions

2 replies
Question marked as Top-ranking reply

May 26, 2023 09:10 AM in response to c_warwick

I have a folder named PDF on my Desktop. I choose several multi-page PDFs from another location, and the following workflow on Ventura 13.4 produces a shuffled PDF.




The Combine PDF action worked on Monterey until Apple removed the Python 2 distribution from Monterey 12.3, thus breaking that Python scripting dependency in this Automator action. It was never fixed in subsequent updates of Monterey, there is no alternative solution, and you would need to upgrade to Ventura 13.4 to have this functionality restored in Automator. Apple replaced the Python 2 dependent functionality with a compiled Swift application in Ventura.

May 26, 2023 09:33 AM in response to VikingOSX

Ah.. well, sadly updating to Ventura isn't available option at this point in time.


I'll fall back onto a brute force method of manually splitting the pages of two source files into individual documents, renaming the pages from one with sequential odd numbers, and the other as sequential even numbers, then combining those into a single document.


Thank you for the explanation of why it doesn't work, though.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

How to shuffle PDF pages in Automator?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.