{"id":13991911,"url":"https://github.com/TimboKZ/Rammy","last_synced_at":"2025-07-22T15:30:29.216Z","repository":{"id":65478992,"uuid":"131081400","full_name":"TimboKZ/Rammy","owner":"TimboKZ","description":"📝🛠️ Command line assistant for LaTeX projects","archived":false,"fork":false,"pushed_at":"2018-10-07T22:21:00.000Z","size":214,"stargazers_count":13,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-11-23T18:51:40.310Z","etag":null,"topics":["cli","es6","generator","javascript","latex","nodejs","rammy"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/rammy","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TimboKZ.png","metadata":{"files":{"readme":"README.md","changelog":"Changelog.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-26T01:08:26.000Z","updated_at":"2019-10-04T00:57:21.000Z","dependencies_parsed_at":"2023-01-25T08:15:25.458Z","dependency_job_id":null,"html_url":"https://github.com/TimboKZ/Rammy","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2FRammy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2FRammy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2FRammy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2FRammy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TimboKZ","download_url":"https://codeload.github.com/TimboKZ/Rammy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227124052,"owners_count":17734248,"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":["cli","es6","generator","javascript","latex","nodejs","rammy"],"created_at":"2024-08-09T14:01:40.362Z","updated_at":"2024-11-29T12:30:56.287Z","avatar_url":"https://github.com/TimboKZ.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# ![Rammy](./assets/rammy-banner.png)\n\n[![npm](https://img.shields.io/npm/v/rammy.svg)](https://www.npmjs.com/package/rammy)\n[![npm](https://img.shields.io/npm/dt/rammy.svg)](https://www.npmjs.com/package/rammy)\n[![Build Status](https://travis-ci.org/TimboKZ/Rammy.svg?branch=master)](https://travis-ci.org/TimboKZ/Rammy)\n[![Build status](https://ci.appveyor.com/api/projects/status/5x1l205m023tfe5n/branch/master?svg=true)](https://ci.appveyor.com/project/TimboKZ/rammy/branch/master)\n![David](https://img.shields.io/david/TimboKZ/Rammy.svg)\n\n📝🛠️ Command line assistant and template manager for LaTeX projects.\n\nFeatures:\n* **LaTeX project setup** with Git support\n* **Rammy modules** with templates and useful LaTeX snippets\n* **TeX file generation** using templates from modules\n* **TeX compilation** supporting several TeX engines\n* **Directory cleaning** by removing auxiliary files\n\nDocumentation:\n* **README.md** (this file): General usage, command reference.\n* **[Modules.md](./Modules.md)**: Information about Rammy modules, example templates and snippets.\n* **[Changelog.md](./Changelog.md)**: Overview of changes in each version, including breaking changes.\n\n\u003e Rammy is still in active development - any feedback is welcome! If you encounter a bug, please [create an issue](https://github.com/TimboKZ/Rammy/issues) so it can be fixed.\n\u003e Development branch status:\n\u003e [![Build Status](https://travis-ci.org/TimboKZ/Rammy.svg?branch=dev)](https://travis-ci.org/TimboKZ/Rammy)\n\u003e [![Build status](https://ci.appveyor.com/api/projects/status/5x1l205m023tfe5n/branch/dev?svg=true)](https://ci.appveyor.com/project/TimboKZ/rammy/branch/dev)\n\n# Quick example\n\n```bash\n# Install Rammy\nnpm install -g rammy\n\n# Prepare a folder for the project\nmkdir my-project\ncd my-project\n\n# Initialise a Rammy project\nrammy init\n# Add `--git` flag to create a Git repo at the same time\n\n# Add a Rammy module, we'll use https://github.com/TimboKZ/latex-common\nrammy add TimboKZ/latex-common\n\n# List available modules, templates, snippets\nrammy list\n\n# Create a TeX file from `lecture-notes` template\nrammy create notes.tex lecture-notes\n\n# Compile the .tex file into a .pdf\nrammy compile notes.tex\n\n# Delete logs, .aux files, etc.\nrammy clean\n```\n\n# Installation\n\nFirst, install [Node.js v6+](https://nodejs.org/). Then run the following command:\n\n```bash\nnpm install -g rammy\n```\n\nThis will install Rammy globally and expose the `rammy` command in the terminal.\n\n# Commands\n\nYou can execute `rammy` or `rammy help \u003ccommand\u003e` in terminal for to view a brief overview of commands. This section has\na detailed description of each command.\n\n\n------------\n\n\n### Create a Rammy project\n\n```bash\nrammy init [directory] [--git]\n```\n\nCreates a Rammy project in the target directory. If no directory is specified, current directory is used. By default,\nonly creates a `.rammyrc.json` file.\n\nWhen `--git` flag is supplied, Rammy executes `git init` (if necessary) and appends [the contents of\n`TeX.gitignore`](./assets/TeX.gitignore) to `.gitignore`. `.gitignore` is created if it doesn't already exist. Using\nthis flag requires [Git](https://git-scm.com/) to be installed (for the `git` command).\n\n\n------------\n\n\n### Create a Rammy module\n\n```bash\nrammy init-module \u003cname\u003e [directory]\n```\n\nCreates a module `.rammyrc.json` in the specified directory. If no directory is specified, current directory is used.\nThe name should be command-line friendly, e.g. `latex-common`.\n\nYou only need to create a new Rammy module if you want to define some new templates or snippets.\n\n\n------------\n\n\n### Add a Rammy module\n\n```bash\nrammy add \u003cmodule\u003e\n```\n\nAdds a Rammy module to the current project. `\u003cmodule\u003e` can be one of the following:\n\n1. Shorthand for a GitHub repository, e.g. `TimboKZ/latex-common`.\n2. Valid Git URL, e.g. `git@github.com:TimboKZ/Rammy.git`. This doesn't have to be hosted on GitHub.\n3. Local path, e.g. `./path/to/module`. When using a local path, you must supply the `--path` flag.\n\nWhen using (1) or (2), Git logic might differ. If your Rammy project is inside a Git repository, the Rammy module folder\nwill be added as a Git submodule. If Rammy project is not inside a Git repository, the Rammy module will be simply\ncloned. The project is always cloned into the directory where `.rammyrc.json` is located. See [Modules.md](./Modules.md)\nfor more details on how modules work.\n\nIf you don't want to or can't use Git, you can just place the module folder anywhere on your hard disk and use (3).\n\n\n------------\n\n\n### List details of available modules\n\n```bash\nrammy list [--modules-only]\n```\n\nLists modules, templates and snippets discovered through the config. `--modules-only` or `-m` flag can be supplied to\nonly display module names.\n\n\n------------\n\n\n### Remove a module\n\n```bash\nrammy remove \u003cmodule-name\u003e\n```\n\nRemoves a module by its name. You can find out what modules are installed using `rammy list`. Doesn't actually remove\nthe module folder, just erases it from the config.\n\n\n------------\n\n\n### Create a TeX file from a template\n\n```bash\nrammy create \u003cfile\u003e \u003ctemplate\u003e\n```\n\nCreates a TeX file using the specified template. The template can either be a full template name (e.g.\n`latex-common/lecture-notes`), short template name (e.g. `lecture-notes`) or a path to a tex file (e.g. `\n./path/to/template.tex`).\n\n\n------------\n\n\n### Add a snippet to existing TeX file\n\n```bash\nrammy extend \u003cfile\u003e \u003csnippet\u003e\n```\n\nAdds a TeX snippet to an existing `.tex` file. Specified snippet name can either be a snippet name or a path to another\n`.tex` file. Snippets are added through `\\input{...}` commands - see [Modules.md](./Modules.md) for more details on how\nsnippets work.\n\n\n------------\n\n\n### Compile a TeX file into a PDF\n\n```bash\nrammy compile \u003cfile\u003e [--clean]\n```\n\nCompiles a TeX file using either `pdflatex` or `latexmk`, depending on what is available. If none of these are\navailable, the command will fail.\n\n`--clean` or `-c` flag can be supplied to delete auxiliary files afterwards. This is equivalent to running `rammy\ncompile \u003cfile\u003e` followed by `rammy clean \u003cfile\u003e`.\n\n\n------------\n\n\n### Cleaning auxiliary files\n\n```bash\nrammy clean [file]\n```\n\nCleans the current working directory or the specified TeX file. If a TeX file is specified, e.g.\n`rammy clean ./folder/doc.tex`, Rammy will scan the folder containing the TeX file and delete *relevant* `.aux`,\n`.fdb_latexmk`, `.fls`, `.log`, `.out` and others. *Relevant* means files that share the same basename, e.g. `doc.aux`.\n\n\n------------\n\n\n# Contributing\n\nRammy is still in experimental phase so contributing at this stage is not recommended. You can [create an issue](https://github.com/TimboKZ/Rammy/issues) to start a discussion.\n\nIf you end up adding something, make sure `npm test` and `npm run lint` terminate without any errors before creating a\npull request.\n\n\n# Notes about Rammy\n\nSome planned features:\n* `rammy fix \u003cfile\u003e` command: If you move a generated `.tex` file around, relative paths might break. Rammy can fix most (if not all) of these paths thanks to metadata in comments. This command will do exactly that.\n* Add redundancy checks to `rammy extend`: if a snippet is already a part of the file, Rammy will not import it again.\n* Support more engines for `rammy compile`, make `rammy clean` more intelligent.\n\nI wrote Rammy during my time at [Caltech](http://www.caltech.edu/), so I can't help but include this:\n\n![CalTeX](./assets/caltex.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTimboKZ%2FRammy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FTimboKZ%2FRammy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTimboKZ%2FRammy/lists"}