bump_date 372 B

1234567891011121314151617
  1. #!/usr/bin/env bash
  2. #
  3. # bump_date
  4. #
  5. # Bump the Distribution Date in Version.h
  6. #
  7. VERSION_FILE=Marlin/src/inc/Version.h
  8. SED=$(which gsed || which sed)
  9. DIST=$( date +"%Y-%m-%d" )
  10. eval "${SED} -E -i 's/(#define +STRING_DISTRIBUTION_DATE) .*$/\1 \"$DIST\"/g' $VERSION_FILE" || exit 1
  11. git add "$VERSION_FILE" || exit 1
  12. git commit -m "[cron] Bump distribution date ($DIST)"