Installing npm and Node.js on a Mac OS laptop

1. Install Mac iOS installer from Node.js

https://nodejs.org/en/download/

2. Downloading and installing Node.js and npm

Checking your version of npm and Node.js§

To see if you already have Node.js and npm installed and check the installed version, run the following commands:

node -v
npm -v

$ node -v
v10.16.0

$ npm -v
6.9.2

4. Run this npm install [email protected] -g

npm is a separate project from Node.js. So even if you’ve just downloaded Node.js (which also includes npm), you’ll probably need to update your npm. 

To update your npm, type this into your terminal:

$ sudo npm install [email protected] -g
/usr/local/bin/npm -> /usr/local/lib/node_modules/npm/bin/npm-cli.js
/usr/local/bin/npx -> /usr/local/lib/node_modules/npm/bin/npx-cli.js
+ [email protected]
updated 1 package in 4.132s

5. Run and check npm version

$ npm - v or 
$ npm - version

Usage: npm <command>

where <command> is one of:
    access, adduser, audit, bin, bugs, c, cache, ci, cit,
    clean-install, clean-install-test, completion, config,
    create, ddp, dedupe, deprecate, dist-tag, docs, doctor,
    edit, explore, get, help, help-search, hook, i, init,
    install, install-ci-test, install-test, it, link, list, ln,
    login, logout, ls, org, outdated, owner, pack, ping, prefix,
    profile, prune, publish, rb, rebuild, repo, restart, root,
    run, run-script, s, se, search, set, shrinkwrap, star,
    stars, start, stop, t, team, test, token, tst, un,
    uninstall, unpublish, unstar, up, update, v, version, view,
    whoami

npm <command> -h  quick help on <command>
npm -l            display full usage info
npm help <term>   search for help on <term>
npm help npm      involved overview

Specify configs in the ini-formatted file:
    /Users/vulongtran/.npmrc
or on the command line via: npm <command> --key value
Config info can be viewed via: npm help config

[email protected] /usr/local/lib/node_modules/npm

For more details, you can refer to:

Get npm!
Install Node.js, npm, and stay up-to-date. https://www.npmjs.com/get-npm

NPM – Downloading and installing Node.js and npm. https://docs.npmjs.com/downloading-and-installing-node-js-and-npm

How to remove the Elastic Compute Cloud charge from your AWS bill

I have been testing Google Cloud and AWS, so I recently decided to stop all my Amazon services so I can focus on testing on one cloud computing hosting provider. I decided I will test on Google as I like their BigQuery features.

So I scaled down all my Amazon AWS (Amazon Web Services) instances and found that I was still getting charged by AWS.

What I received was a bill, I logged into AWS and found that I needed to disable my Elastic IP address that I had set on AWS.

As I knew I had already disabled the instances itself (and in each region – be sure to check that!). But the instance still had an Elastic IP address associated and set up with it. So I didn’t realise it right now, but I was still using another paid feature, so that was what was causing that charge on my credit card was for in the following month.

Well, here is the example details that I saw when I logged into my AWS account.



Specifically this section of the bill which I discovered!

Elastic IP Addresses $1.19

$0.00 per Elastic IP address not attached to a running instance for the first hour1 Hrs$0.00$0.005 per Elastic IP address not attached to a running instance per hour (prorated)238 Hrs$1.19

Via the Billing Management Console> Bills. Here is the link here in case you need it. https://console.aws.amazon.com/billing/home?region=us-east-2#/bills?year=2019&month=5

So where do you find this Elastic Compute Cloud to turn off in your AWS account?

Well, if you go to AWS Management Console via https://aws.amazon.com/# you can find it within the listing in your dashboard. It will appear innocently as a text link called “Elastic IPs”. So you will want to click and make your way through the steps to finally “Release the IP address”.

Here are some screenshots from my experiences clicking my way through to disable it.

Right click here and select “Release addresses”

I hope that helps you manage your AWS bill better. Remember to use only the features you need!

How to port your mobile number from Singtel to Starhub

I am looking to change my mobile service from Singtel to Starhub, and keep my primary number. So I want to share you my porting process.

Reason for the change if you are wondering – I am changing from Singtel to Starhub, mainly as I am in a new office to Fraser Tower and my 4G coverage for using mobile data is not optimal at the high level my office, when I am looking to tethering internet from my mobile for my laptop to have faster a internet. Note – It is a new building and up quite high, so my SingTel 4G/ 3G signals may be poor as a result of not having enough range of SingTel’s current infrastructure in my new area.

So after going through the steps online via starhub.com, then you want to “Select Your Number” step.

Select Your Number with Starhub

  1. In “Select Your Number”, select “Port from another telco”.
  2. Enter your Singapore phone number under “Enter the 8-digit number”
  3. Select “Yes/ No” for whether you own this number for the question “Do you own this number?”

Great thing that they note here, is that you can “port any Singtel/ M1/ Circles.Life/ MyRepublic/ Zero/ Zero 1 Postpaid number to StarHub”. There may be nuances around this for each telco provider, so be wary, especially with the less mature providers at the moment.

Port from another telco
Singtel/ M1/ Circles.Life postpaid mobile number porting – Source: https://www.starhub.com/personal/support/online-store/personal/purchase.html#mobile
StarHub Number Porting Terms & Conditions

