forked from qt-creator/qt-creator
Fixes: - Quick fix for running on mac...
This commit is contained in:
@@ -16,14 +16,14 @@ fi
|
|||||||
OLD=`sed 's/\./\\\\./g' <<<"$1"`
|
OLD=`sed 's/\./\\\\./g' <<<"$1"`
|
||||||
NEW=`sed 's/\./\\\\./g' <<<"$2"`
|
NEW=`sed 's/\./\\\\./g' <<<"$2"`
|
||||||
|
|
||||||
OLD_MAJOR=`sed 's/^\([0-9]\+\)\.[0-9]\+\.[0-9]\+$/\1/' <<<"$1"`
|
OLD_MAJOR=`sed 's/^\([0-9]\)\.[0-9]\.[0-9]$/\1/' <<<"$1"`
|
||||||
NEW_MAJOR=`sed 's/^\([0-9]\+\)\.[0-9]\+\.[0-9]\+$/\1/' <<<"$2"`
|
NEW_MAJOR=`sed 's/^\([0-9]\)\.[0-9]\.[0-9]$/\1/' <<<"$2"`
|
||||||
|
|
||||||
OLD_MINOR=`sed 's/^[0-9]\+\.\([0-9]\+\)\.[0-9]\+$/\1/' <<<"$1"`
|
OLD_MINOR=`sed 's/^[0-9]\.\([0-9]\)\.[0-9]$/\1/' <<<"$1"`
|
||||||
NEW_MINOR=`sed 's/^[0-9]\+\.\([0-9]\+\)\.[0-9]\+$/\1/' <<<"$2"`
|
NEW_MINOR=`sed 's/^[0-9]\.\([0-9]\)\.[0-9]$/\1/' <<<"$2"`
|
||||||
|
|
||||||
OLD_RELEASE=`sed 's/^[0-9]\+\.[0-9]\+\.\([0-9]\+\)$/\1/' <<<"$1"`
|
OLD_RELEASE=`sed 's/^[0-9]\.[0-9]\.\([0-9]\)$/\1/' <<<"$1"`
|
||||||
NEW_RELEASE=`sed 's/^[0-9]\+\.[0-9]\+\.\([0-9]\+\)$/\1/' <<<"$2"`
|
NEW_RELEASE=`sed 's/^[0-9]\.[0-9]\.\([0-9]\)$/\1/' <<<"$2"`
|
||||||
|
|
||||||
OLD_THREE="${OLD_MAJOR}${OLD_MINOR}${OLD_RELEASE}"
|
OLD_THREE="${OLD_MAJOR}${OLD_MINOR}${OLD_RELEASE}"
|
||||||
NEW_THREE="${NEW_MAJOR}${NEW_MINOR}${NEW_RELEASE}"
|
NEW_THREE="${NEW_MAJOR}${NEW_MINOR}${NEW_RELEASE}"
|
||||||
@@ -61,7 +61,7 @@ pushd "${SCRIPT_DIR}" &>/dev/null || exit 1
|
|||||||
## Patch *.pluginspec
|
## Patch *.pluginspec
|
||||||
while read i ; do
|
while read i ; do
|
||||||
echo "Patching \`$i'"
|
echo "Patching \`$i'"
|
||||||
TMPFILE=`mktemp /tmp/versionPatch.XXXXXX`
|
TMPFILE=`mktemp versionPatch.XXXXXX`
|
||||||
sed -e 's/version="'"${OLD}"'"/version="'"${NEW}"'"/' \
|
sed -e 's/version="'"${OLD}"'"/version="'"${NEW}"'"/' \
|
||||||
-e 's/compatVersion="'"${OLD}"'"/compatVersion="'"${NEW}"'"/' \
|
-e 's/compatVersion="'"${OLD}"'"/compatVersion="'"${NEW}"'"/' \
|
||||||
"${i}" > "${TMPFILE}"
|
"${i}" > "${TMPFILE}"
|
||||||
@@ -70,7 +70,7 @@ done < <(find . -name '*.pluginspec')
|
|||||||
|
|
||||||
|
|
||||||
## Patch coreconstants.h
|
## Patch coreconstants.h
|
||||||
TMPFILE=`mktemp /tmp/versionPatch.XXXXXX`
|
TMPFILE=`mktemp versionPatch.XXXXXX`
|
||||||
CORE_CONSTANT_H="${SCRIPT_DIR}/src/plugins/coreplugin/coreconstants.h"
|
CORE_CONSTANT_H="${SCRIPT_DIR}/src/plugins/coreplugin/coreconstants.h"
|
||||||
echo "Patching \`${CORE_CONSTANT_H}'"
|
echo "Patching \`${CORE_CONSTANT_H}'"
|
||||||
sed \
|
sed \
|
||||||
@@ -82,7 +82,7 @@ mv -f "${TMPFILE}" "${CORE_CONSTANT_H}"
|
|||||||
|
|
||||||
|
|
||||||
## Patch installer.rc
|
## Patch installer.rc
|
||||||
TMPFILE=`mktemp /tmp/versionPatch.XXXXXX`
|
TMPFILE=`mktemp versionPatch.XXXXXX`
|
||||||
INSTALLER_RC="${SCRIPT_DIR}/../../dev/ide/nightly_builds/installer/installer.rc"
|
INSTALLER_RC="${SCRIPT_DIR}/../../dev/ide/nightly_builds/installer/installer.rc"
|
||||||
echo "Patching \`${INSTALLER_RC}'"
|
echo "Patching \`${INSTALLER_RC}'"
|
||||||
sed \
|
sed \
|
||||||
@@ -94,7 +94,7 @@ mv -f "${TMPFILE}" "${INSTALLER_RC}"
|
|||||||
|
|
||||||
|
|
||||||
## Patch Info.plist
|
## Patch Info.plist
|
||||||
TMPFILE=`mktemp /tmp/versionPatch.XXXXXX`
|
TMPFILE=`mktemp versionPatch.XXXXXX`
|
||||||
INFO_PLIST="${SCRIPT_DIR}/share/qtcreator/Info.plist"
|
INFO_PLIST="${SCRIPT_DIR}/share/qtcreator/Info.plist"
|
||||||
echo "Patching \`${INFO_PLIST}'"
|
echo "Patching \`${INFO_PLIST}'"
|
||||||
sed \
|
sed \
|
||||||
@@ -104,7 +104,7 @@ mv -f "${TMPFILE}" "${INFO_PLIST}"
|
|||||||
|
|
||||||
|
|
||||||
## Patch qtcreator.qdocconf
|
## Patch qtcreator.qdocconf
|
||||||
TMPFILE=`mktemp /tmp/versionPatch.XXXXXX`
|
TMPFILE=`mktemp versionPatch.XXXXXX`
|
||||||
QDOCCONF="${SCRIPT_DIR}/doc/qtcreator.qdocconf"
|
QDOCCONF="${SCRIPT_DIR}/doc/qtcreator.qdocconf"
|
||||||
echo "Patching \`${QDOCCONF}'"
|
echo "Patching \`${QDOCCONF}'"
|
||||||
sed \
|
sed \
|
||||||
@@ -115,11 +115,11 @@ mv -f "${TMPFILE}" "${QDOCCONF}"
|
|||||||
|
|
||||||
|
|
||||||
## Patch qtcreator.qdoc
|
## Patch qtcreator.qdoc
|
||||||
TMPFILE=`mktemp /tmp/versionPatch.XXXXXX`
|
TMPFILE=`mktemp versionPatch.XXXXXX`
|
||||||
QDOC="${SCRIPT_DIR}/doc/qtcreator.qdoc"
|
QDOC="${SCRIPT_DIR}/doc/qtcreator.qdoc"
|
||||||
echo "Patching \`${QDOC}'"
|
echo "Patching \`${QDOC}'"
|
||||||
sed \
|
sed \
|
||||||
-e 's/\(The current version of Qt Creator is \)'${OLD_DOT_THREE}'/\1'${NEW_DOT_THREE}'/' \
|
-e 's/'${OLD_DOT_THREE}'/'${NEW_DOT_THREE}'/' \
|
||||||
"${QDOC}" > "${TMPFILE}"
|
"${QDOC}" > "${TMPFILE}"
|
||||||
mv -f "${TMPFILE}" "${QDOC}"
|
mv -f "${TMPFILE}" "${QDOC}"
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user