7 # * is a special character in YAML so you have to quote this string
8 # UTC 09:00 -> CST (China) 17:00, see https://datetime360.com/cn/utc-cst-china-time/
12 group: ${{ github.workflow }}-${{ github.ref }}
13 cancel-in-progress: true
17 runs-on: ubuntu-latest
19 image: ghcr.io/liangyongxiang/gentoo-testing:master
23 uses: actions/checkout@v4
28 echo "::group::eselect repository add and sync"
29 repo_name=$(cat profiles/repo_name)
30 eselect repository add "$repo_name" git "file://${PWD}"
31 emerge --sync "$repo_name"
32 egencache --jobs=$(nproc) --update --repo "$repo_name" &> /dev/null
36 echo "::group::eix search packages"
37 pkgs=$(ACCEPT_LICENSE="*" ACCEPT_KEYWORDS="~amd64 ~arm64 ~loong ~riscv" EIX_LIMIT=0 NAMEVERSION="<category>/<name>-<version>\n" eix --pure-packages --in-overlay "$repo_name" --format '<bestversion:NAMEVERSION>')
38 pkgs=$(qatom -F "\"%{CATEGORY}/%{PN}\": \"%{PV}\"," $pkgs) # remove revision
40 pkgs="{ ${pkgs::-1} }"
41 echo "$pkgs" > .github/workflows/old_ver.json
42 # sed -r -i 's/_p[^"]*//' .github/workflows/old_ver.json
43 cat .github/workflows/old_ver.json
49 echo "::group::nvchecker and nvcmp"
51 echo -e "[keys]\ngithub = \"${{ secrets.GITHUB_TOKEN }}\"" > keyfile.toml
52 nvchecker --file overlay.toml --keyfile keyfile.toml
55 echo "nvcmp=$(nvcmp --file overlay.toml --json --newer)" >> $GITHUB_OUTPUT
60 uses: actions/setup-node@v4
64 - name: install github-script depends
69 uses: actions/github-script@v7
72 pkgs: ${{steps.nvchecker.outputs.nvcmp}}
74 github-token: ${{ secrets.GENTOO_ZH_NVCHECKER_PAT }} # https://github.com/microcai/gentoo-zh/pull/3130
76 const script = require('./.github/workflows/issues-bumper.js');
78 await script({github, context, core});