mirror of
				https://github.com/actions/checkout.git
				synced 2025-11-04 05:58:40 +08:00 
			
		
		
		
	clarify checkout behavior
This commit is contained in:
		
							parent
							
								
									c176d89032
								
							
						
					
					
						commit
						64ed9bea20
					
				| 
						 | 
					@ -21,12 +21,12 @@ steps:
 | 
				
			||||||
- run: npm test
 | 
					- run: npm test
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
To check out the branch or tag ref that triggered the workflow run:
 | 
					By default, the branch or tag ref that triggered the workflow will be checked out. If you wish to check out a different branch, specify that using `with.ref`:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```yaml
 | 
					```yaml
 | 
				
			||||||
- uses: actions/checkout@master
 | 
					- uses: actions/checkout@master
 | 
				
			||||||
  with:
 | 
					  with:
 | 
				
			||||||
    ref: ${{ github.ref }}
 | 
					    ref: some-branch
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
For more details, see [Contexts and expression syntax for GitHub Actions](https://help.github.com/en/articles/contexts-and-expression-syntax-for-github-actions)
 | 
					For more details, see [Contexts and expression syntax for GitHub Actions](https://help.github.com/en/articles/contexts-and-expression-syntax-for-github-actions)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user