FinceptTerminal is a modern finance application offering advanced market analytics, investment research, and economic data tools, designed for interactive exploration and data-driven decision-making in a user-friendly environment.
C++ ai-agentsalgorithmic-tradingbloomberg-terminalcppfinancefinancial-marketsfintechgood-first-issueinvestmentinvestment-researchmachine-learningopensourcepythonqtquantitative-financestock-markettrading
fix(workflow): handle translate-readme action ignoring COMMIT:false by cleaning root after each run
tilakpatel22b6474d79ed8d
diff --git a/.github/workflows/translate-readme.yml b/.github/workflows/translate-readme.ymlindex b6bcb4d02..d5273ebba 100644--- a/.github/workflows/translate-readme.yml+++ b/.github/workflows/translate-readme.yml@@ -61,13 +61,30 @@ jobs:LANG: hiCOMMIT: false- - name: Move translated files to docs/translations and commit+ - name: Move translations and clean up rootrun: |- mkdir -p docs/translations- mv README.es.md README.zh-CN.md README.ja.md README.fr.md README.ko.md README.de.md README.hi.md docs/translations/ 2>/dev/null || truegit config --local user.email "[email protected]"git config --local user.name "GitHub Action"++ # Pull any commits the action made to root despite COMMIT: false+ git pull --rebase origin main || true++ # Move any translated files from root to docs/translations/+ mkdir -p docs/translations+ for lang in es zh-CN ja fr ko de hi; do+ if [ -f "README.${lang}.md" ]; then+ mv "README.${lang}.md" "docs/translations/README.${lang}.md"+ fi+ done++ # Remove any root-level translated READMEs from git tracking+ for lang in es zh-CN ja fr ko de hi; do+ git rm --cached "README.${lang}.md" 2>/dev/null || true+ done++ # Stage the correct locationgit add docs/translations/++ # Commit only if there are changesgit diff --staged --quiet || git commit -m "chore: update translated READMEs in docs/translations/"git push || echo "No changes to push"-