• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Mikey Boldt

What am I doing?

  • Home
  • About Mikey
  • Contact

Tech

VirtualBox Guest Resolution Auto-Resize

April 23, 2012 by Leave a Comment

I’ve been tinkering off-and-on for a while to get my VirtualBox Windows 7 guest resolution auto-resize working. While not mission-critical, it smooths my workflow, and perhaps most importantly, it bugged the heck out of me when it wasn’t working.

The problem was that when I’d resize the guest’s window (or, more specifically, when I shuffled windows in xmonad), it would revert the resolution to 640×480. Some tinkering revealed that auto-resize behaved properly up to a certain window height, then would revert to 640×480.

Some things I tried, which didn’t work (googling shows this is a common problem):

  • Increase video RAM.
  • Install (experimental) 3d acceleration guest additions feature.
  • Set global max UI size to “any”.

But, I believe the thing that worked for me was (in the guest):

  1. Right-click the desktop, select “Screen resolution”.
  2. Click “Advanced Settings” (on right, middle of screen).
  3. Click “Monitor” tab.
  4. Uncheck “Hide modes that this monitor cannot display”.
  5. Click “OK”.

I tried changing the resolution to 1920 x 1440 (though fullscreen for me is 1900 x 1200, I didn’t see this option). The guest screen seemed to virtually flicker a bit, until I changed the window size, at which point it auto-resized as it should.

Filed Under: Tech Tagged With: virtualbox

Emacs: open-line with fill-prefix

January 16, 2012 by Leave a Comment

This has happened to me one-too-many times, so I figure I’d post it:

I’m writing a longish comment in some code. I write it on a single line at first, then call fill-paragraph to let Emacs break it up into multiple lines of sane width. But, it prefixes each line with some text I’ve recently killed. The same prefix pops up when I call open-line as well.

I dug into this a bit, and found that I must have accidentally set the variable fill-prefix (which is bound to C-x .). To undo this, just call set-variable and set fill-prefix to nil, and go back to happily opening lines and filling paragraphs.

Filed Under: Tech Tagged With: emacs

Execute Code via Org-mode Links

January 5, 2012 by Leave a Comment

I was recently browsing the org-mode link documentation to see how I could link to my Gnus email inbox1. Looking through, I noticed a couple of interesting link capabilities I had not known about before:

shell:ls *.org A shell command
elisp:org-agenda Interactive Elisp command
elisp:(find-file-other-frame "Elisp.org") Elisp form to evaluate

Having the ability to run arbitrary shell commands and Elisp code via an Org-mode link seems very powerful. This is mainly a note-to-self to remember this capability. I will report back if/when I find a good practical application for this.

Footnotes:

1 The format is gnus:group.

Filed Under: Tech Tagged With: emacs, orgmode

SOPA Revisited

December 22, 2011 by Leave a Comment

A family member sent out an email with information on the new petition to veto SOPA, and he asked for my take from the technical side. This is based on my reply.

I am aware of SOPA, and the senate version called PROTECT IP. They are bad. There’s a good video at http://vimeo.com/31100268 that explains a bit.

I don’t know a lot about the technical details, but on a high-level, “The bill would allow the U.S. Department of Justice, as well as copyright holders, to seek court orders against websites accused of enabling or facilitating copyright infringement. Depending on who requests the court orders, the actions could include barring online advertising networks and payment facilitators such as PayPal from doing business with the allegedly infringing website, barring search engines from linking to such sites, and requiring Internet service providers to block access to such sites.”1

Frankly, I find the scary part to be giving US government and copyright holders the right to control what websites we can access. As if our media isn’t controlled enough already (see this for an example), this would remove the main open exchange of ideas and information we currently have. Sounds like China.

Since you asked about technical details, here is an article that looks at some of the ways SOPA could be implemented by ISPs. Pretty technical (I wouldn’t bother reading it if “DNS” doesn’t mean anything to you), but it gives a nice concise overview if you have the background.

Though I have admittedly not followed this very closely, and I’m typically not much of an activist, I have signed a prior petition and contacted my representatives, blogged about it, and posted on twitter and facebook about it. The Electronic Frontier Foundation has some good resources for doing more.

So, yes, I will be signing this new petition and contacting my representatives. Thank you for sharing the update and the new petition!

Footnotes:

1 http://en.wikipedia.org/wiki/Stop\_Online\_Piracy\_Act

Filed Under: Tech Tagged With: politics, sopa

Disciplined Email via Emacs Gnus

December 18, 2011 by 1 Comment

