Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

UserPrefs being overwritten, but not read

Discussion in 'macOS' started by AMA_MR, Aug 6, 2018.

  1. AMA_MR

    AMA_MR

    Joined:
    Mar 23, 2018
    Posts:
    17
    Hi there-

    Like the title says, I'm running into a problem where the User-Prefs .plist file under ~/Library/Preferences/ is being overwritten when the app starts up, but any changes I make to the file (e.g, current username) are not being picked up by the app itself on startup- they just disappear from the file. It seems like either some information must be missing from the documentation or else I'm missing something? Any pointers?

    Cheers, MA
     
  2. madleen_unity

    madleen_unity

    Unity Technologies

    Joined:
    Aug 28, 2018
    Posts:
    17
    Hi MA,

    The correct .plist is stored under ~/Library/Preferences/ as you mentioned.
    However there is a process running in the background that will invalidate any additions or changes directly to the .plist from outside the app.

    1) Close Unity.
    2) Open the terminal and add:
    kill $(ps x | awk '/[c]fprefsd/{ print $1 }')
    and hit enter.
    3) Modify/add then stuff to the .plist from above.
    4) Reopen Unity and check that all is now working the way you need it to work.

    I just tested it myself and it worked for me, so lets hope it does for you too!

    Best Regards
     
    AMA_MR likes this.
  3. AMA_MR

    AMA_MR

    Joined:
    Mar 23, 2018
    Posts:
    17
    Thanks Justyna. Much obliged.