Skip to content

Commit 8e2190c

Browse files
cursoragentpierre.juillard
authored andcommitted
Update README and git push logic in CI
Co-authored-by: pierre.juillard <[email protected]>
1 parent f468a18 commit 8e2190c

File tree

1 file changed

+9
-12
lines changed

1 file changed

+9
-12
lines changed

.github/workflows/data.yml

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -134,18 +134,15 @@ jobs:
134134
fi
135135
136136
# Update README with timestamp
137-
cat > README.md << 'HEREDOC'
138-
# Halvix Data Cache
139-
140-
This branch contains cached price data (parquet files).
141-
It is automatically updated by CI and has no history (orphan branch).
142-
143-
**Do not manually edit files in this branch.**
144-
145-
HEREDOC
146-
137+
echo "# Halvix Data Cache" > README.md
138+
echo "" >> README.md
139+
echo "This branch contains cached price data (parquet files)." >> README.md
140+
echo "It is automatically updated by CI and has no history (orphan branch)." >> README.md
141+
echo "" >> README.md
147142
echo "**Last updated:** $(date -u '+%Y-%m-%d %H:%M:%S UTC')" >> README.md
148143
echo "" >> README.md
144+
echo "**Do not manually edit files in this branch.**" >> README.md
145+
echo "" >> README.md
149146
echo "## Contents" >> README.md
150147
echo "" >> README.md
151148
@@ -187,8 +184,8 @@ HEREDOC
187184
fi
188185
189186
# Force push to keep orphan branch with single commit
190-
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git 2>/dev/null || \
191-
git remote add origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git 2>/dev/null || true
187+
git remote set-url origin "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git" 2>/dev/null || \
188+
git remote add origin "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git" 2>/dev/null || true
192189
193190
echo "Pushing to data branch..."
194191
git push --force origin data

0 commit comments

Comments
 (0)