-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (43 loc) · 1.32 KB
/
t3code-update.yaml
File metadata and controls
43 lines (43 loc) · 1.32 KB
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
42
43
name: Update T3 Code
on:
workflow_dispatch:
schedule:
- cron: "0 * * * *"
jobs:
update-t3code:
name: Update T3 Code
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v5
- name: Check if update is needed
id: check
env:
GH_TOKEN: ${{ github.token }}
run: |
bash .github/update.sh --ci --only-check
- name: Install Nix
if: steps.check.outputs.should_update == 'true'
uses: cachix/install-nix-action@v31
with:
nix_path: nixpkgs=channel:nixpkgs-unstable
- name: Update versions
id: update
if: steps.check.outputs.should_update == 'true'
env:
GH_TOKEN: ${{ github.token }}
run: |
bash .github/update.sh --ci
- name: Validate builds
if: steps.check.outputs.should_update == 'true'
run: |
nix build --accept-flake-config .#t3code .#t3code-appimage .#t3code-with-codex .#t3code-appimage-with-codex
- name: Commit changes
id: commit
if: steps.check.outputs.should_update == 'true'
uses: stefanzweifel/git-auto-commit-action@v6
with:
commit_message: "${{ steps.update.outputs.commit_message }}"
file_pattern: "sources.json"