generated from HenriqueAmorim20/GEROcuidadoAPITemplate
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ff7c7ac
commit 2d42677
Showing
3 changed files
with
48 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,40 @@ | ||
name: Export de métricas | ||
# name: Export de métricas | ||
|
||
on: | ||
push: | ||
branches: [main, develop] | ||
tags: | ||
- "v*" | ||
# on: | ||
# push: | ||
# branches: [main, develop] | ||
# tags: | ||
# - "v*" | ||
|
||
jobs: | ||
release: | ||
runs-on: "ubuntu-latest" | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Criar diretório | ||
run: mkdir analytics-raw-data | ||
# jobs: | ||
# release: | ||
# runs-on: "ubuntu-latest" | ||
# steps: | ||
# - uses: actions/checkout@v3 | ||
# with: | ||
# fetch-depth: 0 | ||
# - name: Criar diretório | ||
# run: mkdir analytics-raw-data | ||
|
||
- name: Coletar métricas no SonarCloud | ||
run: python parser.py ${{ github.event.repository.name }} ${{ github.ref_name }} | ||
# - name: Coletar métricas no SonarCloud | ||
# run: python parser.py ${{ github.event.repository.name }} ${{ github.ref_name }} | ||
|
||
- name: Envia métricas para repo de Doc | ||
run: | | ||
git config --global user.email "${{secrets.USER_EMAIL}}" | ||
git config --global user.name "${{secrets.USER_NAME}}" | ||
git clone --single-branch --branch main "https://x-access-token:${{secrets.API_TOKEN_DOC}}@github.com/fga-eps-mds/2023-2-GEROcuidado-Doc" docs | ||
mkdir -p docs/analytics-raw-data | ||
cp -R analytics-raw-data/*.json docs/analytics-raw-data | ||
cd docs/ | ||
git add . | ||
git commit -m "Adicionando métricas do repositório ${{ github.event.repository.name }} ${{ github.ref_name }}" | ||
git push | ||
# - name: Envia métricas para repo de Doc | ||
# run: | | ||
# git config --global user.email "${{secrets.USER_EMAIL}}" | ||
# git config --global user.name "${{secrets.USER_NAME}}" | ||
# git clone --single-branch --branch main "https://x-access-token:${{secrets.API_TOKEN_DOC}}@github.com/fga-eps-mds/2023-2-GEROcuidado-Doc" docs | ||
# mkdir -p docs/analytics-raw-data | ||
# cp -R analytics-raw-data/*.json docs/analytics-raw-data | ||
# cd docs/ | ||
# git add . | ||
# git commit -m "Adicionando métricas do repositório ${{ github.event.repository.name }} ${{ github.ref_name }}" | ||
# git push | ||
|
||
- name: Envia métricas como assets da release | ||
if: startsWith(github.ref, 'refs/tags') | ||
uses: AButler/[email protected] | ||
with: | ||
files: 'analytics-raw-data/*' | ||
repo-token: ${{ secrets.GITHUB_TOKEN }} | ||
release-tag: ${{ github.ref_name }} | ||
# - name: Envia métricas como assets da release | ||
# if: startsWith(github.ref, 'refs/tags') | ||
# uses: AButler/[email protected] | ||
# with: | ||
# files: 'analytics-raw-data/*' | ||
# repo-token: ${{ secrets.GITHUB_TOKEN }} | ||
# release-tag: ${{ github.ref_name }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters