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
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[![CI](https://github.com/llerandi/json-tree-editor/actions/workflows/ci.yaml/badge.svg)](https://github.com/llerandi/json-tree-editor/actions/workflows/ci.yaml)
[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
[![Tauri v2](https://img.shields.io/badge/tauri-v2-blue?logo=tauri&logoColor=white)](https://tauri.app)
[![Tauri v1](https://img.shields.io/badge/tauri-v1-blue?logo=tauri&logoColor=white)](https://tauri.app)
[![Rust](https://img.shields.io/badge/rust-stable-orange?logo=rust&logoColor=white)](https://www.rust-lang.org)
[![Platform](https://img.shields.io/badge/platform-windows%20%7C%20macos%20%7C%20linux-lightgrey)](#building-for-production)

Expand Down Expand Up @@ -53,7 +53,7 @@ rustc --version
Once Rust is installed, run:

```
cargo install tauri-cli --version "^2.0" --locked
cargo install tauri-cli --version "^1.0" --locked
```

This downloads and compiles the CLI. It may take a few minutes the first time.
Expand Down
16 changes: 7 additions & 9 deletions src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,15 @@ name = "json-tree-editor"
version = "0.1.0"
edition = "2021"

# The lib target is required by Tauri's build process.
[lib]
name = "app_lib"
crate-type = ["staticlib", "cdylib", "rlib"]

[build-dependencies]
tauri-build = { version = "2", features = [] }
tauri-build = { version = "1", features = [] }

[dependencies]
tauri = { version = "2", features = [] }
tauri-plugin-dialog = "2"
tauri-plugin-fs = "2"
tauri = { version = "1", features = [
"dialog-save",
"dialog-open",
"fs-write-file",
"fs-read-file",
] }
serde = { version = "1", features = ["derive"] }
serde_json = "1"
13 changes: 0 additions & 13 deletions src-tauri/capabilities/default.json

This file was deleted.

14 changes: 0 additions & 14 deletions src-tauri/src/lib.rs

This file was deleted.

6 changes: 3 additions & 3 deletions src-tauri/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// On Windows in release mode this attribute hides the console window that
// would otherwise appear behind the app. It has no effect on other platforms.
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]

fn main() {
app_lib::run()
tauri::Builder::default()
.run(tauri::generate_context!())
.expect("error while running tauri application");
}
53 changes: 33 additions & 20 deletions src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,40 @@
{
"$schema": "https://schema.tauri.app/config/2",
"productName": "JSON Tree Editor",
"version": "0.1.0",
"identifier": "com.treeform.json-tree-editor",
"$schema": "../node_modules/@tauri-apps/cli/schema.json",
"build": {
"frontendDist": "../src"
"distDir": "../src"
},
"app": {
"package": {
"productName": "JSON Tree Editor",
"version": "0.1.0"
},
"tauri": {
"withGlobalTauri": true,
"allowlist": {
"all": false,
"dialog": {
"save": true,
"open": true
},
"fs": {
"readFile": true,
"writeFile": true,
"scope": ["**"]
}
},
"bundle": {
"active": true,
"identifier": "com.treeform.json-tree-editor",
"icon": [
"icons/32x32.png",
"icons/128x128.png",
"icons/128x128@2x.png",
"icons/icon.icns",
"icons/icon.ico"
]
},
"security": {
"csp": null
},
"windows": [
{
"title": "JSON Tree Editor",
Expand All @@ -17,20 +44,6 @@
"minHeight": 400,
"resizable": true
}
],
"security": {
"csp": null
}
},
"bundle": {
"active": true,
"targets": "all",
"icon": [
"icons/32x32.png",
"icons/128x128.png",
"icons/128x128@2x.png",
"icons/icon.icns",
"icons/icon.ico"
]
}
}
Loading
Loading