New Upstream Snapshot - php-league-mime-type-detection

Ready changes

Summary

Merged new upstream version: 1.11.0+git20230101.1.6b094dd+ds (was: 1.10.0+ds).

Resulting package

Built on 2023-01-16T13:03 (took 5m1s)

The resulting binary packages can be installed (if you have the apt repository enabled) by running one of:

apt install -t fresh-snapshots php-league-mime-type-detection

Diff

diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml
deleted file mode 100644
index bf2fb54..0000000
--- a/.github/FUNDING.yml
+++ /dev/null
@@ -1,2 +0,0 @@
-github: [frankdejonge]
-tidelift: "packagist/league/flysystem"
diff --git a/.github/workflows/quality-assurance.yml b/.github/workflows/quality-assurance.yml
deleted file mode 100644
index 3649ab8..0000000
--- a/.github/workflows/quality-assurance.yml
+++ /dev/null
@@ -1,44 +0,0 @@
----
-name: Quality Assurance
-on:
-  push:
-    paths:
-      - src/**/*.php
-      - .github/workflows/quality-assurance.yml
-    branches:
-      - main
-  pull_request:
-    paths:
-      - src/**/*.php
-      - .github/workflows/quality-assurance.yml
-    branches:
-      - main
-
-jobs:
-  phpunit:
-    name: PHPUnit tests on ${{ matrix.php }} ${{ matrix.composer-flags }}
-    runs-on: ubuntu-latest
-    strategy:
-      matrix:
-        php: [ '7.2', '7.3', '7.4', '8.0' ]
-        composer-flags: [ '' ]
-        upgrade-aws-sdk: [ 'no' ]
-        phpunit-flags: [ '--coverage-text' ]
-        include:
-          - php: '7.2'
-            composer-flags: '--prefer-lowest'
-            phpunit-flags: '--no-coverage'
-    steps:
-      - uses: actions/checkout@v2
-      - uses: shivammathur/setup-php@v2
-        with:
-          php-version: ${{ matrix.php }}
-          coverage: pcov
-          tools: composer:v2
-      - run: composer update --no-progress ${{ matrix.composer-flags }}
-      - run: COMPOSER_OPTS='${{ matrix.composer-flags }}' vendor/bin/phpunit ${{ matrix.phpunit-flags }}
-      - run: vendor/bin/phpstan analyse -l 6 src
-        if: ${{ matrix.php == '7.4' }}
-      - run: vendor/bin/php-cs-fixer fix --diff --dry-run
-        if: ${{ matrix.php == '7.4' }}
-
diff --git a/.gitignore b/.gitignore
deleted file mode 100644
index cb06ef3..0000000
--- a/.gitignore
+++ /dev/null
@@ -1,7 +0,0 @@
-/vendor/
-/coverage/
-/.phpunit.result.cache
-/.php-cs-fixer.php
-/.php-cs-fixer.cache
-/phpunit.xml
-/composer.lock
diff --git a/LICENSE b/LICENSE
index 1f01652..39d50b5 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2013-2022 Frank de Jonge
+Copyright (c) 2013-2023 Frank de Jonge
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
diff --git a/debian/changelog b/debian/changelog
index 5b028fb..d7143df 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+php-league-mime-type-detection (1.11.0+git20230101.1.6b094dd+ds-1) UNRELEASED; urgency=low
+
+  * New upstream snapshot.
+
+ -- Debian Janitor <janitor@jelmer.uk>  Mon, 16 Jan 2023 12:59:54 -0000
+
 php-league-mime-type-detection (1.10.0+ds-1) unstable; urgency=medium
 
   * New upstream version 1.10.0+ds
diff --git a/debian/patches/0001-Use-local-mime-db-instead-of-downloading-one.patch b/debian/patches/0001-Use-local-mime-db-instead-of-downloading-one.patch
index 9a92493..00dadea 100644
--- a/debian/patches/0001-Use-local-mime-db-instead-of-downloading-one.patch
+++ b/debian/patches/0001-Use-local-mime-db-instead-of-downloading-one.patch
@@ -9,11 +9,11 @@ Forwarded: not-needed
  src/Generation/JsHttpMimeDBMimeTypeProvider.php | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/src/Generation/JsHttpMimeDBMimeTypeProvider.php b/src/Generation/JsHttpMimeDBMimeTypeProvider.php
