Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Ux Native Cli

Ux Native Cli Laravel Package

akyos/ux-native-cli

Bundle Symfony exposant des commandes console pour générer des coques Hotwire Native minimales (Android et iOS) depuis des modèles, puis lancer Gradle et xcodebuild depuis la racine d’un projet PHP. Configuration via native.yaml (URL, application_id, bundle_id, chemins).

View on GitHub
Deep Wiki
Context7

At a glance

Frequently asked questions about Ux Native Cli
Does akyos/ux-native-cli work with Laravel?
Partially. The package is a Symfony bundle, but its core value, console commands that scaffold Hotwire Native Android and iOS shells and shell out to Gradle and xcodebuild, runs on the Symfony Console and Process components that Laravel 10+ already ships with. You must register the commands manually in a service provider and port config/packages/native.yaml to config/native.php, because Laravel has no bundles.php or Symfony extension aliases. Anything relying on symfony/ux-native, such as server-side detection or path configuration, needs a Laravel bridge or your own middleware.
How do I install akyos/ux-native-cli in a Laravel project?
Run composer require akyos/ux-native-cli, then skip the bundles.php registration step and instead register the package's commands in a dedicated service provider. Publish a config/native.php file that mirrors the YAML keys so the commands can read app_name, url, application_id, bundle_id and the path settings. Confirm with php artisan list that native:init, native:build and native:qr-install are available before running them.
How do I migrate the native.yaml configuration to Laravel?
Create config/native.php returning an array with the same keys as the Symfony YAML: app_name, url, application_id, bundle_id, android_path, ios_path, android_gradle_task, ios_scheme, ios_project, ios_product_name, ios_derived_data_path, android_home and java_home. Values that vary per environment, such as the backend URL, signing team and SDK paths, should come from env() calls rather than being committed. Then adjust the command wiring so it resolves config('native.key') instead of the Symfony extension alias native.
Which Laravel and PHP versions are supported by this package?
It targets Symfony 7/8 components such as symfony/console and symfony/process, which are the ones bundled with Laravel 10 and later, so Laravel 10+ is the realistic baseline. Your PHP version must satisfy those Symfony releases, so check the constraint in the package's composer.json before upgrading. Older Laravel versions shipping Symfony 5/6 components are not a supported combination.
What do I need installed to run native:build from Laravel?
Android builds need a JDK plus the Android SDK and the Gradle wrapper, located through the android_home and java_home config keys, the ANDROID_HOME and JAVA_HOME environment variables, or the usual install locations. iOS builds need macOS with Xcode and xcodebuild available, since there is no cross-platform route to an IPA. The commands simply shell out, so any CI runner with those toolchains installed can execute them.
Do I need symfony/ux-native in a Laravel app?
It is a suggested, not required, dependency used for server-side Hotwire Native detection and for serving path configuration JSON to the apps. In Laravel you would replace it with your own route or middleware that returns the same JSON contract for tabs, modals and path rules. If you skip it, the generated native shells still work, but you lose the ready-made backend bridge.
How do push notifications work with this package in Laravel?
Version 0.3.0 adds a notification option that wires Firebase Cloud Messaging on Android and APNs on iOS into the generated projects, plus a notification-token endpoint the apps call to register devices. In Laravel you implement that endpoint yourself as a route and controller backed by a tokens table, including user-to-device association and token rotation. For dispatch, check whether akyos/native-push fits your stack, otherwise wrap kreait/firebase-php or APNs HTTP/2 directly. Remember that foreground, background and closed-app deep linking must also be handled on the client side.
How do I handle iOS signing and ios_development_team in CI?
The ios_development_team key together with xcodebuild -allowProvisioningUpdates lets Xcode resolve signing automatically, but it requires an authenticated Xcode session or an App Store Connect API key on the build host. Keep the team ID and API key in CI secrets and inject them through env() instead of committing them to config/native.php. Use a macOS runner with certificates and provisioning profiles pre-installed for reliable builds.
Can I customize the app name, bundle IDs, paths and Gradle task?
Yes. app_name, application_id and bundle_id control the displayed name and the Android applicationId and iOS bundle identifier, and the Kotlin package folder is moved to match. android_path and ios_path default to native/android and native/ios under the project root but accept absolute paths. android_gradle_task (assembleDebug by default) and ios_scheme, ios_project and ios_product_name control what Gradle and xcodebuild actually build, which also affects the APK path used by adb install.
What are the alternatives for Laravel teams that want native app builds?
You can keep this bundle and treat it as a thin Artisan wrapper around Gradle and xcodebuild, accepting the Symfony-to-Laravel configuration port. Or write your own stubs plus Artisan commands, which is little work if you only need one platform and fixed identifiers. For push delivery, kreait/firebase-php covers FCM for both platforms, and direct APNs HTTP/2 is a solid option for iOS-only sending.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
se7enxweb/flysystem
lampwick/laravel
jeslage/statamic-emojis
micahdshackelford/rmap-laravel
draftsmaninc/draftsman
square-bit/laravel-volition
himito/laravel-mailman
htinlynn/genius-helper
maco-studios/hephaestus
elmogy/larafast
xeviant/laravel-paystack
gorilladash/laravel-website-sdk
martialbe/flysystem-oss
chondal/3312client
jeroen-g/flickr
opscale-co/nova-genbi
itsjustvita/laravel-retention
tequilarapido/trackit
gregsphotography/site-builder-filament
cabaoctavio/laravel-query-log