You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using the CLI to change the identifier of a particular bundle using the command packagesutil --file <pkgproj path> set package-<index> identifier <string>
any valid string returns the error "packagesutil: Low memory"
Examples of strings tested include defaultIdentifier and com.mypackage.pkg.application, in the format packagesutil --file <pkgproj path> set package-1 identifier defaultIdentifier. These are valid identifiers when using the GUI to save the pkgproj, but do not work from the CLI using the above command.
Possible Cause:
The pertinent line in PUUtilities.m may have a bug. Please see
This is where the "packagesutil: Low memory" error arises.
Possible Solution:
It seems that if (tFormatter!=nil) may need to be if (tFormatter==nil) instead. When PKGBundleIdentifierFormatter initializes, it stores NSCharacterSet * _forbiddenCharacterSet;. It may be that if packagesutil is truly out of memory and PKGBundleIdentifierFormatter was not able to initialize properly, then the stored value will be nil. In this case, a properly initialized PKGBundleIdentifierFormatter would always trigger the error condition, which seems consistent with current symptoms.
Request:
Would it be possible to check this issue, or otherwise resolve why the CLI can't be used to rename bundle identifiers? This is a very useful functionality for automating packaging workflows with Packages.
Thank you for your help!
The text was updated successfully, but these errors were encountered:
Issue:
When using the CLI to change the identifier of a particular bundle using the command
packagesutil --file <pkgproj path> set package-<index> identifier <string>
any valid string returns the error
"packagesutil: Low memory"
Examples of strings tested include
defaultIdentifier
andcom.mypackage.pkg.application
, in the formatpackagesutil --file <pkgproj path> set package-1 identifier defaultIdentifier
. These are valid identifiers when using the GUI to save the pkgproj, but do not work from the CLI using the above command.Possible Cause:
The pertinent line in PUUtilities.m may have a bug. Please see
packages/packagesutil/packagesutil/PUUtilities.m
Lines 450 to 454 in b195cf8
Possible Solution:
It seems that
if (tFormatter!=nil)
may need to beif (tFormatter==nil)
instead. When PKGBundleIdentifierFormatter initializes, it storesNSCharacterSet * _forbiddenCharacterSet;
. It may be that if packagesutil is truly out of memory and PKGBundleIdentifierFormatter was not able to initialize properly, then the stored value will be nil. In this case, a properly initialized PKGBundleIdentifierFormatter would always trigger the error condition, which seems consistent with current symptoms.Request:
Would it be possible to check this issue, or otherwise resolve why the CLI can't be used to rename bundle identifiers? This is a very useful functionality for automating packaging workflows with Packages.
Thank you for your help!
The text was updated successfully, but these errors were encountered: