I’m trying to convert a simple pipeline into a plugin:
The original pipeline does:
---
kind: pipeline
name: check pr size
steps:
- name: check size
image: xx.xxx.net/git-file-size-diff
steps:
- git fetch --tags
- git-size.sh
If I add git fetch --tags
to git-size.sh and run as:
---
kind: pipeline
name: check pr size
steps:
- name: check size
image: xxx/git-file-size-diff
fatal: could not read Username for 'https://git.xxxx: terminal prompts disabled
ie drone does not inject the token as it would for a pipeline. Is there a way to have this in a plugin?
Complete code is here: GitHub - johanvdw/drone_size: Compare HEAD size to base branch