Using laptop as a second programming monitor - development-environment

The joys of multimonitor programming are countless, I think there are about 5 blog posts on Coding Horror on the topic alone!
I often code in Windows on my main machine, and have my Mac laptop set up to the side. I use the Mac both to compile Mac builds but also as my "reference web browser". There's no KVM or anything.
However a casual conversation at a conference led me to the question, could I use two independent machines to share windows? Literally move some windows from one machine to another, so I could use one PC's display as "overflow" from the other.
Some googling suddenly shows that this is possible in some situations for sure:
Synergy and Maxivista
My question is whether any programmers have tried such a setup. We have unique needs especially with multiple text windows and editors, and this kind of tool may be a huge win or a huge hassle.
This solution feels like a combination of easy KVM switching AND multiple monitors.. it sounds like a programming dream! So advice or especially reports of actual experience in a programming environment would be greatly useful before I invest in the rather complex setup.
Followup:
Sounds like I'm asking for something that doesn't exist! It's kind of combination of a software KVM and VNC. But the VNC would need to break out the app windows and allow individual manipulation (like that maxivista commercial tool, which is Vista only).
Thanks for all the feedback. Looks like there's demand for a cool app if anyone has the drive to be first in this new nich!

Synergy doesn't allow you to move windows between machines (that would require a silly amount of work behind the scenes), but it does allow you to share a keyboard and mouse between two machines so they "appear" to be all one machine, but actually run separately.
I personally use Input Director, as I found it more stable than Synergy. I have my laptop with an external monitor to the right, and my desktop to the left as an Input Director slave. My desktop runs a different O/S and is basically my guinea pig box for testing stuff and for anything I need to keep running when I leave the office. Cut + paste is pretty seamless, so I can quite happily fire up an RDP session to a server on my desktop, and cut+paste SQL scripts from that to my laptop.
It's a very useful thing to have if you have a few physical boxes and monitors kicking around :)

I've actually managed to use spare notebook as a second monitor to Desktop PC. This allows to move windows to second PC, but not vise-versa.
Solution would work basically with any OS.
The only requirement is a spare VGA (or DVI-I/DVI-A) port on server PC.
Make a dummy VGA plug http://www.overclock.net/t/384733/the-30-second-dummy-plug
This will also work for DVI-I/DVI-A port + DVI-VGA adapter
Detect virtual monitor with your OS. Monitor will be detected as very generic monitor, so you can set up any resolution. Set it to slave PC resolution.
Use any remote control software to connect from slave to server PC. Set it to display only "virtual" monitor.
That's all. Your slave PC is a second monitor for server PC.
I've used this on Windows 7 + TeamViewer. I've additionally set up Mouse Without Borders (Microsoft Synergy analog) to be able to use slave PC with same mouse&keyboard, though this is not required if you intend to transform it to monitor-only.

Xdmx - Distributed Multihead X Project (linux only)
Provides native X display on external machines, no VNC cons.

The following is not exactly what you want, but pretty close:
You can start a VNC server on the Windows machine, which will let you "export" its graphical screen.
Then, unplug the monitor from the Windows machine and use it as external laptop monitor instead, with your Mac laptop.
There, on your Mac, you just connect to the VNC session using Chicken of the VNC, which will give you the graphical screen content of the Windows machine as a Mac window (interactively, so you can actually control the windows machine as if you were working on it directly). You can put that on the external monitor, and you can also put other windows there, so you really have a shared environment.
I believe this solution also lets you copy and paste content from the Windows screen to Mac windows and vice versa.

I use MaxiVista on WinXP while programming. It works fantastically and lets me add a third screen to my multi-monitor configuration.

There is hope, here for windows users: http://virtualmonitor.github.io/ Looks like a work-in-progress and only supports windows 2000 - windows 7, but he's looking for help with windows 7 - 8.

Unfortunately, synergy doesn't allow moving windows across screens currently. It only forwards mouse&keyboard events from one set of physical devices to different computers.

