[Yum] code cleanup: one function in one source

seth vidal skvidal at phy.duke.edu
Sun Jul 14 19:08:38 UTC 2002


On Sun, 2002-07-14 at 14:35, Vladimir Bormotov wrote:
> 

I'm not going to respond to each individual point, but I will give my
general view:

1. I don't have a problem with the clean ups for comma space and space =
space or space == space etc. I don't always type it the same way and I
don't entirely notice it. I do have to read all the patches that you
send me b/c I _HAVE_ to read them. I won't apply a patch w/o reading an
understanding it so if it seems like I'm taking a while its b/c I'm busy
with other things.

2. The reason a lot of functions have import module at the beginning of
them is b/c I moved stuff around quite a bit. So I figured if I could
cut and paste the module w/little or no modification then it made the
function more easily used for me or for other things.

3. I am not a full time programmer, I've never had any formal training
in programming save one class. I maintain a large number of linux
systems for a living and it probably shows in my code. I'm a sysadmin
who happens to end up doing a lot of weird stuff. Having said that, I
don't find it horribly unreadable code so I'm not sure how much benefit
comes from some of the modifications suggested in the style guides.

4. Regarding additional classes. I can see a couple of places where an
additional class would be handy but I've not seen a lot of them.
Arguments persuading me to remove all functions outside of classes are
going to need to be DAMNED impressive. I'm not always taken by
additional classes. Frequently, I find they do a lot for abstraction but
they also do A LOT for obfuscation. MANY MANY MANY classes make it hard
for non-programmers to begin to understand the code, and given that this
code is for a utility that A LOT of sysadmins could use it would seem to
me to be useful to make sure that they can understand it. 

  I'm not wed to this concept in anyway, and I might be more than glad
to get rid of it and add in a bunch of classes. But I learned how to
program mostly in perl and some C, so I'm more comfortable with
procedural programming. Object Orientation is great for some things but
I know what the old yup code looked like and I'm a little afraid of
"object orienting" to that extent. 


5. I'm using this program everyday on quite a few systems and the reason
I didn't go with apt-rpm was that I wanted to completely understand what
the code was doing when it did it, so if I'm slow in integrating patches
its b/c I'm thinking about them and making sure I understand them.

So, in summary, I am reading through all the emails regarding style and
I'll address them as soon as I can. (refer to my last email about the
broken hard drive :)

I'd like to make it cleaner looking but it is possible that your concept
of cleaner and my concept of cleaner might not gibe.

-sv

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 232 bytes
Desc: This is a digitally signed message part
Url : http://lists.baseurl.org/pipermail/yum/attachments/20020714/9809b5e9/attachment-0001.pgp 


More information about the Yum mailing list