Skip to main content

Posts

Create your own custom ROM for any Android device (from XDA)

Don't want to spend time reading? Have a look at the videos here You can find a detailed guide, which keeps on updating in this thread . This guide is for the one who have little experience with Android. Also covers some good advanced topics.

Meld: Comparison Tool

Meld is a visual diff and merge tool targeted at developers. Meld helps you compare files, directories, and version controlled projects. It provides two- and three-way comparison of both files and directories, and has support for many popular version control systems. Meld helps you review code changes and understand patches. It might even help you to figure out what is going on in that merge you keep avoiding. Features Two- and three-way comparison between files and directories Comparisons update as you type Visualisations make it easier to compare your files Actions on diff chunks make for easier merges Supports Git, Bazaar, Mercurial, Subversion, etc. File comparison Edit files in-place, and your comparison updates on-the-fly Perform two- and three-way diffs and merges Easily navigate between differences and conflicts Visualise global and local differences with insertions, changes and conflicts marked Use the built-in regex text filtering to ignore uninter...

OS X 10.8 Mountain Lion bootable USB (without MAC)

Download the raw file from here . How to use: 1 - Copy the .raw file to an USB stick using  SUSE Studio Image Writer . If you have error during copy, eject and re-connect the pen drive. When Windows asks if you want to format it, cancel and run Image Writer again. If the problem persists, disable your anti-virus software, it may be blocking raw write to the drive. Another Image Writer for Windows, if SUSE doesn't work https://launchpad.net/win32-image-writer/+download 2 - Boot the USB drive and install. If you need, type  boot options , for example: -v (verbose boot) [default] -x (safe) -s (single user) GraphicsEnabler=yes (enable graphics card drivers) [default] USBBusFix=yes (fix problems with USB devices) npci=0x2000 (use if boot stops at "PCI configuration begin") cpus=1 If you need, use  TransMac  to remove kexts which are causing problems (System/Library/Extensions) and use the flag -f (ignore caches) at boot, or remove /System/Libra...

Boot Options

The boot: prompt waits for you to type advanced startup options. If you don't type anything, the computer continues starting up normally. It uses the kernel and configuration files on the startup device, which it also uses as the root device. Advanced startup options use the following syntax: [device]<kernel> [arguments] Example arguments include device: rd=<BSD device name>       (e.g. rd=disk0s2) rd=*<IODeviceTree path>    (e.g. rd=*/PCI0@0/CHN0@0/@0:1) kernel: kernel name                (e.g. "mach_kernel" - must be in "/" ) flags: -v (verbose)                -s (single user mode) -x (safe mode)              -f (ignore caches) -F (ignore "Kernel Flags" specified in boot configuration file) ...

Multi-Booting Windows 7, Windows 8, Mac OS X Lion and Ubuntu

Getting Started Things you need: - Lion USB prepared with UniBeast (see tonymacx86.com) - Win7 install media (preferably USB stick with Win7 SP1) - Win8 install media (USB stick) - Ubuntu 12.04LTS (USB stick) (see ubuntu.com) - A blank HDD or SSD ready as install target Section A (plan your partition scheme) When setting up a multi-boot system involving Windows it is important to realize you will need to create what is known as a hybrid MBR/GPT partition scheme.  It is necessary to place all partitions intended to be accessed by Windows such that they are in sync’d MBR table.  This means they should be placed first.  For this guide, I will be setting up the following partitions on a 320GB hard drive: EFI: 200MB, created by Mac OS X Disk Utility when partitioning Win7: ~60GB, NTFS Win8: ~60GB, NTFS Transfer: ~60GB, exFAT (could use FAT32 as well) Lion:~60GB, Mac OS X Extended (journaled) Linux-Swap: 8GB (my computer has 8GB memory) Linux: a bit less than...

JavaScript - Singleton Pattern

The singleton design pattern is probably the simplest and most common pattern in JavaScript. So why should you use the singleton pattern? Encapsulation of members & functions Creates its own Namespace A singleton is a single instance object Encourages code reuse Improves readability because you can logically organise your code The point of a singleton is to only have one instance. A shopping cart is a good example of something that you may want only a single instance of at one time. The simplest form of Singleton is an object literal. This loose form of Singleton cannot be instantiated. All of the members are now accessible through the Singleton variable, accessible through dot notation. var myCart = {     self: this ,     totalCost: 0,     totalQty: 0,     cart: {},     getCart: function (){ },     updateCart: function (){ } }; alert( "Total cost: ...

HTML5 localStorage

Persistent Client-Side Key-Value Pairs The localStorage object has four primary method: localStorage. clear () localStorage. getItem ( key ) localStorage. removeItem ( key ) localStorage. setItem ( key, value ) When dealing with the localStorage object, it is important to remember that, like cookies, you are dealing with string values. Both the key and the value arguments must be strings. And, while the browser might not throw an error if you pass-in non-string values, you'll quickly find that it is simply calling the toString() method implicitly. Run the following sample code and check the console: <html> <head> <script type="text/javascript"> console.log("tim in localStorage —",("tim" in localStorage)); console.log("localStorage.getItem( tim ) —",localStorage.getItem( "tim" )); localStorage.setItem( "tim", "nice" ); localStorage[ "bad" ] = "awesome...