setuptools: add .pth file to site-packages automatically

Maxim Yaskevich <[email protected]> Wed, 8 Jan 2014 13:22:58 +0300
Newsgroups gmane.comp.python.peak
Message-ID <CAHX5G6Yaf6kLR8tmKPiJzoXkZjH8gKe6sQkaohYyBCs6jFe8Fg@mail.gmail.com>
--===============1264840213==
Content-Type: multipart/alternative; boundary=089e011609bc7b551404ef72e0f1

--089e011609bc7b551404ef72e0f1
Content-Type: text/plain; charset=ISO-8859-1

Hi.

I'm wondering about how a user could add package's .pth file into system
`site-packages` directory without having write access to it.

Setuptools documentation<http://pythonhosted.org/setuptools/formats.html#installation-and-path-management-issues>
says
there is a workaroung for this problem, but I don't really get it.

Is it possible to have the foobar.pth file copied to site-packages dir
automatically with python setup.py install command?

src/
  foobar/...
  foobar.pth
  setup.py


--
Best regards,
Maxim Yaskevich

--089e011609bc7b551404ef72e0f1
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Hi.<div><br></div><div>I&#39;m wondering about how a user =
could add package&#39;s .pth file into system `site-packages` directory wit=
hout having write access to it.</div><div><br></div><div><a href=3D"http://=
pythonhosted.org/setuptools/formats.html#installation-and-path-management-i=
ssues">Setuptools documentation</a>=A0says there is a workaroung for this p=
roblem, but I don&#39;t really get it.</div>
<div><br></div><div>Is it possible to have the=A0<span style=3D"font-family=
:&#39;courier new&#39;,monospace">foobar.pth</span>=A0file copied to site-p=
ackages dir automatically with<font face=3D"courier new, monospace">=A0pyth=
on setup.py install=A0</font>command?</div>
<div><br></div><blockquote style=3D"margin:0px 0px 0px 40px;border:none;pad=
ding:0px"><div><font face=3D"courier new, monospace">src/</font></div><div>=
<font face=3D"courier new, monospace">=A0 foobar/...</font></div><div><font=
 face=3D"courier new, monospace">=A0 foobar.pth</font></div>
<div><font face=3D"courier new, monospace">=A0 setup.py</font></div></block=
quote><font face=3D"courier new, monospace"><br></font><div><font face=3D"a=
rial, helvetica, sans-serif">--</font></div><div><font face=3D"arial, helve=
tica, sans-serif">Best regards,</font></div>
<div><font face=3D"arial, helvetica, sans-serif">Maxim Yaskevich</font></di=
v></div>

--089e011609bc7b551404ef72e0f1--

--===============1264840213==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
PEAK mailing list
[email protected]
http://www.eby-sarna.com/mailman/listinfo/peak
--===============1264840213==--