hunk.code_window:       graceful-fs: 4.1.11
         mkdirp-promise: 5.0.1
         mz: 2.6.0
         rimraf-then: 1.0.1
       resolution: 109f177704943a3796ce49b0b518da8757955ac2
     /linkify-it/1.2.4:
       dependencies:
         uc.micro: 1.0.3
       resolution: 0773526c317c8fd13bd534ee1d180ff88abf881a
     /load-json-file/1.1.0:
  
hunk.labels: keep keep keep keep replace keep keep keep keep keep
hunk.after_edit:     resolution: ca8c686d6f8f75d1708b9e166c5dafb7c8ba0f04
  
hunk.file_path: shrinkwrap.yaml
hunk.type: replace
file: import path = require('path')
  import loadYamlFile = require('load-yaml-file')
  import writeYamlFile = require('write-yaml-file')
  
  const STORE_YAML = 'store.yaml'
  
  export type Store = {
    [name: string]: string[],
  }
  
  export async function read (storePath: string): Promise<Store | null> {
    const storeYamlPath = path.join(storePath, STORE_YAML)
    try {
      return await loadYamlFile<Store>(storeYamlPath)
    } catch (err) {
      if ((<NodeJS.ErrnoException>err).code !== 'ENOENT') {
        throw err
      }
      return null
    }
  }
  
  export function save (storePath: string, store: Store) {
    const storeYamlPath = path.join(storePath, STORE_YAML)
    return writeYamlFile(storeYamlPath, store, {sortKeys: true})
  }
  