Skip to content

Instantly share code, notes, and snippets.

@lightsofapollo
Last active August 29, 2015 14:09
Show Gist options
  • Select an option

  • Save lightsofapollo/8ae7ea4f827d8c532fe4 to your computer and use it in GitHub Desktop.

Select an option

Save lightsofapollo/8ae7ea4f827d8c532fe4 to your computer and use it in GitHub Desktop.

Caches

We should be using as many caches as possible so what about something like this:

Create some json file (we can move this into the tree at some point?)

{
  "repository": "url"
}
repo_cache() {
  local registry=$1
  local repository=$2
  local target=$3
  
  local url=$(cat registry | jq ."['$repository']" )
  
  # Expand url, etc....
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment