mirror of
				https://github.com/actions/cache.git
				synced 2025-11-04 07:38:37 +08:00 
			
		
		
		
	Make save/restore logs akin
- Print primary key when saving cache
This commit is contained in:
		
							parent
							
								
									aeaf731ae2
								
							
						
					
					
						commit
						3c88bb2ae4
					
				
							
								
								
									
										1
									
								
								dist/save/index.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								dist/save/index.js
									
									
									
									
										vendored
									
									
								
							| 
						 | 
					@ -45471,6 +45471,7 @@ function run() {
 | 
				
			||||||
                yield cache.saveCache(cachePaths, primaryKey, {
 | 
					                yield cache.saveCache(cachePaths, primaryKey, {
 | 
				
			||||||
                    uploadChunkSize: utils.getInputAsInt(constants_1.Inputs.UploadChunkSize)
 | 
					                    uploadChunkSize: utils.getInputAsInt(constants_1.Inputs.UploadChunkSize)
 | 
				
			||||||
                });
 | 
					                });
 | 
				
			||||||
 | 
					                core.info(`Cache saved with key: ${primaryKey}`);
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
            catch (error) {
 | 
					            catch (error) {
 | 
				
			||||||
                if (error.name === cache.ValidationError.name) {
 | 
					                if (error.name === cache.ValidationError.name) {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -44,6 +44,7 @@ async function run(): Promise<void> {
 | 
				
			||||||
            await cache.saveCache(cachePaths, primaryKey, {
 | 
					            await cache.saveCache(cachePaths, primaryKey, {
 | 
				
			||||||
                uploadChunkSize: utils.getInputAsInt(Inputs.UploadChunkSize)
 | 
					                uploadChunkSize: utils.getInputAsInt(Inputs.UploadChunkSize)
 | 
				
			||||||
            });
 | 
					            });
 | 
				
			||||||
 | 
					            core.info(`Cache saved with key: ${primaryKey}`);
 | 
				
			||||||
        } catch (error) {
 | 
					        } catch (error) {
 | 
				
			||||||
            if (error.name === cache.ValidationError.name) {
 | 
					            if (error.name === cache.ValidationError.name) {
 | 
				
			||||||
                throw error;
 | 
					                throw error;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user