File: os.coffee

Defined in: lib/resin/os

Method Summary

Method Details

~ (String) generateCacheName(id, connectionParams)

Note: For security reasons, the wifiSsid is omitted from the filename
Note: The original filename extension (*.zip in this case) is lost in the renaming process

Generate os cache name

It generates an unique name for a certain instance of the os with id and connection params embedded in the filename.

result = resin.os.generateCacheName(51, { network: 'ethernet' })
console.log(result)
# 51-ethernet-1418040928724

result = resin.os.generateCacheName(51, {    network: 'wifi'    wifiKey: 'MyWifi'    wifiSsid: 'secret'
})
console.log(result)
# 51-wifi-MyWifi-1418040928724

Parameters:

  • id ( String, Number ) application id
  • connectionParams ( Object ) connection parameters

Options Hash: (connectionParams):

  • network ( String ) network type
  • wifiKey ( String ) wifi key
  • wifiSsid ( String ) wifi ssid

Returns:

  • ( String ) — os cache name

    Quickly fuzzy find classes, mixins, methods, file:

    Control the navigation frame:

    You can focus and blur the search input: