convert-csv-to-json 2.6.0 → 2.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -30,10 +30,11 @@ jobs:
|
|
|
30
30
|
name: release
|
|
31
31
|
runs-on: ubuntu-latest
|
|
32
32
|
steps:
|
|
33
|
-
- uses: actions/checkout@v4
|
|
33
|
+
- uses: actions/checkout@v4
|
|
34
34
|
with:
|
|
35
35
|
token: ${{ secrets.ACTION_TOKEN }}
|
|
36
36
|
- uses: fregante/setup-git-user@v2
|
|
37
|
+
- run: git config --global user.name "dependabot"
|
|
37
38
|
- name: Use Node.js 21.x
|
|
38
39
|
uses: actions/setup-node@v4
|
|
39
40
|
with:
|
package/package.json
CHANGED
package/semantic-versioning.sh
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
+
|
|
2
3
|
set -e
|
|
3
|
-
|
|
4
|
+
|
|
5
|
+
validate_is_master_branch(){
|
|
4
6
|
echo "Checking branch...";
|
|
5
7
|
RELEASE_BRANCH="master";
|
|
6
8
|
CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD);
|
|
@@ -9,6 +11,9 @@ if [ $RELEASE_BRANCH != $CURRENT_BRANCH ]; then
|
|
|
9
11
|
echo "Exiting...";
|
|
10
12
|
exit 0;
|
|
11
13
|
fi
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
npm_release(){
|
|
12
17
|
PATCH_MSG="[PATCH]";
|
|
13
18
|
MAJOR_MSG="[MAJOR]";
|
|
14
19
|
echo "Parsing git message...";
|
|
@@ -16,12 +21,33 @@ COMMIT_MSG=$(git log -1 --pretty=format:"%s");
|
|
|
16
21
|
echo "Last commit message: ${COMMIT_MSG}";
|
|
17
22
|
if [[ $COMMIT_MSG == *"$PATCH_MSG"* ]]; then
|
|
18
23
|
echo "Executing new PATCH release..."
|
|
19
|
-
npm
|
|
24
|
+
npm version patch --force;
|
|
20
25
|
elif [[ $COMMIT_MSG == *"$MAJOR_MSG"* ]]; then
|
|
21
26
|
echo "Executing new MAJOR release..."
|
|
22
|
-
npm
|
|
27
|
+
npm version major --force;
|
|
23
28
|
else
|
|
24
29
|
echo "Executing new MINOR release...";
|
|
25
|
-
npm
|
|
30
|
+
npm version minor --force;
|
|
26
31
|
fi
|
|
27
|
-
echo "
|
|
32
|
+
echo "Publish new version..."
|
|
33
|
+
npm publish;
|
|
34
|
+
echo "New version successfully published."
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
push_git_info(){
|
|
38
|
+
echo "Publish git info...";
|
|
39
|
+
TAG=$(git describe --tags --abbrev=0)
|
|
40
|
+
git commit --amend -m "new release $TAG [skip ci]"
|
|
41
|
+
echo "new commit message: $(git log -1 --pretty=format:"%s")"
|
|
42
|
+
git push --follow-tags
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
execute-new-release(){
|
|
46
|
+
echo "Start Semantic Versioning release...";
|
|
47
|
+
validate_is_master_branch;
|
|
48
|
+
npm_release;
|
|
49
|
+
push_git_info;
|
|
50
|
+
echo "End Semantic Versioning release.";
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
execute-new-release;
|