{"id":27611658,"url":"https://github.com/grazen0/plates","last_synced_at":"2026-04-28T08:02:19.402Z","repository":{"id":285057632,"uuid":"956938179","full_name":"Grazen0/plates","owner":"Grazen0","description":"A neat CLI program to manage file (tem)plates.","archived":false,"fork":false,"pushed_at":"2025-04-11T21:02:28.000Z","size":38,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-23T00:40:15.791Z","etag":null,"topics":["cli","rust","terminal"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Grazen0.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-03-29T06:55:13.000Z","updated_at":"2025-04-11T21:02:32.000Z","dependencies_parsed_at":null,"dependency_job_id":"f13d19aa-d5f4-445b-b8ba-42061f2041cf","html_url":"https://github.com/Grazen0/plates","commit_stats":null,"previous_names":["grazen0/plates"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Grazen0/plates","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grazen0%2Fplates","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grazen0%2Fplates/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grazen0%2Fplates/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grazen0%2Fplates/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Grazen0","download_url":"https://codeload.github.com/Grazen0/plates/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grazen0%2Fplates/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32371672,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T20:07:02.737Z","status":"online","status_checked_at":"2026-04-28T02:00:07.250Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","rust","terminal"],"created_at":"2025-04-23T00:40:05.820Z","updated_at":"2026-04-28T08:02:19.372Z","avatar_url":"https://github.com/Grazen0.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# plates [![Tests](https://github.com/Grazen0/plates/actions/workflows/tests.yml/badge.svg)][workflow-tests]\n\nA neat CLI program to manage file (tem)plates. Plates allows you to create **templates** at `~/.config/plates/templates` and **render** them to any directory of your liking.\n\nThis project is _very much_ inspired from [copier]. I just wanted to see if I could build something like it in Rust.\n\n## Usage example\n\n\u003e [!NOTE]\n\u003e For more complete examples, you can check out [my own plates config][config-example].\n\nEach **template** is a directory located at `$XDG_CONFIG_HOME/plates/templates`. You may include a `_plates.yml` file to define, among other things, **placeholders** for your template.\n\nFor a simple Python template, take the following directory structure for `~/.config/plates`\n\n```\ntemplates\n└── python-starter/\n    ├── src/\n    │   └── main.py\n    └── _plates.yml\n```\n\nYour `_plates.yml` file could look something like this:\n\n```yaml\nplaceholders:\n  - name: author_name\n    message: \"What's your name? \"\n  - name: project_name\n    message: \"Project name: \"\n    default: \"{{ plates_dir_basename }}\" # Will expand to the name of the directory being rendered to\n  - name: creation_date\n    message: \"Project creation date: \"\n    default:\n      # type can be one of \"str\", \"shell\", \"env\".\n      type: shell\n      value: \"date +%Y-%m-%d\"\n```\n\nThen, any file inside your template (such as`main.py`) may use these placeholders. For example:\n\n```python\n# This is project \"{{ project_name }}\", by {{ author_name }}.\n# Created at {{ creation_date }}.\n# Use for Good, not Evil.\n\n\ndef main():\n    print(\"Hello, {{ author_name }}!\")\n```\n\nYou may now run the following command:\n\n```bash\nplates render my-new-project\n```\n\nYou'll be prompted for the template you want to render and any placeholders it may have. Then, the template will be rendered at a (perhaps new) directory called \"my-new-project\".\n\n\u003e [!TIP]\n\u003e You can list all currently available templates with `plates list`.\n\n## Features\n\n- [x] Placeholder support.\n  - [x] Built-in placeholders (plates_dir, plates_dir_basename, etc.).\n  - [x] Placeholders can use previous placeholders.\n  - [x] Placeholder transformation (via shell commands).\n  - [ ] Different placeholder types (number, select, etc.).\n  - [x] Placeholders within directory names.\n  - [ ] Custom prompt validation.\n- [x] Shell completions\n  - [ ] Show available templates\n- [x] Man pages.\n\n## Building\n\nIf you use [Nix][nix], you already know what to do. Otherwise, this project is managed with Cargo, so you should be just a `cargo build` away from building this locally.\n\n[copier]: https://github.com/copier-org/copier\n[workflow-tests]: https://github.com/Grazen0/plates/actions/workflows/tests.yml\n[config-example]: https://github.com/Grazen0/nixos-config/tree/main/profiles/home/ttymax/programs/plates/config/templates/cpp-cmake\n[nix]: https://nixos.org/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrazen0%2Fplates","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgrazen0%2Fplates","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrazen0%2Fplates/lists"}