Team Ai
Apppublic

errorcode418/php

sourceHugging Faceupdated 1y agoView on Hugging Face
0likes
update-resources.sh20 linesDownload Raw Back to uap-php
1#! /bin/bash2 3function try_catch() {4    output=`"$@" &>/dev/stdout`5    if [ $? -gt 0 ]; then6        echo -e "Command $@ failed\n\n$output"7        exit 18    fi9}10 11try_catch git pull12try_catch git submodule foreach git pull origin master13try_catch bin/uaparser ua-parser:convert uap-core/regexes.yaml14try_catch vendor/bin/phpunit --stop-on-failure15try_catch git commit -a -m "Scheduled resource update"16try_catch git push origin master17new_version=`git tag | sort --version-sort | tail -n 1 | awk -F. -v OFS=. 'NF==1{print ++$NF}; NF>1{if(length($NF+1)>length($NF))$(NF-1)++; $NF=sprintf("%0*d", length($NF), ($NF+1)%(10^length($NF))); print}'`18try_catch git tag $new_version19git push origin $new_version20