From f7b5e91206a8af8b26290c51a930f23074ec4727 Mon Sep 17 00:00:00 2001 From: Tim Buckley Date: Wed, 12 Jun 2019 17:16:56 -0600 Subject: [PATCH] don't patch versions for PRs (duh) --- .circleci/config.yml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bc12c1f..bcd2e35 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -11,10 +11,12 @@ jobs: - run: name: patch crate version command: | - version=$(echo "$CIRCLE_TAG" | sed -e 's/^v//') - sed -i -e "s/version = \"0.1.0\"/version = \"$version\"/" Cargo.toml + if [[ -n "$CIRCLE_TAG" ]]; then + version=$(echo "$CIRCLE_TAG" | sed -e 's/^v//') + sed -i -e "s/version = \"0.1.0\"/version = \"$version\"/" Cargo.toml - cargo update -p woodchipper + cargo update -p woodchipper + fi - run: name: Build static linux x86_64 command: cargo build --release --locked @@ -54,10 +56,12 @@ jobs: - run: name: patch crate version command: | - version=$(echo "$CIRCLE_TAG" | sed -e 's/^v//') - sed -i -e "s/version = \"0.1.0\"/version = \"$version\"/" Cargo.toml + if [[ -n "$CIRCLE_TAG" ]]; then + version=$(echo "$CIRCLE_TAG" | sed -e 's/^v//') + sed -i -e "s/version = \"0.1.0\"/version = \"$version\"/" Cargo.toml - cargo update -p woodchipper + cargo update -p woodchipper + fi - run: name: Build windows x86_64 command: |