0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Rustとウェブ技術を用いてネイティブアプリをパッケージするTauri2.0のtauri.config.jsonまたはtauri.conf.jsonに書く項目です。

ルート

configファイルのトップに書く項目です。

  • productName:プロジェクト・アプリの名前です。
  • version:アプリのバージョンです。
  • identifier:識別子です。(例:com.kanade.app)

Build

開発サーバーの指定や、ビルドの前後に実行するコマンドの定義です。

  • beforeBuildCommand:ビルド前に実行するコマンドです。
  • beforeDevCommand:tauri devの前に実行するコマンドの定義です。
  • devUrl:開発サーバーのURLです。
  • frontendDist:ビルド時に読み込むdistのパスです。

app

appセクションはいくつかのセクションに分かれます。

security

  • csp
  • capabilities

Windows

Windowの定義を配列で行います。

  • title
  • width
  • height
  • resizable
  • fullscreen
  • decorations
  • transparent
  • fileDropEnabled
    これに限らず他にも項目はありますが、説明しきれません。
[
  {
     "title":"App"
  } 
]
  • trayIcon:タスクバーなどに表示するアイコンのパスです。

Bundles

アプリをバンドルする際のプラットフォームの設定です。

{
  "bundle": {
    "active": true,
    "targets": ["app", "dmg", "msi", "deb", "rpm"],
    "identifier": "com.example.app",
    "icon": ["icons/icon.icns", "icons/icon.ico", "icons/icon.png"],
    "resources": ["assets/data.json", "assets/config/"],
    "copyright": "",
    "category": "DeveloperTool",
    "shortDescription": "Short app description",
    "longDescription": "Longer description of the application.",
    "publisher": "Your Company",
    "publisherUrl": "https://example.com",
    "license": "MIT",
    "licenseFile": "LICENSE",
    "externalBin": ["bin/some-tool"],
    "fileAssociations": [
      {
        "ext": ["myext"],
        "mimeType": "application/x-myapp",
        "description": "My custom file type",
        "icon": "icons/file-icon.png"
      }
    ],

    "macOS": {
      "frameworks": [],
      "minimumSystemVersion": "10.13",
      "exceptionDomain": "",
      "signingIdentity": null,
      "entitlements": null,
      "exceptionDomains": {},
      "appCategory": "public.app-category.developer-tools",
      "dmg": {
        "background": "icons/dmg-background.png",
        "iconSize": 128,
        "windowSize": { "width": 600, "height": 400 }
      }
    },

    "windows": {
      "certificateThumbprint": null,
      "digestAlgorithm": "sha256",
      "timestampUrl": "http://timestamp.digicert.com",
      "wix": {
        "language": "en-US",
        "template": null,
        "fragmentPaths": [],
        "componentGroupRefs": [],
        "componentRefs": []
      }
    },

    "linux": {
      "deb": {
        "depends": ["libgtk-3-0", "libwebkit2gtk-4.0-37"]
      },
      "rpm": {
        "depends": ["gtk3", "webkit2gtk3"]
      },
      "appimage": {
        "bundleMedia": true
      }
    }
  }
}
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?