Skip to content

Commit

Permalink
add fw version print during build
Browse files Browse the repository at this point in the history
  • Loading branch information
madcowswe committed Jul 1, 2018
1 parent 187acfe commit 86095e1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tools/odrive/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@ def get_version_str(git_only=False, is_post_release=False, bump_rev=False):
args = parser.parse_args()

git_name, major, minor, revision, unreleased = get_version_from_git()
print('Firmware version {}.{}.{}{}, aka {}'.format(
major, minor, revision, '-dev' if unreleased else '',
git_name))
args.output.write('#define FW_VERSION "{}"\n'.format(git_name))
args.output.write('#define FW_VERSION_MAJOR {}\n'.format(major))
args.output.write('#define FW_VERSION_MINOR {}\n'.format(minor))
Expand Down

0 comments on commit 86095e1

Please sign in to comment.