Re: Python and Emacs

2002-05-22 Thread Jonne Itkonen
On 21 May 2002, Ron Johnson wrote: > On Tue, 2002-05-21 at 15:27, Jérôme Marant wrote: > [snip] > > I'm a bit annoyed with Emacs when editing Python programs because > > Emacs always replaces TABs with spaces ; this wouldn't bother me if > > Emacs was the only editor in the world. But when y

Re: Python and Emacs

2002-05-22 Thread Ron Johnson
On Wed, 2002-05-22 at 01:40, Jonne Itkonen wrote: > On 21 May 2002, Ron Johnson wrote: > > > On Tue, 2002-05-21 at 15:27, Jérôme Marant wrote: [snip] > And now something useful: less has an option '-x' which tells less how > many spaces to use when rendering tabs. The correct and the default valu

Re: Python and Emacs

2002-05-22 Thread Luca - De Whiskey's - De Vitis
On Tue, May 21, 2002 at 11:21:44PM +0200, J?r?me Marant wrote: > > Of course, we all know that using tabs in Python code is Evil. :-) > > Sure. Now, you make me think that sharing code with Vimers is > Evil too. I wouldn't need such a trick ;-) If the problem is that `Vimers' do not use space

Re: Python and Emacs

2002-05-22 Thread Florent Rougon
Jonne Itkonen <[EMAIL PROTECTED]> wrote: > And I again opposite to your opinion. If everybody uses tab to indent, > then everyone can set his or her environment to render that tab with > as many spaces as necessary, _or_ when using proportional fonts, as > long an empty space as needed. I really d

Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
[please CC me, I'm not on the list] Hypothetical situation: Source package: contains foo.py (python module, works with every python version under the sun) and foo (a script whose first line is "import foo"). I want to properly support people who want 2.1 and 2.2. There are several audiences here:

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Bastian Kleineidam
On Wed, May 22, 2002 at 11:01:14AM -, Moshe Zadka wrote: > [please CC me, I'm not on the list] NP. > Hypothetical situation: > Source package: contains foo.py (python module, works with every python > version under the sun) and foo (a script whose first line is > "import foo"). I want to prop

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > There is a package called python-central which allows version-independent > packages. > http://people.debian.org/~calvin/python-central/ > Precondition: you have a "pure" pyhthon module, no C-compiled Extension. Sorry, the situa

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Bastian Kleineidam
Hi Moshe, On Wed, May 22, 2002 at 12:09:11PM -, Moshe Zadka wrote: > > a) python2.1-foo: python foo.py module for 2.1 Depends: python2.1 > > b) python2.2-foo: python foo.py module for 2.2 Depends: python2.2 > > c) python-foo: /usr/bin/foo binary with #!/usr/bin/python > >Depends: python2

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Chris Lawrence
On May 22, Moshe Zadka wrote: > Doesn't work. > What if the user installed python2.2-foo but /usr/bin/python > is /usr/bin/python2.1, or vice versa? > If this is what python-central does, then python-central, I'm afraid, > has a bug... Under Debian's Python policy, /usr/bin/python is guaranteed to

Re: Python and Emacs

2002-05-22 Thread dman
On Wed, May 22, 2002 at 10:46:59AM +0200, Luca - De Whiskey's - De Vitis wrote: | On Tue, May 21, 2002 at 11:21:44PM +0200, J?r?me Marant wrote: | > > Of course, we all know that using tabs in Python code is Evil. :-) | > | > Sure. Now, you make me think that sharing code with Vimers is | > Ev

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > On Wed, May 22, 2002 at 12:09:11PM -, Moshe Zadka wrote: > > > a) python2.1-foo: python foo.py module for 2.1 > Depends: python2.1 > > > > b) python2.2-foo: python foo.py module for 2.2 > Depends: python2.2 Of course You do

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Matthias Klose
Moshe Zadka writes: > On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > > > On Wed, May 22, 2002 at 12:09:11PM -, Moshe Zadka wrote: > > > > a) python2.1-foo: python foo.py module for 2.1 > > Depends: python2.1 > > > > > > b) python2.2-foo: python foo.py module for 2.2 > >

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Matthias Klose <[EMAIL PROTECTED]> wrote: > > > > > c) python-foo: /usr/bin/foo binary with #!/usr/bin/python > > > > >Depends: python2.1-foo | python2.2-foo ^ that's an or sign, right > > python2.1, python2.2, python2.2-foo and pyt

Re: Python and Emacs

2002-05-22 Thread Luca - De Whiskey's - De Vitis
On Wed, May 22, 2002 at 08:38:26AM -0500, dman wrote: > | --- cut --- > | augroup Python > | au! > | autocmd BufRead *.py set expandtab softtabstop=4 shiftwidth=4 tabstop=4 > | augroup END > | --- /cut --- > It will work, but I disagree with changing the 'tabstop' variable. > > Try cattin

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Bastian Kleineidam
On Wed, May 22, 2002 at 01:09:02PM -, Moshe Zadka wrote: > Situation: > python2.1, python2.2, python2.2-foo and python-foo are all installed. > python2.1 is the default. > All dependancies are resolved, right? > > #!/usr/bin/python > import foo > > equivalent to > > #!/usr/bin/python2.1 > i

Re: Python and Emacs

2002-05-22 Thread dman
On Wed, May 22, 2002 at 05:50:10PM +0200, Luca - De Whiskey's - De Vitis wrote: | On Wed, May 22, 2002 at 08:38:26AM -0500, dman wrote: | > | --- cut --- | > | augroup Python | > | au! | > | autocmd BufRead *.py set expandtab softtabstop=4 shiftwidth=4 tabstop=4 | > | augroup END | > | ---

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > Ok, thats a problem. There is no way out for this; you'd have to > have two binaries. Yes, I know I'll have to have two binaries. > Provide library packages: python2.1-foo, python2.2-foo. > Provide *one* binary package for the

Re: Python and Emacs

2002-05-22 Thread Juha Autero
Jonne Itkonen <[EMAIL PROTECTED]> writes: > On 21 May 2002, Ron Johnson wrote: > >> This is amusing: I think exactly the opposite, since I indent >> every 4 columns, and if \t were set to 4, then when less'ing >> the file, it would look differently that it does in the editor... > > (Skip the next

.pyo files.

2002-05-22 Thread Luca - De Whiskey's - De Vitis
I'm wandering why so many (if not all) python modules compile the py files twice: first simply, then with the -O flag. Reading the python documentation it seems that this does not improve the perfomance so much. OTOH, it increase the disk usage a lot. More over, if you compile a module with -O pyth

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Donovan Baarda
On Wed, May 22, 2002 at 04:50:02PM -, Moshe Zadka wrote: > On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > > > Ok, thats a problem. There is no way out for this; you'd have to > > have two binaries. > > Yes, I know I'll have to have two binaries. if I understand it, foo

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Donovan Baarda
On Thu, May 23, 2002 at 10:10:51AM +1000, Donovan Baarda wrote: [...] > 1a) as 1), but also provide foo symlink for python (default). > > as 1), but also make foo (Depends: python (>=2.1), python (<<2.2), > foo-python2.1) with symlink /usr/bin/foo to /usr/bin/foo-python2.2 Ack! typo... should be

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Thu, 23 May 2002, [EMAIL PROTECTED] (Donovan Baarda) wrote: > if I understand it, foo is not really a 'binary' but an 'executable > script'... (which means it can be Python version independant). Yep. > This situation is identical to the existing idle package. It's worth looking > at how it ha