<div dir="ltr"><div>@Ted S : I wonder how close this might be to what you were looking for:<br><br><a href="https://github.com/dustractor/UserPrefsBaseline">https://github.com/dustractor/UserPrefsBaseline</a><br><br>It's something I started but never finished or published and if you 
think its in the right ballpark.  I just tested and it still seems to work.<br></div><div><br></div><div>The usage video should give an overview, but for those reading here's my quick summary:<br><br></div><div>It is an addon that stores sets of user-preferences and puts them on a menu.  It has to be re-calibrated with each blender version in order to pick up api changes because it only stores the delta from the factory settings.<br><br></div><div>Anyway, you're welcome to do whatever you want with the code, if that helps.<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 31, 2016 at 5:00 AM,  <span dir="ltr"><<a href="mailto:bf-python-request@blender.org" target="_blank">bf-python-request@blender.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Send Bf-python mailing list submissions to<br>
        <a href="mailto:bf-python@blender.org">bf-python@blender.org</a><br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
        <a href="https://lists.blender.org/mailman/listinfo/bf-python" rel="noreferrer" target="_blank">https://lists.blender.org/<wbr>mailman/listinfo/bf-python</a><br>
or, via email, send a message with subject or body 'help' to<br>
        <a href="mailto:bf-python-request@blender.org">bf-python-request@blender.org</a><br>
<br>
You can reach the person managing the list at<br>
        <a href="mailto:bf-python-owner@blender.org">bf-python-owner@blender.org</a><br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than "Re: Contents of Bf-python digest..."<br>
<br>
<br>
Today's Topics:<br>
<br>
   1. Preferred way to persist settings? (Ted Schundler)<br>
   2. Re: Preferred way to persist settings? (Sybren A. St?vel)<br>
   3. Re: Preferred way to persist settings? (Sybren A. St?vel)<br>
   4. Re: Preferred way to persist settings? (Domino Marama)<br>
<br>
<br>
------------------------------<wbr>------------------------------<wbr>----------<br>
<br>
Message: 1<br>
Date: Tue, 30 Aug 2016 22:23:44 -0700<br>
From: Ted Schundler <<a href="mailto:tschundler@gmail.com">tschundler@gmail.com</a>><br>
Subject: [Bf-python] Preferred way to persist settings?<br>
To: Blender Foundation Python list <<a href="mailto:bf-python@projects.blender.org">bf-python@projects.blender.<wbr>org</a>><br>
Message-ID:<br>
        <CAO=<a href="mailto:DEgf_032JkdF28tRwqDXS07FqorB1eX6GqvK%2B0BkU7rO_WQ@mail.gmail.com">DEgf_<wbr>032JkdF28tRwqDXS07FqorB1eX6Gqv<wbr>K+0BkU7rO_WQ@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
