I did what Arno suggested (thank you) and I now have a requested.txt file that, 
as far as I can tell, is a good representation of both:

• The ports I migrated to this machine when I first set it up last October.
• The ports that I later installed.

What I still don’t understand is what happened to the ports that I either 
migrated or installed?

Many of them simply disappeared after I upgraded to Sequoia and used the new 
MacPorts migration procedure.

Fifteen:desktop mnewman$ xargs -n1 sudo port setrequested < old_requested.txt
Password:
Error: exiftool is not installed
Error: jshon is not installed
Error: lynx is not installed
Error: mailutils is not installed
Error: msmtp is not installed
Error: nano is not installed
Error: nbsmtp is not installed
Error: tree is not installed

(old_requested.txt is the file I used to migrate to the new machine and which I 
recovered from TimeMachine.)

Where did they all go?

> On Sep 23, 2024, at 21:33, Arno Hautala <[email protected]> wrote:
>
> I think an easier way to resolve the missed requested items would be with:
>
> xargs -n1 sudo port setrequested < requested.txt
>
> The ‘-n1’ tells xargs to execute the command once for each argument. It will 
> be less efficient because you’re starting up the port command multiple times, 
> but you’ll only be missing the failed ports.
>
> MacPorts doesn’t keep a history of installed ports, so the currently 
> installed / requested is the best you can do at any given time. And your 
> TimeMachine requested.txt is the best you’ll get for the past.
>
> Any manually installed ports should already be marked as requested.
>
>> On Sep 23, 2024, at 06:05, Michael Newman via macports-users 
>> <[email protected]> wrote:
>>
>> After yesterday’s partially unsuccessful migration, I noticed that some 
>> ports that I had previously installed were missing after the migration, even 
>> though there was no error message during “sudo port migrate” on any of the 
>> missing ports. For example, I have several shell scripts that use “sponge” 
>> which is found in moreutils. Those scripts started failing after the 
>> migration yesterday:
>>
>> /Users/mnewman/bin/remove_jpg.sh: line 23: /opt/local/bin/sponge: No such 
>> file or directory
>>
>> I ran this: port echo requested | cut -d ' ' -f 1 | uniq > requested.txt and 
>> found that it only contained the following ports:
>>
>> aom
>> ffmpeg
>> ImageMagick
>>
>> Those are all ports that I installed manually after the migration partially 
>> failed.
>>
>> I used TimeMachine to find the previous requested.txt file and see that it 
>> contains the following:
>>
>> bash
>> curl
>> exiftool
>> ffmpeg
>> ImageMagick
>> jshon
>> lynx
>> mailutils
>> moreutils
>> msmtp
>> nano
>> nbsmtp
>> tree
>>
>> I’ve read this:
>>
>>    •
>>        • Note: ports that are not available on your new platform will be 
>> skipped, with only a warning message.
>>        • Restore requested status: If you saved the list of requested ports, 
>> you can now restore the requested flags for your newly installed ports to 
>> their former states.sudo port unsetrequested installed
>> xargs sudo port setrequested < requested.txt
>>
>> Warning: if a port in requested.txt was not installed in the previous step, 
>> the iterative setrequested will terminate, leaving some ports still marked 
>> as not-requested. Edit requested.txt to remove any ports that were not 
>> installed and repeat this step. Double-check your desired ports are set as 
>> requested with port echo requested.
>> And don’t understand it at all.
>>
>> What do I need to do to get a list of all the ports that I have requested in 
>> the past? Or, is the TimeMachine resurrection the best I can do; even though 
>> I’m sure I’ve installed several ports since the resurrected requested.txt 
>> file was created.
>>
>> Please excuse my ignorance in these matters. I’ve been a MacPorts user for a 
>> long time, but don’t know much about it. I’ve done many migrations both 
>> after OS updates and from machine to machine and have always had success. 
>> This has been a confusing experience.
>>
>> Mike Newman
>> Korat, Thailand
>>
>>
>
> --
> arno  s  hautala    /-|   [email protected]
>
> pgp b2c9d448
>
>
>
>

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to