Two patches -- reformatting and

13 views
Skip to first unread message

Matěj Cepl

unread,
Jan 9, 2012, 3:20:26 PM1/9/12
to jbr...@googlegroups.com
Ability of camera makers to put endless amount of junk to comments is
apparently endless. Here are two patches for jbrout:

* 0001*.patch .. just when I opened the db.py file in Eclipse I got a
lot of changes just by its reformatting; so I have made the file PEP8
compliant and made some other bits of changes pylint suggested.
* 0002*.patch ... the patch itself. The idea is to finally face the
problem of non-XML-compatible characters head on. I have found a cleaner
script which could be included into jBrout.

What do you think?

Matěj
--
http://www.ceplovi.cz/matej/, Jabber: mcepl<at>ceplovi.cz
GPG Finger: 89EF 4BC6 288A BF43 1BAB 25C3 E09F EF25 D964 84AC

In those days spirits were brave, the stakes were high, men were
real men, women were real women and small furry creatures from
Alpha Centauri were real small furry creatures from Alpha
Centauri.
-- Douglas Adams

0001-Reformatting-to-make-code-PEP8-compatible.patch
0002-Overkill-solution-for-illegal-XML-characters.patch

mana...@gmail.com

unread,
Feb 19, 2012, 7:42:44 AM2/19/12
to jbr...@googlegroups.com
Thanks I apply the n°2


--
You received this message because you are subscribed to the Google Groups "jBrout" group.
To post to this group, send email to jbr...@googlegroups.com.
To unsubscribe from this group, send email to jbrout+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/jbrout?hl=en.


mcepl

unread,
Apr 3, 2012, 5:24:45 PM4/3/12
to jbr...@googlegroups.com
Dne neděle, 19. února 2012 13:42:44 UTC+1 manatlan napsal(a):
Thanks I apply the n°2
 
What's wrong with no. 1 ... I believe following PEP-8 improves the readability of the code (not mentioning, that my PyDEV has problems to work with non-compliant code, in fact it always reformats misformatted scripts to the correct shape)?

Matěj

mana...@gmail.com

unread,
Apr 4, 2012, 5:10:46 AM4/4/12
to jbr...@googlegroups.com
In fact, I've got some local changes ...
So, I didn't want to apply that ...

How can I reformat "according PEP8" my local changes ? (without pydev ;-)

--
You received this message because you are subscribed to the Google Groups "jBrout" group.
To view this discussion on the web visit https://groups.google.com/d/msg/jbrout/-/KJCSaWI-3QcJ.

To post to this group, send email to jbr...@googlegroups.com.
To unsubscribe from this group, send email to jbrout+un...@googlegroups.com.

Matěj Cepl

unread,
Apr 4, 2012, 5:16:06 AM4/4/12
to jbr...@googlegroups.com
On 4.4.2012 11:10, mana...@gmail.com wrote:
> In fact, I've got some local changes ...
> So, I didn't want to apply that ...
>
> How can I reformat "according PEP8" my local changes ? (without pydev ;-)

pip install pep8

(or easy_install if you insist)

and then in one window

$EDITOR file.py

in other run pep8 file.py

and beat the file into submission?

Best,

Matěj

--
http://www.ceplovi.cz/matej/, Jabber: mcepl<at>ceplovi.cz
GPG Finger: 89EF 4BC6 288A BF43 1BAB 25C3 E09F EF25 D964 84AC

Faithful love is what people look for in a person; ...
-- Proverbs 19:22 (NJB)

Matěj Cepl

unread,
May 25, 2012, 10:46:18 AM5/25/12
to jbr...@googlegroups.com
On 04/04/2012 11:10 AM, mana...@gmail.com wrote:
> In fact, I've got some local changes ...
> So, I didn't want to apply that ...
>
> How can I reformat "according PEP8" my local changes ? (without pydev ;-)

Are you a vim guy? (I am just switching to vim for work-related reasons
myself) If yes, add http://mcepl.fedorapeople.org/tmp/python.vim to
~/.vim/after/ftplugin and then you can run :Pycheck command.

Originally from http://vim.wikia.com/wiki/Combine_quickfix_steps

Matěj

--
http://www.ceplovi.cz/matej/, Jabber: mcepl<at>ceplovi.cz
GPG Finger: 89EF 4BC6 288A BF43 1BAB 25C3 E09F EF25 D964 84AC

- Do you think of yourself as a Christian artist?
- I'm an artist who is a Christian. I'm not a Christian artist.
-- Johny Cash
in his last interview

Reply all
Reply to author
Forward
0 new messages