From ead9c33d1db1d8a1fad21104d3f11f31187dd442 Mon Sep 17 00:00:00 2001
From: Felix Yan <felixonmars@archlinux.org>
Date: Sat, 17 Jul 2021 03:13:59 +0800
Subject: [PATCH] Use platformdirs instead of appdirs
Forwarded: https://github.com/alex/rply/pull/110

--- a/rply/parsergenerator.py
+++ b/rply/parsergenerator.py
@@ -6,7 +6,7 @@
 import tempfile
 import warnings
 
-from appdirs import AppDirs
+from platformdirs import PlatformDirs
 
 from rply.errors import ParserGeneratorError, ParserGeneratorWarning
 from rply.grammar import Grammar
@@ -178,7 +178,7 @@ def build(self):
 
         table = None
         if self.cache_id is not None:
-            cache_dir = AppDirs("rply").user_cache_dir
+            cache_dir = PlatformDirs("rply").user_cache_dir
             cache_file = os.path.join(
                 cache_dir,
                 "%s-%s-%s.json" % (
--- a/setup.py
+++ b/setup.py
@@ -13,5 +13,5 @@
     author="Alex Gaynor",
     author_email="alex.gaynor@gmail.com",
     packages=["rply"],
-    install_requires=["appdirs"],
+    install_requires=["platformdirs"],
 )
