Skip to content

Commit 47d05fb

Browse files
Corex Generators + New Components (#25)
1 parent 7e68672 commit 47d05fb

File tree

3,095 files changed

+859132
-37307
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,095 files changed

+859132
-37307
lines changed

.github/workflows/elixir.yml

Lines changed: 186 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Elixir CI
1+
name: CI
22

33
on:
44
push:
@@ -9,42 +9,68 @@ on:
99
permissions:
1010
contents: read
1111

12+
env:
13+
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
14+
1215
jobs:
1316
unit-tests:
14-
name: Unit tests
15-
runs-on: ubuntu-22.04
17+
name: Unit tests (OTP ${{ matrix.otp }} | Elixir ${{ matrix.elixir }})
18+
runs-on: ubuntu-24.04
1619
env:
1720
MIX_ENV: test
1821
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19-
22+
23+
strategy:
24+
matrix:
25+
include:
26+
- elixir: 1.15.8
27+
otp: 25.3.2.9
28+
- elixir: 1.18.4
29+
otp: 27.3
30+
- elixir: 1.18.4
31+
otp: 28.0.1
32+
2033
steps:
21-
- uses: actions/checkout@v4
22-
with:
23-
fetch-depth: 0
24-
25-
- name: Set up Elixir
26-
uses: erlef/setup-beam@v1
27-
with:
28-
elixir-version: '1.15.2'
29-
otp-version: '26.0'
30-
31-
- name: Restore dependencies cache
32-
uses: actions/cache@v3
33-
with:
34-
path: deps
35-
key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }}
36-
restore-keys: ${{ runner.os }}-mix-
37-
38-
- name: Install dependencies
39-
run: mix deps.get
40-
41-
- name: Run tests and post coverage to Coveralls
42-
run: mix coveralls.github
34+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
35+
with:
36+
fetch-depth: 0
37+
38+
- name: Set up Elixir
39+
uses: erlef/setup-beam@3580539ceec3dc05b0ed51e9e10b08eb7a7c2bb4
40+
with:
41+
elixir-version: ${{ matrix.elixir }}
42+
otp-version: ${{ matrix.otp }}
43+
44+
- name: Restore dependencies cache
45+
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306
46+
with:
47+
path: |
48+
deps
49+
_build
50+
key: deps-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }}
51+
restore-keys: |
52+
deps-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}
53+
54+
- name: Install dependencies
55+
run: mix deps.get
56+
57+
- name: Run tests and post coverage to Coveralls
58+
run: mix coveralls.github
4359

