mirror of
				https://code.forgejo.org/actions/cache.git
				synced 2025-11-04 06:19:11 +00:00 
			
		
		
		
	Merge 44401f0ae6 into 638ed79f9d
				
					
				
			This commit is contained in:
		
						commit
						1c3b4952aa
					
				
					 1 changed files with 51 additions and 0 deletions
				
			
		
							
								
								
									
										51
									
								
								.github/workflows/npm-gulp.yml
									
										
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										51
									
								
								.github/workflows/npm-gulp.yml
									
										
									
									
										vendored
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,51 @@
 | 
				
			||||||
 | 
					            - name: Cache
 | 
				
			||||||
 | 
					  uses: actions/cache@v4.2.3
 | 
				
			||||||
 | 
					  with:
 | 
				
			||||||
 | 
					    # A list of files, directories, and wildcard patterns to cache and restore
 | 
				
			||||||
 | 
					    path: 
 | 
				
			||||||
 | 
					    # An explicit key for restoring and saving the cache
 | 
				
			||||||
 | 
					    key: 
 | 
				
			||||||
 | 
					    # An ordered multiline string listing the prefix-matched keys, that are used for restoring stale cache if no cache hit occurred for key. Note `cache-hit` returns false in this case.
 | 
				
			||||||
 | 
					    restore-keys: # optional
 | 
				
			||||||
 | 
					    # The chunk size used to split up large files during upload, in bytes
 | 
				
			||||||
 | 
					    upload-chunk-size: # optional
 | 
				
			||||||
 | 
					    # An optional boolean when enabled, allows windows runners to save or restore caches that can be restored or saved respectively on other platforms
 | 
				
			||||||
 | 
					    enableCrossOsArchive: # optional, default is false
 | 
				
			||||||
 | 
					    # Fail the workflow if cache entry is not found
 | 
				
			||||||
 | 
					    fail-on-cache-miss: # optional, default is false
 | 
				
			||||||
 | 
					    # Check if a cache entry exists for the given input(s) (key, restore-keys) without downloading the cache
 | 
				
			||||||
 | 
					    lookup-only: # optional, default is false
 | 
				
			||||||
 | 
					    # Run the post step to save the cache even if another step before fails
 | 
				
			||||||
 | 
					    save-always: # optional, default is false
 | 
				
			||||||
 | 
					          
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					name: NodeJS with Gulp
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					on:
 | 
				
			||||||
 | 
					  push:
 | 
				
			||||||
 | 
					    branches: [ "main" ]
 | 
				
			||||||
 | 
					  pull_request:
 | 
				
			||||||
 | 
					    branches: [ "main" ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					jobs:
 | 
				
			||||||
 | 
					  build:
 | 
				
			||||||
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      matrix:
 | 
				
			||||||
 | 
					        node-version: [18.x, 20.x, 22.x]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					    - uses: actions/checkout@v4
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    - name: Use Node.js ${{ matrix.node-version }}
 | 
				
			||||||
 | 
					      uses: actions/setup-node@v4
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        node-version: ${{ matrix.node-version }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    - name: Build
 | 
				
			||||||
 | 
					      run: |
 | 
				
			||||||
 | 
					        npm install
 | 
				
			||||||
 | 
					        gulp
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue