Download the PHP package syriable/localizator without Composer

On this page you can find all versions of the php package syriable/localizator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package localizator

Syriable Localizator

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

An advanced Laravel package for automatic translation scanning and AI-powered translation generation. Built for Laravel 12+ with modern PHP standards and FilamentPHP 4 compatibility.

๐Ÿš€ Features

๐Ÿ“‹ Requirements

๐Ÿ“ฆ Installation

Install the package via Composer:

Publish the configuration file:

This will publish the configuration file to config/localizator.php.

โš™๏ธ Configuration

The package comes with extensive configuration options. Here are the key settings:

Environment Variables

Add these to your .env file:

๐Ÿ› ๏ธ Usage

Automatic Generation (Recommended)

Generate all translation files automatically without any interactive prompts:

Interactive Scanning

Scan your application with interactive prompts and review options:

Advanced Options

The scan command supports various options for different use cases:

Command Comparison

Feature localizator:generate localizator:scan
Interaction Fully automatic, zero prompts Interactive with prompts and choices
Locale Selection Uses config defaults or arguments Prompts for locale selection if not specified
AI Review Auto-accepts all translations Optional review process for AI translations
Best for CI/CD, automated workflows Manual control, reviewing translations
Speed Fast, no waiting for input Slower due to interactive prompts
Silent Mode Yes (--silent flag) No
Configuration Uses locales from config Always prompts if no arguments

Recommendation: Use localizator:generate for most cases, especially in automated environments. Use localizator:scan when you need to review and approve translations manually.

Interactive Mode

When you run the command without specifying locales, it will prompt you to select from supported languages:

๐Ÿ” What Gets Scanned

The package automatically detects and extracts translation keys from:

Comment Detection & Skipping

NEW in v1.4.0: The package now automatically skips translation keys found in comments, preventing disabled or temporary keys from being added to your language files.

Supported Comment Types:

Why This Matters:

File Types Scanned

PHP Files

Blade Templates

Vue.js Components

JavaScript Files

๐Ÿ—๏ธ Intelligent Nested Structure

The package automatically organizes translation files based on dot notation keys, following Laravel's best practices:

How It Works

Translation Key โ†’ Generated File Structure

Key Benefits

โœ… Organized Structure: Files are automatically organized by context
โœ… Laravel Standard: Follows Laravel's recommended translation file structure
โœ… Deep Nesting: Supports unlimited nesting levels (auth.forms.login.validation.required)
โœ… Backward Compatible: Can be disabled with 'nested' => false
โœ… Merge Existing: Intelligently merges with existing translation files

๐Ÿงน Remove Missing Keys

NEW in v1.4.0: The --remove-missing option has been improved to properly clean up unused translation keys from your language files.

How It Works

When you delete translation keys from your source code, they remain in your language files. The --remove-missing flag solves this by:

  1. Scanning your codebase for currently used translation keys
  2. Comparing with existing translation files
  3. Removing keys that no longer exist in your source code
  4. Preserving all keys that are still in use

Usage Examples

Before & After Example

Before (your source code changed):

Translation file before cleanup:

After running --remove-missing:

Safety Features

๐Ÿค– AI Translation Features

Supported AI Providers

Translation Context

Provide context to improve AI translations:

Batch Processing

AI translations are processed in batches to optimize API usage:

Validation

Automatic validation ensures translation quality:

๐Ÿ“ Output Formats

JSON Format

PHP Array Format

Nested Structure (Default)

With 'nested' => true in configuration, translation keys use dot notation to create organized, nested file structures:

Flat Structure (Legacy)

With 'nested' => false, keys remain flat within files:

๐Ÿงช Testing

Run the package tests:

Run static analysis:

Fix code style:

Run all quality checks:

๐Ÿ“ˆ Performance

The package is optimized for large codebases:

๐Ÿ›ก๏ธ Security

๐Ÿ”ง Advanced Configuration

Custom Translation Functions

Add your own translation function patterns:

File Exclusion

Exclude specific files or directories:

Custom Output Settings

Customize the generated files:

๐Ÿšจ Troubleshooting

Common Issues

1. No translation keys found

2. AI translation failures

3. --remove-missing not working

4. Permission errors

Debug Mode

Enable verbose output for debugging:

Log Analysis

Check Laravel logs for detailed error information:

๐Ÿค Contributing

We welcome contributions! Please see CONTRIBUTING.md for guidelines.

Development Setup

  1. Clone the repository
  2. Install dependencies: composer install
  3. Run tests: composer test
  4. Run static analysis: composer analyse
  5. Fix code style: composer format

๐Ÿ“„ Changelog

Please see CHANGELOG.md for more information on what has changed recently.

๐Ÿ”’ Security

If you discover any security-related issues, please email [email protected] instead of using the issue tracker.

๐Ÿ“ License

The MIT License (MIT). Please see License File for more information.

๐Ÿ™ Credits

๐Ÿ”— Related Packages

๐Ÿ’ก Tips & Best Practices

1. Organize Translation Keys

Use dot notation for hierarchical organization:

2. Use Placeholders

Keep translations flexible with placeholders:

3. Review AI Translations

Always review AI-generated translations for:

4. Version Control

Include translation files in version control but consider:

5. Performance Optimization

For large applications:


Made with โค๏ธ by Syriable


All versions of localizator with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
illuminate/support Version ^10.0|^11.0|^12.0
illuminate/console Version ^10.0|^11.0|^12.0
illuminate/config Version ^10.0|^11.0|^12.0
symfony/finder Version ^7.0
guzzlehttp/guzzle Version ^7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package syriable/localizator contains the following files

Loading the files please wait ...