Skip to content

Commit

Permalink
Remove ISO 3166-2 data in favor of PHP ISO codes
Browse files Browse the repository at this point in the history
Keeping the list of ISO 3166-2 up-to-date requires some maintenance. At
the same time, PHP ISO Codes maintains an up-to-date database with even
more ISO codes we could use in this library.

This change doesn't fully use all resources of PHP ISO Codes, but it
already removes some unnecessary code from the repository.

We've already used this library, but it was heavy because it included
all the localizations in it. Now, the package is much smaller (5.0M).

Signed-off-by: Henrique Moody <[email protected]>
  • Loading branch information
henriquemoody committed Feb 13, 2024
1 parent d3b6b74 commit 04b2722
Show file tree
Hide file tree
Showing 256 changed files with 112 additions and 6,811 deletions.
102 changes: 0 additions & 102 deletions bin/update-iso-codes

This file was deleted.

6 changes: 5 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,18 @@
"phpunit/phpunit": "^10.5",
"psr/http-message": "^1.0",
"respect/coding-standard": "^4.0",
"sokil/php-isocodes": "^4.2",
"sokil/php-isocodes-db-only": "^4.0",
"squizlabs/php_codesniffer": "^3.8"
},
"suggest": {
"ext-bcmath": "Arbitrary Precision Mathematics",
"ext-fileinfo": "File Information",
"ext-mbstring": "Multibyte String Functions",
"egulias/email-validator": "Improves the Email rule if available",
"giggsey/libphonenumber-for-php-lite": "Enables the phone rule if available"
"giggsey/libphonenumber-for-php-lite": "Enables the phone rule if available",
"sokil/php-isocodes": "Enable rules that validate ISO codes",
"sokil/php-isocodes-db-only": "Enable rules that validate ISO codes"
},
"autoload": {
"psr-4": {
Expand Down
13 changes: 0 additions & 13 deletions data/iso_3166-2/AD.php

This file was deleted.

13 changes: 0 additions & 13 deletions data/iso_3166-2/AE.php

This file was deleted.

40 changes: 0 additions & 40 deletions data/iso_3166-2/AF.php

This file was deleted.

14 changes: 0 additions & 14 deletions data/iso_3166-2/AG.php

This file was deleted.

6 changes: 0 additions & 6 deletions data/iso_3166-2/AI.php

This file was deleted.

18 changes: 0 additions & 18 deletions data/iso_3166-2/AL.php

This file was deleted.

17 changes: 0 additions & 17 deletions data/iso_3166-2/AM.php

This file was deleted.

24 changes: 0 additions & 24 deletions data/iso_3166-2/AO.php

This file was deleted.

6 changes: 0 additions & 6 deletions data/iso_3166-2/AQ.php

This file was deleted.

30 changes: 0 additions & 30 deletions data/iso_3166-2/AR.php

This file was deleted.

6 changes: 0 additions & 6 deletions data/iso_3166-2/AS.php

This file was deleted.

15 changes: 0 additions & 15 deletions data/iso_3166-2/AT.php

This file was deleted.

14 changes: 0 additions & 14 deletions data/iso_3166-2/AU.php

This file was deleted.

6 changes: 0 additions & 6 deletions data/iso_3166-2/AW.php

This file was deleted.

6 changes: 0 additions & 6 deletions data/iso_3166-2/AX.php

This file was deleted.

Loading

0 comments on commit 04b2722

Please sign in to comment.