Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add file watching feature for automatic retranslation #243

Open
maxprilutskiy opened this issue Oct 14, 2024 · 6 comments
Open

Add file watching feature for automatic retranslation #243

maxprilutskiy opened this issue Oct 14, 2024 · 6 comments
Assignees
Labels
enhancement New feature or request

Comments

@maxprilutskiy
Copy link
Contributor

maxprilutskiy commented Oct 14, 2024

WHAT

Implement a "watch" mode that automatically triggers retranslation when changes are detected in the source file.

WHY

  • Saves time by eliminating manual retranslation after each edit
  • Improves workflow for users working on iterative translations
  • Keeps target language files in sync with source file changes

HOW

  1. Monitor specified source file for changes via replexica i18n --watch
  2. When changes detected, trigger retranslation process
  3. Implement debounce mechanism to avoid excessive retranslations on rapid changes

Additional Context

No response

@maxprilutskiy maxprilutskiy added the enhancement New feature or request label Oct 14, 2024
@bluzeey
Copy link
Contributor

bluzeey commented Oct 17, 2024

I would like to try my hands on the same, @maxprilutskiy .

@maxprilutskiy
Copy link
Contributor Author

@bluzeey awesome, go ahead!

@bluzeey
Copy link
Contributor

bluzeey commented Oct 26, 2024

Hey Max, I was trying on adding a file in the @replexica/cli for the watch command , such that it changes the source file. However in the package json , there were these libraries from replexica which were causing me error while running npm i .

"@replexica/sdk": "workspace:",
"@replexica/spec": "workspace:
",

Any ideas what should i do to remove this error ?

@maxprilutskiy
Copy link
Contributor Author

maxprilutskiy commented Nov 10, 2024

hey @bluzeey, we're using pnpm:

git clone https://github.com/replexica/replexica
cd replexica
pnpm i
pnpm turbo build

# in terminal window 1
cd packages/cli
pnpm run dev # to start watching for changes in the cli code

# in terminal window 2
cd package
pnpm replexica --help # this command will use the current cli code + demo config from ./package/i18n.json

feel free to ask questions on discord as well (replexica.com/go/discord)

@Akshat76845
Copy link

can i work on this issue?

@maxprilutskiy
Copy link
Contributor Author

@Akshat76845 yep, go ahead!

@maxprilutskiy maxprilutskiy assigned Akshat76845 and unassigned bluzeey Jan 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants