Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit aa01141

Browse files
committed
Automatically insert the date.
1 parent 288a60f commit aa01141

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

Modules/config.c.in

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,27 +24,38 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
2424

2525
/* Configurable Python configuration file */
2626

27-
char version[] = "0.9.3 beta (2)";
27+
#define VERSION "0.9.4 beta"
28+
29+
#ifdef __DATE__
30+
#define DATE __DATE__
31+
#else
32+
#define DATE "Dec 16 1991"
33+
#endif
2834

2935
#include <stdio.h>
3036

3137
#ifdef USE_STDWIN
3238
#include <stdwin.h>
3339
#endif
3440

41+
char version[80];
42+
3543
/*ARGSUSED*/
3644
void
3745
initargs(p_argc, p_argv)
3846
int *p_argc;
3947
char ***p_argv;
4048
{
49+
sprintf(version, "%s (%s)", VERSION, DATE);
50+
4151
#ifdef USE_STDWIN
4252
wargs(p_argc, p_argv);
4353
#endif
4454
if (*p_argc < 2 && isatty(0) && isatty(1))
4555
{
4656
printf("Python %s.\n", version);
47-
printf("Copyright 1990, 1991 Stichting Mathematisch Centrum, Amsterdam\n");
57+
printf(
58+
"Copyright 1990, 1991, 1992 Stichting Mathematisch Centrum, Amsterdam\n");
4859
}
4960
}
5061

0 commit comments

Comments
 (0)