1.  

    Android market download/install app error -101

    Today I ran into this error while trying to install a new app on my Galaxy Nexus running ICS 4.02.

    [App name] could not be downloaded. error (-101)

    It appears this will happen from time to time and phone model, brand, or version of android doesn’t seem to matter.

    There are several key factors which all seem to affect how the Market app functions.

    Google Talk must be signed into an active account. Google’s trouble shooting page: https://support.google.com/androidmarket/bin/answer.py?hl=en&answer=1067233

    Also, the “Download Manager” app seems to handle the download portion of installing an app from the market.

    So here are the steps I took to fix my market issue.

    • Clear the cache and app data of the apps: Market, Download Manager, Talk
    • Try installing an app
    • If you are still getting the same error, open Talk and make sure you’re signed in
    • If it’s still broken, sign out of Talk, clear the app cache and data for Talk, and try again.

    You may need to try any number of combinations above, while throwing in a reboot now and then for good measure.

    If the market says “Can’t connect [retry]”, click Menu, then go to Accounts, and add a another google account. This will trigger the market app to ask you to agree to the terms an conditions. Make sure you don’t sync you phone to this new account or it may import a bunch of data you don’t want/need. You should now be able to connect to the market and can remove the new account by going into Settings -> Accounts & Sync, select the account, then press menu -> remove account.

    I hope this helps!

    Edit 1/13/12:

    The market issue has returned. After much trial and error, I have narrowed it down to the issue of Google/Market thinking you haven’t accepted the Market’s Terms and Conditions. If for some reason, your google account no longer reflects that you have accepted these terms, then the Market app will refuse to connect. The trick is to force the Market app to ask you to accept the Terms and Conditions again.

    I can’t tell you exactly what I did to resolve this issue the second time, but it was a series of clearing caches and restoring my user apps from backups made with Titanium Backup which finally did the trick this time.

    I hope this issue gets resolved, it’s a real pain in the ass.

  2.  

    generate ssh key for a user in linux

    ssh-keygen -t rsa -C “frank@stallone.com”

  3.  

    List files ignored by .gitignore

    git ls-files -i -o --exclude-standard

  4.  

    Some useful git commands

    Remove files from the git repository, while untouch the files locally.

    git rm —cached

    Completely reset/revert your repository to a certain commit point. Replace HEAD with the first few letters of the desired commit hash 7e46dc.

    git reset —hard HEAD

  5.  

    Adding custom template hints in Drupal 6

    http://pastebin.com/G5ZdDExm

  6.  

    Setting Debian sever timezone

    dpkg-reconfigure tzdata

  7.  

    Remapping your caps lock to search google on your Mac (OS X)

    I wasn’t satisfied with Lifehacker’s solution since it doesn’t allow you to re-map the caps lock key without having to us a modifier like shift or control.

    I wanted to emulate the CR-48’s search key so after a few quick searches I’ve come up with the following solution:

    1. Use Key Codes to reveal the key code of the button on your keyboard you’d like your caps lock key to use instead of the default code of 57.
    2. Download and install PCKeyboard Hack. Remap your caps lock key to use the key code of the button you picked from step 1. I’m using F19 which has a code of 80.

    3. Copy and paste the script below (bottom of page) into Applescript Editor. Optionally you can test it’s functionality, then save it as a script in your Documents folder. (or anywhere else safe from accidental deletion)
    4. Create a custom trigger in Quicksilver using your newly re-mapped caps lock key and have it run the new script you just created and you’re done!

    Applescript code:

     tell application "System Events"
            tell application "Google Chrome" to activate
            keystroke "t" using command down
            keystroke "l" using command down
    end tell

    This code will open Chrome (replace “Google Chrome” with the browser of your choice) if it’s not already open, create a new tab, then set focus to the address bar.