{"id":13438038,"url":"https://github.com/racer-rust/emacs-racer","last_synced_at":"2025-04-05T16:08:48.475Z","repository":{"id":54155294,"uuid":"41726417","full_name":"racer-rust/emacs-racer","owner":"racer-rust","description":"Racer support for Emacs","archived":false,"fork":false,"pushed_at":"2021-03-07T02:43:27.000Z","size":411,"stargazers_count":398,"open_issues_count":36,"forks_count":48,"subscribers_count":13,"default_branch":"master","last_synced_at":"2025-03-29T15:08:24.249Z","etag":null,"topics":["completion-racer","emacs","racer","rust"],"latest_commit_sha":null,"homepage":null,"language":"Emacs Lisp","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/racer-rust.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-09-01T08:25:40.000Z","updated_at":"2025-01-25T20:27:58.000Z","dependencies_parsed_at":"2022-08-13T07:50:27.640Z","dependency_job_id":null,"html_url":"https://github.com/racer-rust/emacs-racer","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/racer-rust%2Femacs-racer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/racer-rust%2Femacs-racer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/racer-rust%2Femacs-racer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/racer-rust%2Femacs-racer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/racer-rust","download_url":"https://codeload.github.com/racer-rust/emacs-racer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247361691,"owners_count":20926643,"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":["completion-racer","emacs","racer","rust"],"created_at":"2024-07-31T03:01:02.417Z","updated_at":"2025-04-05T16:08:48.449Z","avatar_url":"https://github.com/racer-rust.png","language":"Emacs Lisp","funding_links":[],"categories":["Development tools","开发工具 Development tools","开发工具","Emacs Lisp"],"sub_categories":["IDEs","编译器 IDEs","集成开发环境(IDE)","编辑器 IDEs"],"readme":"# Racer for Emacs\n[![MELPA](http://melpa.org/packages/racer-badge.svg)](http://melpa.org/#/racer)\n[![MELPA Stable](http://stable.melpa.org/packages/racer-badge.svg)](http://stable.melpa.org/#/racer)\n[![Coverage Status](https://coveralls.io/repos/github/racer-rust/emacs-racer/badge.svg?branch=master)](https://coveralls.io/github/racer-rust/emacs-racer?branch=master)\n\nThis is the official Emacs package for\n[Racer](http://github.com/phildawes/racer).\n\n\u003c!-- markdown-toc start - Don't edit this section. Run M-x markdown-toc-generate-toc again --\u003e\n**Table of Contents**\n\n- [Racer for Emacs](#racer-for-emacs)\n    - [Completion](#completion)\n    - [Find Definitions](#find-definitions)\n    - [Describe Functions and Types](#describe-functions-and-types)\n    - [Installation](#installation)\n        - [Testing your setup](#testing-your-setup)\n    - [Tests](#tests)\n\n\u003c!-- markdown-toc end --\u003e\n\n## Completion\n\nracer.el supports code completion of variables, functions and modules.\n\n![racer completion screenshot](images/racer_completion.png)\n\nYou can also press \u003ckbd\u003eF1\u003c/kbd\u003e to pop up a help buffer for the current\ncompletion candidate.\n\nNote that due to a\n[limitation of racer](https://github.com/phildawes/racer/issues/389),\nracer.el cannot offer completion for macros.\n\n## Find Definitions\n\nracer.el can jump to definition of functions and types.\n\n![racer go to definition](images/racer_goto.gif)\n\nYou can use \u003ckbd\u003eM-.\u003c/kbd\u003e to go to the definition, and \u003ckbd\u003eM-,\u003c/kbd\u003e\nto go back.\n\n## Describe Functions and Types\n\nracer.el can show a help buffer based on the docstring of the thing at\npoint.\n\n![racer completion screenshot](images/racer_help.png)\n\nUse \u003ckbd\u003eM-x racer-describe\u003c/kbd\u003e to open the help buffer.\n\n## Installation\n\n1. You will need to use a nightly version of rust.\n   If you're using rustup, run\n   ```\n   $ rustup toolchain add nightly\n   ```\n\n2. Install [Racer](http://github.com/phildawes/racer) and download the\n   source code of Rust:\n\n   ```\n   $ rustup component add rust-src\n   $ cargo +nightly install racer\n   ```\n\n3. Allow Emacs to install packages from MELPA:\n\n   ```el\n   (require 'package)\n   (add-to-list 'package-archives '(\"melpa\" . \"https://melpa.org/packages/\"))\n   ```\n\n4. Install the Emacs package for Racer: `M-x package-install RET racer RET`\n\n5. Configure Emacs to activate racer when rust-mode starts:\n   ```el\n   (add-hook 'rust-mode-hook #'racer-mode)\n   (add-hook 'racer-mode-hook #'eldoc-mode)\n   ```\n\n   For completions, install company with `M-x package-install RET company RET`. A sample configuration:\n   ```el\n\n   (add-hook 'racer-mode-hook #'company-mode)\n\n   (require 'rust-mode)\n   (define-key rust-mode-map (kbd \"TAB\") #'company-indent-or-complete-common)\n   (setq company-tooltip-align-annotations t)\n   ```\n   For automatic completions, customize `company-idle-delay` and\n   `company-minimum-prefix-length`.\n\n   Racer process may be slow to respond for instance when indexing. You can\n   customize `racer-command-timeout` and `racer-eldoc-timeout` to avoid rendering\n   your Emacs session unresponsive. Eldoc timeout should be on the lower side and\n   defaults to 0.5 seconds. You can probably tweak it down on a fast machine.\n   Timeout of `nil` will wait indefinitely.\n\n### Testing your setup\n\nTo test **completion**: Open a rust file and try typing ```use\nstd::io::B``` and press \u003ckbd\u003eTAB\u003c/kbd\u003e.\n\nTo test **go to definition**: Place your cursor over a symbol and press\n`M-.` to jump to its definition.\n\nPress `C-x 4 .` to jump to its definition in another window.\n\nPress `C-x 5 .` to jump to its definition in another frame.\n\nPress `M-,` to jump back to the previous cursor location.\n\n\nIf **it doesn't work**, try `M-x racer-debug` to see what command was\nrun and what output was returned.\n\n## Tests\n\nracer.el includes tests. To run them, you need to install\n[Cask](https://github.com/cask/cask), then:\n\n```\n$ cask install\n$ cask exec ert-runner\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fracer-rust%2Femacs-racer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fracer-rust%2Femacs-racer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fracer-rust%2Femacs-racer/lists"}