-
Notifications
You must be signed in to change notification settings - Fork 69
798 lines (690 loc) · 29.6 KB
/
release.yaml
File metadata and controls
798 lines (690 loc) · 29.6 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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
name: Release
on:
schedule:
- cron: '0 2 * * *' # run at 2 AM UTC
workflow_dispatch:
inputs:
tag_name:
description: 'Tag name for release'
required: false
default: nightly
push:
tags:
- v[0-9]+.[0-9]+.[0-9]+
env:
cache-version: v9
jobs:
check-new-commit:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- run: >
test \( "${{github.event_name}}" == "schedule"
-a 0 -lt $(git log --oneline --show-pulls --since "yesterday" -- . ":!.github" ":!.gitignore" ":!.golangci.yml" | wc -l) \)
-o \( "${{github.event_name}}" != "schedule" \)
#################################################################
# Linux
#################################################################
linux-x86_64:
needs: [check-new-commit]
strategy:
matrix:
go-version: [1.24.x]
platform: [ubuntu-24.04]
runs-on: ${{ matrix.platform }}
env:
GOPATH: ${{ github.workspace }}
QT_API: 5.13.0
QT_DEBUG: false
GO111MODULE: on
QT_PKG_CONFIG: true
CGO_CXXFLAGS: "-Wno-deprecated-declarations -O2"
steps:
- name: Linux prerequisites
run: |
sudo apt update
sudo apt-get -y install build-essential libglu1-mesa-dev libpulse-dev libglib2.0-dev cmake
sudo apt-get --no-install-recommends -qq -y install fontconfig libasound2t64 libegl1 libnss3 libpci3 libxcomposite1 libxcursor1 libxi6 libxrandr2 libxtst6
sudo apt-get --no-install-recommends -qq -y install libdbus-1-dev libssl-dev libzstd-dev
sudo apt-get install '^libxcb.*-dev' libx11-xcb-dev libglu1-mesa-dev libxrender-dev libxi-dev libxkbcommon-dev libxkbcommon-x11-dev
sudo apt-get install libwayland-dev libwayland-egl++ wayland-scanner++
sudo apt-get --no-install-recommends install libqt*5-dev qt*5-dev qml-module-qtquick-* qt*5-doc-html
sudo apt install -y build-essential cmake qtbase5-dev qtbase5-dev-tools qtchooser qt5-qmake
sudo apt install -y \
qtdeclarative5-dev qml-module-qtquick-controls qml-module-qtquick-controls2 \
qml-module-qtgraphicaleffects \
qtmultimedia5-dev qml-module-qtmultimedia \
qttools5-dev qttools5-dev-tools
sudo apt install -y libwayland-dev wayland-protocols
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{ env.GOPATH }}/src/github.com/${{ github.repository }}
- name: Free disk space
run: |
sudo swapoff -a
sudo rm -f /swapfile
sudo apt clean
sudo rm -rf /usr/share/dotnet
- name: Get dependencies
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make deps
- name: Get Qt binding for Go
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make qt_bindings
- name: Retrieve version
id: version-linux
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
- name: Build
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make app
- if: github.event_name == 'workflow_dispatch'
run: echo "ARCHIVE_NAME=goneovim-linux-x86_64" >> $GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo "ARCHIVE_NAME=goneovim-linux-x86_64" >> $GITHUB_ENV
- if: github.event_name == 'push'
run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-linux.outputs.GONEOVIM_VERSION }}-linux-x86_64" >> $GITHUB_ENV
- name: Archive
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy
mv linux "$ARCHIVE_NAME"
tar -jcvf "$ARCHIVE_NAME".tar.bz2 "$ARCHIVE_NAME"
- name: Upload for linux
uses: actions/upload-artifact@v4
with:
name: goneovim-linux-x86_64
path: ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.tar.bz2
#################################################################
# Linux ARM
#################################################################
linux-arm64:
needs: [check-new-commit]
strategy:
matrix:
go-version: [1.24.x]
platform: [ubuntu-24.04-arm]
runs-on: ${{ matrix.platform }}
env:
GOPATH: ${{ github.workspace }}
QT_API: 5.13.0
QT_DEBUG: false
GO111MODULE: on
QT_PKG_CONFIG: true
CGO_CXXFLAGS: "-Wno-deprecated-declarations -O2"
steps:
- name: Linux prerequisites
run: |
sudo apt update
sudo apt-get -y install build-essential libglu1-mesa-dev libpulse-dev libglib2.0-dev cmake
sudo apt-get --no-install-recommends -qq -y install fontconfig libasound2t64 libegl1 libnss3 libpci3 libxcomposite1 libxcursor1 libxi6 libxrandr2 libxtst6
sudo apt-get --no-install-recommends -qq -y install libdbus-1-dev libssl-dev libzstd-dev
sudo apt-get install '^libxcb.*-dev' libx11-xcb-dev libglu1-mesa-dev libxrender-dev libxi-dev libxkbcommon-dev libxkbcommon-x11-dev
sudo apt-get install libwayland-dev libwayland-egl++ wayland-scanner++
sudo apt-get --no-install-recommends install libqt*5-dev qt*5-dev qml-module-qtquick-* qt*5-doc-html
sudo apt install -y build-essential cmake qtbase5-dev qtbase5-dev-tools qtchooser qt5-qmake
sudo apt install -y \
qtdeclarative5-dev qml-module-qtquick-controls qml-module-qtquick-controls2 \
qml-module-qtgraphicaleffects \
qtmultimedia5-dev qml-module-qtmultimedia \
qttools5-dev qttools5-dev-tools
sudo apt install -y libwayland-dev wayland-protocols
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{ env.GOPATH }}/src/github.com/${{ github.repository }}
- name: Free disk space
run: |
sudo swapoff -a
sudo rm -f /swapfile
sudo apt clean
sudo rm -rf /usr/share/dotnet
- name: Get dependencies
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make deps
- name: Get Qt binding for Go
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make qt_bindings
- name: Retrieve version
id: version-linux
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
- name: Build
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make app
- if: github.event_name == 'workflow_dispatch'
run: echo "ARCHIVE_NAME=goneovim-linux-arm64" >> $GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo "ARCHIVE_NAME=goneovim-linux-arm64" >> $GITHUB_ENV
- if: github.event_name == 'push'
run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-linux.outputs.GONEOVIM_VERSION }}-linux-arm64" >> $GITHUB_ENV
- name: Archive
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy
mv linux "$ARCHIVE_NAME"
tar -jcvf "$ARCHIVE_NAME".tar.bz2 "$ARCHIVE_NAME"
- name: Upload for linux
uses: actions/upload-artifact@v4
with:
name: goneovim-linux-arm64
path: ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.tar.bz2
#################################################################
# MacOS x86_64
#################################################################
macos-x86_64:
needs: [check-new-commit]
strategy:
matrix:
go-version: [1.24.x]
platform: [macos-15-intel]
runs-on: ${{ matrix.platform }}
env:
GOPATH: ${{ github.workspace }}
QT_HOMEBREW: true
QT_API: 5.13.0
QT_DEBUG: false
GO111MODULE: on
QT_QMAKE_DIR: /usr/local/opt/qt@5/bin
CGO_CXXFLAGS: "-Wno-deprecated-declarations -O2"
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Install Qt for macOS
run: |
brew install qt@5
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{ github.workspace }}/src/github.com/${{ github.repository }}
- name: Get dependencies
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make deps
- name: Get Qt binding for Go
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make qt_bindings
- name: Retrieve version
id: version-macos
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
echo "::set-output name=GONEOVIM_VERSION_HASH::$(git rev-parse HEAD)"
- name: Build
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make app
- if: github.event_name == 'workflow_dispatch'
run: echo "ARCHIVE_NAME=goneovim-macos-x86_64" >> $GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo "ARCHIVE_NAME=goneovim-macos-x86_64" >> $GITHUB_ENV
- if: github.event_name == 'push'
run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-macos.outputs.GONEOVIM_VERSION }}-macos-x86_64" >> $GITHUB_ENV
- name: Archive
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy
mv darwin "$ARCHIVE_NAME"
tar -jcvf "$ARCHIVE_NAME".tar.bz2 "$ARCHIVE_NAME"
- name: Upload for macos
uses: actions/upload-artifact@v4
with:
name: goneovim-macos-x86_64
path: ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.tar.bz2
#################################################################
# MacOS M1
#################################################################
macos-arm64:
needs: [check-new-commit]
strategy:
matrix:
go-version: [1.24.x]
platform: [macos-14]
qtversion: [5.15.16]
runs-on: ${{ matrix.platform }}
env:
GOPATH: ${{ github.workspace }}
QT_HOMEBREW: false
QT_API: 5.13.0
QT_DIR: ${{ github.workspace }}/qt5
QT_STATIC: true
QT_DEBUG: false
GO111MODULE: on
QT_QMAKE_DIR: ${{ github.workspace }}/qt5/bin
CGO_CXXFLAGS: "-Wno-deprecated-declarations -O2"
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Download pre built Qt
run: |
curl -L -o qt-macos-static-${{ matrix.qtversion }}.tar.bz2 https://github.com/akiyosi/qt-static-builds/releases/download/qt-static-${{ matrix.qtversion }}/qt-macos-arm64-${{ matrix.qtversion }}.tar.bz2
tar xf qt-macos-static-${{ matrix.qtversion }}.tar.bz2
mkdir qt5 && mv ./Users/runner/work/qt-static-builds/qt-static-builds/Qt/* qt5/
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{ github.workspace }}/src/github.com/${{ github.repository }}
- name: Get dependencies
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make deps
- name: Get Qt binding for Go
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make qt_bindings
- name: Retrieve version
id: version-macos
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
echo "::set-output name=GONEOVIM_VERSION_HASH::$(git rev-parse HEAD)"
- name: Build
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}
make app
- if: github.event_name == 'workflow_dispatch'
run: echo "ARCHIVE_NAME=goneovim-macos-arm64" >> $GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo "ARCHIVE_NAME=goneovim-macos-arm64" >> $GITHUB_ENV
- if: github.event_name == 'push'
run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-macos.outputs.GONEOVIM_VERSION }}-macos-arm64" >> $GITHUB_ENV
- name: Archive
run: |
cd ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy
mv darwin "$ARCHIVE_NAME"
tar -jcvf "$ARCHIVE_NAME".tar.bz2 "$ARCHIVE_NAME"
- name: Upload for macos
uses: actions/upload-artifact@v4
with:
name: goneovim-macos-arm64
path: ${{ github.workspace }}/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.tar.bz2
#################################################################
# Windows
#################################################################
windows-x86_64:
needs: [check-new-commit]
strategy:
matrix:
go-version: [1.24.0]
platform: [windows-latest]
runs-on: ${{ matrix.platform }}
env:
GOPATH: ${{ github.workspace }}
QT_API: 5.13.0
QT_MSYS2: true
QT_MSYS2_DIR: C:\a\msys64\
QT_MSVC: false
QT_DEBUG: false
GO111MODULE: on
CGO_CFLAGS_ALLOW: ".*"
CGO_CXXFLAGS_ALLOW: ".*"
CGO_LDFLAGS_ALLOW: ".*"
CGO_CXXFLAGS: "-Wno-deprecated-declarations -O2"
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
QT_BINDING_VER: "v0.0.0-20251021043539-c059a317d6ad"
steps:
- name: Setup MSYS2 and install Qt5
uses: msys2/setup-msys2@v2
with:
update: true
msystem: mingw64
install: >
mingw-w64-x86_64-toolchain
mingw-w64-x86_64-qt5
mingw-w64-x86_64-angleproject
location: C:\a\
- shell: msys2 {0}
run: |
pacman --noconfirm -S sed git make tree zip unzip
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{ env.GOPATH }}\src\github.com\${{ github.repository }}
- name: Get dependencies
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/x64/bin/:$PATH
cd /d/a/goneovim/goneovim/src/github.com/${{ github.repository }}
make deps
- name: Copy Qt tools (keep both names)
run: |
Get-ChildItem -Path "C:\a\msys64\mingw64\bin\" -Filter "*-qt5.exe" | ForEach-Object {
$newName = $_.Name -replace "-qt5\.exe$", ".exe"
Copy-Item $_.FullName -Destination (Join-Path $_.Directory $newName)
}
shell: pwsh
- name: Get Qt binding for Go
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/x64/bin/:$PATH
cd /d/a/goneovim/goneovim/src/github.com/${{ github.repository }}
go get github.com/akiyosi/qt@${{ env.QT_BINDING_VER }}
go get github.com/akiyosi/qt/internal/cmd@${{ env.QT_BINDING_VER }}
go get github.com/akiyosi/qt/internal/cmd/moc@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtdeploy@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtminimal@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtmoc@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtrcc@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtsetup@${{ env.QT_BINDING_VER }}
$(go env GOPATH)/bin/qtsetup -test=false
$(go env GOPATH)/bin/qtmoc desktop ./cmd/goneovim
- name: Retrieve version
id: version-windows
run: |
cd ${{ env.GOPATH }}\src\github.com\${{ github.repository }}
echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
- name: Build
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/x64/bin/:$PATH
cd /d/a/goneovim/goneovim/src/github.com/${{ github.repository }}
$(go env GOPATH)/bin/qtdeploy build desktop ./cmd/goneovim
cp -pR runtime cmd/goneovim/deploy/windows/
- name: Bundle specific DLLs
shell: msys2 {0}
run: |
set -e
DST=/d/a/goneovim/goneovim/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/windows
cp -u /mingw64/bin/libmd4c.dll "$DST" || true
cp -u /mingw64/bin/libzstd.dll "$DST" || true
cp -u /mingw64/bin/libbrotlidec.dll "$DST" || true
cp -u /mingw64/bin/libpcre2-8-0.dll "$DST" || true
cp -u /mingw64/bin/libbrotlicommon.dll "$DST" || true
- if: github.event_name == 'workflow_dispatch'
run: echo "ARCHIVE_NAME=goneovim-windows-x86_64" >> $env:GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo "ARCHIVE_NAME=goneovim-windows-x86_64" >> $env:GITHUB_ENV
- if: github.event_name == 'push'
run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-windows.outputs.GONEOVIM_VERSION }}-windows-x86_64" >> $env:GITHUB_ENV
- name: Archive
shell: msys2 {0}
run: |
cd /d/a/goneovim/goneovim/src/github.com/${{ github.repository }}/cmd/goneovim/deploy
mv windows ${{ env.ARCHIVE_NAME }}
zip -r ${{ env.ARCHIVE_NAME }}.zip ${{ env.ARCHIVE_NAME }}
- name: Upload
uses: actions/upload-artifact@v4
with:
name: goneovim-windows-x86_64
path: D:/a/goneovim/goneovim/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.zip
#################################################################
# Windows ARM
#################################################################
windows-arm64:
needs: [check-new-commit]
strategy:
matrix:
go-version: [1.24.0]
platform: [windows-11-arm]
runs-on: ${{ matrix.platform }}
env:
GOPATH: ${{ github.workspace }}
QT_API: 5.13.0
QT_MSYS2: true
QT_MSYS2_ARCH: "arm64"
QT_MSYS2_DIR: /
QT_QMAKE_DIR: /clangarm64/bin
QT_MSVC: false
QT_DEBUG: false
GO111MODULE: on
CGO_CFLAGS: "--target=aarch64-w64-mingw32 -O2"
CGO_CXXFLAGS: "--target=aarch64-w64-mingw32 -Wno-deprecated-declarations -Wno-ignored-attributes -DQT_CORE_LIB -O2"
CGO_LDFLAGS: "--target=aarch64-w64-mingw32 -L/clangarm64/lib -lQt5Widgets -lQt5Gui -lQt5Core -lQt5Network -lQt5Svg -lQt5Multimedia -lQt5PrintSupport -lQt5Qml -lQt5Quick -lstdc++ -lole32 -luuid -lws2_32 -luser32 -lgdi32 -lopengl32 -lwinmm"
CPATH: "/clangarm64/include/QtScriptTools/5.15.17/QtScriptTools/private:/clangarm64/include/QtScriptTools:/clangarm64/include/QtScript/5.15.17/QtScript/private:/clangarm64/include/QtScript:/clangarm64/include/QtRemoteObjects/5.15.17/QtRemoteObjects/private:/clangarm64/include/QtRemoteObjects:/clangarm64/include/QtQuick/5.15.17/QtQuick/private:/clangarm64/include/QtQuick:/clangarm64/include/QtQml/5.15.17/QtQml/private:/clangarm64/include/QtQml:/clangarm64/include/QtDesigner/5.15.17/QtDesigner/private:/clangarm64/include/QtDesigner:/clangarm64/include/QtPrintSupport/5.15.17/QtPrintSupport/private:/clangarm64/include/QtPrintSupport:/clangarm64/include/QtOpenGL/5.15.17/QtOpenGL/private:/clangarm64/include/QtOpenGL:/clangarm64/include/QtSvg/5.15.17/QtSvg/private:/clangarm64/include/QtSvg:/clangarm64/include/QtMultimedia/5.15.17/QtMultimedia/private:/clangarm64/include/QtMultimedia:/clangarm64/include/QtDBus/5.15.17/QtDBus/private:/clangarm64/include/QtDBus:/clangarm64/include/QtNetwork/5.15.17/QtNetwork/private:/clangarm64/include/QtNetwork:/clangarm64/include/QtWidgets/5.15.17/QtWidgets/private:/clangarm64/include/QtWidgets:/clangarm64/include/QtGui/5.15.17/QtGui/private:/clangarm64/include/QtGui:/clangarm64/include/QtCore/5.15.17/QtCore/private:/clangarm64/include/QtCore:/clangarm64/include"
LIBRARY_PATH: /clangarm64/lib
CC: "aarch64-w64-mingw32-clang"
CXX: "aarch64-w64-mingw32-clang++"
AR: "llvm-ar"
RANLIB: "llvm-ranlib"
NM: "llvm-nm"
PKG_CONFIG: "/clangarm64/bin/pkg-config"
PKG_CONFIG_PATH: "/clangarm64/lib/pkgconfig"
MSYSTEM: "CLANGARM64"
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
QT_BINDING_VER: "v0.0.0-20251021043539-c059a317d6ad"
steps:
- name: Setup MSYS2 (ARM64) and install Qt5
uses: msys2/setup-msys2@v2
with:
update: true
msystem: clangarm64
install: >
mingw-w64-clang-aarch64-toolchain
mingw-w64-clang-aarch64-llvm
mingw-w64-clang-aarch64-pkgconf
mingw-w64-clang-aarch64-angleproject
mingw-w64-clang-aarch64-qt5-base
mingw-w64-clang-aarch64-qt5-multimedia
mingw-w64-clang-aarch64-qt5-svg
mingw-w64-clang-aarch64-qt5-imageformats
mingw-w64-clang-aarch64-qt5-tools
mingw-w64-clang-aarch64-qt5-declarative
mingw-w64-clang-aarch64-qt5-remoteobjects
mingw-w64-clang-aarch64-qt5-script
mingw-w64-clang-aarch64-qt5-quickcontrols2
location: C:\a\
- name: Setup tools
shell: msys2 {0}
run: |
pacman --noconfirm -S sed git make tree zip unzip
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{ env.GOPATH }}\src\github.com\${{ github.repository }}
- name: Get dependencies
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/arm64/bin/:$PATH
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}
make deps
- name: Copy Qt tools (keep both names)
run: |
Get-ChildItem -Path "C:\a\msys64\clangarm64\bin\" -Filter "*-qt5.exe" | ForEach-Object {
$newName = $_.Name -replace "-qt5\.exe$", ".exe"
Copy-Item $_.FullName -Destination (Join-Path $_.Directory $newName)
}
shell: pwsh
- name: Get Qt binding for Go
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/arm64/bin/:$PATH
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}
go get github.com/akiyosi/qt@${{ env.QT_BINDING_VER }}
go get github.com/akiyosi/qt/internal/cmd@${{ env.QT_BINDING_VER }}
go get github.com/akiyosi/qt/internal/cmd/moc@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtdeploy@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtminimal@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtmoc@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtrcc@${{ env.QT_BINDING_VER }}
go install -v -tags=no_env github.com/akiyosi/qt/cmd/qtsetup@${{ env.QT_BINDING_VER }}
$(go env GOPATH)/bin/qtsetup -test=false
$(go env GOPATH)/bin/qtmoc desktop ./cmd/goneovim
- name: Test
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/arm64/bin:/clangarm64/bin:$PATH
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}
make test
- name: Build ARM64 resource
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/arm64/bin:/clangarm64/bin:$PATH
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}
/clangarm64/bin/llvm-windres -O coff -i cmd/goneovim/icon.rc -o cmd/goneovim/icon_windows_arm64.syso
- name: Strip incompatible .syso (amd64)
shell: msys2 {0}
run: |
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}
rm cmd/goneovim/icon_windows.syso
- name: Retrieve version
id: version-windows
run: |
cd ${{ env.GOPATH }}\src\github.com\${{ github.repository }}
echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
- name: Build
shell: msys2 {0}
run: |
export PATH=/c/hostedtoolcache/windows/go/${{ matrix.go-version }}/arm64/bin:/clangarm64/bin:$PATH
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}
$(go env GOPATH)/bin/qtdeploy build desktop ./cmd/goneovim
cp -pR runtime cmd/goneovim/deploy/windows/
- if: github.event_name == 'workflow_dispatch'
run: echo "ARCHIVE_NAME=goneovim-windows-arm64" >> $env:GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo "ARCHIVE_NAME=goneovim-windows-arm64" >> $env:GITHUB_ENV
- if: github.event_name == 'push'
run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-windows.outputs.GONEOVIM_VERSION }}-windows-arm64" >> $env:GITHUB_ENV
- name: Archive
shell: msys2 {0}
run: |
cd /c/a/goneovim/goneovim/src/github.com/${{ github.repository }}/cmd/goneovim/deploy
mv windows ${{ env.ARCHIVE_NAME }}
zip -r ${{ env.ARCHIVE_NAME }}.zip ${{ env.ARCHIVE_NAME }}
- name: Upload
uses: actions/upload-artifact@v4
with:
name: goneovim-windows-arm64
path: C:/a/goneovim/goneovim/src/github.com/${{ github.repository }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.zip
#################################################################
# FreeBSD
#################################################################
# freebsd:
# needs: [check-new-commit]
# strategy:
# matrix:
# go-version: [1.24.x]
# platform: [macos-latest]
# runs-on: ${{ matrix.platform }}
# steps:
# - name: Checkout code
# uses: actions/checkout@v4
# with:
# fetch-depth: 0
#
# - name: Retrieve version
# id: version-freebsd
# run: |
# echo "::set-output name=GONEOVIM_VERSION::$(git describe --tags)"
# echo "::set-output name=GONEOVIM_VERSION_HASH::$(git rev-parse HEAD)"
#
# - name: Build for freeBSD
# uses: cross-platform-actions/action@v0.13.0
# env:
# GOPATH: /home/runner/go
# QT_PKG_CONFIG: true
# QT_API: 5.13.0
# QT_DEBUG: false
# QT_STATIC: true
# GO111MODULE: on
# GOPROXY: https://goproxy.io
# CGO_CPPFLAGS: '-O3 -Wno-deprecated'
# with:
# environment_variables: GOPATH QT_PKG_CONFIG QT_API QT_DEBUG QT_STATIC GO111MODULE GOPROXY
# operating_system: freebsd
# architecture: x86_64
# version: '13.2'
# shell: bash
# memory: 12G
# cpu_count: 4
# run: |
# yes | sudo pkg install git go pkgconf
# yes | sudo pkg install devel/qt5
# yes | sudo pkg install gmake
# gmake qt_bindings
# gmake deps
# gmake app
#
# - if: github.event_name == 'workflow_dispatch'
# run: echo "ARCHIVE_NAME=goneovim-freebsd" >> $GITHUB_ENV
# - if: github.event_name == 'schedule'
# run: echo "ARCHIVE_NAME=goneovim-freebsd" >> $GITHUB_ENV
# - if: github.event_name == 'push'
# run: echo "ARCHIVE_NAME=goneovim-${{ steps.version-freebsd.outputs.GONEOVIM_VERSION }}-freebsd" >> $GITHUB_ENV
#
# - name: Archive
# run: |
# cd cmd/goneovim/deploy
# mv freebsd "$ARCHIVE_NAME"
# tar -jcvf "$ARCHIVE_NAME".tar.bz2 "$ARCHIVE_NAME"
#
# - name: Upload
# uses: actions/upload-artifact@v4
# with:
# name: goneovim-freebsd
# path: ${{ github.workspace }}/cmd/goneovim/deploy/${{ env.ARCHIVE_NAME }}.tar.bz2
publish:
# needs: [linux, windows, macos, freebsd]
needs: [linux-x86_64, linux-arm64, windows-x86_64, windows-arm64, macos-x86_64, macos-arm64]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y gettext-base
- if: github.event_name == 'workflow_dispatch'
run: echo "TAG_NAME=${{ github.event.inputs.tag_name }}" >> $GITHUB_ENV
- if: github.event_name == 'schedule'
run: echo 'TAG_NAME=nightly' >> $GITHUB_ENV
- if: github.event_name == 'push'
run: |
TAG_NAME=${{ github.ref }}
echo "TAG_NAME=${TAG_NAME#refs/tags/}" >> $GITHUB_ENV
- if: env.TAG_NAME == 'nightly'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
(echo 'SUBJECT=Goneovim Nightly build';
echo 'PRERELEASE=--prerelease') >> $GITHUB_ENV
gh release delete nightly --yes || true
git push origin :nightly || true
- if: env.TAG_NAME != 'nightly'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
(echo "SUBJECT=Goneovim $TAG_NAME";
echo 'PRERELEASE=') >> $GITHUB_ENV
- name: Publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release create $TAG_NAME $PRERELEASE --title "$SUBJECT" --target $GITHUB_SHA /home/runner/work/goneovim/goneovim/goneovim-macos-x86_64/* /home/runner/work/goneovim/goneovim/goneovim-macos-arm64/* /home/runner/work/goneovim/goneovim/goneovim-linux-x86_64/* /home/runner/work/goneovim/goneovim/goneovim-linux-arm64/* /home/runner/work/goneovim/goneovim/goneovim-windows-x86_64/* /home/runner/work/goneovim/goneovim/goneovim-windows-arm64/*