Creating source files



Hello,

I'm writing some helper scripts to make working with source code
repositories a bit easier and have a uniform interface. For example,
assume a program called srchelper which allows you to 'cd' into a
repository after a git clone, and create a new empty GObject/C++/Python
class like this:

$ srchelper create class MyClass

without even needing to check the project's coding guidelines or make
sure you use the right version of GPL or put all the special definitions
in the right places. Soma hacking will work faster this way, I hope. At
least for me :)

This is somewhat a terminal version of some common operations an IDE
does for you, but I never used programs like Emacs and Vi for source
code editing so I may be partially re-inventing the wheel (I'll research
this soon).

Now, I'd like to know how you GNOME module maintainers and contributors
usually work with source files. I mean, what do you do when you want a
new source file? Consider the following actions:

1. Create the new header and source files
2. Add GObject biolerplate
3. Fill in the specifics: class name, signals you use, base class, etc.
4. Add the class files to Makefile.am
5. Add a unit test (possibly empty for now)
6. Add the unit test to Makefile.am

How do you do these things? Example: Manually copy the style of existing
files and do all the editing of source and Makefile.am by hand. Another
possible option: use an IDE which does it all for you. Of course there
may be many other patterns.

Also, if you have comments/suggestions regarding the scripts I'm writing
(ideas to improve them, or a link to a similar thing which makes my idea
obsolete, or anything else you wish to say), I'd like to hear them.

Thanks in advance!!

-- fr33



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]