Setting up an emacs environment in windows? - windows

I am currently constrained to a windows dev box and I want to migrate my projects from eclipse to emacs.
What are some good references on setting up an emacs dev environment for windows? Anything that could assist in migrating from eclipse as well would be appreciated.

If you're used to windows behaviors (e.g. ctrl-c is copy, etc.), a good (customized) version of emacs for windows is the 'EmacsW32' package.
If you're looking at migrating away from eclipse, I assume that you probably want java support. For this you will want to get the JDEE package, also. Unfortunately, it's non-trivial to deploy on windows, as it depends on other packages (and requires cygwin or msys (pseudo-unix environments for windows) in order to install).
You may also want to install additional modes to support e.g. SCM systems, etc. A good source of information for this is the EmacsWiki. There's a significant amount of material there about emacs on windows, although some of it is out of date....

Sure, just download a prebuilt version and use it.
For example, as I use R a lot with the wonderful Emacs ESS mode, the prebuilt version by Vincent Goulet is really useful as it contains Emacs, ESS, Auctex (for LaTeX) and more.
Other prebuilds exist for Cygwin, MinGW, or plain old Windows.

Eclipse is pretty good on Windows; I'm a big user of emacs but for Java development I spend most of my time in Eclipse.
Regarding general use of emacs on windows I highly recommend you install GnuWin32, as it is much faster than Cygwin and integrates very well. Also see my blog post on Visual Studio tricks in emacs and this one on tags.

I'll assume you are doing Java development for the most part and that you would prefer not to be using Windows. This is a situation I find myself in from time to time. My preferences are to use a Linux machine (virutal or real) in addition to the Windows machine. Emacs just works better in a real Unix environment. And then use both Emacs and Eclipse where each is stronger. Emacs for editing, mail, planning, "thinking" type stuff and Eclipse for debugging, refactoring, some error fixing. Fortunately both Emacs and Eclipse make it easy to use both simultaneously.

