Is there such a thing as an "elisp bundle" for TextMate? - lisp

I started using Code Collector Pro to organise and save my Emacs codes, and this software requires TextMate bundles for syntax highlighting. They have a lisp bundle, but not an elisp bundle, at least not that I can see. I would think that the syntax highlighting would work under the lisp bundle, but for some reason it isn't happening.
I have never even seen any lisp code with syntax highlighting, so it is possible that the thing is working and I don't know, but I honestly don't think so, because the ;; before a line seems to me to be a comment thing, so anything after that should be in the color defined for comments which in my case is green. Here is a picture of my code collector screen with a piece of code written by huaiyuan answering my question posted here:
Is this looking as it should or is there something wrong?
Back to the initial question: is there a textmate bundle for elisp or a bundle like the ones from textmate I can download to get syntax highlighting?

I wouldn't have thought so, because anyone writing elisp is going to do it in Emacs so there wouldn't be any call for a Textmate bundle for it.

Related

Flycheck Autocorrect errors

Hello Community I am using Spacemacs and I love it. It is working great for me all his features and the way all the layers are organized is amazing. Right now I am working with typescript but this question is common for any language.
I correctly setup flycheck and it is working perfectly. It is signaling all the errors.
How I can make Flycheck correct all the syntax errors in a bulk for me? Right now I am going one by one adding a semicolon or a space or who knows; it should be a function or something that allow me run an script that correct all this errors.

I need to code (and understand) an ELISP script to automatically generate a file header