Yes, and I love it. It allows you get past 2 screens on a laptop, and really I find 3 a great amount.
If your main machine is a Mac you want ScreenRecycler. You can then use monitors on other Mac, Windows, and Linux machines (anything with a VNC client). You will want something better than the Mac's crappy windows management though. I suggest Many Tricks' Moom and Witch.
On Windows, as #LachlanG said, MaxiVista works great. And it supports adding monitors from Windows, Mac, and Linux machines.

I am reusing my old laptop as a second monitor to see the live preview while coding. I am using SpaceDesk, which is free.

I use barrier and open source fork of synergy. Its a little hard to use but works really well. (To find it just search google for 'barrier github').

Related

Fedora 35 - DisplayLink - USB 3 in 2xDVI out - WIll it work?

I have an Dell Inspiron 3780. This is a really nice laptop, and runs Fedora 35 beautifully. I wish to attach 2x Samsung 2333T monitors via their DVI-D interface.
I have read that an HDMI to DVI splitter can only really mirror to two separate monitors, which is not the desired result. I wish to have an extended workspace across both monitors so they can be used as a single monitor.
I have also discovered that DisplayLink via USB might be able to solve my problem, but, of course, I then will require more expensive hardware. It looks like this product might be able to solve my problem : Targus 4k Universal Docking Station.
So, that would mean I would require the DisplayLink driver to be installed into my F35 instance.
Am I analyzing this correctly. I don't want to shell out loads of money if there's a better solution.
Yes, for this device to work, you must have functioning displayport in the system os.
The linked Targus does not appear to offer linux support or installation instructions, that might mean it is difficult or impossible with standard repositories.
Displayport installation may be possible through the https://negativo17.org/multimedia/ repository, but it's quite a gamble with the linked device as they show no support for any linux distro.
I got this working with a fujitsu PR8.1 This device has a DVI-D and a DisplayPort graphics connection, so, all I needed was a DisplayPort to DVI adapter, and everything works absolutely fine

Run IntelliJ in client-server mode

Currently, IntelliJ IDEA does not have a "Remote Development" feature.
Lets say I have two machines: Machine 1 (very good configuration ex 64GB ram with Intel Xeon processors) and Machine 2 (Macbook Pro with 8GB RAM).
Lets say I have IntelliJ IDEA installed on both machines. The problem now is, there is no client-server mode for the IDE. The closes thing I have is to use OpenNX.
What I'm looking for is a plugin/feature that enable remote development. What I mean by this is: On my macbook, I should be able to add Machine 1 as a "server". And once that is done, the IntelliJ IDEA on my macbook will only act as a client for the IntelliJ IDEA on my Linux box. Basically it would be replicating the UI. However, the catch here is that, it shouldn't do so by sending images (the way any VNC or NX client would). Instead, since it is for a specific application most of the data can be managed through text data only.
Since OpenNX uses images, even with compression it wouldn't match up the performance of text only transmission.
Basically I'm looking for IDEA on one machine to be a client (Remote GUI) for IDEA on another machine.
UPDATE
The eventual answer is: This is not possible (As of now). While I was aware of other options, that wasn't what I really wanted. However, it appears there is no such option.
The main reason why I wanted the option was because my desktop (remote Linux box) has a much higher configuration (Intel Xeon 2GHz processor and 64GB RAM) and my client was an Macbook Pro with Intel Core i7 and 8GB RAM. (By no means any less). However, due to the size of my codebase etc, the indexing of the code etc by the IDE slows it down.
Both client and server are perfectly capable of running an IDE by themselves. However, due the size of the code base it would be better to have the build of the work being done by the IDE on the server and the client being just the front end to it.
The other solutions like VNC, Nomachine - OpenNx all use image compression. And when your client is a Mac, you run into keyboard mapping problems. A client-server mode in the IDE itself would use text compression instead and would be much faster. It would also solve the keyboard mapping problems.
While to me, it sounds like a good idea, it probably doesn't get used by enough people for it to be a feature of the IDE.
Note: I would also be open to considering Eclipse as the IDE if this feature is available. Any answers will always be apreciated.
You'd probably be better off switching instead to a remote code repository that you keep in sync. While the concept of doing this in an IDE plugin is interesting, it has some fundamental flaws. What happens when the machines can't talk to each other? Are you unable to work at that point, or can you work offline. If you work offline on both machines, how do you reconcile changes...
I suggest looking into using "git". You can set up a remote repository very easily. If you have ssh access to either machine or some other shared machine, you can create a remote repository on that machine, and your "client" machines can easily push files/changes around.
There are plenty of other code repository options, but I've found git the easiest to set up.

