2009-06-08, Mon

mercurial (hg) equivalent of "svn export"

Having recently switched from subversion (svn) to mercurial (hg) for my source control needs, I needed to find an equivalent to my web development workflow that looks something like this:

      svn export ..\project.export
      rsync ..\project.export ssh://[email protected]

The equivalent of exporting an unversioned copy of your code in mercurial is:

      hg archive ..\project.export

And then you can do whatever you want with it.

Isaac Su

tags: archive export hg mercurial subversion svn

Comment

---

2009-05-21, Thu

Apache page load delay in Windows 7

In a previous WILT, we fixed a page load delay in Apache running on Windows Vista.

I’ve noticed a similar delay happening in Windows 7, though the solution is slightly different. This time round, Microsoft has commented out both IPv4 and IPv6 localhost name resolutions by default in the C:\Windows\system32\drivers\etc\hosts file.

All we need to do is add a line to point localhost to 127.0.0.1.

Open up C:\Windows\system32\drivers\etc\hosts and add this line to the file.
bc. 127.0.0.1 localhost

Now loading the page load on a local Apache running on Windows 7 should be instantaneous rather than having a slight delay.

Isaac Su

tags: apache delay httpd localhost page-load windows-7

Comment

---

2009-05-07, Thu

Reading the Windows minidump file

If you’ve recently experience persistent BSOD on windows vista or windows xp, but don’t have any information except for the useless stop error codes like 0×0000007E, taking a peek into the windows crash dump or minidump file might give you some vital clues as to what’s causing the crash.

  1. Download and install Debugging Tools for Windows (64bit version here)
  2. After installing it, run the application WinDbg.
  3. File -> Open Crash Dump
  4. Look under c:\windows\Minidump and open the most recent .dmp file.
  5. Once it is loaded, something like this should come up:
      Probably caused by : ifsmount.sys ( ifsmount+cbf0 )

Deal with the file, and you’re fixed!

Isaac Su

tags: bsod crash crash-dump drivers minidump vista windows windowsxp

Comment

---

2009-04-22, Wed

Custom softkey shortcuts on Treo 750

I use the SMS function a lot more than I use the E-mail function on my Treo 750 (running Windows Mobile 6.1), so it speeds things up a lot if I’m able to use the left softkey (that defaults to E-mail) to access my Messaging program.

  1. Download Advanced Configuration Tool from TouchXperience.
  2. Grab the Microsoft .NET Compact Framework 3.5 if you haven’t already installed it on your Treo 750.
  3. Install both files.
  4. Open Advanced Config on your Treo 750.
  5. Tap on Menu → More settings → Key mapping

There, you can assign shortcuts to pretty much any the hardware buttons on the Treo 750, including the left softkey.

Isaac Su

tags: advanced-config mobile palm shortcut soft-key softkey tips treo-750 windows-mobile

Comment

---

2009-04-21, Tue

Internet Explorer won't parse AJAX XML responses

A few components in http://stimpack.info/ required asynchronous requests to be sent, and an XML document containing the results to be parsed and display. In this case, I was using the jQuery Javascript framework, and calling the all powerful:

      $.ajax();

While testing the component on different browsers, I noticed that the results would come through fine in Firefox, but it would just blank out in Internet Explorer. Furthermore, a peek at the HTTP requests/responses indicated that server was indeed sending through the XML data, but Internet Explorer just refused to parsed it.

This is what fixed it:

      // At least in PHP
      header('Content-Type: text/xml');

You see, Internet Explorer is very strict about what it would parse as XML, and text/plain or text/html just wasn’t good enough.

As long as the content type turns up as text/xml, it’ll go ahead and do what it’s meant to do.

Isaac Su

tags: ajax http ie internet-explorer jquery php xml

Comment

---

« Older Newer »