Full Code of mmorearty/elixir-ctags for AI

master 45d0118a046f cached
3 files
5.2 KB
1.7k tokens
1 requests
Download .txt
Repository: mmorearty/elixir-ctags
Branch: master
Commit: 45d0118a046f
Files: 3
Total size: 5.2 KB

Directory structure:
gitextract_9aszdwf7/

├── .ctags
├── LICENSE
└── README.md

================================================
FILE CONTENTS
================================================

================================================
FILE: .ctags
================================================
--langdef=Elixir
--langmap=Elixir:.ex.exs
--regex-Elixir=/^[ \t]*def(p?)[ \t]+([a-z_][a-zA-Z0-9_?!]*)/\2/f,functions,functions (def ...)/
--regex-Elixir=/^[ \t]*defcallback[ \t]+([a-z_][a-zA-Z0-9_?!]*)/\1/c,callbacks,callbacks (defcallback ...)/
--regex-Elixir=/^[ \t]*defdelegate[ \t]+([a-z_][a-zA-Z0-9_?!]*)/\1/d,delegates,delegates (defdelegate ...)/
--regex-Elixir=/^[ \t]*defexception[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/e,exceptions,exceptions (defexception ...)/
--regex-Elixir=/^[ \t]*defimpl[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/i,implementations,implementations (defimpl ...)/
--regex-Elixir=/^[ \t]*defmacro(p?)[ \t]+([a-z_][a-zA-Z0-9_?!]*)\(/\2/a,macros,macros (defmacro ...)/
--regex-Elixir=/^[ \t]*defmacro(p?)[ \t]+([a-zA-Z0-9_?!]+)?[ \t]+([^ \tA-Za-z0-9_]+)[ \t]*[a-zA-Z0-9_!?!]/\3/o,operators,operators (e.g. "defmacro a <<< b")/
--regex-Elixir=/^[ \t]*defmodule[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/m,modules,modules (defmodule ...)/
--regex-Elixir=/^[ \t]*defprotocol[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/p,protocols,protocols (defprotocol...)/
--regex-Elixir=/^[ \t]*Record\.defrecord[ \t]+:([a-zA-Z0-9_]+)/\1/r,records,records (defrecord...)/
--regex-Elixir=/^[ \t]*test[ \t]+\"([a-z_][a-zA-Z0-9_?! ]*)\"*/\1/t,tests,tests (test ...)/


================================================
FILE: LICENSE
================================================
This is free and unencumbered software released into the public domain.

Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.

In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
of the public at large and to the detriment of our heirs and
successors. We intend this dedication to be an overt act of
relinquishment in perpetuity of all present and future rights to this
software under copyright law.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.

For more information, please refer to <http://unlicense.org>


================================================
FILE: README.md
================================================
ctags-elixir
============

[Exuberant CTags](http://ctags.sourceforge.net/) support for the
[Elixir](http://elixir-lang.org/) language.

This means that if you are writing your Elixir code using an editor
that supports Ctags (e.g.  Vim, Emacs, Sublime Text, and many others), you
can easily jump to the definition of any symbol.  Handy for navigating 
your way around a large, unfamiliar source tree.

To enable:
----------

Copy or append this `.ctags` file to your own `~/.ctags`.

Once you have done that, you can build tags for an Elixir app with the usual
ctags command line: cd into your project, and then

    $ ctags -R .

What is this Exuberant Ctags thing and how do I use it?
-------------------------------------------------------

Well, that's a separate topic, really.  But here's a quick start.

Ctags is a tool to make it easier to implement "go to definition" in lots
of different text editors and for lots of different programming languages.
It has parsers for many languages, and it generates a simple `tags` file
that any editor can read in order to find the file and line where a given
symbol is defined.

The original Ctags supported only C (I think).  Exuberant Ctags is a rewrite
that supports many more languages.

**Install Exuberant Ctags**

If you don't already have Exuberant Ctags, [install it](http://ctags.sourceforge.net/).
On OSX, the best way is using [brew](http://mxcl.github.com/homebrew/):

    $ brew install ctags
    
On Windows, the best way is using [chocolatey](https://chocolatey.org/):

    choco install ctags

**Vim**

If you are using the [vim](http://www.vim.org/) editor:

1. Do the above `ctags -R .` command
2. Open an Elixir source file in vim.
3. Put the cursor on any symbol name, and type the `^]` (Control-]) key.
   The cursor will jump to the definition of that symbol.
4. Type `^O` (or `^T`) to return cursor to previous location.

**Sublime Text 2**

If you are using [Sublime Text](http://www.sublimetext.com/), there is a
[package](https://github.com/SublimeText/CTags) you can install that
adds CTags support.  I haven't tried it, but this is what you would do:

1. If you have not already done so, install [Sublime Package
   Control](http://wbond.net/sublime_packages/package_control).
2. From Sublime Text, Cmd-Shift-P, "install package"
3. Pick "CTags" from the list of packages, and install it
4. Put the cursor on any symbol name, and then type `^T^T`.  This
   should jump to the symbol definition.
5. See the rest of the key bindings [here](https://github.com/SublimeText/CTags).

**Other editors**

There are also other editors that support Ctags.  Check your editor's
documentation, or Google for it.

Feedback
--------

Feedback is more than welcome; I'm new to the Elixir language, so I
probably got some things wrong.
Download .txt
gitextract_9aszdwf7/

├── .ctags
├── LICENSE
└── README.md
Condensed preview — 3 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (6K chars).
[
  {
    "path": ".ctags",
    "chars": 1325,
    "preview": "--langdef=Elixir\n--langmap=Elixir:.ex.exs\n--regex-Elixir=/^[ \\t]*def(p?)[ \\t]+([a-z_][a-zA-Z0-9_?!]*)/\\2/f,functions,fun"
  },
  {
    "path": "LICENSE",
    "chars": 1210,
    "preview": "This is free and unencumbered software released into the public domain.\n\nAnyone is free to copy, modify, publish, use, c"
  },
  {
    "path": "README.md",
    "chars": 2797,
    "preview": "ctags-elixir\n============\n\n[Exuberant CTags](http://ctags.sourceforge.net/) support for the\n[Elixir](http://elixir-lang."
  }
]

About this extraction

This page contains the full source code of the mmorearty/elixir-ctags GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 3 files (5.2 KB), approximately 1.7k tokens. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!