DataMuseum.dk

Presents historical artifacts from the history of:

Commodore CBM-900

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Commodore CBM-900

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦ab7fb089a⟧ TextFile

    Length: 406 (0x196)
    Types: TextFile
    Notes: UNIX file
    Names: »version.c«

Derivation

└─⟦f27320a65⟧ Bits:30001972 Commodore 900 hard disk image with partial source code
    └─⟦f4b8d8c84⟧ UNIX V7 Filesystem
        └─ ⟦this⟧ »cmd/version.c« 

TextFile

#include <stdio.h>
#include <time.h>
struct tm *localtime();
long time();
char *getwd();

char mon[12][4] = {
	"Jan", "Feb", "Mar", "Apr", "May", "Jun",
	"Jul", "Aug", "Sep", "Oct", "Nov", "Dec"
};

main()
{
	long clock;
	register struct tm *tp;
	register char *pwd;

	time(&clock);
	tp = localtime(&clock);
	pwd = getwd();
	printf("%s/%d/%s/%d\n",
		pwd, tp->tm_mday, mon[tp->tm_mon], tp->tm_year%100);
}