File: setup_ccache

package info (click to toggle)
obs-gradient-source 0.3.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 440 kB
  • sloc: ansic: 425; makefile: 22; cpp: 16
file content (14 lines) | stat: -rwxr-xr-x 396 bytes parent folder | download | duplicates (44)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
autoload -Uz log_debug log_warning

if (( ${+commands[ccache]} )) {
  log_debug "Found ccache at ${commands[ccache]}"

  if (( ${+CI} )) {
    ccache --set-config=cache_dir="${GITHUB_WORKSPACE:-${HOME}}/.ccache"
    ccache --set-config=max_size="${CCACHE_SIZE:-500M}"
    ccache --set-config=compression=true
    ccache -z > /dev/null
  }
} else {
  log_warning "No ccache found on the system"
}