Skip to content

Commit 254407f

Browse files
committed
Add bash script to bump JSON nuget
1 parent 471631e commit 254407f

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

Build/bump-version-json.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/bin/bash
2+
# Increments version of nuget UnitNets.Serialization.JsonNet.
3+
script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4+
set_version_script="$script_dir/set-version-UnitsNet.Serialization.JsonNet.ps1"
5+
6+
names=(major minor patch suffix);
7+
if [[ " "${names[@]}" " == *" "$1" "* ]] ;then
8+
powershell -NoProfile $set_version_script -bump $1
9+
exit 0
10+
else
11+
echo "Usage: ./bump-version-json.sh <major|minor|patch|suffix>"
12+
exit 1
13+
fi

Build/bump-version.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#!/bin/bash
2+
# Increments version of nugets UnitNets, UnitsNet.NumberExtensions.
23
script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
34
set_version_script="$script_dir/set-version-UnitsNet.ps1"
45

@@ -7,6 +8,6 @@ if [[ " "${names[@]}" " == *" "$1" "* ]] ;then
78
powershell -NoProfile $set_version_script -bump $1
89
exit 0
910
else
10-
echo "Usage: ./bump-version <major|minor|patch|suffix>"
11+
echo "Usage: ./bump-version.sh <major|minor|patch|suffix>"
1112
exit 1
1213
fi

0 commit comments

Comments
 (0)