From 8c97d8bdf0ec2b099aefc1eb76cace79ff932d27 Mon Sep 17 00:00:00 2001 From: Michael Jerger Date: Fri, 12 Mar 2021 09:42:17 +0000 Subject: [PATCH] improve prerelease ci --- .gitlab-ci.yml | 11 +++++------ package.json | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2c46fa7..d343408 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -31,6 +31,8 @@ stages: .clj-job: &clj image: clojure:lein-2.7.1-alpine + before_script: + - echo "{:auth {:repository-auth {#\"clojars\" {:username \"${CLOJARS_USER}\" :password \"${CLOJARS_PASSWORD}\" }}}}" > ~/.lein/profiles.clj build_and_test: <<: *cljs @@ -42,7 +44,7 @@ build_and_test: paths: - .m2 -#activate as soon as https://github.com/thheller/shadow-cljs/issues/843 is implemented +#activate as soon as https://github.com/thheller/shadow-cljs/issues/843 is implemented .report: <<: *cljs stage: build_and_test @@ -84,10 +86,8 @@ upload-cljs-prerelease: - if: '$CI_COMMIT_BRANCH == "master" && $CI_COMMIT_TAG == null' script: - cp package.json target/npm-build/ + - sed -i 's|SNAPSHOT|'$(date +"%Y%m%d%H%M%S")'|' ./target/npm-build/package.json - npm publish ./target/npm-build --access public - # unsure wether that's a good idea to bump versions from ci. - #- npm version prerelease -m "[skip-ci] version bump prerelease version" - #- git push upload-clj-prerelease: <<: *clj @@ -95,8 +95,7 @@ upload-clj-prerelease: rules: - if: '$CI_COMMIT_BRANCH == "master" && $CI_COMMIT_TAG == null' script: - - echo "{:user {:auth {#\"clojars\" {:username :env/CLOJARS_USER :password :env/CLOJARS_PASSWORD}}}}" > ~/.lein/profiles.clj - - lein deploy + - lein deploy clojars upload-js-release: <<: *js-upload diff --git a/package.json b/package.json index 998f56e..4a3e771 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "mastodon-bot", "description": "Bot to publish twitter, tumblr or rss posts to an mastodon account.", "author": "Dmitri Sotnikov", - "version": "1.10.5-20210311180500", + "version": "1.10.5-SNAPSHOT", "homepage": "https://github.com/yogthos/mastodon-bot", "repository": "https://www.npmjs.com/package/mastodon-bot", "license": "MIT",