mirror of
https://github.com/Icinga/icinga-php-library.git
synced 2025-07-22 21:24:42 +02:00
README, composer: upgrade, release
This commit is contained in:
parent
575bc1c147
commit
3871c67584
@ -5,14 +5,14 @@ This module ships the new Icinga PHP library. Please download the latest
|
|||||||
release and install it like any other module.
|
release and install it like any other module.
|
||||||
|
|
||||||
> **HINT**: Do NOT install the GIT master, it will not work! Checking out a
|
> **HINT**: Do NOT install the GIT master, it will not work! Checking out a
|
||||||
> branch like `stable/0.2.1` or a tag like `v0.2.1` is fine.
|
> branch like `stable/0.3.0` or a tag like `v0.3.0` is fine.
|
||||||
|
|
||||||
Sample Tarball installation
|
Sample Tarball installation
|
||||||
---------------------------
|
---------------------------
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
MODULE_NAME=ipl
|
MODULE_NAME=ipl
|
||||||
MODULE_VERSION=v0.2.1
|
MODULE_VERSION=v0.3.0
|
||||||
MODULES_PATH="/usr/share/icingaweb2/modules"
|
MODULES_PATH="/usr/share/icingaweb2/modules"
|
||||||
MODULE_PATH="${MODULES_PATH}/${MODULE_NAME}"
|
MODULE_PATH="${MODULES_PATH}/${MODULE_NAME}"
|
||||||
RELEASES="https://github.com/Icinga/icingaweb2-module-${MODULE_NAME}/archive"
|
RELEASES="https://github.com/Icinga/icingaweb2-module-${MODULE_NAME}/archive"
|
||||||
@ -27,7 +27,7 @@ Sample GIT installation
|
|||||||
|
|
||||||
```sh
|
```sh
|
||||||
MODULE_NAME=ipl
|
MODULE_NAME=ipl
|
||||||
MODULE_VERSION=v0.2.1
|
MODULE_VERSION=v0.3.0
|
||||||
REPO="https://github.com/Icinga/icingaweb2-module-${MODULE_NAME}"
|
REPO="https://github.com/Icinga/icingaweb2-module-${MODULE_NAME}"
|
||||||
MODULES_PATH="/usr/share/icingaweb2/modules"
|
MODULES_PATH="/usr/share/icingaweb2/modules"
|
||||||
git clone ${REPO} "${MODULES_PATH}/${MODULE_NAME}" --branch "${MODULE_VERSION}"
|
git clone ${REPO} "${MODULES_PATH}/${MODULE_NAME}" --branch "${MODULE_VERSION}"
|
||||||
@ -47,4 +47,4 @@ Developer Documentation
|
|||||||
|
|
||||||
e.g.
|
e.g.
|
||||||
|
|
||||||
./bin/make-release.sh 0.2.1
|
./bin/make-release.sh 0.3.0
|
||||||
|
@ -8,6 +8,12 @@ if [[ -z $VERSION ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
function fail {
|
||||||
|
local msg="$1"
|
||||||
|
echo "ERROR: $msg"
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
TAG=$(git tag | grep -c "$VERSION")
|
TAG=$(git tag | grep -c "$VERSION")
|
||||||
|
|
||||||
if [[ "$TAG" -ne "0" ]]; then
|
if [[ "$TAG" -ne "0" ]]; then
|
||||||
@ -20,8 +26,8 @@ BRANCH="stable/$VERSION"
|
|||||||
git checkout -b "$BRANCH"
|
git checkout -b "$BRANCH"
|
||||||
git rm -rf vendor
|
git rm -rf vendor
|
||||||
rm -rf vendor
|
rm -rf vendor
|
||||||
rm composer.lock
|
rm -f composer.lock
|
||||||
composer install
|
composer install || fail "composer install failed"
|
||||||
find vendor/ -type f -name "*.php" \
|
find vendor/ -type f -name "*.php" \
|
||||||
| grep -v '/examples/' \
|
| grep -v '/examples/' \
|
||||||
| grep -v '/example/' \
|
| grep -v '/example/' \
|
||||||
@ -31,11 +37,12 @@ find vendor/ -type f -name "*.php" \
|
|||||||
find vendor/ -type f -name LICENSE | xargs -L1 git add -f
|
find vendor/ -type f -name LICENSE | xargs -L1 git add -f
|
||||||
sed -i.bak "s/^Version:.*/Version: v$VERSION/" module.info && rm -f module.info.bak
|
sed -i.bak "s/^Version:.*/Version: v$VERSION/" module.info && rm -f module.info.bak
|
||||||
git add module.info
|
git add module.info
|
||||||
|
git add composer.lock
|
||||||
git commit -m "Version v$VERSION"
|
git commit -m "Version v$VERSION"
|
||||||
|
|
||||||
rm -f composer.lock
|
|
||||||
rm -rf vendor
|
rm -rf vendor
|
||||||
git checkout vendor
|
git checkout vendor
|
||||||
|
composer validate --no-check-all --strict || fail "Composer validate failed"
|
||||||
|
|
||||||
git tag -a v$VERSION -m "Version v$VERSION"
|
git tag -a v$VERSION -m "Version v$VERSION"
|
||||||
echo "Finished, tagged v$VERSION"
|
echo "Finished, tagged v$VERSION"
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "icinga/icingaweb2-module-ipl",
|
"name": "icinga/icingaweb2-module-ipl",
|
||||||
"type": "project",
|
"type": "project",
|
||||||
|
"description": "Icinga Web 2 - bundled ipl libraries",
|
||||||
"homepage": "https://github.com/Icinga/icingaweb2-module-ipl",
|
"homepage": "https://github.com/Icinga/icingaweb2-module-ipl",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"config": {
|
"config": {
|
||||||
@ -17,9 +18,9 @@
|
|||||||
"require": {
|
"require": {
|
||||||
"php": ">=5.4.0",
|
"php": ">=5.4.0",
|
||||||
"guzzlehttp/psr7": "^1.5",
|
"guzzlehttp/psr7": "^1.5",
|
||||||
"ipl/html": "^0.1",
|
"ipl/html": ">=0.2.1",
|
||||||
"ipl/sql": "dev-master",
|
"ipl/sql": "dev-master",
|
||||||
"ipl/stdlib": "^0.1"
|
"ipl/stdlib": ">=0.2"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user