{"id":18320356,"url":"https://github.com/alice1017/load-template","last_synced_at":"2025-04-09T14:24:38.844Z","repository":{"id":150055594,"uuid":"127065873","full_name":"alice1017/load-template","owner":"alice1017","description":"Create a file from the template with the variables.","archived":false,"fork":false,"pushed_at":"2018-05-10T02:22:12.000Z","size":35,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-15T08:25:57.965Z","etag":null,"topics":["template-rendering"],"latest_commit_sha":null,"homepage":null,"language":"Python","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/alice1017.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}},"created_at":"2018-03-28T01:25:36.000Z","updated_at":"2018-05-10T02:22:13.000Z","dependencies_parsed_at":"2023-04-06T05:16:32.361Z","dependency_job_id":null,"html_url":"https://github.com/alice1017/load-template","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alice1017%2Fload-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alice1017%2Fload-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alice1017%2Fload-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alice1017%2Fload-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alice1017","download_url":"https://codeload.github.com/alice1017/load-template/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248054407,"owners_count":21039999,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["template-rendering"],"created_at":"2024-11-05T18:16:00.632Z","updated_at":"2025-04-09T14:24:38.818Z","avatar_url":"https://github.com/alice1017.png","language":"Python","readme":"# load-template\n\n[![forthebadge](http://forthebadge.com/images/badges/made-with-python.svg)](http://forthebadge.com)\n\n[![Build Status](https://travis-ci.org/alice1017/load-template.svg?branch=master)](https://travis-ci.org/alice1017/load-template)\n[![Coverage Status](https://coveralls.io/repos/github/alice1017/load-template/badge.svg)](https://coveralls.io/github/alice1017/load-template)\n![Python 2.7 only](https://img.shields.io/badge/python-2.7-blue.svg)\n\n* [:page_facing_up: Overview](#page_facing_up-overview)\n* [:wrench: Usage](#wrench-usage)\n* [:inbox_tray: Installation](#inbox_tray-installation)\n* [:eyes: Contribution](#eyes-contribution)\n* [CHANGELOG](#changelog)\n\n## :page_facing_up: Overview\n\nThe **load-template** create a file from the **template** with the **variables**,\nand **edit** the file in your **editor**.\n\nYou can create templates as freely if you save it :open_file_folder: `~/.templates/`.\n\nIf you want to add new default template, please send pull request. :+1:\n\n## :wrench: Usage\n\n### basic\n\n```\n$ load-template [template] [file] [variables [variables ...]]\n```\n\n### positional arguments\n\n* ***template*** - The template name. You can show all templates by `--list`.\n* ***file*** - The file name to create.\n* ***variables*** - The template variables formatted `key=value`.\n\n### optional arguments\n\n* *-l*, *--list* - Display the all template list.\n* *-c*, *--contents* - Display contents of the template.\n* *-s*, *--sync* - Sync the default template to local template. Before using this feature, you have to do `git pull`.\n* *-n*, *--no-edit* - Create a file from template without edit.\n* *-D*, *--dev* - Run development mode.\n\n### template variable\n\nYou can set some **variables** to the template as follows:\n\n```html\n\u003ch1\u003eHello, {name}\u003c/h1\u003e\n```\n\nwhen use this variable:\n\n```\n$ load-template template hello.html name=Alice\n```\n\nrendered:\n\n```html\n\u003ch1\u003eHello, Alice\u003c/h1\u003e\n```\n\n## :inbox_tray: Installation\n\n```\n$ git clone git@github.com:alice1017/load-template.git\n$ cd load-template\n$ python setup.py build install\n```\n\nYou **need to clone this repository** for installation, Because the\nload-template **copies** the default templates to `~/.templates/` directory.\n\n## :eyes: Contribution\n\n1. Forks on [Github](https://github.com/alice1017/load-template)\n2. Find a bug? Add new default template? Send a pull request to get it merged and published.\n\n## CHANGELOG\n\nAll notable changes to this project will be documented in this file.\nThe format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)\n\n### [1.0.0] - 2018/4/16\n\n#### Added new feature\n\n* Added `--contents` argument to display template contents. Fixed [#2]\n* Added **edit** feature. Fixed [#3]\n* Added `--sync` argument to sync default template and local template. Fixed [#1]\n\n#### Added new template\n\n* Added `templates/readme-py` template.\n* Added `templates/python-argparser` template.\n\n#### Changed\n\n* Changed a template name: `mit_license` to `mit-license`\n\n#### Other\n\n* Use [**travis-ci**](https://travis-ci.org/alice1017/load-template).\n* Use [**coverall**](https://coveralls.io/github/alice1017/load-template).\n\n### [1.0.0b1] - 2018/3/28\n\nA Beta Version Release.\n\n[1.0.0b1]: https://github.com/alice1017/load-template/compare/a2f5136...1.0.0b1\n[1.0.0]: https://github.com/alice1017/load-template/compare/1.0.0b1...1.0.0\n[#1]: https://github.com/alice1017/load-template/issues/1\n[#2]: https://github.com/alice1017/load-template/issues/2\n[#3]: https://github.com/alice1017/load-template/issues/3\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falice1017%2Fload-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falice1017%2Fload-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falice1017%2Fload-template/lists"}