The reg program can be used to operate on the Windows registry from the command-line. Exporting registry entries is one of the tasks it can perform. Exporting registry entries is useful to save settings to a file and restoring or importing those settings on a different computer.
To export a registry entry, provide its registry path and an output filename. For example, to export the settings of the PuTTY program I used this invocation:
I SSH into a Ubuntu computer from a Windows computer using PuTTY. I run tmux (actually byobu which runs tmux underneath) and at a shell inside tmux I find that the left and right arrow keys do not work. They are actually detected as shift+left and shift+right arrow keys inside tmux.
This problem has been discussed here. One of the suggested solutions was to add set enable-keypad on to ~/.inputrc. That did not seem to work for me.
However, the above bug report also mentioned that this was a bug in tmux and it was fixed in tmux 2.4. So, I used this tmux PPA and updated the tmux 2.1 shipping in Ubuntu 16.04 to a tmux 2.6. The arrow key problem disappeared.
The vim-powerline plugin can be used to enable a statusline in Vim that is both beautiful and informative. Using it fully on Windows and especially for use with PuTTY has a few problems:
The Consolas font needs to be patched to view the fancy Unicode symbols in the statusline.
Visual mode string symbols are not downloaded properly from Github.
Mercurial symbol in Consolas, a lightning symbol, does not display for some reason.
Patched Consolas font name cannot be distinguished from the default Consolas in PuTTY.
I have forked the main vim-powerline repository and fixed these issues in it. These fixed files can be obtained here. Follow the instructions from my post on vim-powerline with this fork and you should be able to get the plugin running on Windows.
For PuTTY, remember to change the font for you SSH session to Powerline-Consolas and also ensure that the terminal can support 256 colors.
The statusline in Vim gets the job done: it shows the current mode and the location of the cursor in the currently open file. The vim-powerline plugin is a great way to jazz up the statusline of Vim and show lots of useful additional information. (As of this writing, folks are working on a new powerline plugin. This post is about the older vim-powerline plugin.)
The plugin uses lots of bright colors and needs 256-color support in Vim. One way to turn this on in Vim is by adding this line to your vimrc:
By default it shows a simple colored statusline. By using Unicode symbols, it can present a more beautiful statusline. To turn this on, add this line to your vimrc:
let g:Powerline_symbols = "fancy"
The plugin can show symbols if the file is in version control (Git or Mercurial), for the filetype, for the line number and many more. For this to work, you need to patch your font and use that patched font for your terminal or Vim.
If you are on Ubuntu and using the default Ubuntu Mono font, then a patched version of this font can be obtained here. Follow the instructions on that page to install the fonts.
If you are on Windows and using Consolas, either directly or through SSH with PuTTY, I have more information in another post.
For other fonts and setups, use the script and directions in the fontpatcher directory.
The plugin can show information on syntax errors and also version control information for Git and Mercurial. To view these status symbols and messages, install these three plugins: syntastic (for syntax checking), fugitive (for Git) and hgrev (for Mercurial).
With all this set up correctly, you get a Vim statusline that looks gorgeous and shows lots of useful information, both in terminal and GUI modes.
The PuTTY executable can be carried around on a USB thumbdrive or shared using Dropbox. However, the PuTTY sessions (profiles) that you created on a computer are stored in that computer’s registry and are hence not portable.
An easier way to make PuTTY portable is to install and use PortablePuTTY. It stores the sessions locally in a reg file and so you can use those profiles from any location transparently.
You are running Byobu on a remote computer to which you have connected using PuTTY. Everything works fine, except that the Byobu commands that use function keys (like F2, F3 and F6 for example) do not work. This problem is caused because the sequences sent by PuTTY for function key press does not match what Byobu expects. This can be fixed easily in PuTTY.
Load the session you use to connect to the remote computer. Go to Connection → Data and set the Terminal-type string to putty-256color. Save the session.
Load the session. Go to Terminal → Keyboard and choose Xterm R6 in the Function keys and keypad section. Save the session.
You connect to a server using PuTTY and run Byobu there. Everything looks fine, except the status line at the bottom starts to scroll up.
This problem is caused because by default PuTTY thinks that the characters it is receiving from the remote computer are encoded as ISO-8859-1. But, Byobu is encoding its characters in UTF-8. So, fixing this is simple.
Load the session you are using to connect in PuTTY. Go to Window → Translation and change the Remote character set to UTF-8 from the dropdown. Save the session.
Install a SSH server on the Nook Color. I installed DropBear Server II from the Google Play Store.
Start the DropBear Server II app. Choose Install. You will be asked to provide it superuser privileges.
Start the SSH server by choosing Start in DropBear Server II.
The password for root user can be found in the Settings section of DropBear Server II. Change it to anything you want.
On your computer, ping the IP address of the Nook Color to make sure it is reachable over wireless. If you cannot ping it, you have some networking problem.
If you can ping your Nook Color and its SSH server is running, then SSH to it using PuTTY. Provide the IP address of Nook Color and use root as user and password set in DropBear Server II as the password.
Happy hacking! 🙂
Tried with: Nook Color 8 GB, CyanogenMod 10-20121228-NIGHTLY-encore and DropBear Server II 1.5.4
You have installed Raspbmc on your Raspberry Pi, converting it into a cool little HTPC. (Here is how to do that.) The Pi is running Linux after all and it is connected to the home network. Now, you want to SSH into it to explore its internals. That is easy.
In your Raspbmc, navigate to System → System info → Summary. Take note of the IP address (for example: 192.168.0.12) that has been assigned to your Raspbmc.
Ping your Raspbmc to make sure it is reachable from the computer you want to SSH from. For example: ping 192.168.0.12. If the ping does not work, check the settings of your wireless router.
Use PuTTY and SSH to your Raspbmc using its IP address and port 22.
At the login prompt presented by your Raspbmc use the username pi and password raspberry.
Bingo! You are inside your Raspbmc now. Have fun playing around with it 🙂