Skip to content

docs(cicd-ex2-2): switch to fork workflow and shrink the code change #31

docs(cicd-ex2-2): switch to fork workflow and shrink the code change

docs(cicd-ex2-2): switch to fork workflow and shrink the code change #31

Workflow file for this run

name: Repo Info
on:
push:
branches: [main]
workflow_dispatch:
jobs:
fetch-info:
runs-on: ubuntu-latest
steps:
- name: Fetch repository info
env:
REPO: ${{ github.repository }}
run: curl -s "https://api.github.com/repos/${REPO}" > repo.json
- name: Show repository name
run: jq -r .full_name repo.json
- name: Show star count
run: |
STARS=$(jq -e .stargazers_count repo.json)
echo "This repo has $STARS stars"
- name: Show description
run: jq -r .description repo.json