what-mac

0.1.3 • Public • Published

What Mac?

This module takes Apple serial numbers and returns hardware details of your Mac within JSON.

{
    "serial": "XXXXXXXXXDV33",
    "year": "Mid 2012",
    "size": "15-inch",
    "name": "MacBook Pro",
    "_configCode": "MacBook Pro (15-inch, Mid 2012)"
}

Usage

echo "XXXXXXXXXDV33" | bin/what-mac.js

The CLI accepts a stream of line-separated serial numbers. You can provide a list of any number of serial numbers to return a JSON object for each.

Credit to this StackExchange question for putting me on the right track.

Todo

  • Convert bin/what-mac to support command line options rather than only stream data
  • Browserify the module for front-end use
  • Develop example HTML/JS webpage for demo/quick use purposes.

/what-mac/

    Package Sidebar

    Install

    npm i what-mac

    Weekly Downloads

    9

    Version

    0.1.3

    License

    none

    Last publish

    Collaborators

    • jimmyhillis