Deploying a networked browser compatibility testing system

I need to provide our web developers an easy and quick way to test their code on multiple browsers. Here's my current plan:
Get a Mac
Install Windows XP and Linux over VMWare
Install all possible major browsers on these OSes, including on the Mac and the god-forsaken IE6.
This will allow developers to use the system to test their applications.
But is it possible to give them some sort of desktop sharing tool, so they can test remotely... keeping in mind that the their systems can be windows, linux(linus?) or macs.
Or am I doing it all wrong?
There are a few viable options I have used:
Get hardware. If you develop on Macs and have an old Windows box laying around, you might as well use it. You then need to figure out how you are going to connect to it. I have used:
(a) remote control tool (like VNC) to
a shared box. At one company we had a
IE6 testing box we all VNCed into
(b) Synergy on my desktop (which
allows sharing keyboard and mouse)
(c) Walking
VMs. Some developers like this because they have everything on one box, and can take it with them. You'll probably need multiple VMs for different versions of Windows. I've done this with both Parallels and VMWare.
External service. #chotchki mentioned one, but there are many others.
My current favorite is 1b, but they are all workable.
To answer your question: VMs are a reasonable solution.
There a web service that already does this Browser Shots. You can also install the software on your own systems if you want to host your own.

What is X Server and Remote Terminal Server?