Is there a preferred way to persist settings in Blender?<br>
<br>
For example, I'd like the images as planes add-on to let me set defaults,<br>
since I generally want them shadeless. That's useful for compositing, but<br>
not as useful in a shaded 3D scene, so the right default depends on the<br>
user.<br>
<br>
I see the Blender ID add-on stores current credentials in a json file. But<br>
they may have other concerns about users leaking their credentials in<br>
shared preferences blend files.<br>
<br>
I was thinking attaching preferences as a custom property of the current<br>
scene, and if not found, look for other scenes. But that's a little clunky.<br>
<br>
Is there anything that can have custom properties that is global? I can't<br>
seem to attach custom properties to UserPreferences.<br>
<br>
Or is there another way?<br>
<br>
<br>
-Ted<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://lists.blender.org/pipermail/bf-python/attachments/20160830/895aad23/attachment.html" rel="noreferrer" target="_blank">http://lists.blender.org/<wbr>pipermail/bf-python/<wbr>attachments/20160830/895aad23/<wbr>attachment.html</a><br>
<br>
------------------------------<br>
<br>
Message: 2<br>
Date: Wed, 31 Aug 2016 09:59:09 +0200<br>
From: Sybren A. St?vel <<a href="mailto:sybren@stuvel.eu">sybren@stuvel.eu</a>><br>
Subject: Re: [Bf-python] Preferred way to persist settings?<br>
To: Blender Foundation Python list <<a href="mailto:bf-python@blender.org">bf-python@blender.org</a>><br>
Cc: Blender Foundation Python list <<a href="mailto:bf-python@projects.blender.org">bf-python@projects.blender.<wbr>org</a>><br>
Message-ID: <<a href="mailto:20160831075909.GN1982@sapphire.stuvel.eu">20160831075909.GN1982@<wbr>sapphire.stuvel.eu</a>><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
On Tue, Aug 30, 2016 at 10:23:44PM -0700, Ted Schundler wrote:<br>
> I see the Blender ID add-on stores current credentials in a json<br>
> file. But they may have other concerns about users leaking their<br>
> credentials in shared preferences blend files.<br>
<br>
The credentials (which I understand to be username/password) aren't<br>
stored, just an authentication token. Since the Python scripts running<br>
in Blender have unlimited access to your machine anyway (this<br>
shouldn't come as a surprise), this one token isn't that much of a<br>
security issue.<br>
<br>
> I was thinking attaching preferences as a custom property of the<br>
> current scene, and if not found, look for other scenes. But that's a<br>
> little clunky.<br>
><br>
> Is there anything that can have custom properties that is global? I<br>
> can't seem to attach custom properties to UserPreferences.<br>
<br>
It's all Open Source. Why not alter those add-ons you're interested in<br>
so that they have the preferences you need?<br>
<br>
--<br>
Sybren A. St?vel<br>
<br>
<a href="https://cloud.blender.org/" rel="noreferrer" target="_blank">https://cloud.blender.org/</a><br>
<a href="https://stuvelfoto.nl/" rel="noreferrer" target="_blank">https://stuvelfoto.nl/</a><br>
<a href="https://stuvel.eu/" rel="noreferrer" target="_blank">https://stuvel.eu/</a><br>
-------------- next part --------------<br>
A non-text attachment was scrubbed...<br>
Name: not available<br>
Type: application/pgp-signature<br>
Size: 819 bytes<br>
Desc: Digital signature<br>
Url : <a href="http://lists.blender.org/pipermail/bf-python/attachments/20160831/97a58f27/attachment-0002.pgp" rel="noreferrer" target="_blank">http://lists.blender.org/<wbr>pipermail/bf-python/<wbr>attachments/20160831/97a58f27/<wbr>attachment-0002.pgp</a><br>
<br>
------------------------------<br>
<br>
Message: 3<br>
Date: Wed, 31 Aug 2016 09:59:09 +0200<br>
From: Sybren A. St?vel <<a href="mailto:sybren@stuvel.eu">sybren@stuvel.eu</a>><br>
Subject: Re: [Bf-python] Preferred way to persist settings?<br>
To: Blender Foundation Python list <<a href="mailto:bf-python@blender.org">bf-python@blender.org</a>><br>
Cc: Blender Foundation Python list <<a href="mailto:bf-python@projects.blender.org">bf-python@projects.blender.<wbr>org</a>><br>
Message-ID: <<a href="mailto:20160831075909.GN1982@sapphire.stuvel.eu">20160831075909.GN1982@<wbr>sapphire.stuvel.eu</a>><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
On Tue, Aug 30, 2016 at 10:23:44PM -0700, Ted Schundler wrote:<br>
> I see the Blender ID add-on stores current credentials in a json<br>
> file. But they may have other concerns about users leaking their<br>
> credentials in shared preferences blend files.<br>
<br>
The credentials (which I understand to be username/password) aren't<br>
stored, just an authentication token. Since the Python scripts running<br>
in Blender have unlimited access to your machine anyway (this<br>
shouldn't come as a surprise), this one token isn't that much of a<br>
security issue.<br>
<br>
> I was thinking attaching preferences as a custom property of the<br>
> current scene, and if not found, look for other scenes. But that's a<br>
> little clunky.<br>
><br>
> Is there anything that can have custom properties that is global? I<br>
> can't seem to attach custom properties to UserPreferences.<br>
<br>
It's all Open Source. Why not alter those add-ons you're interested in<br>
so that they have the preferences you need?<br>
<br>
--<br>
Sybren A. St?vel<br>
<br>
<a href="https://cloud.blender.org/" rel="noreferrer" target="_blank">https://cloud.blender.org/</a><br>
<a href="https://stuvelfoto.nl/" rel="noreferrer" target="_blank">https://stuvelfoto.nl/</a><br>
<a href="https://stuvel.eu/" rel="noreferrer" target="_blank">https://stuvel.eu/</a><br>
-------------- next part --------------<br>
A non-text attachment was scrubbed...<br>
Name: not available<br>
Type: application/pgp-signature<br>
Size: 819 bytes<br>
Desc: Digital signature<br>
Url : <a href="http://lists.blender.org/pipermail/bf-python/attachments/20160831/97a58f27/attachment-0003.pgp" rel="noreferrer" target="_blank">http://lists.blender.org/<wbr>pipermail/bf-python/<wbr>attachments/20160831/97a58f27/<wbr>attachment-0003.pgp</a><br>
<br>
------------------------------<br>
<br>
Message: 4<br>
Date: Wed, 31 Aug 2016 09:16:16 +0100<br>
From: Domino Marama <<a href="mailto:domino@dominodesigns.info">domino@dominodesigns.info</a>><br>
Subject: Re: [Bf-python] Preferred way to persist settings?<br>
To: Blender Foundation Python list <<a href="mailto:bf-python@blender.org">bf-python@blender.org</a>><br>
Message-ID: <<a href="mailto:fad23597-8fb0-a75d-c0ab-41ca331cebb1@dominodesigns.info">fad23597-8fb0-a75d-c0ab-<wbr>41ca331cebb1@dominodesigns.<wbr>info</a>><br>
Content-Type: text/plain; charset=windows-1252; format=flowed<br>
<br>
On 31/08/16 06:23, Ted Schundler wrote:<br>
> Is there a preferred way to persist settings in Blender?<br>
><br>
> I see the Blender ID add-on stores current credentials in a json file.<br>
> But they may have other concerns about users leaking their credentials<br>
> in shared preferences blend files.<br>
Not checked how that addon does it, but my first choice for user<br>
specific config is to get a path to store it with:<br>
<br>
config_path = bpy.utils.user_resource('<wbr>CONFIG', 'plugin_name')<br>
<br>
<br>
------------------------------<br>
<br>
______________________________<wbr>_________________<br>
Bf-python mailing list<br>
<a href="mailto:Bf-python@blender.org">Bf-python@blender.org</a><br>
<a href="https://lists.blender.org/mailman/listinfo/bf-python" rel="noreferrer" target="_blank">https://lists.blender.org/<wbr>mailman/listinfo/bf-python</a><br>
<br>
<br>
End of Bf-python Digest, Vol 135, Issue 3<br>
******************************<wbr>***********<br>
</blockquote></div><br></div>