How to write a clisp executable file? [duplicate] - lisp

This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
Lisp Executable
Was getting started with Clisp and the biggest problem I faced is that there are very few tutorials out there to explain how to write clisp files. Most of the tutorials are about using it in command line.
I'm not using Emacs. I'm using Clisp + Sublime on Ubuntu. Thus, what should I do to write a file of lisp code and execute it.

See the CLISP documentation how to save an executable:
http://clisp.org/impnotes/image.html

The most common way is to load your file using Slime. I strongly suggest you start using it.
If you absolutely don't want to, you can, as Clisp documentation states, use the --lisp-file option.

Related

Execute PowerShell without leaving gVim [duplicate]

This question already has answers here:
How to execute file I'm editing in Vi(m)
(13 answers)
Closed 8 years ago.
I'm currently using vim to edit several PowerShell files, but I'm finding it to be a real pain to always have to go back to my PowerShell console to run the scripts.
Is there a plugin that would allow me to either a) run the current script and/or b) run selected text. I've seen videos where such thing is done for other languages, but I can't for the life of me find the plugin.
This article gives a pretty straightforward description on how to do this. You are wanting to run Powershell through VIM correct?

How do I make an executable to avoid command prompt on Windows? [duplicate]

This question already has answers here:
How do I make my Perl scripts act like normal programs on Windows?
(5 answers)
Closed 9 years ago.
The reason I'm asking this is because after half an hour of failing to figure out what key word or jargon to use I figured it wouldn't hurt to ask here.
What I'm currently doing is getting a perl code to run using the good ol:
perl myPerlScript.pl
To get it to run. What I'd like to do for simplicity of presentation as a prototype would be to figure out how to make a script that I can run as an executable that would effectively be just a replacement of that. I know on Linux/Unix you can make bash scripts, but I'm trying to run this like I would Steam or other executables. Any advice or am I asking for something impossible? Having the command prompt pop up in the background is an option but preferably avoidable.
Also I've been using Cava Packager, but it's so bulky I figured since I'm only using one script there would be an easier way.
This answer shows how to make it so you can simply do
myPerlScript.pl
or even simply
myPerlScript
(Another way of achieving the latter is with the pl2bat tool.)

What guide should I read to start learning Emacs? [duplicate]

This question already has answers here:
How do you learn proper Emacs? [closed]
(11 answers)
Closed 9 years ago.
I don't really know if this is a decent question or not, but I am fairly new to programming and looking for a good text editor to use. I have read this question on Unix.SE and this question on SO which have convinced me that Emacs is the way to go. But I can't really find any good documentation that is aimed at people who have no idea what "M-x-foobar" means. Once again, this is probably too subjective for SO, but I thought I would try anyway.
If you're just starting programming, you've probably got enough on your plate without dealing with a crazy moon editor! gedit (Linux), Notepad++ (Win) or TextWrangler (OS X) are all free and may be more familiar to you.
Still, Emacs is great if you're game. I learned from a couple of resources:
O'Reilly's Learning GNU Emacs
Emacs' built-in tutorial - press Ctrl-h and then t.
These got me up-and-running quickly.
After you've learned the very basics, you'll want customize Emacs to make it more confortable. Download someone's Emacs configuration off GitHub and tweak that. The Emacs Prelude is very good.
From then on, it's all about building muscle-memory:
Try to use Emacs for all the random mundane typing and editing you normally do
Use the Emacs movement keys wherever you can, such as in your terminal program
If you use OS X, most of the emacs movement keys work in text fields. Use those instead of the arrow keys to move around.
Emacs has a reputation for being hard on your hands - the key combos were designed for older keyboards from a more civilized age. If your pinky starts to hurt while you're learning, it's a good idea to remap your Caps-Lock key as Ctrl.
According to my experience, Emacs is a huge topic to cover. I'd suggest you to start with its tutorial by selecting the first entry in the "Help" menu (or pressing Ctrl+h, then pressing t, which is denoted C-h t in Emacs style).
Then just follow your needs by reading specialized articles or documentation. A bunch of useful information you may find in an Emacs Info, which can be called by C-h i (Ctrl+h, then i).
Knowing at least a bit of Emacs Lisp would be very useful as it's used to configure the editor and sometimes helps understanding how some things work. For that you may find useful An Introduction to Programming in Emacs Lisp (but you may find it in Emacs Info as well).

Can emacs sessions (open buffers) be restored on a restart [duplicate]

This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
Restore Emacs Session/Desktop
I am using emacs for development. And there may be many buffers open. Is there a way that I can save the state when I close emacs. So that when emacs is again opened it restores the different windows?
I am looking at what browsers are able to do for restoring a previous browsing session.
Generally speaking, you don't ever "close" your Emacs. That's not meant to be a joke. The general style of working is to keep an Emacs running all the time and to just open new buffers in there using emacsclient. This is different from the vim style where vim is continuously opened and closed.
However, your question is an old one which has been asked by a lot of people and a lot of solutions have been proposed and coded up. There's a list of them on emacswiki. You can pick one that works for you.

How do I install a MATLAB mode in GNU Emacs?

Is there an Emacs major mode for MATLAB and / or Octave files? For those who don't know, MATLAB files generally have a ".m" file extension.
My primary interest is GNU Emacs but XEmacs tips would also be appreciated.
Have you tried the octave-mode that is part of the standard emacs distribution? I have found that this works well.
If you're finding it doesn't associate the .m extension, add this to your .emacs:
(setq auto-mode-alist
(cons
'("\\.m$" . octave-mode)
auto-mode-alist))
You'll be wanting http://matlab-emacs.sourceforge.net/ , I would imagine? Read the instructions there.
I used an ancestor of this years ago in XEmacs, so it certainly used to have support for it, but I believe the author is an GNUEmacs user. The guy who wrote it (Eric Ludlam) is a Mathworks employee, so it has vague official credentials.
Not built in in GNU Emacs 22. I found a matlab mode on the web (elisp), but it dates from circa 2000, so I don't know what kind of support you have.
To install you must get emacs to load it, then invoke the mode. You can interactively issue a load-file (With M-x load-file) to test it.
There's a matlab.el file from Matthew Wette on The MathWorks File Exchange. The file doesn't appear to have been updated since 1997 (!), and simply says it is "for early versions of Emacs", but hopefully it will still be of use to you.
I recently downloaded a Matlab mode for Emacs from the Matlab Central file exchange. Works just fine. Don't recall exactly where I found it, if you have trouble let me know and I will look harder.