2007 Dec 6, 12:24The spec for FeedSync which allows for synchronizing RSS and Atom files among multiple machines.
sse rss atom feedsync feed specification microsoft 2007 Nov 28, 1:23One of the new Zune features that had me the most excited was the claimed improved Windows Media Center integration which unfortunately turned out to simply mean support for the Win MCE video format
(
with an exception for HD). I wanted to be able to pick shows recorded by my Win MCE and have the Zune automatically sync up the
latest episodes. However, with the improved podcast support in the Zune software one can easily create a ridiculous hack to accomplish this.
The new Zune software has podcast support which does everything I'd want to do with a
Win MCE recorded TV series so the goal is to shoehorn a TV series into a Zune podcast. An overview of the steps: Create an XSLT that converts Win MCE data to a podcast, run the XSLT as a scheduled
task every few hours per TV series, setup a Web server pointed at the resulting podcasts and the Win MCE Recorded TV directory, and subscribe to the resulting podcasts in the Zune software.
- Reading through the Win MCE data stored as an XML file in "C:\ProgramData\Microsoft\eHome\Recording\Recordings.xml" and the spec for podcasts I created an XSLT to convert a series from Win MCE data to a podcast.
- I added a new task to the Scheduled Tasks to run my XSLT using my xsltproc.js script. The task runs a handful of commands that look something like the following:
C:\windows\system32\wscript.exe C:\users\dave\bin\xsltproc.js C:\Users\Dave\Documents\trunk\development\mce-zune\mce-to-podcast.xslt
C:\ProgramData\Microsoft\eHome\Recording\Recordings.xml --param title "The Daily Show With Jon Stewart" --param max 4 --param baseURI "http://groucho/" --param thisRelURI "tds.xml" -o
"D:\recorded tv\tds.xml"
For each TV series I run a command like the above and that outputs a podcast for that series into my "D:\Recorded TV\" directory.
- Zune only allows http URIs for its podcasts so I installed a web server on my Win MCE server. I'm running Vista Ultimate so it was quick and easy for me to install IIS7 but any Web server will do. Then I pointed it at "D:\Recorded TV\".
- Once all the above was done I just subscribed to the resulting podcasts via my Web server and viola! Since I'm forced to use a Web server I can even run the Zune software on a machine other
than my Win MCE server. You can see a screen-shot above of my Zune software showing my Colbert Report podcast.
technical xml mce hack windows media center zune windows xslt podcast 2007 Nov 19, 3:47I really appreciate that
the first gen Zune's get the new Zune's
firmware and software. I like the updated Zune software personally because its faster and simpler, has better podcast support, and the whole social thing has is on their website now. So, I guess
I like the software because it has new features that should have been there in the first place.
The social thing is like a Zune social network. It uses your Xbox Live friends to seed your Zune friends list, lets you do the expected social network stuff, lets you preview songs, and unlike first
gen Zunes which required face to face time with other Zune owners, allows you to send songs to people. It also lets you display your recently played tracks and your favorite tracks, similar to what
Last.FM has, via a
Zune Card. I like the Zune Card from a technical perspective because it
separates
the
Zune Card view, written in flash from the
User Card data which is in XML. I hope
they intend to keep the XML available via this UserCard Service because I think there's potential to easily do cool things.
microsoft technical music zune social 2007 Nov 16, 12:2424 parody: 24 set in 1994. Thankfully, specific knowledge of 24 is not a prerequisite to enjoying this video.
humor video via:ericlaw 2007 Oct 22, 4:47I purchased the
Orange Box off of Steam a bit ago and like
others before me who have
discussed elsewhere, I already owned two of the five games that come from the Orange Box. However, the combined price of
HL2E2 and Portal, the two games I actually wanted was supposedly equivalent to the price of the Orange Box bundle. Incidentally, if anyone would like HL2 or HL2E1 I can
gift them to you.
HL2E2 was excellent of course but the big surprise for me was Portal. (Mild spoilers follow) It has a sort of zen simplicity: there are a few simple game-play mechanics, a handful of textures and
objects, and a deceptively simple story all used well and tied together to produce an entertaining and polished game. It seems a bit short but its probably better to end with the gamer demanding
more. The humor and the sort of
play within a play aspect of the game is what really sold me though. It has the funniest
ending theme I've heard (also
blogged by the creator). The voices of the automated turrets are so adorable I would feel compelled to hug them if they weren't
always trying to kill me. Additionally the
weighted companion cube seems like an experiment in understanding gamers'
attachment to NPCs. In this case the NPC is a box and yet I still felt awful incinerating it. The whole time I was vaguely reminded of
Solitary the reality show
that sticks contestants alone in small rooms forcing them to endure various tests all the while being watched by a humorous computer with a female voice. Someone should sue...
RPS has articles on Portal including
a Portal review, a page
suggesting Portal is a tale of
lesbianism, and
others.
hl2e2 game hl2 solitary valve portal nontechnical 2007 Oct 14, 3:12I've updated my homepage by moving stuff about me onto a separate
About page. Creating the About page was the perfect opportunity
to get
FoaF, a machine readable way of describing yourself and your friends, off my to do list. I have a
base FoaF file to which I add friends, projects, and accounts
from delicious
using an XSLT. This produces the
FoaF XML resource on which I use another
XSLT to convert into HTML and produce the About page.
I should also mention a few FoaF pages I found useful in doing this:
-
FOAF Vocabulary Specification - The standard on which I based my XSLT to add in info from delicious.
-
FoaF Explorer - Turns any RDF XML FOAF resource into a webpage with links to the other people, projects, etc mentioned in the FOAF file.
-
FoaF-a-Matic - I used this to produce my base FoaF file.
-
RDF Validator - This is the closest thing I could find for validation. It does RDF in general but unfortunately not FoaF specifically. I found two
links to sites that are down or dead that claimed to do what I actually wanted.
technical xml foaf personal xslt xsl homepage 2007 Oct 12, 10:04FTA: 'From just released Microsoft security bulletin: "..formerly known as Wang Image Viewer, handles specifically crafted images files.."'. Specially crafted eh?
humor article michael-kaplan blog wang msrc microsoft security 2007 Oct 12, 4:08As noted in the
XSL Transformations spec you can create the identity transform using the xsl:copy element. With the MSXML implementation of xsl:copy
the example the spec gives produces slightly ugly elements. For instance given it produces . In order to ensure empty elements turn out pretty I've modified the example as follows:
This got me thinking about inverting XSLTs. Clearly in general an XSLT isn't invertible since an XSLT can completely ignore the input XML and produce something else entirely but then the above is an
example of an XSLT that is invertible. So there is a subset of XSLTs that are invertible, how might you produce the inverse of an XSLT, and would this ever be useful?
xml msxml inverse xlst xsl 2007 Oct 9, 4:41Notes on using XSLT on FOAF XML files. Apparently its not super simple due to the various equivalent ways of representing the same RDF in XML.
xml foaf xslt xsl reference rdf semanticweb 2007 Oct 3, 10:21Tim Berners-Lee writes about principles for new technology in the context of the evolution of HTML and the development of namespaces and XML.
architecture article tim-berners-lee w3c internet history evolution html namespace xml web mmm multimedia-mesh humor test-of-independent-invention 2007 Sep 27, 2:17Starting on a new simple project I wanted to get the history of my Delicious links. Delicious has an export tool available via the settings section so I thought I'd try that. However, the links
aren't exported in XML not even in XHTML but rather in HTML. Shocking. An example:
"Don't Tase Me, Bro!" (UF Student Tasered Remix)
Remix of the 'Don't tase me, bro!' guy getting tasered.
At this point I'm already not going to use this file because its in HTML but I'm even more disgusted by those date time values.
Raymond Chen of the Old New Thing posted about recognizing timestamps and timestamp sentinel values. From the first blog post and with the use of a calculator for base conversion one can tell that
those are UNIX style timestamps counting the number of seconds since 1970.
It reminds me of my hatred for the MIME date time format I developed working on my webpage's server side parsing of atom and RSS. Atom is
of course my favorite as Atom uses the Internet date time format described in the following documents. Here's an example of one
2007-09-27T020:50:00.000-08:00
On the other hand the evil and villainous RSS uses the MIME date time format now described in the more
recent IETF MIME standard. Here's an example Thu, 27 Sep 2007 20:50:00 -0800
The Internet date time format has the advantage of being so easy to sort. An alphabetic sort with normal C-style collation rules of strings containing Internet date times will also sort them
chronologically. This is not the case for the MIME date time due to the preceding day of the week and the spelled out month name. This also means that when producing these you have to figure out
the day of the week and when parsing them you have to match month names rather than just parsing out numbers. Anyway now days if I see mention of a date time in a new proposed standard or spec I be
sure to point out the numerous advantages of the Internet date time format.
date xml html feed time technical date-time code atom rss 2007 Sep 11, 1:46The XML spec. Info on setting the default namespace including how to remove a default namespace once its been set.
specification reference w3c xml namespace 2007 Aug 9, 5:41To satisfy my hands which have already learned to type *nix commands I like to install
Win32 versions of common GNU utilities. Unfortunately, the
which
command is a rather literal port and requires you to enter the entire name of the command for which you're looking. That is '
which which
' won't find itself but
'
which which.exe
' will. This makes this almost useless for me so I thought to write my own as a batch file. I had learned about a few goodies available in cmd.exe that I thought would
make this an easy task. It turned out to be more difficult than I thought.
for /F "usebackq tokens=*" %%a in ( `"echo %PATH:;=& echo %"` ) do (
for /F "usebackq tokens=*" %%b in ( `"echo %PATHEXT:;=& echo %"` ) do (
if exist "%%a"\%1%%b (
for %%c in ( "%%a"\%1%%b ) do (
echo %%~fc
)
)
)
)
The environment variables
PATH
and
PATHEXT
hold the list of paths to search through to find commands, and the extensions of files that should be run as
commands respectively. The '
for /F "usebackq tokens=*" %%a in (...) do (...)
' runs the '
do
' portion with
%%a
sequentially taking on the value of every line in
the '
in
' portion. That's nice, but
PATH
and
PATHEXT
don't have their elements on different lines and I don't know of a way to escape a newline character to
appear in a batch file. In order to get the
PATH
and
PATHEXT
's elements onto different lines I used the
%ENV:a=b%
syntax which replaces occurrences of a with b
in the value of ENV. I replaced the '
;
' delimiter with the text '
& echo
' which means
%PATHEXT:;=& echo%
evaluates to something like "
echo
.COM& echo .EXE& echo .BAT& ...
". I have to put the whole expression in double quotes in order to escape the '&' for appearing in the batch file. The
usebackq
and
the backwards quotes means that the backquoted string should be replaced with the output of the execution of its content. So in that fashion I'm able to get each element of the env. variable onto new
lines. The rest is pretty straight forward.
Also, it supports wildcards:
C:\Users\davris>which.cmd *hi*
C:\Windows\System32\GRAPHICS.COM
C:\Windows\System32\SearchIndexer.exe
D:\bin\which.exe
D:\bin\which.cmd
which cmd technical batch for 2007 Aug 3, 3:11The JavaScript language. The whole thing.
javascript reference language specification 2007 Jul 25, 7:15Documentation on the URI format that maps.live.com uses. Makes it easy to dynamically construct a URI that maps a specific location.
map live windows microsoft uri url help howto 2007 Jul 14, 12:15How hackers bugged the largest Greek cell provider and listened to government and military officials.
article ieee cellphone phone conspiracy hack hackers politics privacy security 2007 Jul 13, 8:30I bought an external backup drive a few weekends ago. I've previously setup a
Subversion repository so I decided to move everything into the repository and
then back it up. So in went the contents of all of my %USERPROFILE% and ~ directories with a bit of sorting and pruning. Not too much though given its much easier to dump in everything and search for
what I want then to take the time to examine and grade each file. What follows are the notes I took while setting this up. It takes me a bit of time to look up the help on each command so I figure
I'll write it all down here for the benefit of myself and potentially others...
Setting Up the Backup Drive For Linux
I first changed the filesystem on the drive to ext3. I plugged it into my USB2.0 port and ran fdisk:
sudo fdisk /dev/sda
Useful commands I used to do this follow mostly in order:
-
m
-
help
-
p
-
print current partitions
-
d
-
delete current partition
-
n
-
create new partition (I used the defaults)
-
w
-
write changes and exit
Then I formatted for ext3.
sudo mkfs.ext3 /dev/sda1
I made it easy to mount:
sudo vim /etc/fstab
# added line to end:
/dev/sda1 /media/backup ext3 rw,user,noauto 0 0
I setup the directory structure on the disk
mount /media/backup
sudo mkdir /media/backup/users
sudo mkdir /media/backup/users/dave
sudo chown dave:dave /media/backup/users/dave
After all that its easy to make a copy of the Subversion repository:
mount /media/backup
cp -Rv /home/dave/svn /media/backup/users/dave/
umount /media/backup
Next on the agenda is to add a cron job to do this regularly.
Subversion Command Reference
On a machine that has local access to the Subversion repository you can check out a specific subdirectory as follows using the file scheme:
svn co file:///home/dave/svn/trunk/web/dave%40deletethis.net/public_html
Note also that although one of my directories is named 'dave@deletethis.net' Subversion requires the '@' to be percent-encoded.
Other useful subversion commands:
-
svn help
-
help
-
svn list file:///home/dave/svn/
-
list all files in root dir of svn depot
-
svn list -R file:///home/dave/svn/
-
list all files in svn depot
-
svn list -R file:///home/dave/svn/ | grep \/$
-
list all directories
-
svn status
-
List status of all files in the working copy directory as in - modified, not in repository, etc
-
svn update
-
Brings the working copy up to date wrt the repository
-
svn commit
-
Commit changes from the working copy to the repository
-
svn add / move / delete
-
Perform the specified action -- occurs immediately
Setting up Windows Client for Auto Auth into SVN
When using an SVN client on Windows via svn+ssh its useful to have the Windows automatically generate connections to the SVN server. I use
putty on my Windows machines so I read the directions on
using public keys with putty.
putty.exe dave@deletethis.net
cd .ssh
vim authorized_keys # leave the putty window open for now
puttygen.exe
Click the 'generate' button
Move the mouse around until finished
Copy text in 'Public key for pasting into OpenSSH authorized_keys file:' to putty window & save & close putty window
Enter Key passphrase & Comment in puttygen
Save the private key somewhere private
pageant.exe
'Add Key' the private key just saved.
Checking out using Tortoise SVN
On one of my Windows machines I've already installed Tortoise SVN. Checking out from my SVN repository was really easy. I just right clicked in Explorer in a directory and selected "SVN Checkout...".
Then in the following dialog I entered the svn URI:
svn+ssh://dave@deletethis.net/home/dave/svn/trunk/web/dave%40deletethis.net/public_html/
Note again that the '@' that is part of the directory name is percent-encoded as '%40' while the '@' in the userinfo is not.
Windows Command Line Check Out
On my media center I didn't want to install Tortoise SVN so rather I used the
command line tool. I setup pageant like before the only
difficulty was getting the SVN command line tool to use putty. With the default configuration you can use the SVN_SSH environment variable to point at a compliant SSH command line tool. The trick is
that its interpreted as a backslash escaped string. So I set mine thusly:
set SVN_SSH=C:\\users\\dave\\bin\\putty\\plink.exe
The escaping solved the vague error I received about not being able to create the tunnel.
backup technical personal windows svn linux subversion 2007 Jul 11, 10:36How to encode URIs that contain international characters as specified by the HTML spec.
html uri encoding iri unicode utf8