Skip to content

Commit 8a0d415

Browse files
authored
Better features detection and much more (#1458)
1 parent 1a10059 commit 8a0d415

File tree

79 files changed

+1203
-723
lines changed

Some content is hidden

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

79 files changed

+1203
-723
lines changed

.github/workflows/linux_cli.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@ jobs:
1818
run: sudo apt update || true; sudo apt install libheif-dev libraw-dev ffmpeg -y
1919

2020
- name: Setup rust version
21-
run: rustup default stable
21+
run: rustup default 1.85.0
2222

2323
- name: Enable LTO
24+
if: ${{ github.ref == 'refs/heads/master' }}
2425
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
2526

2627
- name: Build Release with fast_image_resize

.github/workflows/linux_cli_eyra.yml

+1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ jobs:
2929
cd ..
3030
3131
- name: Enable LTO
32+
if: ${{ github.ref == 'refs/heads/master' }}
3233
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
3334

3435
- name: Build Release

.github/workflows/linux_gui.yml

+12-6
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,10 @@ jobs:
1515
- uses: actions/checkout@v4
1616

1717
- name: Setup rust version
18-
run: rustup default stable
18+
run: rustup default 1.85.0
1919

2020
- name: Enable LTO
21+
if: ${{ github.ref == 'refs/heads/master' }}
2122
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
2223

2324
- name: Build Release Krokiet
@@ -50,9 +51,10 @@ jobs:
5051
run: sudo apt update || true; sudo apt install libheif-dev libraw-dev -y
5152

5253
- name: Setup rust version
53-
run: rustup default stable
54+
run: rustup default 1.85.0
5455

5556
- name: Enable LTO
57+
if: ${{ github.ref == 'refs/heads/master' }}
5658
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
5759

5860
- name: Build Release Krokiet heif
@@ -85,9 +87,10 @@ jobs:
8587
run: sudo apt update || true; sudo apt install libgtk-4-dev libheif-dev libraw-dev -y
8688

8789
- name: Setup rust version
88-
run: rustup default stable
90+
run: rustup default 1.85.0
8991

9092
- name: Enable LTO
93+
if: ${{ github.ref == 'refs/heads/master' }}
9194
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
9295

9396
- name: Build Release Heif Libraw
@@ -130,9 +133,10 @@ jobs:
130133
run: sudo apt update || true; sudo apt install libgtk-4-dev libheif-dev libraw-dev librsvg2-dev wget fuse libfuse2 desktop-file-utils -y
131134

132135
- name: Setup rust version
133-
run: rustup default stable
136+
run: rustup default 1.85.0
134137

135138
- name: Enable LTO
139+
if: ${{ github.ref == 'refs/heads/master' }}
136140
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
137141

138142
- name: Build Release
@@ -173,7 +177,9 @@ jobs:
173177
rm -rf czkawka_gui
174178
cp target/release/czkawka_gui .
175179
strip czkawka_gui
176-
wget https://github.com/AppImageCommunity/pkg2appimage/releases/download/continuous/pkg2appimage--x86_64.AppImage -O pkg2.appimage
180+
wget https://github.com/qarmin/Automated-Fuzzer/releases/download/test/pkg2appimage-1eceb30-x86_64.AppImage -O pkg2.appimage
181+
# TODO - official link from below, no longer works and there is no official releases except continuous versions which have no stable version numbering
182+
# wget https://github.com/AppImageCommunity/pkg2appimage/releases/download/continuous/pkg2appimage--x86_64.AppImage -O pkg2.appimage
177183
chmod +x ./pkg2.appimage
178184
./pkg2.appimage misc/czkawka-appimage-recipe.yml
179185
mv out/Czkawka*.AppImage out/czkawka_gui-minimal.AppImage
@@ -205,7 +211,7 @@ jobs:
205211
run: sudo apt update || true; sudo apt install libgtk-4-dev libheif-dev libraw-dev librsvg2-dev wget fuse libfuse2 -y xvfb
206212

207213
- name: Setup rust version
208-
run: rustup default stable
214+
run: rustup default 1.85.0
209215

210216
- name: Test
211217
run: xvfb-run cargo test

.github/workflows/mac.yml

+112-33
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ env:
99
CARGO_TERM_COLOR: always
1010

1111
jobs:
12-
macos:
13-
runs-on: macos-latest
12+
macos_x86_64:
13+
runs-on: macos-13
1414
steps:
1515
- uses: actions/checkout@v4
1616

@@ -24,9 +24,10 @@ jobs:
2424
brew link --overwrite [email protected]
2525
2626
- name: Setup rust version
27-
run: rustup default stable
27+
run: rustup default 1.85.0
2828

2929
- name: Enable LTO
30+
if: ${{ github.ref == 'refs/heads/master' }}
3031
run: sed -i '' 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
3132

3233
- name: Build Release
@@ -35,55 +36,133 @@ jobs:
3536
- name: Store MacOS CLI
3637
uses: actions/upload-artifact@v4
3738
with:
38-
name: czkawka_cli-${{ runner.os }}
39+
name: czkawka_cli-${{ runner.os }}-x86_64
3940
path: target/release/czkawka_cli
4041

4142
- name: Store MacOS GUI
4243
uses: actions/upload-artifact@v4
4344
with:
44-
name: czkawka_gui-${{ runner.os }}
45+
name: czkawka_gui-${{ runner.os }}-x86_64
4546
path: target/release/czkawka_gui
4647

4748
- name: Store MacOS Krokiet
4849
uses: actions/upload-artifact@v4
4950
with:
50-
name: krokiet-${{ runner.os }}
51+
name: krokiet-${{ runner.os }}-x86_64
5152
path: target/release/krokiet
5253

5354
- name: Prepare files to release
5455
run: |
55-
mv target/release/czkawka_cli macos_czkawka_cli
56-
mv target/release/czkawka_gui macos_czkawka_gui
57-
mv target/release/krokiet macos_krokiet
56+
mv target/release/czkawka_cli macos_czkawka_cli_x86_64
57+
mv target/release/czkawka_gui macos_czkawka_gui_x86_64
58+
mv target/release/krokiet macos_krokiet_x86_64
59+
5860
- name: Release
5961
uses: softprops/action-gh-release@v2
6062
if: ${{ github.ref == 'refs/heads/master' }}
6163
with:
6264
tag_name: "Nightly"
6365
files: |
64-
macos_czkawka_cli
65-
macos_czkawka_gui
66-
macos_krokiet
66+
macos_czkawka_cli_x86_64
67+
macos_czkawka_gui_x86_64
68+
macos_krokiet_x86_64
69+
token: ${{ secrets.PAT_REPOSITORY }}
70+
71+
# TODO - compilation is broken, not sure why, if you want to use it you need to fix it(I'm too lazy and don't have MacOS)
72+
- name: Build Release Heif
73+
run: cargo build --release --features heif
74+
75+
- name: Store MacOS CLI Heif
76+
uses: actions/upload-artifact@v4
77+
with:
78+
name: czkawka_cli-${{ runner.os }}-heif-x86_64
79+
path: target/release/czkawka_cli
80+
81+
- name: Store MacOS GUI Heif
82+
uses: actions/upload-artifact@v4
83+
with:
84+
name: czkawka_gui-${{ runner.os }}-heif-x86_64
85+
path: target/release/czkawka_gui
86+
87+
- name: Store MacOS Krokiet Heif
88+
uses: actions/upload-artifact@v4
89+
with:
90+
name: krokiet-${{ runner.os }}-heif-x86_64
91+
path: target/release/krokiet
92+
93+
- name: Prepare files to release 2
94+
run: |
95+
mv target/release/czkawka_cli macos_czkawka_cli_heif_x86_64
96+
mv target/release/czkawka_gui macos_czkawka_gui_heif_x86_64
97+
mv target/release/krokiet macos_krokiet_heif_x86_64
98+
99+
- name: Release 2
100+
uses: softprops/action-gh-release@v2
101+
if: ${{ github.ref == 'refs/heads/master' }}
102+
with:
103+
tag_name: "Nightly"
104+
files: |
105+
macos_czkawka_cli_heif_x86_64
106+
macos_czkawka_gui_heif_x86_64
107+
macos_krokiet_heif_x86_64
67108
token: ${{ secrets.PAT_REPOSITORY }}
68109

69-
# # TODO - compilation is broken, not sure why
70-
# - name: Build Release Heif
71-
# run: cargo build --release --features heif
72-
#
73-
# - name: Store MacOS CLI Heif
74-
# uses: actions/upload-artifact@v4
75-
# with:
76-
# name: czkawka_cli-${{ runner.os }}-heif
77-
# path: target/release/czkawka_cli
78-
#
79-
# - name: Store MacOS GUI Heif
80-
# uses: actions/upload-artifact@v4
81-
# with:
82-
# name: czkawka_gui-${{ runner.os }}-heif
83-
# path: target/release/czkawka_gui
84-
#
85-
# - name: Store MacOS Krokiet Heif
86-
# uses: actions/upload-artifact@v4
87-
# with:
88-
# name: krokiet-${{ runner.os }}-heif
89-
# path: target/release/krokiet
110+
macos_arm:
111+
runs-on: macos-latest
112+
steps:
113+
- uses: actions/checkout@v4
114+
115+
- name: Install Homebrew
116+
run: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
117+
118+
- name: Install GTK4
119+
run: |
120+
brew link --overwrite [email protected]
121+
brew install rust gtk4 libheif || true
122+
brew link --overwrite [email protected]
123+
124+
- name: Setup rust version
125+
run: rustup default 1.85.0
126+
127+
- name: Enable LTO
128+
if: ${{ github.ref == 'refs/heads/master' }}
129+
run: sed -i '' 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
130+
131+
- name: Build Release
132+
run: cargo build --release
133+
134+
- name: Store MacOS CLI
135+
uses: actions/upload-artifact@v4
136+
with:
137+
name: czkawka_cli-${{ runner.os }}-arm
138+
path: target/release/czkawka_cli
139+
140+
- name: Store MacOS GUI
141+
uses: actions/upload-artifact@v4
142+
with:
143+
name: czkawka_gui-${{ runner.os }}-arm
144+
path: target/release/czkawka_gui
145+
146+
- name: Store MacOS Krokiet
147+
uses: actions/upload-artifact@v4
148+
with:
149+
name: krokiet-${{ runner.os }}-arm
150+
path: target/release/krokiet
151+
152+
- name: Prepare files to release
153+
run: |
154+
mv target/release/czkawka_cli macos_czkawka_cli_arm
155+
mv target/release/czkawka_gui macos_czkawka_gui_arm
156+
mv target/release/krokiet macos_krokiet_arm
157+
158+
- name: Release
159+
uses: softprops/action-gh-release@v2
160+
if: ${{ github.ref == 'refs/heads/master' }}
161+
with:
162+
tag_name: "Nightly"
163+
files: |
164+
macos_czkawka_cli_arm
165+
macos_czkawka_gui_arm
166+
macos_krokiet_arm
167+
token: ${{ secrets.PAT_REPOSITORY }}
168+
# TODO - arm builds not works now with heif

.github/workflows/minimial_version.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
run: sudo apt update || true; sudo apt install libgtk-4-dev libheif-dev libraw-dev ffmpeg -y
1919

2020
- name: Setup rust version
21-
run: rustup default 1.82.0
21+
run: rustup default 1.85.0
2222

2323
- name: Build
2424
run: |

.github/workflows/quality.yml

+6
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ jobs:
1717
- name: Install Gtk 4
1818
run: sudo apt update || true; sudo apt install -y libgtk-4-dev libraw-dev libheif-dev libavif-dev libdav1d-dev -y
1919

20+
- name: Setup rust version
21+
run: |
22+
rustup default 1.85.0
23+
rustup component add rustfmt
24+
rustup component add clippy
25+
2026
- name: Check the format
2127
run: cargo fmt --all -- --check
2228

.github/workflows/windows.yml

+7-1
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,11 @@ jobs:
2424
2525
- name: Setup rust version
2626
run: |
27+
rustup default 1.85.0
2728
rustup target add x86_64-pc-windows-gnu
2829
2930
- name: Enable LTO
31+
if: ${{ github.ref == 'refs/heads/master' }}
3032
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
3133

3234
- name: Compile Krokiet
@@ -86,9 +88,10 @@ jobs:
8688
cp a/sd-v1.0.0-x86_64-pc-windows-gnu/sd.exe .
8789
8890
- name: Setup rust version
89-
run: rustup default stable-x86_64-pc-windows-gnu
91+
run: rustup default 1.85.0-x86_64-pc-windows-gnu
9092

9193
- name: Enable LTO
94+
if: ${{ github.ref == 'refs/heads/master' }}
9295
run: sed -i 's/#lto = "thin"/lto = "thin"/g' Cargo.toml
9396

9497
- name: Compile Krokiet
@@ -148,6 +151,7 @@ jobs:
148151
dnf install curl wget2 unzip mingw64-bzip2.noarch mingw64-poppler mingw64-poppler-glib mingw32-python3 rust-gio-devel adwaita-icon-theme -y && dnf clean all -y
149152
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
150153
source "$HOME/.cargo/env"
154+
rustup default 1.85.0
151155
rustup target add x86_64-pc-windows-gnu
152156
153157
- name: Cross compile for Windows
@@ -215,6 +219,7 @@ jobs:
215219
dnf install curl wget2 unzip mingw64-bzip2.noarch mingw64-poppler mingw64-poppler-glib mingw32-python3 rust-gio-devel adwaita-icon-theme -y && dnf clean all -y
216220
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
217221
source "$HOME/.cargo/env"
222+
rustup default 1.85.0
218223
rustup target add x86_64-pc-windows-gnu
219224
220225
- name: Cross compile for Windows
@@ -290,6 +295,7 @@ jobs:
290295
dnf install curl wget2 unzip mingw64-bzip2.noarch mingw64-poppler mingw64-poppler-glib mingw32-python3 rust-gio-devel adwaita-icon-theme -y && dnf clean all -y
291296
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
292297
source "$HOME/.cargo/env"
298+
rustup default 1.85.0
293299
rustup target add x86_64-pc-windows-gnu
294300
295301
- name: Show console window on windows

0 commit comments

Comments
 (0)