-
-
Notifications
You must be signed in to change notification settings - Fork 14k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cargo-tauri.hook: init #335751
cargo-tauri.hook: init #335751
Conversation
I will look into documenting this as this will help build Tauri apps on nix |
And soon bun I am looking to make a hook |
They seem good. I don't have time unfortunately to review and help with the rest of the PR :/, so I'm unsubscribing myself. |
Editorconfig check is failing Apart from that this looks good. |
because of newer rust version, I got an error when testing treedome. I can make a fix and a quick release, can the new release be in this PR? |
Not really sure what to do there as it's failing due to an icon file
As said in the original comment, this is due to the
Once the update for treedome is merged into master, you can run |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The editorconfig CI test giving an error is the canary in the coalmine. nixpkgs should have as little vendored code as possible, and it's quite easy to make a repository for this example app.
aa6497a
to
3b40326
Compare
I will look into using this once I have a bun install/config hook. |
3b40326
to
4ada60a
Compare
Fixed merge conflict with #335795. Treedome should build now |
Result of 4 packages marked as broken and skipped:
2 packages failed to build:
|
6043d53
to
d90dd95
Compare
This hook isn't meant for developers to package and distribute their apps outside of nixpkgs. Again, this is an implementation detail; there would be no point in outputting an appimage, deb package, etc If you really wanted to do this though, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution, Seth (@getchoo)!
I'm approving. This looks good to me. I plan on merging in another day or so unless someone in the greater Rust-in-nixpkgs community requests changes. (CC @emilazy?)
The build failure of insulator2
is part of #332957.
In what I hope is a my-system-issue, both on master and on this PR, I can't run any of the binaries to validate that they're functioning.
For example,
** (kiwi-talk:248290): WARNING **: 12:20:51.751: webkit_settings_set_enable_offline_web_application_cache is deprecated and does nothing.
(kiwi-talk:248290): Gtk-CRITICAL **: 12:20:51.860: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed
Gdk-Message: 12:20:52.015: Error 71 (Protocol error) dispatching to Wayland display.
I pretty strongly suspect this is about how I've configured my system, though, so I'm certainly not blocking this PR on investigating that.
Result of nixpkgs-review pr 335751
run on x86_64-linux 1
1 package marked as broken and skipped:
- cinny-desktop
2 packages blacklisted:
- nixos-install-tools
- tests.nixos-functions.nixos-test
1 package failed to build:
- insulator2
11 packages built:
- cargo-tauri
- en-croissant
- gitbutler
- kiwitalk
- modrinth-app
- modrinth-app-unwrapped
- mouse-actions-gui
- nixpkgs-manual
- pot
- surrealist
- treedome
Specifically: - Tighten dependencies by only listing what's needed to build - Better sorting things - Adding `meta.changelog`
d90dd95
to
26b1cef
Compare
Rebased to fix merge conflicts with the release notes |
Description of changes
With Tauri apps getting more popular and added to nixpkgs, I believe it's time we share the tedious setup required to build them. This PR introduces a new hook in
cargo-tauri.hook
that builds on top ofrustPlatform.buildRustPackage
(or more acurately, its hooks) to leverage Tauri's bundling feature in creating packages. It is compatible with the two primary targets we share with Tauri -- Linux and macOS -- and meant to be used alongside pre-existing tools for package managers such as npm, pnpm, and yarnSupersedes #318117
CC @doronbehar for changes made to
yarnConfigHook
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Result of
nixpkgs-review
run on x86_64-linux 15 packages failed to build:
24 packages built:
powerdns-admin
has been broken since 574c80aThe remaining packages fail with the now infamous
Add a 👍 reaction to pull requests you find important.