Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .changelog/6.feature.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add USD ROSE prices at the day of the transactions
6 changes: 4 additions & 2 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ jobs:
uses: actions/checkout@v6
with:
submodules: true
- name: Set up Node.js 20
- name: Set up Node.js 24
uses: actions/setup-node@v6
with:
node-version: "20.x"
node-version: "24.x"
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
Expand All @@ -37,6 +37,8 @@ jobs:
id: vars
run: |
echo "SHORT_SHA=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Run tests
run: yarn test
- name: Build app
run: yarn build
- name: Upload build artifacts
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ jobs:
uses: actions/setup-python@v6
with:
python-version: "3.x"
- name: Set up Node.js 20
- name: Set up Node.js 24
uses: actions/setup-node@v6
with:
node-version: "20.x"
node-version: "24.x"
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/update-prices.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: update-prices

on:
schedule:
# Run daily at 01:00 UTC (after midnight to ensure previous day's candle is closed)
- cron: '0 1 * * *'
workflow_dispatch: # Allow manual trigger

permissions:
contents: write

jobs:
update-prices:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '24'

- name: Update ROSE prices
run: node scripts/update-prices.js

- name: Commit and push changes
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"

if git diff --quiet; then
echo "No changes to commit"
else
git add src/prices/rose-usd.json
git commit -m "chore: update ROSE/USD prices"
git push
fi
Loading