File: weekly-tag.yml

package info (click to toggle)
vulkan-validationlayers 1.4.341.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 54,356 kB
  • sloc: cpp: 675,478; python: 12,311; sh: 24; makefile: 24; xml: 14
file content (31 lines) | stat: -rw-r--r-- 751 bytes parent folder | download
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
name: Weekly tag

# run every Sunday at 00:15 UTC
on:
  schedule:
  - cron: "15 0 * * 0"

jobs:
  create-tag:
    runs-on: ubuntu-latest
    permissions: write-all
    steps:
    - name: Create Tag
      uses: actions/github-script@v8
      with:
        script: |
          let output = '';
          const options = {};
          options.listeners = {
            stdout: (data) => {
              output += data.toString();
            }
          };
          await exec.exec('date', ['+snapshot-%Gwk%V'], options);
          const date = output.trim()
          github.rest.git.createRef({
            owner: context.repo.owner,
            repo: context.repo.repo,
            ref: `refs/tags/${date}`,
            sha: context.sha
          })