mirror of
				https://github.com/actions/cache.git
				synced 2025-10-31 03:38:36 +08:00 
			
		
		
		
	 6ec565b197
			
		
	
	
		6ec565b197
		
	
	
	
	
		
			
			Basically, do exactly what GH did to save and restore cache with the exception being that the files are stored on GCS.
		
			
				
	
	
		
			31 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			31 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
| name: 'Save a cache'
 | |
| description: 'Save Cache artifacts like dependencies and build outputs to improve workflow execution time'
 | |
| author: 'GitHub'
 | |
| inputs:
 | |
|   path:
 | |
|     description: 'A list of files, directories, and wildcard patterns to cache'
 | |
|     required: true
 | |
|   key:
 | |
|     description: 'An explicit key for saving the cache'
 | |
|     required: true
 | |
|   upload-chunk-size:
 | |
|     description: 'The chunk size used to split up large files during upload, in bytes'
 | |
|     required: false
 | |
|   enableCrossOsArchive:
 | |
|     description: 'An optional boolean when enabled, allows windows runners to save caches that can be restored on other platforms'
 | |
|     default: 'false'
 | |
|     required: false
 | |
|   gcs-bucket:
 | |
|     description: 'Google Cloud Storage bucket name to use for caching. When provided, GCS will be used as the cache backend.'
 | |
|     required: false
 | |
|   gcs-path-prefix:
 | |
|     description: 'Optional prefix path within the GCS bucket for cache files'
 | |
|     default: 'github-cache'
 | |
|     required: false
 | |
| runs:
 | |
|   using: 'node20'
 | |
|   main: '../dist/save-only/index.js'
 | |
| branding:
 | |
|   icon: 'archive'
 | |
|   color: 'gray-dark'
 |