Can someone explain what is the difference between X server and Remote Terminal servers in simple terms?
For example, Hummingbird Exceed is an X server and Citrix is a Remote Terminal Server. How do these servers work?
A terminal server runs at the "other" machine while you use a remote desktop client to view the other machine's screen.
A X server (of the X11 Window System) runs on your machine while another machine (or several thereof) send their output to your computer.
The most important difference to the end user is probably "culture": With the X Window system you typically work with windows that run on several hosts. (You often sit in front of a quite stripped down workstation, get one application from one computer, another one from another computer.) When working with X things feel very heterogeneous - a special application only runs on a HP workstation while your company is stuffed with suns or linux boxes? No problem, just buy one HP, everone can use that application over the network like as it was local.)
Remote terminal services feel more like another computer sends its complete screen to you, more like you have a 100-Mile-Long monitor and usb cable (with a little lag built in). You typically use a remote desktop client that sends a complete desktop to you.
However in recent times both techniques get close to another - windows remote desktop (which is based on citrix) can send only application windows to your desktop, while a lot of programs based on X11 are theoretically network transparent but practically need to run on the local machine. (Sorry, no 3D shooter over the network - an extreme example).
Which one is better? I don't dare to say. White X11 is a lot more flexible (it was designed with network transparency in mind - it makes absolutely no difference if an application runs local or remote - it is in many aspects more complicated. As long as there was no remote desktop sharing there was a clear advantage, but slowly the gap is closing, for example by terminal services now allowing you to do many things that were available with X11 only in earlier times.)
By the way, the main reason many X11 application still feel a little "snappier" over the network than windows counterparts is the thing that many application programmers on windows still think they always run local and dump a lot of bitmap graphics on the screen - like custom toolbars in ZIP tools. X11 applications did not do this for a long time and chose "ugly but fast" because X11 forces you to think about the network. But as X11 applications get more pretty and Windows programmers more aware about terminal services the difference will dwindle.
Oh and an important point: X11 is deeply ingrained in the Unix way of things, Citrix is mainly used on Windows (in the form of Microsoft's Windows Terminal Services - which originated in Citrix code). So lock a terminal services admin and a X11 operator into a cage and step back watching bloodshed when they figure out who they are locked in with ...
An X server most likely refers to the X11 windowing system, which is the GUI that most unix flavors (including linux) use. It's a client/server setup, and has been around for a very long time
A remote Terminal Server in the case of Citrix is a remote windows instance that can be connected to with a special Citrix client. The Citrix environments I'm familiar with are all MS Windows solutions, ie they work similar to X, but are for Windows Servers only
They both sort of operate in similar fashions, which is serving a remote client a windowing solution. IE, they both let a server run the actual application while the display of that application is sent back over the network to a client PC.
A 'Terminal Server', as it's called, basically allow you to connect to a Windows session remotely. They employ a bit of magic to make the experience snappy over connections with latency. The Windows GUI system isn't network transparent like X, so it took a while longer to get this feature. Windows Server 2008 and Citrix products have the ability to let you use a single application, unlike the traditional Terminal Server.
X is the GUI protocol for Unix/Linux. The X server accepts connections and displays their windows. The clients are actually the programs themselves. These clients can be local or remote, it doesn't matter to X. X just displays them as requested, on the local screen or over a TCP connection. This is lower level stuff than terminal servers, and allows graphical programs to run on one machine and display on another. X11 doesn't compress or encrypt the traffic like RDP does (although SSH can help you out there).
The linux equivalent of RDP is NX. They provide free software to run NX servers/clients. I've used it and it works pretty well.

Pros and Cons of Developing on a VM on a PC

I recently build myself a semi beef up PC (Q9450, 8GB DDR2 1066, 1TB HDD, Dual 8600GT, Vista Ultimate and Dual 22' Monitors) and I'm evaluating whether i should develop on a VPC/VMWare session on top of Vista or not?
One benefit I can see is that I can run the same VM on my Vista laptop so my development environment is the same on any of my machines. I also plan on purchasing a MBP before the end of the year as well.
Found a couple of articles online that semi-help Here
Any other thoughts would be really appreciated?
For webdevelopment I like to have the serverpart separeted out into a VM. My current setup is a Macbook Pro with several Debian VM's inside. I like the isolation aspect of it. I can try new software on the servers and have the ability to revert them back if something is messed up.
I do the programming via network-share (samba) in Textmate on the host system.
Another advantage of a VM is having a clean installed base. I use my desktop and laptop for lots of things aside from development. You never know when a piece of software you install is going to conflict, or if the little tweaks and what not you play around with are going to trash your OS. Reinstalling/configuring all your tools so they are exactly the way you want them can take quite some time. If you have a backup of your Development VM Image you can mess up your PC as much as you want but still be able to code without downtime. It also allows you to run Win/Visual Studio/Etc on a box that you would otherwise prefer Linux or MacOS on.
You can also make multiple copies of the same Image and use each one for a separate project.
Being able to transition between a laptop/desktop/server/remote connection, and always be in the same environment is also very helpful.
One problem I found (at least when using VMWare Server) is that no matter how fast your machine is, the screen refresh rate is still around ~30hz. That makes for a slightly unpleasant experience after using it for a while.
Where I'm working at now I use a VM for all of my development because I don't have admin rights to my base copy of XP.
Pros:
I like using a VM's because it give you some flexibility - you can switch between machines - have programs running on both and have a cool environment to work on.
Cons:
You have to boot up multiple operating systems. This takes time, memory and resources.
Clipboard operations on VM's can be interesting at times. Sometimes copying to clipboard does not work or gets mixed up between VM's. (Using VMWare).
File operations can be interesting when you plug in USB drives and other external devices. VM's sometimes do not see the devices, sometimes it does.
If your VM image become corrupt - you can easily loose everything in it.... unless it is backed up.....
It's great for presenting development talks, you can revert to a snapshot and give the talk from the exact same starting point each time.
Bulk-up your RAM on your future MacBookPro if VMWare will be used. I haven't (yet) and the performance with several other (mac-side) apps open really starts to feel sluggish.
All the best.
I was doing some work with Visual Studio recently with a Windows XP vm on Linux and somehow the guys who made the vm (vmware) made the windows machine actually run faster. We did some time tests to make sure and it wasn't major, but a few things (autocomplete for example) really did pop up faster.
If you are on Windows, Virtual PC is pretty decent for development work. VMWare Virtual Server is not really designed for use as a desktop and you will get very tired of it with any prolonged use. Sun's VirtualBox is another option competing with Virtual PC. VMWare has a workstation product but it is not free.
Typically, I do development on the real desktop (non-virtual) and then deploy or test to virtual machines which I can snapshot and roll back easily.
For a long time, we were developing on very early versions of Visual Studio 2005 and the associated .Net bits that went along with it. To protect our real machines from the various problems associated with pre-release software, we did all of our development work inside virtual machines. It worked amazingly well. I've been considering moving back to that model as it makes upgrading the physical hardware a snap (not to mention making it easier to deal with hardware failures by just replacing the entire machine): you just copy the VM image over.
On my current machine (A Core2Duo with 4GB of RAM), the performance drop when running one VM is almost not noticeable. Running two VMs, however, is painful.
I also can't figure out how to get VMWare Server to work across two monitors well.
I wouldnt want to develop in a VM so much as test things in a VM. For instance, it might be nice to set up a couple VM's to emulate an n-tier architecture, or a client-server setup or finally simply to test code on multiple OSs
It depends what you are developing and in what language.
VM's tend to take a fairly hard hit on disk access, so compiling may slow down significantly, especially for large C/C++ projects. Not sure if this would be such an issue with .NET/Java.
If you are doing anything that is graphics intensive (3D, video, etc) then I would steer clear of a VM too.
I don't know if it is so useful as a development platform unless you are doing something that ties into software you don't want to have installed on your regular working machine or that needs to work around a certain event that you need to be able to reset on a regular basis. It can also be handy when you are working with code that risks crashing your computer as it will at least only crash your VM.
It is brilliant for testing different configurations and setups- working with installers and so on, that is where virtualisation really shines as far as I am concerned, being able to roll things back whenever you need to and run through stuff repeatedy is amazingly useful for identifying problems before your end users run into them.
While doing development at home, I have to VPN into my company to be able to use the collaborative tools that are on the intranet. I also have a desktop + laptop that are hooked together through Synergy.
The problem that I have is that our VPN software wants things to be so secure that it will force all network routing through the VPN gateway -- even if I'm using additional NICs to network my desktop and laptop through a separate private network. The end result is that I can't use Synergy between my desktop and laptop and VPN into my company at the same time.
The solution suggested to me by a co-worker was to setup a VM instance on my desktop and use that for all my VPN needs. Works like a charm!
Speaking from personal experience developing java in an Ubuntu VM on Windows 7, I've found this to be quite productive. Mainly because my local IT support on the ground supports Windows 7, so I can do things like access all the local file shares and printers in Windows, and then config my Ubuntu VM to my heart's content.
Huge productivity benefits around remote access and desktop sharing. Windows allowed me to very quickly and easily use tools like logmein.com and join.me to access my machine from home and to desktop share the VM with other people in the company (both work seamlessly with the VM in a nearly full screen window). Neither of these services are supported on Linux, and I wouldn't want to deal with all the associated VNC/X setup and network config on Ubuntu.
My machine is fairly beefy. Quad core, with 16Gb RAM - 8Gb for the VM. Java dev in the VM is pretty quick.