release-me-sh 0.11.2 → 0.11.4

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "release-me-sh",
3
- "version": "0.11.2",
3
+ "version": "0.11.4",
4
4
  "description": "Blazing fast minimal release workflow script written in Bash with plugins and presets support",
5
5
  "keywords": [
6
6
  "bash",
package/plugins/git.sh CHANGED
@@ -34,12 +34,6 @@ prepare() {
34
34
  SSH_PUBLIC_KEY_FILE=$(mktemp)
35
35
  printf "%s" "${SSH_PUBLIC_KEY}" >>"${SSH_PUBLIC_KEY_FILE}"
36
36
 
37
- git config --local commit.gpgsign true
38
- git config --local user.signingkey "${SSH_PUBLIC_KEY_FILE}"
39
- git config --local tag.forceSignAnnotated true
40
- git config --local gpg.format ssh
41
- log_verbose "Git SSH sign key is set"
42
-
43
37
  if [ -n "${SSH_KEY_PASSPHRASE-}" ]; then
44
38
  SSH_ASKPASS_FILE=$(mktemp)
45
39
  chmod 0755 "${SSH_ASKPASS_FILE}"
@@ -50,12 +44,14 @@ prepare() {
50
44
  log_verbose "Git SSH passphrase set"
51
45
  fi
52
46
 
53
- if ! ssh-add -L | grep -q "${SSH_PUBLIC_KEY-}"; then
54
- printf "%s" "${SSH_PRIVATE_KEY}" | base64 --decode | ssh-add -
55
- log_verbose "Git SSH key import loaded"
56
- else
57
- log_verbose "Git SSH key import skipped"
58
- fi
47
+ printf "%s" "${SSH_PRIVATE_KEY}" | base64 --decode | ssh-add -
48
+ log_verbose "Git SSH key import loaded"
49
+
50
+ git config --local commit.gpgsign true
51
+ git config --local user.signingkey "${SSH_PUBLIC_KEY_FILE}"
52
+ git config --local tag.forceSignAnnotated true
53
+ git config --local gpg.format ssh
54
+ log_verbose "Git SSH sign key is set"
59
55
 
60
56
  if [ -n "${SSH_KEY_PASSPHRASE-}" ]; then
61
57
  rm -rf "${SSH_ASKPASS}"
@@ -90,9 +86,9 @@ cleanup() {
90
86
  fi
91
87
 
92
88
  log_verbose "Git GPG config cleanup"
93
- elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUB_KEY-}" ]; then
89
+ elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUBLIC_KEY-}" ]; then
94
90
  git config --local --unset commit.gpgsign true
95
- git config --local --unset user.signingkey "${SSH_PUB_KEY}"
91
+ git config --local --unset user.signingkey "${SSH_PUBLIC_KEY}"
96
92
  git config --local --unset tag.forceSignAnnotated true
97
93
  git config --local --unset gpg.format ssh
98
94
 
@@ -114,7 +110,7 @@ release() {
114
110
  if [ -z "${GPG_NO_SIGN-}" ] && [ -n "${GPG_KEY-}" ] && [ -n "${GPG_KEY_ID-}" ]; then
115
111
  git tag --sign "${NEXT_RELEASE_TAG-}" "${CHECKOUT_SHA}" --message "Release, tag and sign ${NEXT_RELEASE_TAG}"
116
112
  log "Created GPG signed Git tag [${NEXT_RELEASE_TAG}]!"
117
- elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUB_KEY-}" ]; then
113
+ elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUBLIC_KEY-}" ]; then
118
114
  git tag --sign "${NEXT_RELEASE_TAG}" "${CHECKOUT_SHA}" --message "Release, tag and sign ${NEXT_RELEASE_TAG}"
119
115
  log "Created SSH signed Git tag [${NEXT_RELEASE_TAG}]!"
120
116
  else
@@ -34,12 +34,6 @@ prepare() {
34
34
  SSH_PUBLIC_KEY_FILE=$(mktemp)
35
35
  printf "%s" "${SSH_PUBLIC_KEY}" >>"${SSH_PUBLIC_KEY_FILE}"
36
36
 
37
- git config --local commit.gpgsign true
38
- git config --local user.signingkey "${SSH_PUBLIC_KEY_FILE}"
39
- git config --local tag.forceSignAnnotated true
40
- git config --local gpg.format ssh
41
- log_verbose "Git SSH sign key is set"
42
-
43
37
  if [ -n "${SSH_KEY_PASSPHRASE-}" ]; then
44
38
  SSH_ASKPASS_FILE=$(mktemp)
45
39
  chmod 0755 "${SSH_ASKPASS_FILE}"
@@ -50,12 +44,14 @@ prepare() {
50
44
  log_verbose "Git SSH passphrase set"
51
45
  fi
52
46
 
53
- if ! ssh-add -L | grep -q "${SSH_PUBLIC_KEY-}"; then
54
- printf "%s" "${SSH_PRIVATE_KEY}" | base64 --decode | ssh-add -
55
- log_verbose "Git SSH key import loaded"
56
- else
57
- log_verbose "Git SSH key import skipped"
58
- fi
47
+ printf "%s" "${SSH_PRIVATE_KEY}" | base64 --decode | ssh-add -
48
+ log_verbose "Git SSH key import loaded"
49
+
50
+ git config --local commit.gpgsign true
51
+ git config --local user.signingkey "${SSH_PUBLIC_KEY_FILE}"
52
+ git config --local tag.forceSignAnnotated true
53
+ git config --local gpg.format ssh
54
+ log_verbose "Git SSH sign key is set"
59
55
 
60
56
  if [ -n "${SSH_KEY_PASSPHRASE-}" ]; then
61
57
  rm -rf "${SSH_ASKPASS}"
@@ -90,9 +86,9 @@ cleanup() {
90
86
  fi
91
87
 
92
88
  log_verbose "Git GPG config cleanup"
93
- elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUB_KEY-}" ]; then
89
+ elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUBLIC_KEY-}" ]; then
94
90
  git config --local --unset commit.gpgsign true
95
- git config --local --unset user.signingkey "${SSH_PUB_KEY}"
91
+ git config --local --unset user.signingkey "${SSH_PUBLIC_KEY}"
96
92
  git config --local --unset tag.forceSignAnnotated true
97
93
  git config --local --unset gpg.format ssh
98
94
 
@@ -129,7 +125,7 @@ release() {
129
125
 
130
126
  if [ -z "${GPG_NO_SIGN-}" ] && [ -n "${GPG_KEY-}" ] && [ -n "${GPG_KEY_ID-}" ]; then
131
127
  git commit --sign -m "chore(${PKG_NAME}): update \`package.json\` version to ${NEXT_RELEASE_VERSION-}" --no-verify
132
- elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUB_KEY-}" ]; then
128
+ elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUBLIC_KEY-}" ]; then
133
129
  git commit --sign -m "chore(${PKG_NAME}): update \`package.json\` version to ${NEXT_RELEASE_VERSION}" --no-verify
134
130
  else
135
131
  git commit --no-gpg-sign -m "chore(${PKG_NAME}): update \`package.json\` version to ${NEXT_RELEASE_VERSION}" --no-verify
@@ -137,7 +133,7 @@ release() {
137
133
  else
138
134
  if [ -z "${GPG_NO_SIGN-}" ] && [ -n "${GPG_KEY-}" ] && [ -n "${GPG_KEY_ID-}" ]; then
139
135
  git commit --sign -m "chore(ci): update \`package.json\` version to ${NEXT_RELEASE_VERSION}" --no-verify
140
- elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUB_KEY-}" ]; then
136
+ elif [ -z "${SSH_NO_SIGN-}" ] && [ -n "${SSH_PUBLIC_KEY-}" ]; then
141
137
  git commit --sign -m "chore(ci): update \`package.json\` version to ${NEXT_RELEASE_VERSION}" --no-verify
142
138
  else
143
139
  git commit --no-gpg-sign -m "chore(ci): update \`package.json\` version to ${NEXT_RELEASE_VERSION}" --no-verify