-
Notifications
You must be signed in to change notification settings - Fork 1
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
Keep json formatted #1
Comments
I used steps described in issue asterics#1
Wow, didn't expect any issues or pull requests on that repo that fast. It's work in progress - currently the files of default grid configurations are stored in the main AsTeRICS Grid repository, but this has some disadvantages. In the future the data will be organized within this repository (but it's not yet used). I don't think I want to keep the configuration files as formatted json, since it's the data that is direclty downloaded and imported in AsTeRICS Grid in production and therefore it should be as small as possible. So for translating anything I would recommend one of these:
However, I also like the idea of being able to do translations with a good diff view here on Github. So maybe we can find a way of keeping both formatted (for editing) and single-line json (for downloading). But I'm currently not sure what's the best way to achieve it. The ultimate goal would be a webpage, where it's possible to manage translations and automatically create pull requests here. Maybe we could combine it with crowdin somehow:
I think this would be a good idea, but I still have to think about the details. For now please proceede like written above. |
Hello, it's just a good time anomaly :D. For the future, it would be nice, if grids itself are without translations (maybe keys only or one source language?) and translations were taken in build time from some translation file/crowdin etc.. It would improve translating speed and how easily translations can be added. I think, that you should keep json in formatted form here and minify them in compile time. I can minify it by myself, but doing diff is harder in that case |
What about using custom GitHub actions (you could "minify" json in step (3) before upload static pages). In case, that you plan to download jsons from GitHub pages and not using git submodule or just fetch this repo before build. |
In fact in a very early version, I had grid files and translations separated. However I've changed it, because it's much more comfortable in many other aspects, e.g. at translating things within the app or at downloading single grids. However, as said, maybe we can find a way of extracting separate translations files out of the standard configs here in this repository. I think the difficult part is how to make it possible to still be able to adapt the contents of one of the grids using the app.
Github pages (the way how the files are delivered) is automatically using gzip for
I've never used it, but yes, maybe it can help somehow. |
Check this repo: What does the magic:
Whole workflow file: It's just copied from "sample" to build Jekyll (what doed Github Pages pipeline).
|
Thanks for the examples, I'll have look at the Github workflows in detail after I've finished some other things regarding the grid sharing feature I'm currently working on. In the end I think it should be possible that someone creates a PR on this repository with a new
|
I've now added quite detailed documentation to README how to add or alter configurations. For now I didn't have time to look at the Github actions, but I (or someone else) should add it in the future in order to automatically run |
Hello, I wanted to translate grids/communicators but files are single line, so it will not be possible validate changes... Is issue for you, keep files formatted?
I use VS code to format code, is that OK for you? I'll prepare PR...
How I prepare files, are steps correct?
The text was updated successfully, but these errors were encountered: