Skip to content
This repository has been archived by the owner on Jul 3, 2024. It is now read-only.

Commit

Permalink
Reporting version from release.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
bsousi5 committed May 5, 2020
1 parent 3947bcd commit c7b163d
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -162,12 +162,20 @@ help:
@echo " Exports a program for a single target into a standalone"
@echo " project directory at STANDALONE_DEST."
@echo ""
@echo " version"
@echo " Report the release version for Freedom-E-SDK, Metal library"
@echo " and its tools if it has one."
@echo ""
@echo " open-docs"
@echo " Opens the Freedom E SDK documentation in your HTML"
@echo " viewer of choice. The documentation can also be found"
@echo " online at"
@echo " https://sifive.github.io/freedom-e-sdk-docs/index.html"

.PHONY: version
version: scripts/report-version
$^

.PHONY: open-docs
open-docs: scripts/open-docs
$^
Expand Down
12 changes: 12 additions & 0 deletions scripts/report-version
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash

set -euo pipefail

if [ ! -f release.txt ] ; then
>&2 echo "This is a non IPDelivery Freedom-E-SDK environment"
else
>&2 echo "IPDelivery Freedom-E-SDK environment"
>&2 grep "Date:" release.txt
>&2 grep "Release:" release.txt
fi

0 comments on commit c7b163d

Please sign in to comment.