-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yaml
41 lines (41 loc) · 1.5 KB
/
action.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: 'Android repo init and sync'
description: 'Initialize and sync repos using Androids repo command'
author: Kenneth Mead
branding:
icon: 'aperture'
color: 'green'
inputs:
manifest_url:
description: 'Specifies the url or git repo to fetch the manifest from. Used in repo init'
required: false
default: https://github.com/${{ github.repository_owner }}/manifests
manifest_branch:
description: 'Specifies what manifest branch to use. Used in repo init'
required: false
default: ${{ github.ref_name }}
manifest_filename:
description: 'Specifies the name of the manifest file to find. Used in repo init'
required: false
default: default.xml
username:
description: 'The username to use when authenticating to the manifest server'
required: false
default: ${{ github.actor }}
password:
description: 'The password or token to use when authenticating while fetching the manifest and git fetching repositories'
required: true
runs:
using: "composite"
steps:
- name: Download the android repo tool
shell: bash
run: |
mkdir -p ~/.bin
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/.bin/repo
chmod a+rx ~/.bin/repo
- name: Initialize the repo tool
shell: bash
run: ~/.bin/repo init -u ${{ inputs.manifest_url }} -b ${{ inputs.manifest_branch }} -m ${{ inputs.manifest_filename }}
- name: Sync repos
shell: bash
run: ~/.bin/repo sync -u ${{ inputs.username }} -p ${{ inputs.password }}