Skip to content

Commit 0966cc7

Browse files
committed
Initial commit
0 parents  commit 0966cc7

File tree

16 files changed

+591
-0
lines changed

16 files changed

+591
-0
lines changed

.ci/build.sh

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/bin/bash
2+
3+
set -x
4+
set -e
5+
6+
git -C externals/cetech1/ submodule update --init
7+
8+
zig build init
9+
zig build -Dexternals_optimize=Debug -Dwith_shaderc=false
10+
11+
ls -Rhan zig-out/

.github/workflows/test.yaml

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
name: Test
2+
3+
permissions:
4+
checks: write
5+
6+
on:
7+
pull_request:
8+
push:
9+
10+
concurrency:
11+
group: ${{ github.head_ref || github.run_id }}-${{ github.actor }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
validation:
16+
name: Validation
17+
runs-on: ubuntu-latest
18+
timeout-minutes: 1
19+
steps:
20+
- name: Checkout
21+
uses: actions/checkout@v4
22+
23+
- name: Read .zig-version
24+
id: zigversion
25+
uses: juliangruber/read-file-action@v1
26+
with:
27+
path: ./.zigversion
28+
- name: Install Zig
29+
uses: mlugg/setup-zig@v1
30+
with:
31+
version: ${{ steps.zigversion.outputs.content }}
32+
33+
- name: Lint
34+
run: zig fmt --check . --exclude externals/
35+
36+
# TODO: Fix me
37+
x86-64-linux:
38+
needs: ["validation"]
39+
name: x86-64 Linux
40+
runs-on: ubuntu-latest
41+
timeout-minutes: 20
42+
steps:
43+
- name: Checkout
44+
uses: actions/checkout@v4
45+
with:
46+
submodules: true
47+
48+
- name: Prepare
49+
uses: awalsh128/cache-apt-pkgs-action@latest
50+
with:
51+
packages: libdbus-1-dev
52+
version: 1.0
53+
54+
- name: Read .zig-version
55+
id: zigversion
56+
uses: juliangruber/read-file-action@v1
57+
with:
58+
path: ./.zigversion
59+
- name: Install Zig
60+
uses: mlugg/setup-zig@v1
61+
with:
62+
version: ${{ steps.zigversion.outputs.content }}
63+
64+
- name: Build
65+
run: .ci/build.sh
66+
67+
# FIXME: this works on cetech1 CI but not in this repo.
68+
# x86-64-macos:
69+
# needs: ["validation"]
70+
# name: x86-64 Macos
71+
# runs-on: macos-latest
72+
# timeout-minutes: 20
73+
# steps:
74+
# - name: Checkout
75+
# uses: actions/checkout@v4
76+
# with:
77+
# submodules: true
78+
79+
# - name: Read .zig-version
80+
# id: zigversion
81+
# uses: juliangruber/read-file-action@v1
82+
# with:
83+
# path: ./.zigversion
84+
# - name: Install Zig
85+
# uses: mlugg/setup-zig@v1
86+
# with:
87+
# version: ${{ steps.zigversion.outputs.content }}
88+
89+
# - name: Build
90+
# run: .ci/build.sh
91+
92+
# FIXME: this works on cetech1 CI but not in this repo.
93+
# x86-64-windows:
94+
# needs: ["validation"]
95+
# name: x86-64 Windows
96+
# runs-on: windows-latest
97+
# timeout-minutes: 20
98+
# steps:
99+
# - name: Checkout
100+
# uses: actions/checkout@v4
101+
# with:
102+
# submodules: true
103+
104+
# - name: Read .zig-version
105+
# id: zigversion
106+
# uses: juliangruber/read-file-action@v1
107+
# with:
108+
# path: ./.zigversion
109+
# - name: Install Zig
110+
# uses: mlugg/setup-zig@v1
111+
# with:
112+
# version: ${{ steps.zigversion.outputs.content }}
113+
114+
# - name: Build
115+
# shell: bash
116+
# run: .ci/build.sh

.gitignore

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# Build
2+
/build
3+
4+
# ZIG
5+
*zig-cache
6+
*zig-out
7+
8+
# VSCode
9+
10+
# MacOS
11+
*.DS_Store
12+
.DS_Store
13+
*.dylib
14+
15+
# Xcode
16+
*.pbxuser
17+
*.mode1v3
18+
*.mode2v3
19+
*.perspectivev3
20+
*.xcuserstate
21+
project.xcworkspace/
22+
xcuserdata/
23+
24+
kcov-output/
25+
26+
imgui.ini
27+
28+
_static.zig
29+
30+
# VSCode
31+
.vscode/launch.json
32+
.vscode/settings.json
33+
34+
# Fleet
35+
.fleet/settings.json
36+
.fleet/run.json
37+
38+
# temp folder for tests
39+
/fixtures/tmp
40+
41+
# folder for generated tmp data, cache and debug purpose files
42+
.ct_temp
43+

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "externals/cetech1"]
2+
path = externals/cetech1
3+
url = https://github.com/cyberegoorg/cetech1.git

.version

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
0.1.0-a1

.vscode/extensions.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"recommendations": [
3+
"ziglang.vscode-zig", // ZIG support
4+
"vadimcn.vscode-lldb", // Debugging support
5+
"Gruntfuggly.todo-tree", // Todo viewer
6+
"kdheepak.d2-markdown-preview", // D2 preview
7+
"oderwat.indent-rainbow", // Bring colors to life
8+
"MalcolmMielle.semantic-highlighting" // More colors to life
9+
]
10+
}

.zigversion

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2024.11.0-mach

README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# [CETech1](https://github.com/cyberegoorg/cetech1) minimal project
2+
3+
> [!IMPORTANT]
4+
> Work in progressssssssssssss
5+
6+
## Getting started
7+
8+
1. Create repository from this template.
9+
10+
2. [Get ZIG](https://cyberegoorg.github.io/cetech1/getting-started.html#get-zig)
11+
12+
3. [Get ZLS](https://cyberegoorg.github.io/cetech1/getting-started.html#zls)
13+
14+
4. Init
15+
16+
```sh
17+
git -C externals/cetech1/ submodule update --init
18+
zig build init
19+
```
20+
21+
5. Build
22+
23+
```sh
24+
zig build
25+
```
26+
27+
6. Create CETech1 project in `content` dir
28+
29+
```sh
30+
zig-out/bin/minimal --asset-root content/
31+
```
32+
33+
7. Add `content` dir with project to git
34+
35+
```sh
36+
git add content/
37+
```
38+
39+
8. Replace README.md with your own.
40+
41+
9. Have fun

0 commit comments

Comments
 (0)