<div dir="ltr">One very simple technique used by some projects like numpy is just to have ``setup.py`` write a file into the source tree before calling setup().<div><br></div><div>example: <a href="https://github.com/numpy/numpy/blob/master/setup.py#L338-L339">https://github.com/numpy/numpy/blob/master/setup.py#L338-L339</a><br></div><div><br></div><div>-Robert</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Feb 2, 2016 at 1:48 PM, AltSheets Dev <span dir="ltr"><<a href="mailto:altsheets+mailinglists@gmail.com" target="_blank">altsheets+mailinglists@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hello everyone on distutils-sig@,<div>this is a first timer, please be gentle to me *g*</div><div><br></div><div>I am just starting with setuptools, <br>and I just cannot get my idea working:</div><div><br></div><div>At install time, <br>I'd like to generate a file with a random UID, <br>which will later always be the same. </div><div><br></div><div>I had hoped for a setup('postinstall'='my.py') or setup('preinstall'= ...) but there isn't one. </div><div><br></div><div>Then I have been trying with a customized<br><span style="color:rgb(51,51,51);font-family:Consolas,'Liberation Mono',Menlo,Courier,monospace;font-size:12px;line-height:13.44px;white-space:pre-wrap">distutils.command.install.install</span></div><div>class - but so far with no success.</div><div><br></div><div>Here is a detailed explanation of my futile attempts:</div><div><a href="https://github.com/altsheets/coinquery/blob/master/README-setupCustom.md" target="_blank">https://github.com/altsheets/coinquery/blob/master/README-setupCustom.md</a><br></div><div><br></div><div>I guess this is be a pretty frequent question?</div><div><br></div><div>Happy about any hints. <br></div><div><br></div><div>Thanks.</div><div>:-)</div><div><br></div><div><br></div></div>
<br>_______________________________________________<br>
Distutils-SIG maillist  -  <a href="mailto:Distutils-SIG@python.org">Distutils-SIG@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/distutils-sig" rel="noreferrer" target="_blank">https://mail.python.org/mailman/listinfo/distutils-sig</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div>-Robert</div></div></div>
</div>