I’m a believer in the Inbox Zero philosophy; that is, I don’t like my brain to be in my inbox. If I have more than about 5 read emails sitting around, I get uncomfortable. I recently noticed myself getting sloppy with email, so I watched the Merlin Mann’s original Inbox Zero video for a refresher. The part of the video where Mann describes typical email processing as a deli chef who reads the orders multiple times, organizes them in different ways, but never actually makes a sandwich. Email is a support tool to help us actually do things. It is a means to an end, not an end in itself.

So, I took a look at the tools and processes I use for email. Since email is text, IMHO it belongs in emacs. I have been using emacs mew for a while now, since I like how it allows you to keep using emacs when it’s doing IMAP operations. I also use k9mail on my Android phone to check email hourly. My plan was to process email in mew daily, and keep in touch with the rest on my phone.

My analysis is I got sloppy in three aspects:

  • I read too much email on my phone. I was e.g. catching up on mailing lists on my phone, when really that should be done at my daily mew session.
  • In my daily mew check, I would leave mail for processing later.

To combat this, I started using Gnus instead of mew. The key feature of Gnus is that it reads email like a newsgroup reader–that is, once an email is marked is “read,” by default it no longer shows up in your inbox. This provides a constant reminder that email should be read once and processed, not left in the inbox to reread and process later.

As a side benefit, I find Gnus to display email beautifully. HTML emails show inline images properly. It displays messages properly threaded. I love the overall look-and-feel.

This is my current plan for disciplined email. In a month or two of using Gnus, I’ll check in to see how my email processing is going.

Filed Under: Tech Tagged With: emacs, email, gnus

Fight SOPA and PROTECT IP

December 14, 2011 by 1 Comment

For better or worse, I don’t get into political action much. However, this strikes a chord with me. Current legislation, namely the Stop Online Privacy Act (bill) and PROTECT IP (bill), aim to extend the reach of the US government and copyright holders against websites they believe to be in violation of intellectual property rights. Here’s a video explaining some of the details–watch it to the end, where there are some notes on more recent versions of the bills.  The EFF has some great resources to fight SOPA and PROTECT IP.

[iframe src=”http://player.vimeo.com/video/31100268?title=0&byline=0&portrait=0″ width=”640″ height=”360″ frameborder=”0″]

Filed Under: Tech Tagged With: politics

Emacs: ssh with Tab Completion

December 5, 2011 by 1 Comment

Something that’s bugged me is that when I ssh into another machine inside a shell in emacs, tab completion gets still behaves as if I’m on the local machine. Just by chance, I once started a shell when using TRAMP to edit a remote file via scp, and noticed that the shell was on the remote machine and tab completion worked! So, I used this little in a function to start a remote with tab completion without manually opening a file on the remote machine first:

(defun remote-shell (&optional host)
  "Open a remote shell to a host."
  (interactive)
  (with-temp-buffer
    (let ((host (or host (read-string "Host: "))))
      (cd (concat "/scp:" host ":"))
      (shell (concat "*" host "*")))))

(defun myserver-shell () (interactive) (remote-shell "myserver"))

Filed Under: Tech Tagged With: emacs

Install Emacs 24 in Ubuntu

November 30, 2011 by 16 Comments

[2012-07-19] Update: Please see Damien Cassou’s comment describing his emacs snapshot PPA moving forward.

After reading several good things about emacs 24, I decided to give it a shot. A little googling led me to Damien Cassou’s emacs snapshot PPA. Simply ran the following:

sudo add-apt-repository ppa:cassou/emacs
sudo apt-get update
sudo apt-get install emacs-snapshot
emacs-snapshot

Everything works great so far, specifically email in mew, chatting with jabber.el, my org files, and org2blog/wp. Played with the built-in ELPA package manager a little, and I really thing it will be nice to avoid manual package management.

Haven’t decided if/how often I’ll update my snapshot. Maybe until emacs 24 comes out in the Canonical packages? But then will I want to stay on the bleeding edge? Thoughts/suggestions/experiences?

Filed Under: Tech Tagged With: emacs, ubuntu

Solved the “abfh” Problem

November 7, 2011 by Leave a Comment

One Linux server at work has always messed up my keyboard mapping when connecting to it via VNC. Previously, I had worked around this issue by changing the window manager from gnome to evilwm in my ~/.vnc/xstartup file. This got me by for a while, but I had trouble with the mask keys when I switched from Mac OSX Lion to Linux, so I came back to solving the problem. In my googling, I found this often-encountered situation referred to as the “abfh” problem1.

This post, and in particular, this comment provided the best solution I found for the “abfh” problem:

dcatdemon said...
Perhaps you can try this:

1. edit your $HOME/.vnc/xstartup
2. put the line "export XKL_XMODMAP_DISABLE=1" before your gnome-session.
3. restart vncserver.

and lo, it works :).
credit must go to this link.
http://bugs.gentoo.org/show_bug.cgi?id=190865#c7

