Improve skip_clone documentation (#1747)

Co-authored-by: Anbraten <anton@ju60.de>
This commit is contained in:
6543 2023-05-12 16:28:45 +02:00 committed by GitHub
parent 111fd73e88
commit 77d830d5b5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 16 deletions

View file

@ -727,6 +727,14 @@ pipeline:
...
```
## `skip_clone`
By default Woodpecker is automatically adding a clone step. This clone step can be configured by the [clone](#clone) property. If you do not need a `clone` step at all you can skip it using:
```yaml
skip_clone: true
```
## `when` - Global pipeline conditions
Woodpecker gives the ability to skip whole pipelines (not just steps #when---conditional-execution-1) based on certain conditions by a `when` block. If all conditions in the `when` block evaluate to true the pipeline is executed, otherwise it is skipped, but treated as successful and other pipelines depending on it will still continue.

View file

@ -124,19 +124,7 @@ depends_on:
+runs_on: [ success, failure ]
```
Some workflows don't need the source code, set the `skip_clone` tag to skip cloning:
```diff
pipeline:
notify:
image: debian:stable-slim
commands:
- echo notifying
depends_on:
- deploy
runs_on: [ success, failure ]
+skip_clone: true
```
:::info
Some workflows don't need the source code, like creating a notification on failure.
Read more about `skip_clone` at [pipeline syntax](./20-pipeline-syntax.md#skip_clone)
:::