Skip to content

Commit

Permalink
chore: Adjust Yml File and Update Get Version Command from Entrypoint
Browse files Browse the repository at this point in the history
  • Loading branch information
saulonunesdev committed May 31, 2020
1 parent 4df550c commit b56eba0
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ To use this action in your project, use the following:
```yaml
- name: get-lerna-version
id: package-version
uses: saulonunesdev/lerna-get-version-action@master
uses: saulonunesdev/lerna-get-version-action@v1
```
The Action sets an output variable called `lerna-version` which can be used in a following step by using `${{ steps.lerna-version.outputs.lerna-version}}`.
Expand Down
1 change: 0 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

name: 'Get current lerna version'
description: 'Get the current version of lerna.json'
branding:
Expand Down
2 changes: 1 addition & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/sh -l

LERNA_VERSION=$(grep -m1 version lerna.json | awk -F: '{ print $2 }' | sed 's/[", ]//g')
LERNA_VERSION=$(cat lerna.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g' | tr -d '[[:space:]]')

echo ::set-output name=lerna-version::$LERNA_VERSION

0 comments on commit b56eba0

Please sign in to comment.