There are many other possible solutions, but this seemed cleanest and simplest–and you gotta love a 1-liner.

Footnotes:

1 “abfh” refers to the output of pressing the standard key-mashing sequence “asdf”.

Filed Under: Tech Tagged With: abfh, gnome, keyboard, vnc

Why I left Mac OSX for Linux

November 2, 2011 by 1 Comment

Background

In my days, I’ve explored many different operating systems. My first computer exposure was playing games like Oregon Trail, Number Munchers, and Odell Lake on an Apple II in the classroom (ah, the classics). The first computer in my home, an Intel 386, ran DOS, eventually with Windows 3.1 on top of it. Through high school and college, I ran many flavors of Linux and BSD. When I started collecting a paycheck, I got a Mac, which provided the best of both worlds—a full Unix environment with hardware that just works. I don’t have as much time as I used to for tinkering with device drivers, X configuration, and window managers, though I still spend a lot of time on the command line, so Mac was a good fit.

Lion

First, I admit I hastily upgraded to Lion. I hadn’t had trouble with any previous OSX upgrades. A coworker had good things to say. I was sold. And the upgrade went fine (and even if it hadn’t, I still had my Time Machine backup). But when I saw the new features, I started getting uncomfortable.

My Computer is not an iPad

In my new Lion environment, the new launcher and full-screen apps make my computer look and feel like an iPad. I don’t want my computer to be an iPad. If I wanted an iPad, I would get an iPad. I understand there is nothing forcing me to use these features, but this direction and philosophy worry me. If this is where the train is going, I want off.

The Final Straw

Being a bit of an experimenter, I decided to try to embrace some of the new features. I added a second desktop in Mission Control and started using some full-screen apps. That’s when my machine started acting up. Every so often, apps would become unresponsive. I could switch between apps, but they wouldn’t respond to input. This, for me, was the final straw.

Horror Stories

Beyond my own concerns and issues, I’d heard several people have bad experiences with Lion. My wife’s network card got flaky after her upgrade. I know folks needed to spend time getting MacPorts back together. One coworker’s machine had severe performance issues after his upgrade, and Apple support walked him through their equivalent of fsck. The filesystem “repair” left his machine unbootable, requiring him to start over at Snow Leopard, upgrade again, and recover from his Time Machine. Then there was Tim O’Reilly’s tweet about Lion. These horror stories were reputable enough for me to seriously question Lion’s quality, and not write off my own experience as a fluke.

Linux

So, I installed Ubuntu Linux, as it has the reputation of “just working.” And, that was exactly my experience. Everything down to e.g. the screen brightness buttons on my MacBook Pro keyboard worked out of the box. I’d heard some murmuring about problems with Skype on Linux, but even that worked fine for me. Now instead of my browser taking up a full 1920×1200 screen, I’m running xmonad in Gnome to maximize my screen real estate. Desktop Linux has come a long way since I first used it in the 90’s.

Conclusion

In brief, I do not like the direction Mac OSX seems to be taking. My computer is not an iPad, and I don’t want it to act like one. I’ve heard about and experienced Lion’s bugginess. Over the years I’ve been using Mac, Linux—specifically Ubuntu Linux—has caught up to the point where it works out of the box, while providing the ability to tweak it to my tastes. Linux is the friend I haven’t seen for years, but after reconnecting we have more in common than ever. It’s good to be back.

Filed Under: Tech Tagged With: linux, mac

  • « Go to Previous Page
  • Page 1
  • Page 2

Primary Sidebar

Recent Posts

  • Recover from Blank Screen After Unplugging External Display in XFCE
  • Remove a Key Binding From Emacs Mode
  • Disable Bluetooth on Ubuntu Startup
  • Geequie: Cull Photos on Linux
  • Sync PDFs with Android using Dropsync

Recent Comments

  • Ricardo Orbegozo on Linking to MS Office File in Emacs Org Mode
  • eliaso on Linking to MS Office File in Emacs Org Mode
  • Joao Brito on Linking to MS Office File in Emacs Org Mode
  • Unable to install Emacs 24 from ppa:cassou/emacs | Ubuntu InfoUbuntu Info on Install Emacs 24 in Ubuntu
  • Unable to install Emacs 24 from ppa:cassou/emacs | WyldePlayground.netWyldePlayground.net - on Install Emacs 24 in Ubuntu

Copyright © 2025 · Mikey Boldt Theme on Genesis Framework · WordPress · Log in