Rick Dillon's Wikilog
I often want to know where my disk space is being used. For example, my .thunderbird direcory clocks in at several gigabytes, but the Mutt cache (which should also contain my mail) is 500 megabytes, since it isn't a complete download and doesn't include attachments. I've used various tools over the years to analyze disk usage, but always seem to search the net for something like "disk usage analyzer linux" to find good ones every time a install a new distro. It turns out that going back to basics is often the best policy, since it works everywhere. I think this alias handily covers most of my use cases, since it analyzes the current directory, allowing me to drill down as needed to figure out which directories are the worst offenders and why. No special tools needed.
alias disk='du --max-depth=1 | sort -n -r'
You can pipe it through less or head if you want to browse the results or only view the biggest directories.
I just discovered Ward Cunningham's Smallest Federated Wiki. It's amazing that the man that first innovated the revolution in internet collaboration and sharing seems poised to do so again. Anyone who knows me can tell you how much I value the idea of federation on the web, whether it be social networks, chat, mail, version control, or wikis. Federation is, in my mind, without a doubt, both the past and the future of the web. There are challenges, to be sure: federated search exists, for example, but is extremely difficult to do well. Messaging of various kinds (email, IRC, instant messaging) is a natural fit. Distributed, federated version control is not only possible, it dominates on the web. Social networks are really a form of messaging, so they should be federated, even though the main networks are not.
Wikis are a less obvious application of federation. I've long believed that a federated wiki is really a way to expose the basic functionality of distributed version control through a browser. I even implemented a federated (distributed) wiki based on Mercurial a few years ago. But watching Ward Cunningham's videos makes me realize that there is a whole lot more we can do with federated sharing on the web. It reminds me how lucky we are to have folks like Ward Cunningham leading the charge on such efforts.
Chromium in CrunchBang Statler
I've recently moved to using CrunchBang Linux on, well, pretty much every machine I own. I've done four installs of it in the past week, and I'm very impressed. The only real issue I have with it is that Debian, one of my favorite distros ever, isn't based on a rolling release, so it tends towards older versions of programs. Most of the time, it's not that big of a deal, but for software that I use all the time, or that I'm obsessed with, it doesn't work. Today, the fact it was locked to Chromium 6 was really getting to me. Neither CrunchBang nor Debian make up-to-date repositories available for Chromium, but I did run across an Ubuntu PPA for Lucid (!) that works! Here's how to use it:
# Add the repo sudo echo 'deb http://ppa.launchpad.net/chromium-daily/stable/ubuntu lucid main' > /etc/apt/sources.list.d/ubuntu-chromium.list # Add the repo key sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4E5E17B5 # update & install sudo apt-get update sudo apt-get install chromium-browser
While merge sort is quite simple conceptually (split list in half, sort each half, merge the two halves back together), it has some corners that make it tricky to implement correctly. I like to implement fundamental data structures and algorithms using only arrays, since it gets me down into the details of what's really happening so I can better understand the performance of the algorithm or data structure. I found that I had a couple of OBOEs relating to the exclusive upper index in System.arraycopy that caused my merge sort to do odd things. In the course of debugging, I wrote a little sort visualizer, the output of which I'm including here. I'm not planning on posting the code for my implementation, since there are better sources for that. Maybe I'll put together a subsection of this wiki at some point with my implementations for dynamic arrays, hash tables, sorts, trees and other goodies, but none of the code is really ready for that yet.
So what is this output? It is the state of the array when each call to merge is made. It specifically doesn't include calls to mergeSort, since it doesn't modify the array itself, only the limits of the area of the array under analysis.
[9 2] 1 3 6 8 7 4 10 5 Low: 0 Middle:0 High: 1 [2 9 1] 3 6 8 7 4 10 5 Low: 0 Middle:1 High: 2 1 2 9 [3 6] 8 7 4 10 5 Low: 3 Middle:3 High: 4 [1 2 9 3 6] 8 7 4 10 5 Low: 0 Middle:2 High: 4 1 2 3 6 9 [8 7] 4 10 5 Low: 5 Middle:5 High: 6 1 2 3 6 9 [7 8 4] 10 5 Low: 5 Middle:6 High: 7 1 2 3 6 9 4 7 8 [10 5] Low: 8 Middle:8 High: 9 1 2 3 6 9 [4 7 8 5 10] Low: 5 Middle:7 High: 9 [1 2 3 6 9 4 5 7 8 10] Low: 0 Middle:4 High: 9 1 2 3 4 5 6 7 8 9 10 Low: 11 Middle:11 High: 11
I've written up some of my recent trials and tribulations (see ThinkPadWifi) with Ubuntu 11.10 on my ThinkPad. While that (not yet complete) page is really about problems that are not easily solvable by the community, there are other problems than are, and it's getting a bit frustrating.
The major new desktop environments and influencing the Linux desktop in harmful ways. In particular, I'm thinking of Gnome 3 (Gnome Shell), Unity (both 3D and 2D) and KDE 4.
In short, they are adopting the opposite philosophy that, say, Google does. Google is infamous for leaving products in Beta for years after they are in wide use across the world, and often vastly better than any competing product (GMail comes to mind). Linux desktop environments are doing the opposite: they are delivering low quality replacements for extremely mature, high quality environments. The fact that the software is low quality doesn't bother me: it's free, and it is a work in progress. All software starts out being low quality.
But I am frustrated that various distributions have chosen to make these environments the default, causing new users to run into problems that there is no need to expose them to. Gnome 2.x is still a very servicable desktop environment, and could remain the default while the new version is brought up to speed.
This "adopt early, adopt often" recklessness is part of the reason corporations stick with "enterprise" distributions like RHEL5, which runs software from the stone age. Case in point: Emacs on my corporate desktop is set at version 21.3. Release date? 18 March 2002.
Isn't there a middle ground somewhere here?
The Eclipse Foundation announced yet-another-JVM-language called Xtend. I clicked on the article with the announcement out of curiosity, since I tend to like playing with new languages quite a bit, and have done most of my professional work under the JVM (Java, Scala and Clojure, with a bit of Jython). After looking through what they're doing, I really like it. Xtend makes me exited to start a new project and try it out.
But, when I went to download Xtend, I was presented with an interesting requirement:
"You need a running Eclipse including the Java Development Tools (JDT)."
Now, I understand Xtend was developed by the Eclipse folks, but I'm really disenchanted with new languages that mandate a particular development environment. You'll notice that most languages allow coders to use many different environments (by offers at least passable command-line tools), but are often optimized for a common use case, like using Eclipse as an IDE. Google does this extensively: they clearly are big consumers of Eclipse and have deeply integrated it into their GWT and Android development toolchains, for example. But they always go out of their way to provide a lightweight command-line environment that works with Vi or Emacs as well. I think that is really important; tying a language to an IDE is a brittle approach that forces users into a particular toolchain, whether or not they are familiar with it.
The topic of language design and development tools is deep, but I just wanted to express my surprise and mild disappointment that Xtend is only available under Eclipse. Perhaps some command-line tools for it are available and I just missed them.
Gina Trapani shared a post from Brian Shih, who used to be a product manager for Google Reader. To provide some context, Google Reader has been the dominant RSS reader for just about six years, garnering an extremely strong but limited following (inherent in the genre; RSS is not used by the majority of web surfers).
Reader recently underwent a redesign. The majority of users evaluated it on its aesthetic merits, though users that made extensive use of keyboard shortcuts and for whom sharing was an integral part of the Google Reader experience noticed that the sharing functionality was altered significantly to bring the product more in line with Google Plus. As a result, the changes have impacted users to varying degrees. Some users simply don't understand what the big deal is, others complain about the whitespace that is now more prevalent than ever, and yet others (myself among them) complain about the nerfed sharing functionality, especially that which is accessible via keyboard shortcuts. Because users use Google Reader differently, the changes have had varied impact on them.
This post isn't about any of that.
Rather, when I step back and evaluate what has happened, I'm reminded about the fundamental flaw in Google's strategy, and the fundamental flaw in cloud computing. All the trends in computing are moving away from a world in which the user has control, and towards a model in which the user is merely a consumer.
Consider web applications. These are often touted as the replacement for desktop applications, offering many advantages, like seamless upgrades, a globally distributed network of backups, and accessibility across a wide variety of devices.
Consider app stores. Users are herded into obtaining the programs for their computing devices from fenced off stores, the virtues of which are lauded widely: higher average app quality, reduction of malware, and, again, seamless upgrades.
Consider email. This one is a bit more subtle, but the reason that the original web applications (email, IRC, usenet, websites) were successful was that they were federated. In simple terms, that means that anyone could run their own email server and communicate with anyone else that ran an email server. It was, in essence, peer-to-peer. The same is true of IRC, usenet, and websites. But today, we have consolidated providers that the vast majority of users flock to. The modern day killer apps aren't IRC or usenet, but social networks, and those have emerged in the form of Facebook, an enormous walled garden. Efforts have been made to make a federated version of Facebook (see Appleseed and Disapora), but none have made significant inroads. Users' data is being removed from their control, and in most cases, they don't even know it.
When we remove control from users, we remove the option for them to retain the tools they like, instead forcing them to "upgrade" to whatever new version is deemed "better". This model works very well when the dictator is benevolent. It works best when the code for the tools is open, and can be forked into new versions when the official version is not desirable to a large group of users. But what about when the dictator making the changes is malevolent (i.e. the service provider's interests don't align with the customers' interests), and the code is not available? In those cases, which are the vast majority, the users are locked in, and without recourse.
In the case of Google Reader, I think the changes are bearable, but I also have found two backup solutions that run under my control that can replace it (NewsTicker and RSS2Email). Neither offer the exact same functionality, but they both offer good aggregation of a wide variety of news sources via RSS.
But that's not really the point. The point is that, for many users, the model in which the corporations make decisions for them is optimal. Many users don't want to worry about the detail of running or maintaining these services. But the health of the entire ecosystem is dependent on the minority being able to choose for themselves. And that means a move away from cloud services and towards federated, open source tools. Consider the impact email has had on the growth of the net. It is the first and most basic service every citizen has on the Internet, and we take it for granted. We need to consider what properties made email so successful, and mirror them in other services that we believe should be taken for granted.
Today, Google announced the integration of Google Reader with Google Plus, a feature I've waited for since the announcement of Google Plus. The announcement was covered oddly in some circles, however, indicating that Google Reader would no longer be available as a stand-alone product, and rather as an integral part of Google Plus. While I believe this characterization is not completely accurate, it represents a significant shift for Reader, since Google Plus carries with it its own set of terms of use.
Before I go further, its worth explaining very briefly what Google Reader represents. For its most dedicated users (me among them), it is the gateway to the internet. Years ago, I found myself visiting dozens of sites per day to stay up-to-date on the issue that were important to me. The advent and relatively rapid adoption of RSS across the web was therefore vital to the development of a sustainable model of information consumption for those that drew their news from dozens or hundreds of sources. Reader represents the most advanced and streamlined experience for news aggregation available anywhere online, and offers unmatched social networking functionality by allowing users to share and comment on each others articles. It is a healthy, if little known, social network centered around real content and commentary, rather than mundane status postings (in my biased opinion).
While I will likely continue using Reader in its new incarnation, the event is an excellent reminder that when we use a web service to act as a mediator or aggretagtor of information (as is any news reader or social network), we cede control to the service that provides that functionality. If they decide to discontinue or alter the product, users are left with limited choices.
I've been keenly aware of this issue for some time. For years, I've actively searched for a news reader that comes close to Google Reader, either online or offline, and as of a couple of months ago, I hadn't found one. Then, in September 2011, I looked into Emacs newsticker once again, and not only found newsticker-treeview, but I also found that w3m can be used as a mechanisms to translate HTML to text. The combination is superb, and so closely replicates the functionality of Reader that I feel I have a viable replacement for Reader, should I ever need it. Naturally, it lacks the social sharing features that Reader has, but that is to be expected. It's good to know that Emacs continues to provide cutting edge usability in an age that has pushed text editing to the background.
I'd be very curious to hear about any other open alternatives to Google Reader if you know of any. Feel free to shoot me an email: rpdillon <<at>> killring <<dot>> org.
Ran across this and it struck me - the Dalai Lama was asked what surprised him most about humanity. He replied:
"Man. Because he sacrifices his health in order to make money. Then he sacrifices money to recuperate his health. And then he is so anxious about the future that he does not enjoy the present; the result being that he does not live in the present or the future; he lives as if he is never going to die, and then dies having never really lived."
I've been doing some analysis on my financial situation, and it occurred to me that understanding basic mortgage equations would be useful. Lots of sites offer mortgage calulators, and some even offer equations, but I couldn't find any that offered code that computed the basics like:
I'm sure the code is out there, but I put some scheme code together that computes those values from some equations I found.