PHPackages                             lephare/import - 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. [Database &amp; ORM](/categories/database)
4. /
5. lephare/import

ActiveLibrary[Database &amp; ORM](/categories/database)

lephare/import
==============

Import CSV/XLS files

v2.4.4(4mo ago)613.3k↓83.5%1[3 issues](https://github.com/le-phare/import/issues)[4 PRs](https://github.com/le-phare/import/pulls)1MITPHPPHP ^7.4|^8.0CI passing

Since Jun 25Pushed 4mo ago7 watchersCompare

[ Source](https://github.com/le-phare/import)[ Packagist](https://packagist.org/packages/lephare/import)[ RSS](/packages/lephare-import/feed)WikiDiscussions master Synced yesterday

READMEChangelog (10)Dependencies (42)Versions (20)Used By (1)

Import
======

[](#import)

Resources
---------

[](#resources)

- [Report issues](https://github.com/le-phare/import/issues)

Archive
-------

[](#archive)

Archive affects imported files/resources when a `ImportEvents::POST_COPY` event is triggered.

For archive to take effect on a imported resource, you need to explicitly define:

- the `archive.enabled` value to `true`
- the `resources.references.load` node

```
name: stock
source_dir: "var/exchange/in"

archive:
    enabled: true
    dir: "var/exchange/in/foo/stock"
    rotation: 60

resources:
    references:
        tablename: import.stock
        load:
            pattern: "^stock.csv$"
```

The file will move to a default `archives` directory in the defined `source_dir` or in the `archive.dir` if you explicitly define its value.

The `archive.rotation` define define the number of files to keep before deletion.

Quarantine
----------

[](#quarantine)

Quarantine affects imported files/resources when a `ImportEvents::EXCEPTION` event is triggered (before)

For quarantine to take effect on a imported resource, you need to explicitly define:

- the `quarantine.enabled` value to `true`
- the `resources.references.load` node

The subsequent `stock.csv` file will be quarantined if an import exception happen during the import process.

```
name: stock
source_dir: "var/exchange/in"

quarantine:
    enabled: true
    dir: "var/exchange/in/bar/stock"
    rotation: 60

resources:
    references:
        tablename: import.stock
        load:
            pattern: "^stock.csv$"
```

The file will move to a default `quarantine` directory in the defined `source_dir` or in the `quarantine.dir` value if you explicitly define its value.

The `quarantine.rotation` define define the number of files to keep before deletion.

IDE Integration
---------------

[](#ide-integration)

Beyond validating YAML syntax in your IDE, you can validate the definition of an import configuration using the JSON schema `./lephare-import.schema.json`.

This also provides contextual help for autocompletion and when hovering over a YAML key.

###  Health Score

52

—

FairBetter than 96% of packages

Maintenance67

Regular maintenance activity

Popularity31

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity77

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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.

###  Release Activity

Cadence

Every ~233 days

Recently: every ~37 days

Total

13

Last Release

127d ago

Major Versions

1.0 → v2.0.02023-11-08

PHP version history (2 changes)1.0PHP &gt;=5.4.0

v2.0.0PHP ^7.4|^8.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/7049020?v=4)[Thibaut Selingue](/maintainers/thislg)[@thislg](https://github.com/thislg)

---

Top Contributors

[![thislg](https://avatars.githubusercontent.com/u/7049020?v=4)](https://github.com/thislg "thislg (12 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (9 commits)")[![afrancois-lephare](https://avatars.githubusercontent.com/u/68734185?v=4)](https://github.com/afrancois-lephare "afrancois-lephare (3 commits)")[![lucasmirloup](https://avatars.githubusercontent.com/u/97196064?v=4)](https://github.com/lucasmirloup "lucasmirloup (3 commits)")[![pierreboissinot](https://avatars.githubusercontent.com/u/6716686?v=4)](https://github.com/pierreboissinot "pierreboissinot (2 commits)")[![AlexiZ](https://avatars.githubusercontent.com/u/14053724?v=4)](https://github.com/AlexiZ "AlexiZ (2 commits)")[![erichard](https://avatars.githubusercontent.com/u/651041?v=4)](https://github.com/erichard "erichard (1 commits)")

---

Tags

csvexcelimportphpxlsxdatabaseexcelxlscsvimport

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/lephare-import/health.svg)

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

###  Alternatives

[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M574](/packages/shopware-core)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.5k5.9M736](/packages/sylius-sylius)[oro/platform

Business Application Platform (BAP)

645143.5k115](/packages/oro-platform)[flow-php/flow

PHP ETL - Extract Transform Load - Data processing framework

85036.3k](/packages/flow-php-flow)[contao/core-bundle

Contao Open Source CMS

1231.6M2.8k](/packages/contao-core-bundle)[shopware/platform

The Shopware e-commerce core

3.4k1.5M3](/packages/shopware-platform)

PHPackages © 2026

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