ratatui-org / ratatui-website

Ratatui Documentation
http://ratatui.rs/
MIT License
95 stars 57 forks source link

Add examples to the website #625

Closed joshka closed 1 month ago

joshka commented 1 month ago

Ratatui Examples

Note: Edits to the examples in this folder will be overwritten on each release. To update these examples, do so in the main Ratatui repo.

This folder contains a copy of the examples from the latest release version of Ratatui. It is generated using directly from https://github.com/ratatui-org/ratatui/tree/latest/examples using git read-tree as suggested by a stackoverflow answer:

git remote add --fetch --track latest --no-tags ratatui https://github.com/ratatui-org/ratatui.git
git merge --strategy ours --no-commit ratatui/latest --allow-unrelated-histories --squash
git read-tree --prefix=code/ratatui-examples/examples/ -u ratatui/latest:examples
git commit -m 'Add ratatui examples'

To update the examples in the future:

# This first command should only need to be run once
git remote add --fetch --track latest --no-tags ratatui https://github.com/ratatui-org/ratatui.git

git merge --strategy ours --no-commit ratatui/latest --squash
git rm -rf code/ratatui-examples/examples
git read-tree --prefix=code/ratatui-examples/examples/ -u ratatui/latest:examples
git commit -m 'Update examples'
cloudflare-pages[bot] commented 1 month ago

Deploying ratatui with  Cloudflare Pages  Cloudflare Pages

Latest commit: 4da1f42
Status: ✅  Deploy successful!
Preview URL: https://94d67931.ratatui.pages.dev
Branch Preview URL: https://jm-examples.ratatui.pages.dev

View logs