diff --git a/.circleci/config.yml b/.circleci/config.yml index 3ef40f46..cd440346 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -155,7 +155,7 @@ jobs: name: Publish Release command: | echo "Attempting to create release for Cider v${APP_VERSION} on the ${CIRCLE_BRANCH} branch." - gh release create "v${APP_VERSION}" --title "Cider Version ${APP_VERSION} (${CIRCLE_BRANCH})" --notes "**Beta Release** + gh release create "v${APP_VERSION}" --title "Cider Version ${APP_VERSION} (${CIRCLE_BRANCH})" --target "ciderapp/cider@${CIRCLE_SHA1}" --notes "**Beta Release** A full changelog is unavailable, but you can view the branch comparison [here](https://github.com/ciderapp/cider/compare/stable...main). These builds are considered bleeding edge, expect bugs and please do not use this as a representation of the full app. Our full support disclaimer can be found [here](https://docs.cider.sh/support/disclaimer#support-nightly-beta-releases)." -R ciderapp/cider-releases ~/Cider/dist/artifacts/*.deb ~/Cider/dist/artifacts/*.AppImage ~/Cider/dist/artifacts/*.snap ~/Cider/dist/artifacts/*.exe ~/Cider/dist/artifacts/*.yml ~/Cider/dist/artifacts/*.blockmap diff --git a/resources/version.sh b/resources/version.sh index 43bb4d26..8f3c2880 100755 --- a/resources/version.sh +++ b/resources/version.sh @@ -12,25 +12,11 @@ fi SHA_DATE=$(git show -s --format=%ci $STABLE_SHA) COMMIT_SINCE_STABLE=$(git rev-list $STABLE_SHA..HEAD --count --since="$SHA_DATE") CURRENT_VERSION=$(node -p -e "require('./package.json').version") -LATEST_VERSION=$(curl -s https://api.github.com/repos/ciderapp/cider-releases/releases/latest | grep tag_name | cut -d '"' -f 4 | sed 's/v//' | xargs) - -# Debugging -echo "STABLE_SHA: $STABLE_SHA" -echo "SHA_DATE: $SHA_DATE" -echo "COMMIT_SINCE_STABLE: $COMMIT_SINCE_STABLE" -echo "CURRENT_VERSION: $CURRENT_VERSION" -echo "LATEST_VERSION: $LATEST_VERSION" # Set the version number for commits on main branch if [[ ($CIRCLE_BRANCH == "main" || $GITHUB_REF_NAME == "main") && $COMMIT_SINCE_STABLE -gt 0 ]]; then NEW_VERSION="${CURRENT_VERSION}-beta.${COMMIT_SINCE_STABLE}" - # This is shit - if [[ $GITHUB_REF_NAME == "main" && $CURRENT_VERSION == $NEW_VERSION ]]; then - echo "No version could be made. Picking latest tag." - NEW_VERSION="${LATEST_VERSION}" - fi - # Update the version in package.json if [[ $RUNNER_OS == "macOS" ]]; then sed -i "" -e "s/$CURRENT_VERSION/$NEW_VERSION/" package.json