I generally use EmacsW32 on a new box - it's a good option at least initially. I'd also recommend checking out the emacs starter kits which hook up to ELPA (http://tromey.com/elpa/), which allows you to get a usable setup pretty quickly.

Install Cygwin.
In your .emacs, load these two files, in this order:
http://www.emacswiki.org/emacs/download/cygwin-mount.el
http://www.emacswiki.org/emacs/download/setup-cygwin.el

Related

IDE use a VM compiler?

I'm starting to work on my master thesis at the moment and I have a (maybe) specific question...
I want to stay on windows OS and run a Linux VM via VirtualBox combined with Vagrant. No Problem. I like the feature to reset the VM via vagrant easily.
The next target is using features like auto-completing or similar while developing in C++. This would help me to work with unknown includes/libraries.
Is it possible to access the filesystem/compiler of the VM while using an IDE (like clion) installed on windows? Without explicit loading of the gui und running the IDE on it? Kinda like working with cygwin? I don't want to use cygwin because it doesn't support c++11 standard (or is there a way???)
Maybe you know an alternative way. I would be glad for all hints solving my problem.
I don't know much about cygwin, though I would be surprised if they cannot get recent versions of gcc. But for certain, you can use MSYS2 to get very recent versions of gcc and many other linux packages, which will support C++11.
It's a matter of opinion how best to do cross-platform development, but an alternative worth mentioning is to use cmake for your project. When you want to code in windows, it can make MSVC 2015 project files for you -- when you want to compile in linux, it can find the dependencies and generate a makefile for you to use. IIUC, cmake is the most widely used cross-platform build system right now, besides gnu make itself. (I'm pretty sure it's more popular than "autotools" nowadays, and its definitely more popular than scons.) The advantage is that you avoid the need to maintain multiple platform-specific project files that essentially say the same thing with different formatting.

Windows IDE for Unix application?

We have created C&C++ applications based on Aix 6.1 (fortran for some models).
To improve our productivity (we use emacs or vi as editor, xlc/xlC/xlf as compiler, dbx to debug, IBM Synergy as configuration management tool), we are looking for an windows IDE to allow:
to modify our source code more easily,
to compile as if we are under unix
We also are logging for a graphical debugger.
Thank you for some ideas
I think that Emacs has been ported to Windows. And also GCC and Gnu make.
I've had some success with remote developing for AIX/Unix on Windows via a couple of routes.
Eclipse has some options. You can "mount" your project via ssh/rcp, and it will run the compiler remotely capturing the output. I did't attempt debugging but I assume support is there as well, especially if you use gdb.
BVRDE is another option. Works nicely. This link is also valid.
I also worked with XBuildStudio, it has some similar features to BVRDE.
Give them a try and see if any of them work for you.
Eclipse is a good one, but personally I prefer Codeblocks with Fortran plugin.

Custom Mercurial on Windows

There are some options for me for Mercurial on Windows (I know there is the .msi), most likely:
Cygwin
Bare Python
I'd like to keep a custom mercurial install with some extensions (most likely for GIT/SVN Integration) for three machines (Win32 / x64). So, its likely I'd need to keep the python runtime installed as well.
How would you suggest me managing that?
Thank you
UPDATE: TortoiseHG is an option, but I am concerned about: I only use CLI and MercurialEclipse, with no need to place a burden on my Windows Shell (and I am somewhat hardcore about that). Remember even with TortoiseHG I'd like to add custom extensions for stuff like GIT.
I'm going to shameless steal Master Geisler's obvious answer:
TortoiseHg
It gives you everything. Even kdiff3.
I actually use it exclusively from cygwin. Makes you forget about Windows for a while.

Development Environment in Windows [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
What are your recommendations for setting up a development environment in Windows, especially when not using an IDE. I am attempting to familiarize myself with Windows, and I feel a bit lost. What do developers commonly work on, especially when developing in multiple languages (e.g. Java, Python, C) in the same time.
So far, I have been a hardline using Mac+Linux environments where I love my command line a lot. I pretty much run all my compilations, testing, code repository commands in the terminal and have multiple terminals all the time. Terminal features (e.g. integrated bash completion, easy copy&paste, easy to setup environment variables) and package management tools (e.g. apt-get, port, fink) are quite handy. I dislike hunting down different websites to install their latest binary build.
Coming back to my question. My question is two fold:
What's commonly used? Do developers on Windows commonly use command line, or just be satisfied with an IDE?
For comers from Linux/Mac world: what do you recommend to get up to speed?
NOTE: I realize that a lot of Windows developers haven't used Linux, so they may not know what I'm talking about when it comes to Linux environment.
It's almost unheard of to not use an IDE for Windows development.
I started programming in the early 80's so grew up on the command line, but nothing beats a modern IDE for productivity.
By far the most common choice is Visual Studio, though I have also used #develop (open source) and find it a fine platform to get up to speed with.
I have used Eclipse extensively (on Linux and Windows) and find Visual Studio to be easier to use. I especially miss options for debugging under windows such as moving the instruction pointer around during debug and change-and-continue (change the code, within limits, while debugging, move the instruction pointer back if necessary, and keep debugging).
If you have used Eclipse, Visual Studio or #develop will not be that hard to get used to.
I tend to install cygwin, which is a unix emulation layer and includes many of the standard unix utilities (grep, awk, sed, etc). You can use bash or any other unix shell with cygwin to basically give yourself a unix environment on windows.
There are some downsides, paths are a good example. Windows programs expect windows paths while the unix tools expect unix paths. You can convert between the two using the cygpath program, but sometimes its tricky to know when to use it.
Another thing I do fairly often is create a bunch of batch files that load different programs onto my path. This allows me to have different version of say java installed and I can pick the version I want to use for any given shell session. I link a bunch of these together so that I have a full environment for the program I'm working on. For example, if I require java 1.5, maven, subversion then I would have a batch file to load each into the environment, then have a master file that loads all of them for a standard environment.
This approach gives a lot of flexibility and is really easy to maintain and work with different environment simultaneously.
Most windows developers that develop on the microsoft stack of products probably use Visual Studio. For windows development without Visual Studio, SharpDevelop is the current most popular alternative.
However if you are looking for a user experience more similar to linux you can always use windows command prompt and all of the command prompt compilers still exist. Just like with linux you'll have to modify your environmental variables to make everything work you you'd like it to.
If that still isn't close enough to the feel on linux, you can try out Cygwin.
Many of your common utilities from linux like gdb do have windows builds as well.
And of course there is the Eclipse IDE that is used for many languages, by many people, on multiple platforms. It is very extendable.
Some other tools you may be missing:
GCC - Available Via Cygwin
MS Build can give you similar functionality to what you had with make (I'm not sure if nmake is still used/supported)
Vi/Vim
Grep
SysInternals will have lots of various file/process monitoring utilities to hopefully adequately replace what you miss being able to simply get from /proc
Wireshark(or ethereal) to replace well... wireshark/ethereal/
Tail is available in the Windows Resource Kit
Emacs
Hopefully that covers most of your basic tasks.
Microsoft now has a real shell for Windows: Windows PowerShell.
In addition to Cygwin, there are ports for a lot of the GNU utilities and toolchain to Windows. GnuWin32 seems to be a more up-to-date version than UnixUtils. MSYS is essentially a port of BASH to Windows, but it's fairly useless without the MinGW userland.
C++ / .NET Development: Visual Studio 2008
Java / PHP Development: Eclipse IDE, which also supports C/C++.
For a non-IDE solution, Notepad++ is a very good code highlighter that supports many languages.
Simply install cygwin. The quality has improved dramatically in recent years. I'm currently running cygwin x64 on Vista, and it's great.
One thing to especially take note of in cygwin is your path. Most troubleshooting with scripts and installed software should begin there.
The other tip I'd give is to use the rxvt terminal over the standard issue cygwin terminal. It might be installed by default nowadays, but check to make sure.
Visual Studio for .net/C++ (even the express editions are useful)
The sysinternals tools rock, especially Procmon and process explorer.
If you do native/C++ work knowing windbg can be helpful
Notepad++ and gvim are my preferred editors
For doing command line/shell stuff I often use python to write short scripts (for anything but the simplest batch file)
If you are familiar with .net then learning powershell isn't much of a stretch and there is a ton of functionality available

Ruby and linux, preferred setup?

Mac's have TextMate as there preferred application for ruby development, but what would be the preferred application for linux? I need something where it's easy to work with multiple files, project structure and setup commands to run my ruby app or if it is one my merb app.Syntax highlighting is also a must.
Now I typically use Vim, but it's not the best for working with multiple files or with a project structure, even with VTreeView plug-in or multiple VIM windows.
So what would you guys suggest?
If you have better plugins to use for VIM feel free to mention them, I'm not ruling out VIM here.
I use Vim on both Windows and Linux for development in Rails (we have to use Windows in work, and I only use Linux at home). The environment is almost exactly the same for both platforms. Especially important for me is easy navigation between the various Rails components - from Controllers to views, partials and models, and quick navigation to test files.
Here are the plugins I use:
Vim Rails by Tim Pope. The :R, :A and gf commands are the ones I use mostly for navigation.
NERDTree for a project/explorer view.
NERDCommenter for easy multi-line commenting.
FuzzyFinder and "FuzzyFinder - Textmate" - allows you to quickly find files based on portins of a file name.
Ctags
Bufexplorer
dbext for executing SQL commands and getting the results in a Vim buffer.
Ack and the ack plugin for a better grepping experience from within Vim.
VividChalk colour scheme.
RubyMine from JetBrains.com works well for Mac/Linux/Windows, the price is 99$ but it's probably the most productive IDE for Ruby and Rails I have tested so far.
Setup Gedit to be almost like Textmate
Aptana with the Rails plugin is pretty good.
If you are on Ubuntu/Debian, plain old emacs with ruby-elisp package isn't bad. It's no TextMate, but it's not bad.
I prefer Netbeans on both linux and Mac
+1 for Netbeans for Rails. Each release gets better and better and with 6.7 beta it's better yet. Using it on Windows and Mac -- under Linux it's what I'd use as well.
Since you are a vimmer, have you looked at this? I have no experience with it, but looks quite good in the screencast.
Why don't you just use Sublime Text 2 Text Editor, it is free and cross platform and lighter than any IDE, and then you can install the SublimeCodeIntel which will provide you with autocomplete features , you can do that through installing Package Control , then
⌘+shift+p → “install” → ENTER → “codeintel” → ENTER → Restart ST2
It is working perfectly with me and I'm totally in love with this smart editor .
You can find this helpful somehow if you wanna give it a try , http://www.rockettheme.com/magazine/1319-using-sublime-text-2-for-development
I'm using it with zsh Terminal http://stevelosh.com/blog/2010/02/my-extravagant-zsh-prompt/
Anyways if you are looking for a full IDE give netbeans a try http://netbeans.org/projects/ruby/
I prefer Aptana/RadRails on both Mac and Linux. It gives a consistent experience for me no matter what OS I'm on.
I still don't get the excitement over Textmate...
Given that you use vim, this post might be interesting.
Her is the Fuzzyfinder Textmate vim plugin that the post refers to.
Aptana Studio is indeed very nice. Also Gedit does the job if you don't want a full IDE environment and are more inclined to do stuff by hand :).
The other answers are about ruby editors, so I thought I will add an answer on my linux setup.
I use Ubuntu with VM player (free) on top of windows 7. I dedicate 2 core and 2 GB to the vm. Benefit of using the VM on top of windows is that I can use linux just for development and windows for everything else. Skype, webex, and team viewer works in windows, but i find them to be flaky in linux. Also I use office once in a while, very easy on windows.
I have been using GMATE for a while and I can say that I only need gnome-terminal to complete my ruby/groovy/python setup. It have themes imported from textmate and do some method/property code completion (not much ok? but it comes handy).
Edit: forgot to say that GMATE is a set of plugins for Gedit (default text editor on gnome)
With Linux there are 3 really good IDEs and all are free. You have Eclipse, Netbeans, and Aptana... They are all very good and each have some benfits over the other, its more a matter of preference. I would suggest downloading all 3 and giving them a try to see which you prefer.

Resources