Author Topic: © 2001 - 2017 Mean  (Read 428 times)

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 6052
© 2001 - 2017 Mean
« on: January 01, 2018, 10:00:04 AM »
Yes, Happy New Year ;) Perhaps time again to update the copyright messages © 2001 - 2018 Mean
or automate with a function? like clang example:

 
Quote
You can also define the macro in the Makefile. With this approach, you have complete control over which fields to include in the expansion:

Code: [Select]
ctyear: ctyear.c
    clang '-DBUILD_YEAR="$(shell date +%Y)"' $< -o $@
ctyear.c:

Code: [Select]
#include <stdio.h>

#define COMPANY  "Mean"
#define CYC BUILD_YEAR " " COMPANY

int main(void) {
    printf("Copyright %s\n", CYC);
    return 0;
}

If you have a large project with many source files, you probably have a Makefile and you can add '-DBUILD_YEAR="$(shell date +%Y)"' to the definition of CFLAGS.

source: https://stackoverflow.com/questions/41898659/extract-only-year-from-date-macro

mean

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 10958
Re: © 2001 - 2017 Mean
« Reply #1 on: January 01, 2018, 11:35:02 AM »
No hurry :)
Happy new year

EEMcGee

  • Jr. Member
  • **
  • Posts: 64
Re: © 2001 - 2017 Mean
« Reply #2 on: January 15, 2018, 02:21:54 AM »
Thank you for all of your hard work and dedication.