check supportedsites.rst in release script

pull/86/head
Mike Fährmann 7 years ago
parent 241eda8c3d
commit 7121eeae8b
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88

@ -1,10 +1,12 @@
# Changelog # Changelog
## Unreleased
## 1.3.1 - 2018-03-16 ## 1.3.1 - 2018-03-16
- Added support for: - Added support for:
- `mangadex` - https://mangadex.org/ - `mangadex` - https://mangadex.org/
- `artstation` - https://www.artstation.com/ - `artstation` - https://www.artstation.com/
- Added CloudFlare DDoS protection bypass to `komikcast` extractors - Added Cloudflare DDoS protection bypass to `komikcast` extractors
- Changed archive ID formats for `deviantart` folders and collections - Changed archive ID formats for `deviantart` folders and collections
- Improved error handling for `deviantart` API calls - Improved error handling for `deviantart` API calls
- Removed `imgchili` and various smaller image hosts - Removed `imgchili` and various smaller image hosts

@ -6,4 +6,4 @@
# it under the terms of the GNU General Public License version 2 as # it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation. # published by the Free Software Foundation.
__version__ = "1.3.1" __version__ = "1.3.2-dev"

@ -12,6 +12,7 @@ CATEGORY_MAP = {
"2chan" : "Futaba Channel", "2chan" : "Futaba Channel",
"archivedmoe" : "Archived.Moe", "archivedmoe" : "Archived.Moe",
"archiveofsins" : "Archive of Sins", "archiveofsins" : "Archive of Sins",
"artstation" : "ArtStation",
"b4k" : "arch.b4k.co", "b4k" : "arch.b4k.co",
"deviantart" : "DeviantArt", "deviantart" : "DeviantArt",
"dokireader" : "Doki Reader", "dokireader" : "Doki Reader",

@ -15,6 +15,7 @@ prompt() {
cleanup() { cleanup() {
cd "${ROOTDIR}" cd "${ROOTDIR}"
echo Removing old build directory echo Removing old build directory
if [ -d ./build ]; then if [ -d ./build ]; then
rm -rf ./build rm -rf ./build
fi fi
@ -23,12 +24,14 @@ cleanup() {
update() { update() {
cd "${ROOTDIR}" cd "${ROOTDIR}"
echo Updating version to ${NEWVERSION} echo Updating version to ${NEWVERSION}
sed -i "s#\"${PYVERSION}\"#\"${NEWVERSION}\"#" "gallery_dl/version.py" sed -i "s#\"${PYVERSION}\"#\"${NEWVERSION}\"#" "gallery_dl/version.py"
sed -i "s#v${OLDVERSION}#v${NEWVERSION}#" "${README}" sed -i "s#v${OLDVERSION}#v${NEWVERSION}#" "${README}"
} }
update-dev() { update-dev() {
cd "${ROOTDIR}" cd "${ROOTDIR}"
IFS="." read MAJOR MINOR BUILD <<< "${NEWVERSION}" IFS="." read MAJOR MINOR BUILD <<< "${NEWVERSION}"
BUILD=$((BUILD+1)) BUILD=$((BUILD+1))
# update version to -dev # update version to -dev
@ -41,15 +44,16 @@ update-dev() {
build() { build() {
cd "${ROOTDIR}" cd "${ROOTDIR}"
# build wheel and source distributions
echo Building bdist_wheel and sdist echo Building bdist_wheel and sdist
python setup.py bdist_wheel sdist python setup.py bdist_wheel sdist
} }
build_windows() { build-windows() {
# build windows exe in vm cd "${ROOTDIR}"
echo Building Windows executable echo Building Windows executable
# build windows exe in vm
ln -fs "${ROOTDIR}" /tmp/ ln -fs "${ROOTDIR}" /tmp/
vmstart "Windows 7" & vmstart "Windows 7" &
disown disown
@ -72,6 +76,7 @@ build_windows() {
sign() { sign() {
cd "${ROOTDIR}/dist" cd "${ROOTDIR}/dist"
echo Signing files echo Signing files
gpg --detach-sign --armor gallery_dl-${NEWVERSION}-py3-none-any.whl gpg --detach-sign --armor gallery_dl-${NEWVERSION}-py3-none-any.whl
gpg --detach-sign --armor gallery_dl-${NEWVERSION}.tar.gz gpg --detach-sign --armor gallery_dl-${NEWVERSION}.tar.gz
gpg --detach-sign gallery-dl.exe gpg --detach-sign gallery-dl.exe
@ -89,9 +94,21 @@ changelog() {
"${CHANGELOG}" "${CHANGELOG}"
} }
supportedsites() {
cd "${ROOTDIR}"
echo Checking if "${SUPPORTEDSITES}" is up to date
./scripts/build_supportedsites.py
if ! git diff --quiet "${SUPPORTEDSITES}"; then
echo "updated ${SUPPORTEDSITES} contains changes"
exit 4
fi
}
git-upload() { git-upload() {
cd "${ROOTDIR}" cd "${ROOTDIR}"
echo Pushing changes to github echo Pushing changes to github
git add "gallery_dl/version.py" "${README}" "${CHANGELOG}" git add "gallery_dl/version.py" "${README}" "${CHANGELOG}"
git commit -S -m "release version ${NEWVERSION}" git commit -S -m "release version ${NEWVERSION}"
git tag -s -m "version ${NEWVERSION}" "v${NEWVERSION}" git tag -s -m "version ${NEWVERSION}" "v${NEWVERSION}"
@ -102,6 +119,7 @@ git-upload() {
pypi-upload() { pypi-upload() {
cd "${ROOTDIR}/dist" cd "${ROOTDIR}/dist"
echo Uploading to PyPI echo Uploading to PyPI
twine upload gallery_dl-${NEWVERSION}* twine upload gallery_dl-${NEWVERSION}*
} }
@ -109,6 +127,7 @@ pypi-upload() {
ROOTDIR="$(realpath "$(dirname "$0")/..")/" ROOTDIR="$(realpath "$(dirname "$0")/..")/"
README="README.rst" README="README.rst"
CHANGELOG="CHANGELOG.md" CHANGELOG="CHANGELOG.md"
SUPPORTEDSITES="./docs/supportedsites.rst"
LASTTAG="$(git describe --abbrev=0 --tags)" LASTTAG="$(git describe --abbrev=0 --tags)"
OLDVERSION="${LASTTAG#v}" OLDVERSION="${LASTTAG#v}"
@ -127,10 +146,11 @@ fi
prompt prompt
supportedsites
cleanup cleanup
update update
build build
build_windows build-windows
sign sign
changelog changelog
git-upload git-upload

Loading…
Cancel
Save