Archive for the ‘coolstuff’ tag
How about this for prescient tin foil hat geekery…
While reading the Emacs Elisp source for version 24.3, I stumbled upon a little
gem located at
This file has a created date of May, 1987. Emacs has included this program for many years. Its purpose is to add a series of keywords to email just before sending it. On the theory that the NSA monitors people’s email, the keywords would be picked up by NSA’s snoop computers, causing them to waste time reading your meeting schedule notices or other email boring to everyone but you and the recipient.
You should try it: open Emacs and type
M-x spook to see what happens.
From the commentary on the file itself:
Just before sending mail, do M-x spook. A number of phrases will be inserted into your buffer, to help give your message that extra bit of attractiveness for automated keyword scanners. Help defeat the NSA trunk trawler!
Read this on my Twitter stream:
Wealth is our organised capability to cope effectively with the environment to sustain our healthy regeneration and decreasing both the physical and metaphysical restrictions of the forward days of our lives.
from Operating Manual for Spaceship Earth
Today I ran across a thought provoking article on Dr. Dobb’s. The thesis is that there is a perception that Open Source projects copies what already exists and it’s in Closed Source where the real innovation occurs. This perception exists in part because how geeks choose what to work on.
There is most definitely evidence to the contrary and also to support that perception, but the main point of the article is that there is a fundamental problem in Open Source which manifests itself as this perception. The problem is with project selection.
Now, Dijkstra wrote a memo in 1982 that describes 3 steps to use when selecting a topic for your research. These rules translate really well to hacking and all geeks should consider them when selecting an Open Source project to work on. The rules are:
- Raise your quality standards as high as you can live with, avoid wasting your time on routine problems, and always try to work as closely as possible at the boundary of your abilities. Do this, because it is the only way of discovering how that boundary should be moved forward.
- We all like our work to be socially relevant and scientifically sound. If we can find a topic satisfying both desires, we are lucky; if the two targets are in conflict with each other, let the requirement of scientific soundness prevail.
- Never tackle a problem of which you can be pretty sure that (now or in the near future) it will be tackled by others who are, in relation to that problem, at least as competent and well-equipped as you.
Let’s break this down a little so it can be easily digested.
Rule 1 is an internal one and it tells us that the obviously possible should be shunned as well as the obviously impossible: the first would not be instructive, the second would be hopeless, and both in their own way are barren.
Next, Dijkstra was referring to scientific projects, but Rule 2 can be easily mapped to software projects also.
Rule 3 is the most important from an Open Source perspective. It ensures that your contributions are unique and move the-state-of-the-art forward. As Dijkstra so eloquently puts “If others will come up with as good a solution as you could obtain, the world doesn’t loose a thing if you leave the problem alone. A corollary of the third rule is that one should never compete with one’s colleagues. If you are pretty sure that in a certain area you will do a better job than anyone else, please do it in complete devotion, but when in doubt, abstain.”
I will be applying this rules to my future project selection. I hope you do too.
This is totally off-topic for this site but I really had to take not of this really interesting question that I saw asked on Quora:
This is something which has happened so many times with me now. Have you had similar incidence? What was your reply when your boss asked that question? Or what would you reply if in future you face such a question?
The following answer provided could not be more eloquent:
Take advantage of the opportunity to get valuable face time with your boss. I’d recommend something like:
“I was under a lot of pressure, but things seem to be flowing well now. I’ve got a firm grip on the situation and am seeing some good output. It may take awhile before I achieve completion, but it’s important to take one’s time in order to stay on target. I expect to wash my hands of the whole thing in the next several minutes.”
For many years I have been an ADSL subscriber receiving 3 Mbps service from AT&T. The line came into the house and into a simple ADSL modem that connected to a Linksys WRT54GL running DD-WRT firmware, which was setup to serve as the Internet gateway for all computers in the house. I won’t go into the virtues of this particular model of Linksys router running this particular firmware, but suffice it to say that those who know what I’m talking about will need no further explanation.
Recently, we moved to a new house and AT&T would not let me transfer the ADSL line to the new address, but they said they would be happy to set me up with this shinny new digital service they call UVerse. After doing some checking, I noticed that the reviews from customers were mixed, but that the speeds provided were pretty decent. I was leaning towards cable service, but the wife likes AT&T, so we signed up for the 12 Mbps UVerse Internet plan.
The AT&T technician came to the house and set it all up in the phone box outside — inside the house he hooked the line up to a 2Wire 3600HGV device. When he saw my Linksys router laying nearby, he said “With this beauty right here…” and he showed me the 2Wire device, “… you won’t need that Linksys router of yours.” That should have been my fist sign that something was amiss.
The one redeeming quality of the 2Wire device is that it does have a really strong radio signal, but other than that the firmware running on it is really crippled and perhaps can do a little more than 10% of what the DD-WRT firmware is capable of. The conspiracy theorist in me says that the 2Wire hardware and software are probably more capable than AT&T is willing to document and let the users have access to,
Anyway, the ideal situation for me was to turn the 2Wire into a dumb modem and use my Linksys as the gateway, just like the old ADSL days… but that was easier in concept than in practice. There are all kinds of gotchas and tricks to get it setup, like the Router Behind Router detection. After much trial and error, I persevered, and below is the result of my research into how to get this setup to work.
At this point I recommend that you make a backup of your current DD-WRT setup by
Administration and then the
Backup menu and then clicking the
The first step is to get the Linksys router ready for the setup. Make sure you
can reach it and connect to it with a browser by going to
http://192.168.1.1/. I used an Ethernet cable directly from my laptop and into
one of the 4 LAN ports on the Linksys. Once you logged in to the Linksys, go to
Setup and then
Basic Setup. Under
WAN Setup, make sure that the
Connection Type is DHCP and give the device a unique
name. Under the
Network Setup area, change the
Local IP Address to something
10.0.0.1 — just make sure that the IP you choose is in a different
192.168.1.X. With this setup we are trying to avoid conflicts
between the Linksys DHCP and the 2Wire DHCP servers and in general we want the 2
devices in separate networks anyway.
The next step is to connect to the 2Wire device. I unplugged the Ethernet cable
from the Linksys and connected it to one of the LAN ports on the 2Wire. Now you
should be able to reach the 2Wire setup interface by pointing your browser to
http://192.168.1.254/. If at first you are unable to connect, then check your
current IP address. Since the Linksys was changed to a different network, you
may have gotten an IP in the range
10.0.0.X. You can fix this by releasing and
renewing your IP lease. Also, in order to apply any changes to the 2Wire device
you will need to know the System Password which should printed on a label on
Before moving on, I want you to consider the above image for a moment. Here’s what’s going on:
- The blue ethernet cable connects the the 2Wire device to the WAN Port on the Linksys.
- The yellow ethernet cable was used to connect the laptop directly to the 2Wire device and also to the Linksys previously.
- The green RJ11 cable is the digital data cable connecting to the Internet at large.
- The white RJ11 cable is for the phone/voice service and goes into the telephone set.
As you can see in the above image, the blue cable connected to the 2Wire device terminates into the WAN port of the Linksys device.
Now, back from this little tangent, I was about to connect to the 2Wire device
with the browser. Once connected, go to
Settings and the
LAN tab and click
Wireless link and ensure that the value under
Wireless Interface is
set to Disabled. I want the Linksys in charge of providing Wireless and DHCP
services. Once that’s done, click the
Save button at the bottom of the page.
Next I need some way for the Linksys to receive all inbound Internet traffic
into the house. This can be done by putting the Linksys in DMZPlus mode in the
Firewall setting of the 2Wire device. Go to the
Settings tab in the 2Wire
setup interface and then click on the
Firewall tab and click on the
Applications, Pinholes and DMZ. Choose the DD-WRT (or whatever name you gave
your device) from the list under
Select a computer. Then further down on that
same settings page under
Edit firewall settings for this computer select the
Allow all applications (DMZplus mode). Make sure to click the
button at the bottom of this page when all done.
You can verify that the 2Wire setup is correct by going to the
Firewall sections and seeing that the DD-WRT device
is listed under the
Current Applications, Pinholes and DMZ Settings: Custom
and that it was assigned a public Internet IP.
One more side bar is called for at this point in the setup process. If at any
point in time during the setup you are faced with a warning from the 2Wire
device that it has detected a Router-Behind-Router setup, please just ignore
it as the final outcome of the setup I am doing will render that type of
detection irrelevant. As a matter of fact, while on the 2Wire setup interface,
just go to the
Settings tab and then the
System Info tab and the
Notifications link and make sure that the option
Enable detection of
router-behind-router conditions is not checked. Save your change before moving
Let’s do a quick recap: We first put the Linksys device in DHCP mode at the WAN level and gave it a recognizable name, then we gave it a different subnet IP than the default 2Wire IP. Next we disable the Wireless service on the 2Wire device and then we put the Linksys device in DMZPlus mode in the 2Wire configuration screens. We also verified that the Linksys is getting a public IP from the 2Wire perspective.
Next we need to ensure that the Linksys is getting the public IP address from
it’s own perspective (see above image). Go to the
Status tab and then the
WAN tab on the DD-WRT setup interface. Under the
WAN section on that page
ensure that the
IP Address value is the same as the one assigned to the DD-WRT
in the 2Wire interface. I obfuscated the public values here for obvious reasons.
This is where I was a little stumped when I went through these steps for the
first time. If at first your Linksys/DD-WRT doesn’t recognize the public IP, try
DHCP Release button or rebooting the Linksys. I had to reboot the
Linksys twice initially, but it has been working for me without any issues for a
I hope this write up is useful to you…
If you have ever played around with the Debian distribution proper, you will quickly notice that Firefox is not available as a browser and in its place is something called IceWeasel. Here I will show you how to install the real Firefox browser on Debian 7.
The first step is to remove the IceWeasel package if it’s installed:
$ sudo apt-get remove iceweasel
Next, we will make use of a Linux Mint package repository that targets Debian
proper. To do this add the following line to you
deb http://packages.linuxmint.com debian import
Now when you update your package list you will see an error like so:
$ sudo apt-get update ... a ton of output ... W: GPG error: http://packages.linuxmint.com debian Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 3EE67F3D0FF405B2
This happens because you don’t have the proper key for the Linux Mint repository. To get a valid PGP key do the following:
$ sudo gpg --keyserver pgp.mit.edu --recv-keys 3EE67F3D0FF405B2 $ sudo gpg --export 3EE67F3D0FF405B2 > 3EE67F3D0FF405B2.gpg $ sudo apt-key add ./3EE67F3D0FF405B2.gpg $ sudo rm ./3EE67F3D0FF405B2.gpg
Now you should be able to update the package list successfully. Then what’s left to do is to install firefox and you can do that like so:
$ sudo apt-get install firefox firefox-l10n-en-us
This is off-topic for this venue and the fact that I decided to include it says a lot about how strongly I feel: I just watched the trailer for the upcoming movie Hyde Park on Hudson, starring Bill Murray as F.D.R., and based on that alone, I am hereby predicting that Mr. Murray will win an Academy Award for the performance.
If you aren’t willing to learn,
No one can help you.
If you are determined to learn,
No one can stop you.
Ted Neward (@tedneward), [+] Wed 22 Aug 2012 14:52
Visual Studio 2008 used to have a Emacs key mapping scheme that you could pick from the Options dialog under the Keyboard options. Visual Studio 2010 did away with that key mapping scheme.
But those emacs enthusiasts among us who use Visual Studio should not fear… There is now an Emacs Emulation extension available for VS2010 that you can install via the Extensions Manager under the Tools menu.
To install the Emacs Emulation extension, follow these steps:
- Open Visual Studio 2010
- Go to the Tools menu
- Select the Extension Manager
- On the Extension Manager dialog, select Online Gallery
- Search the Online Gallery for Emacs (top right)
- Select and install the Emacs Emulation package
- Restart Visual Studio 2010
- From the Options dialog, the Emacs key mapping scheme is now available
Beyond the default Emacs key bindings, the ones that I find most useful are the following:
|Edit.EmacsExtendedCommand||ALT + X||Places the cursor in the Find/Command box on the Standard toolbar.|
|Edit.EmacsFindReplace||SHIFT + ALT + 5||Displays the replace options in the Quick tab of the Find and Replace dialog box.|
|Edit.EmacsSwapPointAndMark||CTRL + X, CTRL + X||Moves the cursor to the current mark in the location stack and moves the current mark to the location where the cursor mark was when the command was invoked.|
|Edit.EmacsCloseOtherWindow||CTRL + X, 1||When a window is split, this shortcut closes the pane that does not have focus.|
|Edit.EmacsSplitVertical||CTRL + X, 2||Splits the current document in half vertically. The current line of code is centered in each window.|
… and that’s all, folks!
There is a little known amusement in Emacs that you can use on your loved ones:
- For maximum effect, ensure the loved one is looking over your shoulder.
- Open emacs
- Enter the command:
- Provide your loved one’s name and …
- Voila! Watch the magic happen…
To find out more about it, describe the function (
C-h v animate-birthday-present) or look in
animate.el. Have lots of fun…