Compare commits
3 Commits
Author | SHA1 | Date | |
---|---|---|---|
ee4b5003cd
|
|||
5aa4369f83
|
|||
69738f8be6
|
@ -1,7 +1,13 @@
|
||||
# Octojpack - Easy Joomla Extension Packaging
|
||||
<h2><img align="middle" src="https://raw.githubusercontent.com/odb/official-bash-logo/master/assets/Logos/Icons/PNG/64x64.png" >
|
||||
Octojpack - Easy Joomla Extension Packaging
|
||||
</h2>
|
||||
|
||||
Written by Llewellyn van der Merwe (@llewellynvdm)
|
||||
|
||||
With this script we can easily package multiple extensions in an automated way from a json configuration file, and environment variables.
|
||||
|
||||
Linted by [#ShellCheck](https://github.com/koalaman/shellcheck)
|
||||
|
||||
> program only for ubuntu/debian and Gitea systems at this time (should you like to use it on other OS's please open and issue...)
|
||||
---
|
||||
# Install
|
||||
|
@ -3,7 +3,7 @@
|
||||
# Program name
|
||||
PROGRAM_NAME="Octojpack"
|
||||
PROGRAM_CODE="octojpack"
|
||||
PROGRAM_VERSION="1.3.1"
|
||||
PROGRAM_VERSION="1.3.2"
|
||||
PROGRAM_V="1.3"
|
||||
PROGRAM_URL="https://git.vdm.dev/octoleo/${PROGRAM_CODE}"
|
||||
|
||||
@ -249,7 +249,7 @@ function setValueFromJson() {
|
||||
}
|
||||
|
||||
# Safely use eval to dynamically set the value
|
||||
eval "$target_var"=\'"$value"\'
|
||||
declare -g "$target_var"="$value"
|
||||
}
|
||||
|
||||
# Get value from JSON
|
||||
@ -1033,7 +1033,11 @@ function setRepository() {
|
||||
# give little notice of progress
|
||||
_echo "[info] Pushing (TO CREATE) changes to (${VDM_PACKAGE_OWNER}/${VDM_PACKAGE_REPO}) repository"
|
||||
# push to creat the repository (if allowed)
|
||||
git push -u origin master >/dev/null 2>&1 || return 30
|
||||
if [[ "${VDM_PACKAGE_REPO_BRANCH}" == 'default' ]]; then
|
||||
git push -u origin master >/dev/null 2>&1 || return 30
|
||||
else
|
||||
git push -u origin "${VDM_PACKAGE_REPO_BRANCH:-master}" >/dev/null 2>&1 || return 30
|
||||
fi
|
||||
git push --tags >/dev/null 2>&1 || return 30
|
||||
fi
|
||||
fi
|
||||
@ -1050,7 +1054,7 @@ function getExistingRepository() {
|
||||
git clone "ssh://git@${VDM_PACKAGE_URL}/${VDM_PACKAGE_OWNER}/${VDM_PACKAGE_REPO}.git" >/dev/null 2>&1 || return 23
|
||||
else
|
||||
# clone the existing repository
|
||||
git clone -b "${VDM_PACKAGE_REPO_BRANCH}" "ssh://git@${VDM_PACKAGE_URL}/${VDM_PACKAGE_OWNER}/${VDM_PACKAGE_REPO}.git" >/dev/null 2>&1 || return 23
|
||||
git clone -b "${VDM_PACKAGE_REPO_BRANCH:-master}" "ssh://git@${VDM_PACKAGE_URL}/${VDM_PACKAGE_OWNER}/${VDM_PACKAGE_REPO}.git" >/dev/null 2>&1 || return 23
|
||||
fi
|
||||
# success
|
||||
return 0
|
||||
|
Reference in New Issue
Block a user