Then, you will receive details around the Number Porting Terms & Conditions that you will need to agree to, here are the details here so you know what to expect.

I/WE* wish to sign up for Full Mobile Number Portability service with StarHub.

I/WE* understand that upon commencement of the Full Mobile Number Portability service with StarHub, all existing services associated with the existing mobile number provided by existing Service Provider(s) will be automatically terminated. I shall not hold StarHub responsible for any loss, penalty damage or inconvenience arising from the termination of service with the existing Service Provider(s).

I/WE* shall be responsible for all charges (such as equipment plan/ price plan/ contractual penalty, etc) for service signed up with StarHub until my existing mobile number(s) has/have been transferred

I/WE* agree to the proper disposal of the SIM Card from the existing Service Provider(s)

I/WE* understand that there will be service interruptions to my/our* existing mobile line during the Full Mobile Number Portability provisioning process^^

I/WE* acknowledge that it would be necessary to exchange certain information regarding my/ our existing and new mobile services subscriptions in order for the Full Mobile Number Portability service to be provisioned. I/We* authorise StarHub to communicate with the existing Service Provider and disclose and receive such information as may be necessary in order to provide the Full Mobile Number Portability service.

I/WE* acknowledge and understand that I/WE* have to pay for all outstanding charges imposed by my/ our* existing Service provider(s) for terminating the mobile service(s) prematurely or otherwise.

I/WE* confirm that I/WE* have provided full and accurate information to StarHub. I/WE* have read and agree to be bound by all the terms and conditions herein as well as StarHub’s terms and conditions for info-communications Services# and such other terms and conditions as may be agreed or accepted by me/ us* .

I/WE* acknowledge and agree that if StarHub suspends or terminates any or all the services that I/WE* signed up with StarHub pursuant to and in accordance with StarHub’s terms and conditions for Info-communications Services, StarHub is entitled return my/our* existing Service Provider(or to the Service Provider which the porting originates from, as the case may be), and thereafter StarHub will not be able restore the usage of my/our* existing mobile number for any reason or whatsoever

Once you are comfortable with this, then you will be asked to select a delivery date/ time and make sure you have the right paperwork on the day of delivery.

  • A print-out of the order confirmation email
  • Your physical NRIC* (Singapore Citizens & Permanent Residents) or physical FIN Pass* (Foreigners) with a minimum validity of 6 months

Example from my success screen here for your reference.

Additional information (optional context)

Essentially Starhub, M1, Singtel all follow IMDA’s requirements. This is important given the stickiness requirement of your mobile number for online and modern services such as PayNow and SingPass. Essentially it is:

Full Mobile Number Portability is a solution that allows consumers to keep one mobile number for life, even when they switch operators. It works via a central database system in a multi-operator environment, in which all ported mobile subscribers’ numbers and routing information are kept. When a call/SMS/MMS is made to a ported mobile subscriber under the solution, the caller’s mobile operator will check against the central database information and route the call/SMS/MMS directly to the ported subscriber’s new operator.

Source: https://www.imda.gov.sg/about/newsroom/archived/ida/media-releases/2008/20080416085608
IMDA full mobile number portability

Here’s some details on some of these local telco’s overall Full Mobile Number Portability guidance.

Starhub Full Mobile Number Portability guidance

1. What is Full Mobile Number Portability?

Full Mobile Number Portability is an enhanced mobile number portability solution that will allow you to retain full use of your existing phone number, even when you switch service providers. As such, you will not have to go through the hassle of updating all your contacts on a new number from your new service provider.

Prepaid and postpaid mobile subscribers can make use of this solution to retain their original phone numbers. However, the service is only applicable for prepaid to prepaid and postpaid to postpaid mobile subscribers only. (Starhub)

2. How is Full Mobile Number Portability different from the previous mobile number portability solution?

The previous mobile number portability scheme is based on a call-forwarding solution. As such, subscribers will possess two mobile numbers (the original mobile number and the new mobile number issued by the new service provider which they switched to). A call made to the original number at the previous service provider will be forwarded to the new number under the call-forwarding approach. When a subscriber under the call-forwarding solution makes a call or sends an SMS, the new number will be reflected on the recipient’s phone. Furthermore, the subscriber will not be able to receive MMS on his original number with the call-forwarding solution.

The call-forwarding solution also only applies to post-paid mobile subscribers.

Full Mobile Number Portability will eliminate these limitations, and also extend mobile number portability to prepaid mobile subscribers. (Starhub)

https://www.starhub.com/business/support/mobile/faq/full-number-portability.html

M1 Full Mobile Number Portability guidance

  1. What is Full Mobile Number Portability? Full Mobile Number Portability is an enhanced solution that allows you to retain full use of your existing phone number, even when you switch to M1. It saves you the hassle of having to inform all your contacts that you have changed your number. (M1)
  2. Who can enjoy Full Mobile Number Portability? All prepaid and postpaid mobile customers can make use of Full Mobile Number Portability.However, if your mobile service has been terminated or suspended, you may not be able to use Full Mobile Number Portability to regain the number given up during the service suspension or termination. (M1)

https://www.m1.com.sg/Personal/FAQ/Mobilephonesandplans/postpaid/mobilenumberportability

]]>