postgresql-binaries 0.0.3__tar.gz → 0.0.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: postgresql-binaries
3
- Version: 0.0.3
3
+ Version: 0.0.4
4
4
  Summary: PostgreSQL binaries for Linux, MacOS and Windows
5
5
  Author: Oli Russell
6
6
  Author-email: Oli Russell <mrxoliver@gmail.com>
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "postgresql-binaries"
3
- version = "0.0.3"
3
+ version = "0.0.4"
4
4
  description = "PostgreSQL binaries for Linux, MacOS and Windows"
5
5
  readme = "README.md"
6
6
  authors = [
@@ -1,5 +1,6 @@
1
1
  from functools import cache
2
2
  from pathlib import Path
3
+ import shutil
3
4
  import tarfile
4
5
 
5
6
  LIB = Path(__file__).parent
@@ -13,7 +14,7 @@ def bin() -> Path:
13
14
  # Clean up any previous versions
14
15
  for existing in LIB.glob("postgresql-*"):
15
16
  if existing.is_dir() and existing.name != stem:
16
- existing.unlink()
17
+ shutil.rmtree(existing)
17
18
 
18
19
  if not (LIB / stem).exists():
19
20
  with tarfile.open(archive, "r:gz") as tar: