Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,10 @@ jobs:
run: |
rustup component add rustfmt
cargo fmt -- --check
- name: Run clippy linter
run: |
mkdir ../dist
rustup component add clippy
cargo clippy --all-targets --all-features -- -D warnings
- name: Run tests
run: cargo test --locked --no-fail-fast
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@ dist-ssr
*.db
*.db-shm
*.db-wal

.direnv
.envrc
16 changes: 8 additions & 8 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

114 changes: 59 additions & 55 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,64 +5,68 @@
rust-overlay.url = "github:oxalica/rust-overlay";
};

outputs = { self, nixpkgs, flake-utils, rust-overlay }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
overlays = [ rust-overlay.overlays.default ];
};
outputs = {
self,
nixpkgs,
flake-utils,
rust-overlay,
}:
flake-utils.lib.eachDefaultSystem (system: let
pkgs = import nixpkgs {
inherit system;
overlays = [rust-overlay.overlays.default];
};

toolchain = pkgs.rust-bin.stable.latest.default.override {
extensions = ["rust-analyzer" "rust-src" "rustfmt" "clippy"];
targets = ["wasm32-unknown-unknown"];
};
packages = with pkgs; [
cargo
cargo-tauri
toolchain
rust-analyzer-unwrapped
nodejs_18
nodePackages.pnpm
trunk
];
nativeBuildPackages = with pkgs; [
pkg-config
dbus
openssl
glib
gtk3
libsoup
webkitgtk_4_0
librsvg
protobuf
libayatana-appindicator
];
libraries = with pkgs; [
gtk3
cairo
gdk-pixbuf
glib
dbus
openssl
librsvg
libsoup_3
webkitgtk_4_0
libayatana-appindicator
];
in {
devShells.default = pkgs.mkShell {
buildInputs = packages;
nativeBuildInputs = nativeBuildPackages;
shellHook = with pkgs; ''
export LD_LIBRARY_PATH="${
lib.makeLibraryPath libraries
}:$LD_LIBRARY_PATH"
export OPENSSL_INCLUDE_DIR="${openssl.dev}/include/openssl"
export OPENSSL_LIB_DIR="${openssl.out}/lib"
export OPENSSL_ROOT_DIR="${openssl.out}"
export RUST_SRC_PATH="${toolchain}/lib/rustlib/src/rust/library"
'';
};
});
packages = with pkgs; [
cargo
cargo-tauri
toolchain
rust-analyzer-unwrapped
nodejs_18
nodePackages.pnpm
trunk
];
nativeBuildPackages = with pkgs; [
pkg-config
dbus
openssl
glib
gtk3
libsoup_2_4
webkitgtk_4_0
librsvg
protobuf
libayatana-appindicator
];
libraries = with pkgs; [
gtk3
cairo
gdk-pixbuf
glib
dbus
openssl
librsvg
libsoup_3
webkitgtk_4_0
libayatana-appindicator
];
in {
devShells.default = pkgs.mkShell {
buildInputs = packages;
nativeBuildInputs = nativeBuildPackages;
shellHook = with pkgs; ''
export LD_LIBRARY_PATH="${
lib.makeLibraryPath libraries
}:$LD_LIBRARY_PATH"
export OPENSSL_INCLUDE_DIR="${openssl.dev}/include/openssl"
export OPENSSL_LIB_DIR="${openssl.out}/lib"
export OPENSSL_ROOT_DIR="${openssl.out}"
export RUST_SRC_PATH="${toolchain}/lib/rustlib/src/rust/library"
'';
};
});
}
66 changes: 33 additions & 33 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "defguard-client",
"private": false,
"version": "1.2.3",
"version": "1.2.4",
"type": "module",
"scripts": {
"dev": "npm-run-all --parallel vite typesafe-i18n",
Expand Down Expand Up @@ -41,12 +41,12 @@
},
"dependencies": {
"@floating-ui/react": "^0.26.28",
"@hookform/resolvers": "^3.9.1",
"@hookform/resolvers": "^3.10.0",
"@ladle/react": "^4.1.2",
"@react-hook/resize-observer": "^2.0.2",
"@stablelib/base64": "^1.0.1",
"@stablelib/x25519": "^1.0.3",
"@tanstack/query-core": "^5.62.8",
"@tanstack/query-core": "^5.74.3",
"@tanstack/react-virtual": "3.0.0-beta.54",
"@tauri-apps/api": "^1.6.0",
"@types/byte-size": "^8.1.2",
Expand All @@ -61,66 +61,66 @@
"file-saver": "^2.0.5",
"framer-motion": "^10.18.0",
"get-text-width": "^1.0.3",
"html-react-parser": "^5.2.1",
"itertools": "^2.3.2",
"html-react-parser": "^5.2.3",
"itertools": "^2.4.1",
"lodash-es": "^4.17.21",
"merge-refs": "^1.3.0",
"p-timeout": "^6.1.3",
"p-timeout": "^6.1.4",
"prop-types": "^15.8.1",
"radash": "^11.0.0",
"react": "^18.3.1",
"react-auth-code-input": "^3.2.1",
"react-click-away-listener": "^2.2.4",
"react-click-away-listener": "^2.4.0",
"react-dom": "^18.3.1",
"react-hook-form": "^7.54.1",
"react-hook-form": "^7.55.0",
"react-loading-skeleton": "^3.5.0",
"react-markdown": "^9.0.1",
"react-markdown": "^9.1.0",
"react-qr-code": "^2.0.15",
"react-router-dom": "^6.28.0",
"react-virtualized-auto-sizer": "^1.0.25",
"recharts": "^2.15.0",
"react-router-dom": "^6.30.0",
"react-virtualized-auto-sizer": "^1.0.26",
"recharts": "^2.15.2",
"rehype-sanitize": "^6.0.0",
"rxjs": "^7.8.1",
"rxjs": "^7.8.2",
"tauri-plugin-log-api": "github:tauri-apps/tauri-plugin-log",
"tauri-plugin-window-state-api": "github:tauri-apps/tauri-plugin-window-state#v1",
"use-breakpoint": "^4.0.5",
"zod": "^3.24.1",
"zustand": "^5.0.2"
"use-breakpoint": "^4.0.6",
"zod": "^3.24.2",
"zustand": "^5.0.3"
},
"devDependencies": {
"@hookform/devtools": "^4.3.3",
"@hookform/devtools": "^4.4.0",
"@svgr/cli": "^8.1.0",
"@tanstack/react-query": "^5.62.8",
"@tanstack/react-query-devtools": "^5.62.8",
"@tanstack/react-query": "^5.74.3",
"@tanstack/react-query-devtools": "^5.74.3",
"@tauri-apps/cli": "^1.6.3",
"@types/file-saver": "^2.0.7",
"@types/lodash-es": "^4.17.12",
"@types/node": "^20.17.10",
"@types/react": "^18.3.17",
"@types/react-dom": "^18.3.5",
"@types/node": "^20.17.30",
"@types/react": "^18.3.20",
"@types/react-dom": "^18.3.6",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"@typescript-eslint/parser": "^6.21.0",
"@vitejs/plugin-react": "^4.3.4",
"@vitejs/plugin-react-swc": "^3.7.2",
"autoprefixer": "^10.4.20",
"@vitejs/plugin-react": "^4.4.0",
"@vitejs/plugin-react-swc": "^3.9.0",
"autoprefixer": "^10.4.21",
"eslint": "^8.57.1",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-react": "^7.37.2",
"eslint-plugin-prettier": "^5.2.6",
"eslint-plugin-react": "^7.37.5",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-react-refresh": "^0.4.16",
"eslint-plugin-react-refresh": "^0.4.19",
"eslint-plugin-simple-import-sort": "^10.0.0",
"npm-run-all": "^4.1.5",
"postcss": "^8.4.49",
"sass": "^1.83.0",
"postcss": "^8.5.3",
"sass": "^1.86.3",
"typedoc": "^0.25.13",
"typesafe-i18n": "^5.26.2",
"typescript": "^5.2.2",
"typescript": "^5.8.3",
"typescript-eslint-language-service": "^5.0.5",
"vite": "^4.5.5"
"vite": "^4.5.13"
},
"volta": {
"node": "20.5.1"
}
}
}
Loading