-
-
Notifications
You must be signed in to change notification settings - Fork 118
86 lines (86 loc) · 2.66 KB
/
Copy pathpublish.yml
File metadata and controls
86 lines (86 loc) · 2.66 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: Publish
on:
push:
tags:
- v*
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
permissions:
contents: read
jobs:
build-compiled:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- macos-26
- macos-26-intel
- ubuntu-24.04
- ubuntu-24.04-arm
- windows-11-arm
- windows-2025
fail-fast: false
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
with:
persist-credentials: false
- uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
python-version: "3.14"
enable-cache: false
- run: uvx --exclude-newer '3 days' --no-cache cibuildwheel --output-dir dist
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: wheels-${{ matrix.os }}
path: dist
build-pure:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
with:
persist-credentials: false
- uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
python-version: "3.14"
enable-cache: false
- run: uv build --no-cache
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: wheels-any
path: dist
publish-pypi:
runs-on: ubuntu-24.04
if: ${{ github.repository_owner == 'djlint' && startsWith(github.ref, 'refs/tags/') }}
needs:
- build-compiled
- build-pure
permissions:
id-token: write
steps:
- uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
python-version: "3.14"
enable-cache: false
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8
- run: mkdir dist
- run: mv wheels-*/* dist
- run: uv publish --trusted-publishing always --no-cache
publish-npm:
runs-on: ubuntu-24.04
if: ${{ github.repository_owner == 'djlint' && startsWith(github.ref, 'refs/tags/') }}
needs:
- publish-pypi
permissions:
id-token: write
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
with:
persist-credentials: false
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7
with:
node-version: lts/*
check-latest: true
package-manager-cache: false
registry-url: https://registry.npmjs.org
- run: npm publish --access public