I have this assignment due tomorrow where I have to learn how to customize BOTH emacs and vim. As a vim user, I feel a bit lost when it comes to editing a .emacs file. I found very few ressources online and none of them about generating file headers (I found ready-to-use plugins but that's not what I need).
Can anyone show me a good tutorial website or explain me the few things that'll get me started ? I'd be so grateful !!

Definitive guide for Emacs learners [duplicate]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I am about to learn Emacs, have been through the tutorial and borrowed the O'Reilly book on Emacs. But the question still is - how do you learn good Emacs workflow? I guess, you don't use Emacs as you'd use, for example, Vim.
This question seems revelant to mine:
- Where can I find a video of a professional using Emacs?
I can't believe nobody has mentioned this, but reading the info pages bundled with Emacs is a great way to learn about obscure features. Whenever you need a break from coding, hit M-x info and pick a random page to read. Your emacs ability will improve incredibly quickly.
It is also important to realize how emacs' self-documenting-ness helps you work. Say, for example, you are wondering how you can scale the font size. Instead of interrupting your flow and asking here, or on IRC, or Google, you can ask emacs! Just hit C-h a (M-x command-apropos) and type a search term, in our case scale. If there are matching functions, their names, keybindings, and documentation will appear. There are, and now you've just discovered text-scale-increase and text-scale-decrease.
There are other self-documentation functions that are good to learn C-h m will tell you what keybindings and commands are available in the current major and minor modes. This is a great way to discover features you didn't know existed.
Another way to "learn by osmosis" is to M-x customize-group for the modes you use regularly. (customize is the interactive configuration editor that almost all modes support.)
The final thing to do is to learn Emacs Lisp. It is nice to use existing tools, but sometimes you will need your own. If you try to avoid learning Lisp, you will always be stuck with things not quite working right, and that's a shame.
Emacs is a great environment for customizing itself. Emacs includes two Lisp manuals that are viewable via M-x info. It is self-documenting, so you can say C-h f or M-x describe-function to get the documentation for any function. You can even press TAB ENT to jump to the source code of that function, to see how it's implemented. This is great when you think "I wish I had something that worked like foo, but just slightly different." You can read how foo is implemented, make your change in the *scratch* buffer, and then see if you like the change. There is no edit/compile/test cycle. You press a key and your emacs session immediately has the feature you just wrote.
The more effort you put into learning emacs, the more emacs will do to make your work easier.
Once you mastered the basics (opening/closing files, navigating, basic editing) just use it. As with a lot of other tools, practise makes perfect...
I would, however, set some time aside to work on improving how you use the editor currently, but as part of your normal workflow as opposed to just going off on a tangent and learning things for the sake of it.
I find some useful resources are the EmacsWiki and the Planet Emacsen blog. I use both, mainly by using Planet Emacsen for "inspiration" and then wandering over to EmacsWiki and having a trawl on there for a specific topic. I found that unless you're having at least a vague idea what you're looking for, the available information is just going to swamp you instead of it actually being helpful.
Not to mention that there are a few very useful resources here on StackOverflow, for example this question here. Emacs is a very powerful tool that tends to be able to do a lot more than a single person needs, but in the end that allows you to pick and choose exactly those parts that you need.
My suggestion is just stop using anything but Emacs, when you come across a problem see if you can solve it in Emacs, and then fall back (if you don't have the time or it just won't work). As for work flow, it is pretty much the same as you would normally work. i.e. for a normal ide session you would open/edit a file as normal, then commit (in C-x v v) just as normal.
I agree with the other posters here, you just have to use it! Here's how I did it:
Once I got the very basics (can get between buffers, open/save files, etc), I printed out a reference card and kept it handy. This is a good one. Review it just so you know what is on it, then whenever you find yourself doing something repeatedly that is on the card, start using the shortcut! Before you know it you'll have memorized quite an arsenal of commands. But remember, probably no one uses everything that emacs can do.
When you eventually find yourself doing something repeatedly that doesn't have a shortcut, that's a good time to learn keyboard macros. Once you get them, you'll find uses for them everywhere! From there it's a short jump to writing elisp (if you're a programmer).
The great thing about emacs is that you don't need an "emacs workflow", emacs works around your workflow!
You don't need to learn emacs workflow. Once you complete the tutorial and master the essentials, you'll have to adopt some degree of monogamy and use nothing but Emacs. Eventually you will think of functionality that you really wished existed; most of the time somebody else will have as well and the solution is just one search away! Over time you just can't help but learn and eventually you'll pick up enough that you'll develop your own personal workflow.
If you're looking to accelerate the process, the Emacs wiki has a variety of tips but really the best way is just to do stuff with Emacs.
You could have a look at Bram Molenaar's talk about efficient textediting, http://video.google.com/videoplay?docid=2538831956647446078&ei=EqiGSau8KZ-QiQLi-Nn8Cg&q=bram+molenaar+editing
Although he's a vim guy (he wrote it), you might get some ideas about how best to go about becoming more proficient with your text editor that'll apply to emacs.
To be honest, all I do is learn the keybindings I need. I don't use emacs to its full potential, because I don't need its full potential. My suggestion is to just learn what you need, and don't worry about what you don't. Learn a new key binding everyday, and in about 300 years will you know them all ;)
I am using the emacs since the old Amiga days on all platforms i am currently working on.
The best way to use emacs is curiosity. I still use often apropos (C-h a) and M-x (for a long functionname instead of key-binding) to find a functionality.
a key-concept to "proper use" Emacs is, to learn the very easy elisp (a simple derivate of lisp) and write your own little helpers (own commenting style, underlining, templates) and to know where to look to change values (tab-size, compiler, email)
And the third thing: everything is in emacs: I use the dired (directory editor) for navigating through files. I use a lot of buffers for all textual files (with proper modes for each type of file (c, ruby, list, sql, latex, ...)) which are stored when quitting emacs and recovered when invoking. I start the compiler from emacs and use the jump-to-error-functionality.
Macros are a daily routine (scimming throu code and changing it on the way).
I like the picture-mode, which allows to type downward with replacing, which makes it easy to renumber block of constants (good old c #defines))
There is a hugh mountain to climb, but if you have reached the top, you can see the whole world down your feet, and never want to miss this experience again. I know, there are many good editors around (i work myself thru Eclipse)
As previously stated, the best advice is to use nothing but Emacs for the next year. Once you develop your finger memory, things get to be much easier.
How do you learn a "good workflow" for anything? By using it, getting to know it, making it yours. There is no "proper" use of Emacs.
As for getting to know it: ask Emacs -- use its help system. This can help too: http://www.emacswiki.org/emacs/EmacsNewbieWithIcicles
That's the power of Emacs, you use it the way you like. You just have to configure it before for your liking.

Ocaml - Emacs tuareg mode

I just started to use the tuareg mode in emacs for ocaml programming. So can someone tell me what are the main advantages of using it? Can someone suggest me any tutorial for that?
Tuareg-mode is good because it can parse code and calculate indentation & font-lock basing on this information. Plus it provides pretty good possibilities to interactive work with code.
Regarding tutorial - I don't think that such exists (although I planned to write it long time ago). All information for installation is in README file, and you can learn about available commands by visiting file with OCaml source code, and pressing C-h m to get description of mode, or by getting description of tuareg-mode function (if tuareg.el is loaded already).
Useful addition to these descriptions is Tuareg mode refcard that lists all (or almost) available commands.
Tuareg is really nice for:
Highlighting your code
Indenting your code correctly
Easily sending portions of code to a REPL
Easily compiling your code
Syntax highlight, indentation, as (almost) all language modes.
Compile or evaluate in a top level from a single buffer (you no longer need to open a ocaml toplevel in a command line to test some crap functions)
Caml-types minor mode : after a successful or partial compilation, you can easily point a variable and get the type the compiler inferred for it.

How do you learn proper Emacs? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I am about to learn Emacs, have been through the tutorial and borrowed the O'Reilly book on Emacs. But the question still is - how do you learn good Emacs workflow? I guess, you don't use Emacs as you'd use, for example, Vim.
This question seems revelant to mine:
- Where can I find a video of a professional using Emacs?
I can't believe nobody has mentioned this, but reading the info pages bundled with Emacs is a great way to learn about obscure features. Whenever you need a break from coding, hit M-x info and pick a random page to read. Your emacs ability will improve incredibly quickly.
It is also important to realize how emacs' self-documenting-ness helps you work. Say, for example, you are wondering how you can scale the font size. Instead of interrupting your flow and asking here, or on IRC, or Google, you can ask emacs! Just hit C-h a (M-x command-apropos) and type a search term, in our case scale. If there are matching functions, their names, keybindings, and documentation will appear. There are, and now you've just discovered text-scale-increase and text-scale-decrease.
There are other self-documentation functions that are good to learn C-h m will tell you what keybindings and commands are available in the current major and minor modes. This is a great way to discover features you didn't know existed.
Another way to "learn by osmosis" is to M-x customize-group for the modes you use regularly. (customize is the interactive configuration editor that almost all modes support.)
The final thing to do is to learn Emacs Lisp. It is nice to use existing tools, but sometimes you will need your own. If you try to avoid learning Lisp, you will always be stuck with things not quite working right, and that's a shame.
Emacs is a great environment for customizing itself. Emacs includes two Lisp manuals that are viewable via M-x info. It is self-documenting, so you can say C-h f or M-x describe-function to get the documentation for any function. You can even press TAB ENT to jump to the source code of that function, to see how it's implemented. This is great when you think "I wish I had something that worked like foo, but just slightly different." You can read how foo is implemented, make your change in the *scratch* buffer, and then see if you like the change. There is no edit/compile/test cycle. You press a key and your emacs session immediately has the feature you just wrote.
The more effort you put into learning emacs, the more emacs will do to make your work easier.
Once you mastered the basics (opening/closing files, navigating, basic editing) just use it. As with a lot of other tools, practise makes perfect...
I would, however, set some time aside to work on improving how you use the editor currently, but as part of your normal workflow as opposed to just going off on a tangent and learning things for the sake of it.
I find some useful resources are the EmacsWiki and the Planet Emacsen blog. I use both, mainly by using Planet Emacsen for "inspiration" and then wandering over to EmacsWiki and having a trawl on there for a specific topic. I found that unless you're having at least a vague idea what you're looking for, the available information is just going to swamp you instead of it actually being helpful.
Not to mention that there are a few very useful resources here on StackOverflow, for example this question here. Emacs is a very powerful tool that tends to be able to do a lot more than a single person needs, but in the end that allows you to pick and choose exactly those parts that you need.
My suggestion is just stop using anything but Emacs, when you come across a problem see if you can solve it in Emacs, and then fall back (if you don't have the time or it just won't work). As for work flow, it is pretty much the same as you would normally work. i.e. for a normal ide session you would open/edit a file as normal, then commit (in C-x v v) just as normal.
I agree with the other posters here, you just have to use it! Here's how I did it:
Once I got the very basics (can get between buffers, open/save files, etc), I printed out a reference card and kept it handy. This is a good one. Review it just so you know what is on it, then whenever you find yourself doing something repeatedly that is on the card, start using the shortcut! Before you know it you'll have memorized quite an arsenal of commands. But remember, probably no one uses everything that emacs can do.
When you eventually find yourself doing something repeatedly that doesn't have a shortcut, that's a good time to learn keyboard macros. Once you get them, you'll find uses for them everywhere! From there it's a short jump to writing elisp (if you're a programmer).
The great thing about emacs is that you don't need an "emacs workflow", emacs works around your workflow!
You don't need to learn emacs workflow. Once you complete the tutorial and master the essentials, you'll have to adopt some degree of monogamy and use nothing but Emacs. Eventually you will think of functionality that you really wished existed; most of the time somebody else will have as well and the solution is just one search away! Over time you just can't help but learn and eventually you'll pick up enough that you'll develop your own personal workflow.
If you're looking to accelerate the process, the Emacs wiki has a variety of tips but really the best way is just to do stuff with Emacs.
You could have a look at Bram Molenaar's talk about efficient textediting, http://video.google.com/videoplay?docid=2538831956647446078&ei=EqiGSau8KZ-QiQLi-Nn8Cg&q=bram+molenaar+editing
Although he's a vim guy (he wrote it), you might get some ideas about how best to go about becoming more proficient with your text editor that'll apply to emacs.
To be honest, all I do is learn the keybindings I need. I don't use emacs to its full potential, because I don't need its full potential. My suggestion is to just learn what you need, and don't worry about what you don't. Learn a new key binding everyday, and in about 300 years will you know them all ;)
I am using the emacs since the old Amiga days on all platforms i am currently working on.
The best way to use emacs is curiosity. I still use often apropos (C-h a) and M-x (for a long functionname instead of key-binding) to find a functionality.
a key-concept to "proper use" Emacs is, to learn the very easy elisp (a simple derivate of lisp) and write your own little helpers (own commenting style, underlining, templates) and to know where to look to change values (tab-size, compiler, email)
And the third thing: everything is in emacs: I use the dired (directory editor) for navigating through files. I use a lot of buffers for all textual files (with proper modes for each type of file (c, ruby, list, sql, latex, ...)) which are stored when quitting emacs and recovered when invoking. I start the compiler from emacs and use the jump-to-error-functionality.
Macros are a daily routine (scimming throu code and changing it on the way).
I like the picture-mode, which allows to type downward with replacing, which makes it easy to renumber block of constants (good old c #defines))
There is a hugh mountain to climb, but if you have reached the top, you can see the whole world down your feet, and never want to miss this experience again. I know, there are many good editors around (i work myself thru Eclipse)
As previously stated, the best advice is to use nothing but Emacs for the next year. Once you develop your finger memory, things get to be much easier.
How do you learn a "good workflow" for anything? By using it, getting to know it, making it yours. There is no "proper" use of Emacs.
As for getting to know it: ask Emacs -- use its help system. This can help too: http://www.emacswiki.org/emacs/EmacsNewbieWithIcicles
That's the power of Emacs, you use it the way you like. You just have to configure it before for your liking.