flex-hosts

0.6.11 • Public • Published

FlexHosts

Support Mac OS X, Windows, Linux

var flexHosts = require("flex-hosts");

flexHosts(hostsMap, [dir,] function (err, hosts) {
  ...
});

Arguments

hostsMap

{
  "127.0.0.1": [
    "g.cdn.cn",
    "a.cdn.cn"
  ],
  "127.0.0.2": "t.cdn.cn o.cdn.cn"
}
  • The value relevant to key could be Array or String.

[dir]

The DIR where puts the hostsMap file

/flex-hosts/

    Package Sidebar

    Install

    npm i flex-hosts

    Weekly Downloads

    70

    Version

    0.6.11

    License

    ISC

    Last publish

    Collaborators

    • limingv5