Skip to content

Commit

Permalink
Update tokenlist.json in DragonSwap Client
Browse files Browse the repository at this point in the history
  • Loading branch information
Marko authored and Marko committed Jan 24, 2024
1 parent 4d3ad70 commit 55dfdca
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/push-tokens.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,16 @@ jobs:
- name: Update tokenlist.json in DragonSwap Client
run: |
# Set up necessary variables
SOURCE_FILE_URL="https://raw.githubusercontent.com/dragonswap-app/assets/main/tokenlist.json?token=${{ secrets.GH_TOKEN }}"
SOURCE_REPO_OWNER=dragonswap-app
SOURCE_REPO_NAME=assets
SOURCE_FILE_PATH=tokenlist.json
TARGET_REPO_OWNER=NIMA-Enterprises
TARGET_REPO_NAME=dragonswap-client
TARGET_FILE_PATH=apps/dragon-swap/tokenlist.json
GITHUB_TOKEN=${{ secrets.GH_TOKEN }}
# Get the content of tokenlist.json from the source URL
SOURCE_FILE_CONTENT=$(curl -sSL $SOURCE_FILE_URL)
SOURCE_FILE_CONTENT=$(curl -sSL -H "Authorization: token $GITHUB_TOKEN" \
"https://raw.githubusercontent.com/$SOURCE_REPO_OWNER/$SOURCE_REPO_NAME/main/$SOURCE_FILE_PATH")
# Update tokenlist.json in the target repo
curl -sSL -X PUT -H "Authorization: token $GITHUB_TOKEN" \
Expand Down

0 comments on commit 55dfdca

Please sign in to comment.