Update README.
This commit is contained in:
parent
1f1a0f9f7d
commit
5272aaa47d
36
README.md
36
README.md
|
@ -12,13 +12,45 @@ Starting from a list of git projects and a Bash fragment, for each project, this
|
|||
* [Pipeline: Shared Groovy Libraries](https://plugins.jenkins.io/workflow-cps-global-lib) ver. 2.15 or newer
|
||||
* User credentials configured on Jenkins. These are needed to set the author of the tag.
|
||||
|
||||
## Parameters
|
||||
* _Git Root_: The URL of the parent organization that includes all the listed repositories.
|
||||
* _List of Repositories_: A plain text file, one line for each Git repository name to update.
|
||||
* _Action Root_: The root URL of the Bash fragment to execute.
|
||||
* _Action File_: The relative path under the Action Root of a Bash script
|
||||
|
||||
## How Does It Work
|
||||
The pipeline:
|
||||
1. clones one repository at the time
|
||||
2. downloads the file _Action Root_/_Action File_ in the root folder of the repository
|
||||
3. runs the action file using the root folder of the repository as working dir
|
||||
4. pushes the repository back to Gitea
|
||||
|
||||
Every change to the Git repository **MUST** be done by the action file. The pipeline is in charge only
|
||||
to push the repository to the remote origin.
|
||||
|
||||
## Sample Usage
|
||||
|
||||
### List of Repositories
|
||||
````text
|
||||
52n-wps-algorithm-gcube
|
||||
52n-wps-server-gcube
|
||||
about-vre
|
||||
accept-invite-portlet
|
||||
accounting-aggregator-se-plugin
|
||||
accounting-analytics
|
||||
...
|
||||
````
|
||||
|
||||
### Bash Fragments
|
||||
### Action File
|
||||
The following fragment downloads a file named LICENSE.md and adds it to the repository:
|
||||
|
||||
````bash
|
||||
#!/usr/bin/env bash
|
||||
curl <my URL>/LICENSE.md -o LICENSE.md
|
||||
git add LICENSE.md
|
||||
git commit -m "LICENSE.md"
|
||||
````
|
||||
|
||||
TBP
|
||||
|
||||
## References
|
||||
* [Pipeline as code](https://jenkins.io/doc/book/pipeline-as-code/)
|
||||
|
|
Loading…
Reference in New Issue