-index 0a10fa1..0eec89f 100644
---- a/src/Generation/JsHttpMimeDBMimeTypeProvider.php
-+++ b/src/Generation/JsHttpMimeDBMimeTypeProvider.php
-@@ -9,7 +9,7 @@ class JsHttpMimeDBMimeTypeProvider implements MimeTypeProvider
+Index: php-league-mime-type-detection.git/src/Generation/JsHttpMimeDBMimeTypeProvider.php
+===================================================================
+--- php-league-mime-type-detection.git.orig/src/Generation/JsHttpMimeDBMimeTypeProvider.php
++++ php-league-mime-type-detection.git/src/Generation/JsHttpMimeDBMimeTypeProvider.php
+@@ -9,7 +9,7 @@ class JsHttpMimeDBMimeTypeProvider imple
      public function provideMimeTypes(): array
      {
          $result = [];
diff --git a/debian/patches/0002-Skip-generated-map-should-be-up-to-date-test.patch b/debian/patches/0002-Skip-generated-map-should-be-up-to-date-test.patch
index 6a17911..d337f4e 100644
--- a/debian/patches/0002-Skip-generated-map-should-be-up-to-date-test.patch
+++ b/debian/patches/0002-Skip-generated-map-should-be-up-to-date-test.patch
@@ -11,11 +11,11 @@ Forwarded: not-needed
  src/GeneratedExtensionToMimeTypeMapTest.php | 2 ++
  1 file changed, 2 insertions(+)
 
-diff --git a/src/GeneratedExtensionToMimeTypeMapTest.php b/src/GeneratedExtensionToMimeTypeMapTest.php
-index 0968a33..cfc99fd 100644
---- a/src/GeneratedExtensionToMimeTypeMapTest.php
-+++ b/src/GeneratedExtensionToMimeTypeMapTest.php
-@@ -36,6 +36,8 @@ class GeneratedExtensionToMimeTypeMapTest extends TestCase
+Index: php-league-mime-type-detection.git/src/GeneratedExtensionToMimeTypeMapTest.php
+===================================================================
+--- php-league-mime-type-detection.git.orig/src/GeneratedExtensionToMimeTypeMapTest.php
++++ php-league-mime-type-detection.git/src/GeneratedExtensionToMimeTypeMapTest.php
+@@ -36,6 +36,8 @@ class GeneratedExtensionToMimeTypeMapTes
       */
      public function the_generated_map_should_be_up_to_date(): void
      {
diff --git a/src/FinfoMimeTypeDetectorTest.php b/src/FinfoMimeTypeDetectorTest.php
index 02b6cab..5e3fbd6 100644
--- a/src/FinfoMimeTypeDetectorTest.php
+++ b/src/FinfoMimeTypeDetectorTest.php
@@ -18,6 +18,16 @@ class FinfoMimeTypeDetectorTest extends TestCase
         $this->detector = new FinfoMimeTypeDetector();
     }
 
+    /**
+     * @test
+     */
+    public function detecting_a_csv(): void
+    {
+        $mimeType = $this->detector->detectMimeType('something.csv', '');
+
+        $this->assertEquals('text/csv', $mimeType);
+    }
+
     /**
      * @test
      */
diff --git a/src/Generation/FlysystemProvidedMimeTypeProvider.php b/src/Generation/FlysystemProvidedMimeTypeProvider.php
index da45f0a..a5b2736 100644
--- a/src/Generation/FlysystemProvidedMimeTypeProvider.php
+++ b/src/Generation/FlysystemProvidedMimeTypeProvider.php
@@ -12,6 +12,7 @@ class FlysystemProvidedMimeTypeProvider implements MimeTypeProvider
             new MimeTypeForExtension('application/mac-binhex40', 'hqx'),
             new MimeTypeForExtension('application/mac-compactpro', 'cpt'),
             new MimeTypeForExtension('text/csv', 'csv'),
+            new MimeTypeForExtension('application/octet-stream', 'phar'),
             new MimeTypeForExtension('application/octet-stream', 'bin'),
             new MimeTypeForExtension('application/octet-stream', 'dms'),
             new MimeTypeForExtension('application/octet-stream', 'lha'),

More details

Full run details