Peter Naur's classic 1985 essay "Programming as Theory Building" argues that a program is not its source code. A program is a shared mental construct (he uses the word theory) that lives in the minds of the people who work on it. If you lose the people, you lose the program. The code is merely a written representation of the program, and it's lossy, so you can't reconstruct
# Put this function to your .bashrc file. | |
# Usage: mv oldfilename | |
# If you call mv without the second parameter it will prompt you to edit the filename on command line. | |
# Original mv is called when it's called with more than one argument. | |
# It's useful when you want to change just a few letters in a long name. | |
# | |
# Also see: | |
# - imv from renameutils | |
# - Ctrl-W Ctrl-Y Ctrl-Y (cut last word, paste, paste) |
This is an example usage of registering an update_hook
to a SQLite connection. The motivation for exploring this feature is to test out various implementations of data monitoring interfaces.
A few notable properties of the implementation:
- The hook must be registered on the connection being used which requires clients to manually integrate this code.
- Each
INSERT
andUPDATE
operation requires a subsequentSELECT
to get the row data. - When registering the hook, increasing the
bufsize
under heavy workloads will improve throughput, but the SQLite library is single-threaded by design.
rsync (Everyone seems to like -z, but it is much slower for me)
- a: archive mode - rescursive, preserves owner, preserves permissions, preserves modification times, preserves group, copies symlinks as symlinks, preserves device files.
- H: preserves hard-links
- A: preserves ACLs
I couldn't find any relevant information for getting this to work on ubuntu precise, so I'm writing my founds here.
It's actually pretty simple, this approach doesn't involve PAM but just NSS. The implications are clearly explained in the FAQ of the nss-mysql module:
NSS stands for NameService Switch. NSS allows you to implement access to various data using any number of modules. This means that when the operating system wants to look up the user "cinergi", it doesn't have to know how - it calls upon the NSS system to perform the task. In turn, we can now configure NSS to look for users in traditional places like /etc/passwd, NIS, LDAP, and now (using this module), MySQL. The NSS
# the admin password for all of the IE VMs is “Password1″ without the quotes, it's also used for the password hints | |
1) Install VirtuaBox on your mac | |
http://download.virtualbox.org/virtualbox/4.1.10/VirtualBox-4.1.10-76795-OSX.dmg | |
2) Decide which versions of Internet Explorer you want to download and install – each version of Internet Explorer is contained within a separate virtual machine that runs within VirtualBox. In other words, if you want to run Internet Explorer 7, 8, and 9, you will need to download three separate VM’s, which may take a while so keep that in mind. Select the text below and copy it: | |
# Install ALL versions of Internet Explorer: IE 7, IE 8, and IE 9 (for now this script will also pull down a IE 6 vm with windows xp) |
#!/usr/bin/env ruby | |
=begin | |
Created by keyvan | |
#newznab on irc.synirc.net | |
This script is for importing a giant dump of NZB files into newznab. Be warned, it's HACKY! | |
1) I expect you have downloaded a big archive full of nzbs and have extracted it. | |
The directory structure should be like this: | |
dump/ | |
MoviesHD/ |
/* | |
* anchor-include pattern for already-functional links that work as a client-side include | |
* Copyright 2011, Scott Jehl, scottjehl.com | |
* Dual licensed under the MIT | |
* Idea from Scott Gonzalez | |
* to use, place attributes on an already-functional anchor pointing to content | |
* that should either replace, or insert before or after that anchor | |
* after the page has loaded | |
* Replace: <a href="..." data-replace="articles/latest/fragment">Latest Articles</a> | |
* Before: <a href="..." data-before="articles/latest/fragment">Latest Articles</a> |