Mobile Tauri logo

Mobile Tauri

Community
felvieira
mobile-tauri

Implementa e empacota aplicacoes mobile e desktop com Tauri. Trigger em: "mobile", "Tauri", "APK", "app nativo", "desktop app", "Windows app", "macOS app", "Android", "cross-platform", "build nativo", "executável", ".exe", ".dmg", ".deb", ".AppImage", "notificação nativa", "file system nativo".

Overview

Publisherfelvieira
Repositoryclaude-skills-fv
Skill namemobile-tauri
Stars
28
Forks
5
Bundled files
Instructions only
LicenseApache-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by felvieira on GitHub. Read the source before you install it.

Installation

Install the Mobile Tauri AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/felvieira/claude-skills-fv/tree/main/skills/15-mobile-tauri
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/felvieira/claude-skills-fv.git /tmp/claude-skills-fv
mkdir -p .claude/skills
cp -r /tmp/claude-skills-fv/skills/15-mobile-tauri .claude/skills/mobile-tauri
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Mobile Tauri in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Mobile Tauri on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Mobile Tauri is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Mobile/Desktop Developer - Tauri v2 (OPCIONAL)

Skill OPCIONAL. Usa Tauri para empacotar o frontend web como app nativo para Android, Windows, macOS e Linux.

Governanca Global

Esta skill segue GLOBAL.md, policies/execution.md, policies/handoffs.md, policies/quality-gates.md, policies/token-efficiency.md, policies/stack-flexibility.md, policies/tool-safety.md e policies/evals.md.

Para setup detalhado, permissoes e builds nativos, consultar docs/skill-guides/mobile-tauri.md apenas quando necessario.

Quando Usar

  • adaptar projeto web para app desktop ou mobile via Tauri
  • configurar build nativo, permissao e integracao com APIs nativas

Quando Nao Usar

  • quando o projeto nao precisa de distribuicao nativa
  • para deploy web padrao sem camada nativa

Entradas Esperadas

  • frontend web funcional
  • restricoes de plataforma e distribuicao
  • requisitos de permissao, storage e notificacao

Saidas Esperadas

  • estrategia de empacotamento nativo
  • configuracao de permissao e build coerentes
  • handoff claro para QA/Deploy

Responsabilidades

  1. Configurar projeto Tauri no repositório existente
  2. Adaptar frontend para mobile/desktop (navegação, safe areas, responsividade)
  3. Gerar builds nativos (APK, .exe/.msi, .dmg, .deb/.AppImage)
  4. Configurar permissões nativas com princípio de menor privilégio
  5. Implementar features nativas (notificações, file system, shell)
  6. Otimizar performance para dispositivos mobile de baixo custo

Stack

Framework:    Tauri v2
Frontend:     Mesmo React/Next.js do projeto web
Side-car:     Rust (via Tauri core)
Build:        Cargo + Tauri CLI
Android:      Tauri Android plugin → APK
Desktop:      Windows (.exe/.msi), macOS (.dmg), Linux (.deb/.AppImage)

Setup

bash
npm install -D @tauri-apps/cli@latest
npx tauri init
npm install @tauri-apps/api@latest
npm install @tauri-apps/plugin-notification @tauri-apps/plugin-fs @tauri-apps/plugin-shell @tauri-apps/plugin-http

Configuracao Base

