Re: [Codemill-spec] Re: proposed -L option
Status: Planning
Brought to you by:
richard_kolb
From: Richard K. <rk...@sw...> - 2000-12-14 07:53:57
|
Hi All, John Lindal wrote: > >> > 6) The generated code must be under 'no license'. > >> > >> I agree with what you mean by this statement, but it made me think of > >> something. Most of the code I write is under LGPL and the GPL. For > >> every new bloody file I create, I have to copy/paste the info about the > >> license into the top of the file. I also put a little header with a > >> description of the file and some macros that CVS expands. It would be > >> really helpfull if I could some how point to a file containing the > >> software license/header info and CodeMill could copy that into the > >> created file. I can;t think of an intuitive way to work this into the > >> syntax... > > > > This is a very good idea, We could add a -L option to codemill that would > > add a license template at the top of the generated code, > > Why not just make this part of the template file that has already been > added to the spec? One would specify what should be in the header of the > source file, the header of the header file, same for the footers, and then > the format of the different code snippets that Code Mill creates. One > would probably only need to have one variable, the date, since names, etc. > would be entered by hand (once) into each peronalized template files. Yes , but I think it is important to keep the license template and the code template separate. Since someone could have the GNU coding style with the BSD license etc... ( I guess this is what you meant ) Then people can add there own headers/footers in with codemill. These can have CVS macros/ emacs settings etc. in. if only one set variable is needed then it's not to bad, I don't want have unique / different variables is each template I would also like to propose a system of finding templates. codemill would first search the current directory ( or a specified one ) Then codemill would go into it's own template directory like /usr/local/codemill/templates/cplusplus/ etc... Maybe if a verbose mode is set it will tell where it got it's templates etc... Thanks, Richard. |