PHPackages                             backtheweb/linguo - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. backtheweb/linguo

Abandoned → [backtheweb/laravel-linguo](/?search=backtheweb%2Flaravel-linguo)Library[Localization &amp; i18n](/categories/localization)

backtheweb/linguo
=================

Laravel Gettext integration

073PHP

Since Aug 8Pushed 7y ago1 watchersCompare

[ Source](https://github.com/backtheweb/laravel-linguo)[ Packagist](https://packagist.org/packages/backtheweb/linguo)[ RSS](/packages/backtheweb-linguo/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (0)

linguo
======

[](#linguo)

Gettext for laravel 5

Installation
------------

[](#installation)

### Laravel Service Provider

[](#laravel-service-provider)

Add the service provider and the face on `config/app.php`

```
'providers' => [

    [...]
    Backtheweb\Linguo\LinguoServiceProvider::class,
],

'aliases' => [
    [...]
    'Linguo' => Backtheweb\Linguo\LinguoFacade::class,
]

```

And publish the config:

```
php artisan vendor:publish --provider="Backtheweb\Linguo\LinguoServiceProvider" --tag=config

```

### Setup

[](#setup)

Edit `config/linguo.php`

```
return [

    'headers' => [
        'Project-Id-Version'    => 'linguo',
        'Language-Team'         => 'TeamName '
    ],

    'sources' => [
        base_path('resources/views'),
        base_path('app/Http/Controllers'),
    ] ,

    'i18nPath'  => base_path('resources/lang'),
    'domain'    => 'default',           // defualt domain
    'domains'   => [],                  // others domains to process
    'locales'   => ['es', 'en'],        // may be en or en_GB
];

```

**Sources** : Is where the parser will be looking for translation keys **i18nPath**: Is the path where are stored the translation files

Parse and generate translation files
------------------------------------

[](#parse-and-generate-translation-files)

### Parse

[](#parse)

```
php artisian linguo:parse --compile

```

Compile
-------

[](#compile)

```
php artisian linguo:parse

```

### What does it do?

[](#what-does-it-do)

1. Read the folders defined on `sources` config and extract the keys form translation functions gettext, ngettext, \_\_, \_n
2. Create a catalog `default.pot` file whit keys.
3. Foreach language defined on `locales`:

    - Create or/update the `{local}/default.po` file.
    - Create a `{local}/default.php` file with translations defined on `{local}/default.po`

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/41ae21402ea7e732b8249ffead36784508e8c054765db436cd153a701f4bdadc?d=identicon)[backtheweb](/maintainers/backtheweb)

---

Top Contributors

[![jtouza](https://avatars.githubusercontent.com/u/177118?v=4)](https://github.com/jtouza "jtouza (8 commits)")

### Embed Badge

![Health badge](/badges/backtheweb-linguo/health.svg)

```
[![Health](https://phpackages.com/badges/backtheweb-linguo/health.svg)](https://phpackages.com/packages/backtheweb-linguo)
```

###  Alternatives

[smmoosavi/php-gettext

Wrapper for php-gettext by danilo segan. This library provides PHP functions to read MO files even when gettext is not compiled in or when appropriate locale is not present on the system.

1926.6k1](/packages/smmoosavi-php-gettext)[laradevs/spanish

labels translated to spanish

166.7k](/packages/laradevs-spanish)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