json
{
  "$schema": "https://raw.githubusercontent.com/nicogaldamez/tauri-schema/refs/heads/main/tauri.conf.json",
  "build": {
    "beforeBuildCommand": "npm run build",
    "beforeDevCommand": "npm run dev",
    "frontendDist": "../out",
    "devUrl": "http://localhost:3000"
  },
  "productName": "MeuApp",
  "version": "1.0.0",
  "identifier": "com.empresa.meuapp",
  "app": {
    "security": {
      "csp": "default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data: https:; connect-src 'self' https://api.empresa.com"
    },
    "windows": [
      {
        "title": "MeuApp",
        "width": 1024,
        "height": 768,
        "minWidth": 360,
        "minHeight": 640,
        "resizable": true,
        "fullscreen": false
      }
    ]
  },
  "bundle": {
    "active": true,
    "icon": [
      "icons/32x32.png",
      "icons/128x128.png",
      "icons/128x128@2x.png",
      "icons/icon.icns",
      "icons/icon.ico"
    ],
    "targets": "all",
    "windows": {
      "wix": {
        "language": "pt-BR"
      }
    },
    "macOS": {
      "minimumSystemVersion": "10.15"
    },
    "linux": {
      "deb": {
        "depends": ["libwebkit2gtk-4.1-0", "libssl3"]
      }
    }
  },
  "plugins": {
    "notification": {
      "enabled": true
    },
    "fs": {
      "scope": {
        "allow": ["$APPDATA/**", "$DOWNLOAD/**"],
        "deny": ["$HOME/.ssh/**"]
      }
    }
  }
}

Adaptacoes Mobile

Deteccao de Plataforma

typescript
import { platform } from '@tauri-apps/plugin-os';

function isTauri(): boolean {
  return typeof window !== 'undefined' && '__TAURI__' in window;
}

async function getPlatform(): Promise<'android' | 'ios' | 'windows' | 'macos' | 'linux' | 'web'> {
  if (!isTauri()) return 'web';
  const p = await platform();
  return p as 'android' | 'ios' | 'windows' | 'macos' | 'linux';
}

Hook de Navegacao Mobile

typescript
import { useState, useEffect } from 'react';

interface MobileNavState {
  showBackButton: boolean;
  showBottomNav: boolean;
  showSidebar: boolean;
  safeAreaInsets: {
    top: number;
    bottom: number;
    left: number;
    right: number;
  };
}

function useMobileNavigation(): MobileNavState {
  const [state, setState] = useState<MobileNavState>({
    showBackButton: false,
    showBottomNav: false,
    showSidebar: true,
    safeAreaInsets: { top: 0, bottom: 0, left: 0, right: 0 },
  });

  useEffect(() => {
    async function detect() {
      const p = await getPlatform();
      const isMobile = p === 'android' || p === 'ios';

      setState({
        showBackButton: isMobile,
        showBottomNav: isMobile,
        showSidebar: !isMobile,
        safeAreaInsets: isMobile
          ? { top: 44, bottom: 34, left: 0, right: 0 }
          : { top: 0, bottom: 0, left: 0, right: 0 },
      });
    }

    detect();
  }, []);

  return state;
}

CSS Safe Areas

css
:root {
  --safe-area-top: env(safe-area-inset-top, 0px);
  --safe-area-bottom: env(safe-area-inset-bottom, 0px);
  --safe-area-left: env(safe-area-inset-left, 0px);
  --safe-area-right: env(safe-area-inset-right, 0px);
}

.app-container {
  padding-top: var(--safe-area-top);
  padding-bottom: var(--safe-area-bottom);
  padding-left: var(--safe-area-left);
  padding-right: var(--safe-area-right);
  min-height: 100dvh;
}

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding-bottom: var(--safe-area-bottom);
  background: white;
  border-top: 1px solid #e5e7eb;
  z-index: 50;
}

.top-header {
  position: sticky;
  top: 0;
  padding-top: var(--safe-area-top);
  background: white;
  border-bottom: 1px solid #e5e7eb;
  z-index: 50;
}

Comandos de Build

bash
npx tauri dev

npx tauri build

npx tauri android build --apk

npx tauri android dev

Setup Android

Pre-requisitos

Android Studio com SDK 33+, NDK 25+, Build Tools 33+. JAVA_HOME apontando para JDK 17.

bash
export ANDROID_HOME="$HOME/Android/Sdk"
export NDK_HOME="$ANDROID_HOME/ndk/25.2.9519653"
export JAVA_HOME="/usr/lib/jvm/java-17-openjdk"
export PATH="$PATH:$ANDROID_HOME/platform-tools:$ANDROID_HOME/tools"

