Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #78922

Re: python on Linux

References <CA+FnnTzGH2WDkH1h2EHtEu8C_ib6EHo=7xKvEeyhTDNuiogksw@mail.gmail.com>
Date 2014-10-09 21:38 -0700
Subject Re: python on Linux
From Dan Stromberg <drsalists@gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.14734.1412915945.18130.python-list@python.org> (permalink)

Show all headers | View raw


Try:

sys.path.append(os.path.expanduser('~/MyLib'))

On Thu, Oct 9, 2014 at 9:21 PM, Igor Korot <ikorot01@gmail.com> wrote:
> Hi, ALL,
> When I am on Windows, I can write something like this:
>
> sys.path.append('C:\Users\Igor\Documents\MyLib')
>
> Now, when I'm on Linux, can I do this:
>
> sys.path.append('~/MyLib')
>
> ?
>
> I.e., will '~' sign be expanded correctly?
>
> Thank you.
> --
> https://mail.python.org/mailman/listinfo/python-list

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: python on Linux Dan Stromberg <drsalists@gmail.com> - 2014-10-09 21:38 -0700

csiph-web