Skip to content

Commit

Permalink
Merge branch 'dev' into 'master'
Browse files Browse the repository at this point in the history
Dev

See merge request ergo/rosen-bridge/contract!49
  • Loading branch information
vorujack committed May 9, 2023
2 parents 6e5eb23 + bd63022 commit 136342c
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 32 deletions.
53 changes: 24 additions & 29 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,21 @@ on:
push:
branches:
- master
tags:
- '*'
pull_request:
types:
- opened
- synchronize
release:
types: [published]


jobs:
tests:
name: Tests
strategy:
matrix:
os: [ubuntu-latest]
scala: [2.12.7]
java: [[email protected]]
os: [ ubuntu-latest ]
scala: [ 2.12.7 ]
java: [ [email protected] ]
runs-on: ${{ matrix.os }}

steps:
Expand Down Expand Up @@ -52,9 +51,9 @@ jobs:
needs: tests
strategy:
matrix:
os: [ubuntu-latest]
scala: [2.12.7]
java: [[email protected]]
os: [ ubuntu-latest ]
scala: [ 2.12.7 ]
java: [ [email protected] ]
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -80,42 +79,38 @@ jobs:
run: |
sbt ++${{ matrix.scala }} assembly
- name: RUN Jar File release
if: github.event_name == 'release'
- name: RUN Jar File for push to master
if: github.ref_type == 'branch'
id: set-version
run: |
VERSION_STRING=$(sbt -Dsbt.supershell=false -error "print version")
APP_VERSION_STRING=$(echo "${VERSION_STRING:0:5}")-$(git rev-parse --short HEAD)
echo APP_VERSION=$APP_VERSION_STRING >> "$GITHUB_OUTPUT"
ROSEN=$(find . -name 'contract-rosen-bridge-*.jar')
java -jar $ROSEN all --version ${{ github.event.release.tag_name }}
java -jar $ROSEN all --version $APP_VERSION_STRING
- name: Upload JSON files
uses: softprops/action-gh-release@v1
if: github.event_name == 'release'
with:
if: github.ref_type == 'branch'
with:
tag_name: ${{ steps.build-app.outputs.APP_VERSION }}
prerelease: true
files: |
contracts-*.json
tokensMap-*.json
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}


- uses: dev-drprasad/[email protected]
if: github.event_name != 'release'
with:
delete_release: true
tag_name: Latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: RUN Jar File for push to master
if: github.event_name != 'release'
- name: RUN Jar File release
if: github.ref_type == 'tag'
run: |
ROSEN=$(find . -name 'contract-rosen-bridge-*.jar')
java -jar $ROSEN all --version Latest
java -jar $ROSEN all --version ${{ github.ref_name }}
- name: Upload JSON files
uses: softprops/action-gh-release@v1
if: github.event_name != 'release'
with:
tag_name: Latest
if: github.ref_type == 'tag'
with:
files: |
contracts-*.json
tokensMap-*.json
Expand Down
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ libraryDependencies ++= Seq(

name := "contract"
ThisBuild / scalaVersion := "2.12.7"
ThisBuild / version := "0.1.0-SNAPSHOT"
ThisBuild / version := "1.0.0"
ThisBuild / organization := "rosen.bridge"
ThisBuild / organizationName := "rosen-bridge"
ThisBuild / publishMavenStyle := true
Expand Down
2 changes: 1 addition & 1 deletion tokensMap/Ada.mainnet-public-soft-launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"assetName": "414441",
"decimals": 6,
"metaData": {
"type": "ADA",
"type": "native",
"residency": "native"
}
}
Expand Down
2 changes: 1 addition & 1 deletion tokensMap/Erg.mainnet-public-soft-launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"tokenName": "erg",
"decimals": 9,
"metaData": {
"type": "ERG",
"type": "native",
"residency": "native"
}
},
Expand Down

0 comments on commit 136342c

Please sign in to comment.