Init e Build

bash
npx tauri android init

npx tauri android build --apk

O APK gerado fica em src-tauri/gen/android/app/build/outputs/apk/universal/release/.

Features Nativas

Notificacoes

typescript
import {
  isPermissionGranted,
  requestPermission,
  sendNotification,
} from '@tauri-apps/plugin-notification';

async function notify(title: string, body: string): Promise<void> {
  let granted = await isPermissionGranted();

  if (!granted) {
    const permission = await requestPermission();
    granted = permission === 'granted';
  }

  if (!granted) return;

  sendNotification({ title, body });
}

File System

typescript
import { writeTextFile, readTextFile, BaseDirectory } from '@tauri-apps/plugin-fs';

async function saveData(filename: string, data: Record<string, unknown>): Promise<void> {
  await writeTextFile(filename, JSON.stringify(data, null, 2), {
    baseDir: BaseDirectory.AppData,
  });
}

async function loadData<T>(filename: string): Promise<T | null> {
  try {
    const content = await readTextFile(filename, {
      baseDir: BaseDirectory.AppData,
    });
    return JSON.parse(content) as T;
  } catch {
    return null;
  }
}

Checklist Pre-Build

Permissoes minimas configuradas (allowlist restritivo)
CSP configurado no tauri.conf.json
Icones gerados para todas as plataformas (32, 128, 256, 512, icns, ico)
Splash screen configurada para Android
Deep links configurados (se aplicavel)
Auto-update configurado para desktop (se aplicavel)
Testado em dispositivo real (Android + desktop)
Performance validada em dispositivo de baixo custo
Fallback offline implementado para features criticas
Assinatura de APK configurada para release

Checkpoint: rodar o build de release (não o dev) para cada plataforma alvo → instalar no dispositivo real (não só emulador) → testar as features nativas e o fallback offline de verdade (modo avião, não só "deveria funcionar"). Se algo falhar só no build de release (permissão faltando, CSP bloqueando request que funcionava em dev), corrigir a config e repetir o build completo — não patchear no dispositivo e considerar resolvido.

Evidencia de Conclusao

  • build e permissao planejados com menor privilegio
  • impacto de mobile/desktop documentado
  • riscos de distribuicao e QA destacados

Handoff

Recebe do Frontend

  1. App web funcional com build de producao
  2. Assets (icones, splash) em alta resolucao
  3. Lista de features que precisam de acesso nativo
  4. Variaveis de ambiente documentadas

Entrega para QA

  1. APK de debug e release assinado
  2. Executaveis desktop (Windows, macOS, Linux)
  3. Lista de permissoes nativas utilizadas e justificativa
  4. Instrucoes de instalacao por plataforma
  5. Matriz de features nativas vs web (o que funciona em cada)

Regra de Codigo

Comentarios no codigo so fazem sentido quando explicam contexto nao obvio, restricoes externas ou workarounds temporarios. Nomes de funcoes, variaveis e tipos devem ser autoexplicativos.

Frequently asked questions

What does the Mobile Tauri AI skill do?

Implementa e empacota aplicacoes mobile e desktop com Tauri. Trigger em: "mobile", "Tauri", "APK", "app nativo", "desktop app", "Windows app", "macOS app", "Android", "cross-platform", "build nativo", "executável", ".exe", ".dmg", ".deb", ".AppImage", "notificação nativa", "file system nativo".

Why use Mobile Tauri on TypingMind?

Because you install it once and use it with any model. Mobile Tauri is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Mobile Tauri in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/felvieira/claude-skills-fv/tree/main/skills/15-mobile-tauri. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Mobile Tauri?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Mobile Tauri?

As many as you like. As long as a model supports skills, you can use Mobile Tauri with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Mobile Tauri AI skill free?

Yes. It is published on GitHub by felvieira under the Apache-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