Sunday, December 20, 2020

How to uninstall an app that doesn't show up in Application folder but exists in Launchpad

 Hi Ya!!


Today I encountered a minor technical challenge where there was an app called "GoToMeeting v10.14.0".

I removed it in the Application folder, but somehow it still showed up in my Launchpad.

It is weird, and it turns out in this case, we need to update an Sqlite3 db in our system!!

Steps:

  1. We need to find where our launchpad database is:

    ❯ find /private/var/folders -name com.apple.dock.launchpad -a -user $USER  2>/dev/null

    /private/var/folders/pq/dhk1_sjn5pdf3q2zr7l0vwy80000gn/0/com.apple.dock.launchpad
    ❯ sqlite3 /private/var/folders/pq/dhk1_sjn5pdf3q2zr7l0vwy80000gn/0/com.apple.dock.launchpad/db/db
  2. Once we have the path (note the 'dhk1_sjn5pdf3q2zr7l0vwy80000gn' is random, yours could be different). Let's call '/private/var/folders/pq/dhk1_sjn5pdf3q2zr7l0vwy80000gn/0/com.apple.dock.launchpad/db/db' as $LAUNCHPAD_DB
  3. Run `sqlite3 $LAUNCHPAD_DB/db/db`
  4. You need to have the complete name of your app, if you don't, try the following command
    sqlite> select * from apps;
  5. For my case, the complete name of the app is 'GoToMeeting v10.14.0'
  6. Here are the key steps!!
    sqlite> delete from apps where title='GoToMeeting v10.14.0';
    sqlite> .exit
    killall Dock
  7. Here you go, the app is gone!

Tuesday, December 31, 2019

zsh showing weird ? characters after upgrade on Mac Catalina

Hi ya folks!! It has been a while since I updated my blog (4 years!!)

The issue on hand is after I upgraded my bash to zsh (as recommended by Apple), the terminal is a bit messed up.

After a couple of hours of messing around on Google, here are the steps:

1. Install powerline fonts (https://stackoverflow.com/questions/42271657/oh-my-zsh-showing-weird-character-on-terminal)

2. Reconfigure iTerm2 to use the Powerline fonts for non-ASCII fonts (https://github.com/powerline/fonts/issues/44)

Please do refer to the above links for further information. Tata

Sunday, July 05, 2015

Another Tern Frame Failure (Shearing into half)

Update June 21, 2016: The initial incident report is here

Andrew from London shared with me an accident that happened to him in June 2015.

The bicycle involved was a Tern Verge S11i which was not part of the recall. It just sheared into half while he was approaching a traffic light. Luckily he was slowing down and that section of road was not too busy, or he would suffer more serious injuries.

Here are a few of my thoughts:
  • Most of the incidents failed at the front weld of the folding joint
  • Tern Verge bikes are sold as high-end bikes, this type of catastrophic failure is shocking. It can easily get people severely injured or even killed
Here are some of the pictures Andrew sent me. The complete set of pictures is available here.






 Here is the email sent by Andrew:

Hi Cuppa,

Thanks for the reply, sorry it's taken so long to get back to you. 

I do want people to know about this problem. Had I known before purchase I wouldn't have bought one, especially as frames are failing outside of the recalled batches. 

So...

My Tern Verge S11i failed while approaching a red light in central London at around 8:30am on a Thursday morning. Luck would have it that I was already slowing for the lights and was in a gap between traffic. 500m later and I would have been passing Kings Cross and the situation would have been significantly more dangerous.

As with previous recalls, the failure happened to the front weld of the OCL hinge joint, snapping the frame in two. I hit the ground and was knocked unconscious for half a minute until I was assisted by passers by and helped out of the road. 

Images in my frame and fortunately light injuries, along with Tern's website reporting that my frame was not one affected by the recall can be found on my Flickr album below.  


I want to get the message out, because I don't want anyone else to be put at risk. I am a cyclist, work for a cycle clothing company and everyone has the right to know that the gear they are riding is fit for purpose. 

Tern have yet to approve any of my posts on their forum about this failure. I understand but don't condone their desire to keep these failures under wraps. This has to stop.

Friday, June 19, 2015

[Archive] Tern Verge X20 Frame Failure (Shearing into Two)



Update: There is another post on Tern failure here

The goal of this is to archive this incident as reported by Peter Thomas in the Tern forum. It seems Tern has silently deleted this post. Thumbs down to it.

Original link location: http://www.ternbicycles.com/forum/tern-verge-x20-frame-shearing-two

Cached location:
http://webcache.googleusercontent.com/search?q=cache:wcnDQ77LL10J:www.ternbicycles.com/forum/tern-verge-x20-frame-shearing-two+&cd=1&hl=en&ct=clnk&gl=sg

Captured screen of the description by Peter


The pictures as posted by Peter (from Google cache)

Picture showing Tern Verge X20 with failed frame

Picture of Peter after medical attention


Sunday, May 24, 2015

On C Programming: Some Pitfalls

I have programmed in C for almost 20 years, and over the years, I have my fair share of lessons learned. Here are some of the pitfalls that are very common. Learn these and you don't have to spend hours or even days to debug

  • = and == confusions
 The '=' operator is for assignment, while '==' is for comparison. Mix these up and you will have a major headache as the variable has been changed (or not)
  •  The 'if' block
Consider the following, assume x, y, and z are defined somewhere else:
if (x == 3)
  y = 43;
  z = 0;

{do something more}

Guess what? if x is equal to 3, only the statement 'y = 43;' will be executed, while 'z = 0' will be executed no matter what, which isn't the initial intention.

There are a list of programming pitfalls here

Studying Notes on Elixir

Elixir is a Erlang VM (BEAM) based language (http://elixir-lang.org/). This post serves as a note and thoughts while exploring this language.

On Installation

  1. It is much easier to install Erlang and Elixir via Homebrew, if you are using Mac, you definitely should consider this route
brew install elixir
brew install erlang

On Syntax

  1. true and :true are the same, same goes to false and :false. These have data type of booleans
  2. Constants, or symbols are called atoms. For example :hello is an atom.
  3.  The atom version of booleans (i.e. :true and :false) are special cases, and will be treated as booleans.  As can be shown below by the interactive output of Elixir. Note :hello is an atom, but not a boolean
  4. iex(7)> is_boolean :true
    true
    iex(8)> is_boolean :false
    true
    iex(9)> is_atom :true
    true
    iex(10)> is_atom :false
    true

    iex(11)> is_boolean :hello
    false
    iex(12)> is_atom :hello 

Saturday, May 23, 2015

Some Beers That Consistently Make Me Feel Bad The Next Day



I did this through trial-and-error over the years, so far there are certain brands of beer that consistently cause me to feel bad/weak/shitty the next day, while some don't.

Here are the lists

Beers that cause me to feel sick (in no particular order)
  • Tiger beer
  • Carlsberg
  • Heineken

Beers that are OK after drinking (in no particular order)
  • Guinness Stout (foreign export and draft)
  • Bavaria

Disclaimer: This comes from my own personal experience, and I really don't know why these three international brands will have such effect on me.