diff options
author | Reza Moradi <mrezzamoradi@gmail.com> | 2022-02-22 20:05:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-22 14:05:08 -0500 |
commit | d968ca7419e6f4e40685888c56d03bea50fd39d7 (patch) | |
tree | c26388f34c2e91260fed09a0369f88c8791f94b6 /slugify/__main__.py | |
parent | 07b87da81140cf51e4a585e43d4fe9113f4c2ad5 (diff) | |
download | python-slugify-6.1.0.tar.gz |
allow unicode (#111)v6.1.0
* initial commit to allow unicode
* update version and changelog
* add the flag to the CLI
* update README.md
Diffstat (limited to 'slugify/__main__.py')
-rw-r--r-- | slugify/__main__.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/slugify/__main__.py b/slugify/__main__.py index 5a888fe..7dd6b01 100644 --- a/slugify/__main__.py +++ b/slugify/__main__.py @@ -36,6 +36,8 @@ def parse_args(argv): help="Activate case sensitivity") parser.add_argument("--replacements", nargs='+', help="""Additional replacement rules e.g. "|->or", "%%->percent".""") + parser.add_argument("--allow-unicode", action='store_true', default=False, + help="Allow unicode characters") args = parser.parse_args(argv[1:]) @@ -73,7 +75,8 @@ def slugify_params(args): separator=args.separator, stopwords=args.stopwords, lowercase=args.lowercase, - replacements=args.replacements + replacements=args.replacements, + allow_unicode=args.allow_unicode ) |