4460
e2e-tests:
45-
name: E2E tests
46-
runs-on: ubuntu-22.04
47-
61+
name: E2E tests (OTP ${{ matrix.otp }} | Elixir ${{ matrix.elixir }})
62+
runs-on: ubuntu-24.04
63+
64+
strategy:
65+
matrix:
66+
include:
67+
- elixir: 1.15.8
68+
otp: 25.3.2.9
69+
- elixir: 1.18.4
70+
otp: 27.3
71+
- elixir: 1.18.4
72+
otp: 28.0.1
73+
4874
services:
4975
postgres:
5076
image: postgres:15
@@ -59,37 +85,135 @@ jobs:
5985
--health-retries 5
6086
ports:
6187
- 5432:5432
62-
88+
89+
steps:
90+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
91+
92+
- name: Set up Elixir
93+
uses: erlef/setup-beam@3580539ceec3dc05b0ed51e9e10b08eb7a7c2bb4
94+
with:
95+
elixir-version: ${{ matrix.elixir }}
96+
otp-version: ${{ matrix.otp }}
97+
98+
- name: Restore E2E dependencies cache
99+
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306
100+
with:
101+
path: |
102+
e2e/deps
103+
e2e/_build
104+
key: deps-e2e-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('e2e/mix.lock') }}
105+
restore-keys: |
106+
deps-e2e-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}
107+
108+
- name: Install E2E dependencies
109+
working-directory: e2e
110+
run: mix deps.get
111+
env:
112+
MIX_ENV: test
113+
114+
- name: Setup database
115+
working-directory: e2e
116+
run: mix ecto.setup
117+
env:
118+
MIX_ENV: test
119+
120+
- name: Run E2E tests
121+
working-directory: e2e
122+
run: mix test
123+
env:
124+
MIX_ENV: test
125+
126+
installer-tests:
127+
name: Installer tests (OTP ${{ matrix.otp }} | Elixir ${{ matrix.elixir }})
128+
runs-on: ubuntu-24.04
129+
130+
strategy:
131+
matrix:
132+
include:
133+
- elixir: 1.15.8
134+
otp: 25.3.2.9
135+
- elixir: 1.18.4
136+
otp: 27.3
137+
- elixir: 1.18.4
138+
otp: 28.0.1
139+
140+
steps:
141+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
142+
143+
- name: Set up Elixir
144+
uses: erlef/setup-beam@3580539ceec3dc05b0ed51e9e10b08eb7a7c2bb4
145+
with:
146+
elixir-version: ${{ matrix.elixir }}
147+
otp-version: ${{ matrix.otp }}
148+
149+
- name: Restore installer dependencies cache
150+
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306
151+
with:
152+
path: |
153+
installer/deps
154+
installer/_build
155+
key: deps-installer-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('installer/mix.lock') }}
156+
restore-keys: |
157+
deps-installer-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}
158+
159+
- name: Install installer dependencies
160+
working-directory: installer
161+
run: mix deps.get
162+
163+
- name: Run installer tests
164+
working-directory: installer
165+
run: mix test
166+
167+
integration-tests:
168+
name: Integration tests (OTP ${{ matrix.otp }} | Elixir ${{ matrix.elixir }})
169+
runs-on: ubuntu-24.04
170+
171+
strategy:
172+
matrix:
173+
include:
174+
- elixir: 1.15.8
175+
otp: 25.3.2.9
176+
- elixir: 1.17.3
177+
otp: 27.1.2
178+
179+
services:
180+
postgres:
181+
image: postgres:15
182+
env:
183+
POSTGRES_USER: postgres
184+
POSTGRES_PASSWORD: postgres
185+
POSTGRES_DB: postgres
186+
options: >-
187+
--health-cmd pg_isready
188+
--health-interval 10s
189+
--health-timeout 5s
190+
--health-retries 5
191+
ports:
192+
- 5432:5432
193+
63194
steps:
64-
- uses: actions/checkout@v4
65-
66-
- name: Set up Elixir
67-
uses: erlef/setup-beam@v1
68-
with:
69-
elixir-version: '1.15.2'
70-
otp-version: '26.0'
71-
72-
- name: Restore E2E dependencies cache
73-
uses: actions/cache@v3
74-
with:
75-
path: e2e/deps
76-
key: ${{ runner.os }}-mix-e2e-${{ hashFiles('e2e/mix.lock') }}
77-
restore-keys: ${{ runner.os }}-mix-e2e-
78-
79-
- name: Install E2E dependencies
80-
working-directory: e2e
81-
run: mix deps.get
82-
env:
83-
MIX_ENV: test
84-
85-
- name: Setup database
86-
working-directory: e2e
87-
run: mix ecto.setup
88-
env:
89-
MIX_ENV: test
90-
91-
- name: Run E2E tests
92-
working-directory: e2e
93-
run: mix test
94-
env:
95-
MIX_ENV: test
195+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
196+
197+
- name: Set up Elixir
198+
uses: erlef/setup-beam@3580539ceec3dc05b0ed51e9e10b08eb7a7c2bb4
199+
with:
200+
elixir-version: ${{ matrix.elixir }}
201+
otp-version: ${{ matrix.otp }}
202+
203+
- name: Restore integration test dependencies cache
204+
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306
205+
with:
206+
path: |
207+
integration_test/deps
208+
integration_test/_build
209+
key: deps-integration-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('integration_test/mix.lock') }}
210+
restore-keys: |
211+
deps-integration-${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}
212+
213+
- name: Install integration test dependencies
214+
working-directory: integration_test
215+
run: mix deps.get
216+
217+
- name: Run integration tests
218+
working-directory: integration_test
219+
run: mix test --exclude database:mysql --exclude database:mssql --timeout 600000

.gitignore

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,13 @@ corex-*.tar
3333

3434
/.expert/
3535

36-
/installer/
37-
38-
/integration_test/
39-
40-
/my_app/
36+
/installer/_build/
37+
/installer/assets/
38+
/installer/deps/
39+
/installer/doc/
40+
/installer/phx_new-*.ez
41+
/installer/tmp/
42+
/installer/cover/
43+
44+
/integration_test/_build/
45+
/integration_test/deps/

.sobelow-conf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[exit: false, format: "txt", ignore_files: [], ignore: ["Traversal.FileModule", "RCE.EEx"], out: nil, private: false, router: nil, skip: false, threshold: :low, verbose: false, version: false]

0 commit comments

Comments
 (0)