News:

SimuTranslator
Make Simutrans speak your language.

Header text

Started by An_dz, May 26, 2013, 07:31:04 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

An_dz

I was taking a look in Simutrans source code and I see there are a lot of different headers among the files. In documentation folder I found the template header which includes the date. My question is, don't dates gets outdated too easily? I would suggest delete the date and just use a header like this:

/*
* filename
*
* Copyright (c) Hansjörg Malthaner and
*    the simutrans development team
*
* This file is part of the Simutrans project under the artistic license.
* (see license.txt)
*/

/*
* Brief file/code description
*/


It'll never look outdated.

I know it's nothing about the code, but I think it gives more consistency and a better look in the code. And the brief description helps in finding what the file do in the whole code, specially when using softwares that read the file's first lines.

Ters

The date is important for copyright reasons, but I'm not sure if those reasons apply to Simutrans. They would have in the USA, if there was a formal Simutrans organization holding the rights. The style might just be a mimic of such cases. The date that does matter for Simutrans' copyright is when we die, so maybe we should write that down instead.

Dwachs

The headers need some reworking to make them consistent...
Parsley, sage, rosemary, and maggikraut.

An_dz

If dates are so important, maybe "2004 - infinity", "2004 - the universe reach 0K" or "2004 - and beyond".

IgorEliezer

I remember I had found a Python script for AutoLISP source files, it managed headers and documentation, or something... well, I felt interested in using it but I would have to use tags everywhere. Meh, no. I go back to coding in AutoLISP, I'd prefer to learn Python and make my own thing.

So, I guess there's some kind of header generator/manager for C++ source files.

An_dz

For Sublime Text there's AutoCopyright, you can include the copyright text with a shortcut and when you save the file it auto-update the copyright header.
I contributed with the code by including the filename functionality. It's written in python.

Ters

Quote from: An_dz on May 26, 2013, 04:24:58 PM
If dates are so important, maybe "2004 - infinity", "2004 - the universe reach 0K" or "2004 - and beyond".

That would be lying, at least potentially. The 2004 part might even be legally insignificant, and when that version of the file was written the important thing. I'm not sure, but it is possible that different versions of the same file have distinct copyrights, most likely if much has changed between them. I also don't know if the copyright applies to individual files, or to Simutrans as a whole. It might depend on the country, or even the judge.

An_dz

I see. Well, from 1997 to 2004 it was all Hajo copyright. But from 2004 and on the license changed to Artistic License.

I think that even if the files have no changes between the close-source and the open-source versions the license applies when you got the file. Just as when you are judged, it's all from the applicable laws in the day you committed the offense. If you downloaded the file when it was closed-source you can be prosecuted, no matter if it was open-sourced one second latter with no changes.

From my view, if Simutrans is under the Artistic License, all its files are in the same license. Because Simutrans is a source-code and not a game. Its compilation is only another file derived from the project.

Ters

This has nothing to do with the license, except that the license is void when the copyright expires. If I write a piece of code (at least of some significance), the copyright to that code belongs to me until I die and then a further 70 years. I may grant someone else the right to make copies through a license, but the ultimate right still belongs to me. This means that I, unlike everybody else, can make use of that code without obeying the terms in the license. This gets more complicated as others contribute to the same code, but the basic principles are there.