spec-cleaner


Namespec-cleaner JSON
Version 1.2.4 PyPI version JSON
download
home_pageNone
SummaryRPM .spec files cleaner
upload_time2025-08-06 07:48:31
maintainerNone
docs_urlNone
authorNone
requires_pythonNone
licenseBSD-3-Clause
keywords suse rpm .spec cleaner
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            
# spec-cleaner

![Build Status](https://github.com/rpm-software-management/spec-cleaner/workflows/Python%20package/badge.svg?branch=master)
[![Coverage Status](https://coveralls.io/repos/github/rpm-software-management/spec-cleaner/badge.svg?branch=master)](https://coveralls.io/github/rpm-software-management/spec-cleaner?branch=master)
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)


spec-cleaner is a tool that cleans the given RPM spec file according to the style guide and returns the result.

It's used for [openSUSE](https://www.opensuse.org), where it's planned to be a replacement for `osc service localrun format_spec_file` and it is intended to provide the same or better features in order to be able to unify all the spec files in [OBS](https://build.opensuse.org/).

# Table of contents
* [Installation and usage](#installation-and-usage)
* [Tests](#tests)
* [Contributing](#contributing)
* [Versioning and releasing](#versioning-and-releasing)
* [Authors](#authors)

## Installation and usage

### Installation
The latest version is available on [PyPI](https://pypi.org/project/spec_cleaner/). It can be installed by running `pip install spec_cleaner`.

spec-cleaner is also provided as an RPM package for openSUSE Leap ([15.0](https://build.opensuse.org/package/show/openSUSE:Leap:15.0:Update/spec-cleaner) and [15.1](https://build.opensuse.org/package/show/openSUSE:Leap:15.1:Update/spec-cleaner)) and [openSUSE Tumbleweed](https://build.opensuse.org/package/show/openSUSE:Factory/spec-cleaner). When the new version of spec-cleaner is released then the version updates are performed for all maintained openSUSE codestreams. That means that there is always the latest version available in openSUSE:Leap.

### Usage
Simply run `spec-cleaner -i <specfile>` to clean your specfile up.


## Tests

### Running the tests
spec-cleaner provides quite an extensive testsuite. You can run these tests locally either directly via `pytest`.

#### pytest
Just install `python3-pytest`, `python3-pytest-cov`, `python3-pytest-isort` and `python3-pytest-sugar` (for a nice progress bar) and then run all tests via:

    pytest

## Contributing
You are more than welcome to contribute to this project. If you are not sure about your changes, feel free to create an issue where you can discuss it before the implementation.

### Contribution Guidelines

When changing anything in the code, make sure that you don't forget to:

  * Follow [pep8](https://www.python.org/dev/peps/pep-0008/).
  * Install [pre-commit](https://pre-commit.com/) framework and run `pre-commit install` to install `pre-commit` into your git hooks.
  * Add proper comments and docstrings (follow [pep257](https://www.python.org/dev/peps/pep-0257/) and [Google Python Style Guide for docstrings and comments](http://google.github.io/styleguide/pyguide.html#38-comments-and-docstrings))
  * Add [tests](TESTSUITE.md) (mainly if you implement a new feature).
  * Add `mypy` support for the new code.
  * Run and pass all tests, `flake8` and `mypy` checks.

See below for more details.

### pre-commit

spec-cleaner project adopted `pre-commit` framework for managing and maintaining pre-commit hooks. After you clone the spec-cleaner repository, please install [pre-commit](https://pre-commit.com/) framework (`pip install pre-commit`) and run `pre-commit install` to install `pre-commit` into your git hooks. Then `pre-commit` will run automatically on `git commit` and it will check your contribution with `isort`, `black`, `flake8`, `flake8-docstrings` and `mypy`.

Please note that similar checks run in CI when you submit a PR and it won't pass code review without passing these checks.

### mypy

Optional static type checker support was implemented for the most important parts of the code. If you want to run it on your own, just install `python3-mypy` and run

     mypy spec_cleaner

### Black

The code of spec-cleaner is formated with [Black](https://github.com/psf/black). We use `--skip-string-normalization` and `--line-length 100` options. Black runs automatically in the `pre-commit` hook.

### Adding new tests
When a new feature is added to spec-cleaner then a test for this piece of code must be added. See [how to write tests for spec-cleaner](TESTSUITE.md).


## Versioning and releasing
For the versions available, see the [tags on this repository](https://github.com/openSUSE/spec-cleaner/releases).

If you have proper permissions you can find handy [how to do a new release](RELEASE.md).

## Authors

* See the list of [contributors](AUTHORS) who participated in this project


# [SPDX Licenses](http://spdx.org/licenses)

License Tag | Description
----------- | -----------

# SPDX Exceptions

|Exception name|
|--------------|
0BSD
AAL
ADSL
AFL-1.1
AFL-1.2
AFL-2.0
AFL-2.1
AFL-3.0
AGPL-1.0-only
AGPL-1.0-or-later
AGPL-3.0-only
AGPL-3.0-or-later
AMDPLPA
AML
AMPAS
ANTLR-PD
ANTLR-PD-fallback
APAFML
APL-1.0
APSL-1.0
APSL-1.1
APSL-1.2
APSL-2.0
ASWF-Digital-Assets-1.0
ASWF-Digital-Assets-1.1
Abstyles
AdaCore-doc
Adobe-2006
Adobe-Glyph
Adobe-Utopia
Afmparse
Aladdin
Apache-1.0
Apache-1.1
Apache-2.0
App-s2p
Arphic-1999
Artistic-1.0
Artistic-1.0-Perl
Artistic-1.0-cl8
Artistic-2.0
BSD-1-Clause
BSD-2-Clause
BSD-2-Clause-Patent
BSD-2-Clause-Views
BSD-3-Clause
BSD-3-Clause-Attribution
BSD-3-Clause-Clear
BSD-3-Clause-HP
BSD-3-Clause-LBNL
BSD-3-Clause-Modification
BSD-3-Clause-No-Military-License
BSD-3-Clause-No-Nuclear-License
BSD-3-Clause-No-Nuclear-License-2014
BSD-3-Clause-No-Nuclear-Warranty
BSD-3-Clause-Open-MPI
BSD-3-Clause-Sun
BSD-3-Clause-flex
BSD-4-Clause
BSD-4-Clause-Shortened
BSD-4-Clause-UC
BSD-4.3RENO
BSD-4.3TAHOE
BSD-Advertising-Acknowledgement
BSD-Attribution-HPND-disclaimer
BSD-Inferno-Nettverk
BSD-Protection
BSD-Source-Code
BSD-Systemics
BSL-1.0
BUSL-1.1
Baekmuk
Bahyph
Barr
Beerware
BitTorrent-1.0
BitTorrent-1.1
Bitstream-Charter
Bitstream-Vera
BlueOak-1.0.0
Boehm-GC
Borceux
Brian-Gladman-3-Clause
C-UDA-1.0
CAL-1.0
CAL-1.0-Combined-Work-Exception
CATOSL-1.1
CC-BY-1.0
CC-BY-2.0
CC-BY-2.5
CC-BY-2.5-AU
CC-BY-3.0
CC-BY-3.0-AT
CC-BY-3.0-DE
CC-BY-3.0-IGO
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-2.0
DL-DE-ZERO-2.0
DOC
DRL-1.0
DSDP
Dotseqn
ECL-1.0
ECL-2.0
EFL-1.0
EFL-2.0
EPICS
EPL-1.0
EPL-2.0
EUDatagrid
EUPL-1.0
EUPL-1.1
EUPL-1.2
Elastic-2.0
Entessa
ErlPL-1.1
Eurosym
FBM
FDK-AAC
FSFAP
FSFUL
FSFULLR
FSFULLRWD
FTL
Fair
Ferguson-Twofish
Frameworx-1.0
FreeBSD-DOC
FreeImage
Furuseth
GD
GFDL-1.1-invariants-only
GFDL-1.1-invariants-or-later
GFDL-1.1-no-invariants-only
GFDL-1.1-no-invariants-or-later
GFDL-1.1-only
GFDL-1.1-or-later
GFDL-1.2-invariants-only
GFDL-1.2-invariants-or-later
GFDL-1.2-no-invariants-only
GFDL-1.2-no-invariants-or-later
GFDL-1.2-only
GFDL-1.2-or-later
GFDL-1.3-invariants-only
GFDL-1.3-invariants-or-later
GFDL-1.3-no-invariants-only
GFDL-1.3-no-invariants-or-later
GFDL-1.3-only
GFDL-1.3-or-later
GL2PS
GLWTPL
GPL-1.0-only
GPL-1.0-or-later
GPL-2.0-only
GPL-2.0-or-later
GPL-3.0-only
GPL-3.0-or-later
Giftware
Glide
Glulxe
Graphics-Gems
HP-1986
HP-1989
HPND
HPND-DEC
HPND-Markus-Kuhn
HPND-Pbmplus
HPND-UC
HPND-doc
HPND-doc-sell
HPND-export-US
HPND-export-US-modify
HPND-sell-regexpr
HPND-sell-variant
HPND-sell-variant-MIT-disclaimer
HTMLTIDY
HaskellReport
Hippocratic-2.1
IBM-pibs
ICU
IEC-Code-Components-EULA
IJG
IJG-short
IPA
IPL-1.0
ISC
ImageMagick
Imlib2
Info-ZIP
Inner-Net-2.0
Intel
Intel-ACPI
Interbase-1.0
JPL-image
JPNIC
JSON
Jam
JasPer-2.0
Kastrup
Kazlib
Knuth-CTAN
LAL-1.2
LAL-1.3
LGPL-2.0-only
LGPL-2.0-or-later
LGPL-2.1-only
LGPL-2.1-or-later
LGPL-3.0-only
LGPL-3.0-or-later
LGPLLR
LOOP
LPL-1.0
LPL-1.02
LPPL-1.0
LPPL-1.1
LPPL-1.2
LPPL-1.3a
LPPL-1.3c
LZMA-SDK-9.11-to-9.20
LZMA-SDK-9.22
Latex2e
Latex2e-translated-notice
Leptonica
LiLiQ-P-1.1
LiLiQ-R-1.1
LiLiQ-Rplus-1.1
Libpng
Linux-OpenIB
Linux-man-pages-1-para
Linux-man-pages-copyleft
Linux-man-pages-copyleft-2-para
Linux-man-pages-copyleft-var
Lucida-Bitmap-Fonts
MIT
MIT-0
MIT-CMU
MIT-Festival
MIT-Modern-Variant
MIT-Wu
MIT-advertising
MIT-enna
MIT-feh
MIT-open-group
MIT-testregex
MITNFA
MMIXware
MPEG-SSG
MPL-1.0
MPL-1.1
MPL-2.0
MPL-2.0-no-copyleft-exception
MS-LPL
MS-PL
MS-RL
MTLL
MakeIndex
Martin-Birgmeier
McPhee-slideshow
Minpack
MirOS
Motosoto
MulanPSL-1.0
MulanPSL-2.0
Multics
Mup
NAIST-2003
NASA-1.3
NBPL-1.0
NCGL-UK-2.0
NCSA
NGPL
NICTA-1.0
NIST-PD
NIST-PD-fallback
NIST-Software
NLOD-1.0
NLOD-2.0
NLPL
NOSL
NPL-1.0
NPL-1.1
NPOSL-3.0
NRL
NTP
NTP-0
Naumen
Net-SNMP
NetCDF
Newsletr
Nokia
Noweb
O-UDA-1.0
OCCT-PL
OCLC-2.0
ODC-By-1.0
ODbL-1.0
OFFIS
OFL-1.0
OFL-1.0-RFN
OFL-1.0-no-RFN
OFL-1.1
OFL-1.1-RFN
OFL-1.1-no-RFN
OGC-1.0
OGDL-Taiwan-1.0
OGL-Canada-2.0
OGL-UK-1.0
OGL-UK-2.0
OGL-UK-3.0
OGTSL
OLDAP-1.1
OLDAP-1.2
OLDAP-1.3
OLDAP-1.4
OLDAP-2.0
OLDAP-2.0.1
OLDAP-2.1
OLDAP-2.2
OLDAP-2.2.1
OLDAP-2.2.2
OLDAP-2.3
OLDAP-2.4
OLDAP-2.5
OLDAP-2.6
OLDAP-2.7
OLDAP-2.8
OLFL-1.3
OML
OPL-1.0
OPL-UK-3.0
OPUBL-1.0
OSET-PL-2.1
OSL-1.0
OSL-1.1
OSL-2.0
OSL-2.1
OSL-3.0
OpenPBS-2.3
OpenSSL
PADL
PDDL-1.0
PHP-3.0
PHP-3.01
PSF-2.0
Parity-6.0.0
Parity-7.0.0
Plexus
PolyForm-Noncommercial-1.0.0
PolyForm-Small-Business-1.0.0
PostgreSQL
Python-2.0
Python-2.0.1
QPL-1.0
QPL-1.0-INRIA-2004
Qhull
RHeCos-1.1
RPL-1.1
RPL-1.5
RPSL-1.0
RSA-MD
RSCPL
Rdisc
Ruby
SAX-PD
SCEA
SGI-B-1.0
SGI-B-1.1
SGI-B-2.0
SGI-OpenGL
SGP4
SHL-0.5
SHL-0.51
SISSL
SISSL-1.2
SL
SMLNJ
SMPPL
SNIA
SPL-1.0
SSH-OpenSSH
SSH-short
SSPL-1.0
SWL
Saxpath
SchemeReport
Sendmail
Sendmail-8.23
SimPL-2.0
Sleepycat
Soundex
Spencer-86
Spencer-94
Spencer-99
SugarCRM-1.1.3
SunPro
Symlinks
TAPR-OHL-1.0
TCL
TCP-wrappers
TMate
TORQUE-1.1
TOSL
TPDL
TPL-1.0
TTWL
TTYP0
TU-Berlin-1.0
TU-Berlin-2.0
TermReadKey
UCAR
UCL-1.0
UPL-1.0
URT-RLE
Unicode-DFS-2015
Unicode-DFS-2016
Unicode-TOU
UnixCrypt
Unlicense
VOSTROM
VSL-1.0
Vim
W3C
W3C-19980720
W3C-20150513
WTFPL
Watcom-1.0
Widget-Workshop
Wsuipa
X11
X11-distribute-modifications-variant
XFree86-1.1
XSkat
Xdebug-1.03
Xerox
Xfig
Xnet
YPL-1.0
YPL-1.1
ZPL-1.1
ZPL-2.0
ZPL-2.1
Zed
Zeeff
Zend-2.0
Zimbra-1.3
Zimbra-1.4
Zlib
blessing
bzip2-1.0.6
check-cvs
checkmk
copyleft-next-0.3.0
copyleft-next-0.3.1
curl
diffmark
dtoa
dvipdfm
eGenix
etalab-2.0
fwlw
gSOAP-1.3b
gnuplot
iMatix
libpng-2.0
libselinux-1.0
libtiff
libutil-David-Nugent
lsof
magaz
metamail
mpi-permissive
mpich2
mplus
pnmstitch
psfrag
psutils
python-ldap
snprintf
ssh-keyscan
swrule
ulem
w3m
xinetd
xlock
xpp
zlib-acknowledgement

# SUSE Additions

|License Tag|
|-----------|
|SUSE-BSD-3-Clause-with-non-nuclear-addition|
|SUSE-BSD-Mark-Modifications|
|SUSE-CC-Sampling-Plus-1.0|
|SUSE-CPL-0.5|
|SUSE-CacertRoot|
|SUSE-Copyleft-Next-0.3.0|
|SUSE-Curb|
|SUSE-DMTF|
|SUSE-Docbook-XSL|
|SUSE-EULA|
|SUSE-Egenix-1.1.0|
|SUSE-FHS|
|SUSE-FLTK|
|SUSE-Firmware|
|SUSE-Free-Art-1.3|
|SUSE-Freetype|
|SUSE-Freeware|
|SUSE-GL2PS-2.0|
|SUSE-GPL-2.0+-with-openssl-exception|
|SUSE-GPL-2.0+-with-sane-exception|
|SUSE-GPL-2.0-with-FLOSS-exception|
|SUSE-GPL-2.0-with-OSI-exception|
|SUSE-GPL-2.0-with-linking-exception|
|SUSE-GPL-2.0-with-openssl-exception|
|SUSE-GPL-2.0-with-plugin-exception|
|SUSE-GPL-3.0+-with-font-exception|
|SUSE-GPL-3.0+-with-openssl-exception|
|SUSE-GPL-3.0-with-FLOSS-exception|
|SUSE-GPL-3.0-with-font-exception|
|SUSE-GPL-3.0-with-openssl-exception|
|SUSE-GPL-3.0-with-template-exception|
|SUSE-Gitslave|
|SUSE-Gnuplot|
|SUSE-Hack-Open-Font-2.0|
|SUSE-IBPL-1.0|
|SUSE-IDPL-1.0|
|SUSE-IEEE|
|SUSE-Innernet-2.0|
|SUSE-Innernet-2.00|
|SUSE-LDPL-2.0|
|SUSE-LGPL-2.0-with-linking-exception|
|SUSE-LGPL-2.1-with-digia-exception-1.1|
|SUSE-LGPL-2.1-with-nokia-exception-1.1|
|SUSE-Liberation|
|SUSE-MIT-Khronos|
|SUSE-Manpages|
|SUSE-Matplotlib|
|SUSE-MgOpen|
|SUSE-Oasis-Specification-Notice|
|SUSE-OldFSFDocLicense|
|SUSE-OpenPublication-1.0|
|SUSE-PHP-2.02|
|SUSE-Permissive|
|SUSE-Permissive-Modify-By-Patch|
|SUSE-Public-Domain|
|SUSE-Python-1.6|
|SUSE-QWT-1.0|
|SUSE-Redistributable-Content|
|SUSE-Repoze|
|SUSE-SIP|
|SUSE-SLIB|
|SUSE-SNIA-1.0|
|SUSE-SNIA-1.1|
|SUSE-Scrot|
|SUSE-Sun-Laboratories|
|SUSE-TGPPL-1.0|
|SUSE-TeX|
|SUSE-Ubuntu-Font-License-1.0|
|SUSE-XDebug|
|SUSE-XFree86-with-font-exception|
|SUSE-XSL-Lint|
|SUSE-Xano|
|SUSE-Xenonsoft-1.00|
|SUSE-mirror|
|SUSE-wxWidgets-3.1|

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "spec-cleaner",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "SUSE, RPM, .spec, cleaner",
    "author": null,
    "author_email": "Daniel Garc\u00eda Moreno <daniel.garcia@suse.com>, Kristyna Streitova <kstreitova@suse.com>, Tom\u00e1\u0161 Chv\u00e1tal <tchvatal@suse.com>",
    "download_url": "https://files.pythonhosted.org/packages/11/58/1d1de83cd5bacf5d01b51faaa3544afc0cfb7332d7e2dd494cfcde42e13d/spec_cleaner-1.2.4.tar.gz",
    "platform": "Linux",
    "description": "\n# spec-cleaner\n\n![Build Status](https://github.com/rpm-software-management/spec-cleaner/workflows/Python%20package/badge.svg?branch=master)\n[![Coverage Status](https://coveralls.io/repos/github/rpm-software-management/spec-cleaner/badge.svg?branch=master)](https://coveralls.io/github/rpm-software-management/spec-cleaner?branch=master)\n[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n\n\nspec-cleaner is a tool that cleans the given RPM spec file according to the style guide and returns the result.\n\nIt's used for [openSUSE](https://www.opensuse.org), where it's planned to be a replacement for `osc service localrun format_spec_file` and it is intended to provide the same or better features in order to be able to unify all the spec files in [OBS](https://build.opensuse.org/).\n\n# Table of contents\n* [Installation and usage](#installation-and-usage)\n* [Tests](#tests)\n* [Contributing](#contributing)\n* [Versioning and releasing](#versioning-and-releasing)\n* [Authors](#authors)\n\n## Installation and usage\n\n### Installation\nThe latest version is available on [PyPI](https://pypi.org/project/spec_cleaner/). It can be installed by running `pip install spec_cleaner`.\n\nspec-cleaner is also provided as an RPM package for openSUSE Leap ([15.0](https://build.opensuse.org/package/show/openSUSE:Leap:15.0:Update/spec-cleaner) and [15.1](https://build.opensuse.org/package/show/openSUSE:Leap:15.1:Update/spec-cleaner)) and [openSUSE Tumbleweed](https://build.opensuse.org/package/show/openSUSE:Factory/spec-cleaner). When the new version of spec-cleaner is released then the version updates are performed for all maintained openSUSE codestreams. That means that there is always the latest version available in openSUSE:Leap.\n\n### Usage\nSimply run `spec-cleaner -i <specfile>` to clean your specfile up.\n\n\n## Tests\n\n### Running the tests\nspec-cleaner provides quite an extensive testsuite. You can run these tests locally either directly via `pytest`.\n\n#### pytest\nJust install `python3-pytest`, `python3-pytest-cov`, `python3-pytest-isort` and `python3-pytest-sugar` (for a nice progress bar) and then run all tests via:\n\n    pytest\n\n## Contributing\nYou are more than welcome to contribute to this project. If you are not sure about your changes, feel free to create an issue where you can discuss it before the implementation.\n\n### Contribution Guidelines\n\nWhen changing anything in the code, make sure that you don't forget to:\n\n  * Follow [pep8](https://www.python.org/dev/peps/pep-0008/).\n  * Install [pre-commit](https://pre-commit.com/) framework and run `pre-commit install` to install `pre-commit` into your git hooks.\n  * Add proper comments and docstrings (follow [pep257](https://www.python.org/dev/peps/pep-0257/) and [Google Python Style Guide for docstrings and comments](http://google.github.io/styleguide/pyguide.html#38-comments-and-docstrings))\n  * Add [tests](TESTSUITE.md) (mainly if you implement a new feature).\n  * Add `mypy` support for the new code.\n  * Run and pass all tests, `flake8` and `mypy` checks.\n\nSee below for more details.\n\n### pre-commit\n\nspec-cleaner project adopted `pre-commit` framework for managing and maintaining pre-commit hooks. After you clone the spec-cleaner repository, please install [pre-commit](https://pre-commit.com/) framework (`pip install pre-commit`) and run `pre-commit install` to install `pre-commit` into your git hooks. Then `pre-commit` will run automatically on `git commit` and it will check your contribution with `isort`, `black`, `flake8`, `flake8-docstrings` and `mypy`.\n\nPlease note that similar checks run in CI when you submit a PR and it won't pass code review without passing these checks.\n\n### mypy\n\nOptional static type checker support was implemented for the most important parts of the code. If you want to run it on your own, just install `python3-mypy` and run\n\n     mypy spec_cleaner\n\n### Black\n\nThe code of spec-cleaner is formated with [Black](https://github.com/psf/black). We use `--skip-string-normalization` and `--line-length 100` options. Black runs automatically in the `pre-commit` hook.\n\n### Adding new tests\nWhen a new feature is added to spec-cleaner then a test for this piece of code must be added. See [how to write tests for spec-cleaner](TESTSUITE.md).\n\n\n## Versioning and releasing\nFor the versions available, see the [tags on this repository](https://github.com/openSUSE/spec-cleaner/releases).\n\nIf you have proper permissions you can find handy [how to do a new release](RELEASE.md).\n\n## Authors\n\n* See the list of [contributors](AUTHORS) who participated in this project\n\n\n# [SPDX Licenses](http://spdx.org/licenses)\n\nLicense Tag | Description\n----------- | -----------\n\n# SPDX Exceptions\n\n|Exception name|\n|--------------|\n0BSD\nAAL\nADSL\nAFL-1.1\nAFL-1.2\nAFL-2.0\nAFL-2.1\nAFL-3.0\nAGPL-1.0-only\nAGPL-1.0-or-later\nAGPL-3.0-only\nAGPL-3.0-or-later\nAMDPLPA\nAML\nAMPAS\nANTLR-PD\nANTLR-PD-fallback\nAPAFML\nAPL-1.0\nAPSL-1.0\nAPSL-1.1\nAPSL-1.2\nAPSL-2.0\nASWF-Digital-Assets-1.0\nASWF-Digital-Assets-1.1\nAbstyles\nAdaCore-doc\nAdobe-2006\nAdobe-Glyph\nAdobe-Utopia\nAfmparse\nAladdin\nApache-1.0\nApache-1.1\nApache-2.0\nApp-s2p\nArphic-1999\nArtistic-1.0\nArtistic-1.0-Perl\nArtistic-1.0-cl8\nArtistic-2.0\nBSD-1-Clause\nBSD-2-Clause\nBSD-2-Clause-Patent\nBSD-2-Clause-Views\nBSD-3-Clause\nBSD-3-Clause-Attribution\nBSD-3-Clause-Clear\nBSD-3-Clause-HP\nBSD-3-Clause-LBNL\nBSD-3-Clause-Modification\nBSD-3-Clause-No-Military-License\nBSD-3-Clause-No-Nuclear-License\nBSD-3-Clause-No-Nuclear-License-2014\nBSD-3-Clause-No-Nuclear-Warranty\nBSD-3-Clause-Open-MPI\nBSD-3-Clause-Sun\nBSD-3-Clause-flex\nBSD-4-Clause\nBSD-4-Clause-Shortened\nBSD-4-Clause-UC\nBSD-4.3RENO\nBSD-4.3TAHOE\nBSD-Advertising-Acknowledgement\nBSD-Attribution-HPND-disclaimer\nBSD-Inferno-Nettverk\nBSD-Protection\nBSD-Source-Code\nBSD-Systemics\nBSL-1.0\nBUSL-1.1\nBaekmuk\nBahyph\nBarr\nBeerware\nBitTorrent-1.0\nBitTorrent-1.1\nBitstream-Charter\nBitstream-Vera\nBlueOak-1.0.0\nBoehm-GC\nBorceux\nBrian-Gladman-3-Clause\nC-UDA-1.0\nCAL-1.0\nCAL-1.0-Combined-Work-Exception\nCATOSL-1.1\nCC-BY-1.0\nCC-BY-2.0\nCC-BY-2.5\nCC-BY-2.5-AU\nCC-BY-3.0\nCC-BY-3.0-AT\nCC-BY-3.0-DE\nCC-BY-3.0-IGO\nCC-BY-3.0-NL\nCC-BY-3.0-US\nCC-BY-4.0\nCC-BY-NC-1.0\nCC-BY-NC-2.0\nCC-BY-NC-2.5\nCC-BY-NC-3.0\nCC-BY-NC-3.0-DE\nCC-BY-NC-4.0\nCC-BY-NC-ND-1.0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2.0\nEFL-1.0\nEFL-2.0\nEPICS\nEPL-1.0\nEPL-2.0\nEUDatagrid\nEUPL-1.0\nEUPL-1.1\nEUPL-1.2\nElastic-2.0\nEntessa\nErlPL-1.1\nEurosym\nFBM\nFDK-AAC\nFSFAP\nFSFUL\nFSFULLR\nFSFULLRWD\nFTL\nFair\nFerguson-Twofish\nFrameworx-1.0\nFreeBSD-DOC\nFreeImage\nFuruseth\nGD\nGFDL-1.1-invariants-only\nGFDL-1.1-invariants-or-later\nGFDL-1.1-no-invariants-only\nGFDL-1.1-no-invariants-or-later\nGFDL-1.1-only\nGFDL-1.1-or-later\nGFDL-1.2-invariants-only\nGFDL-1.2-invariants-or-later\nGFDL-1.2-no-invariants-only\nGFDL-1.2-no-invariants-or-later\nGFDL-1.2-only\nGFDL-1.2-or-later\nGFDL-1.3-invariants-only\nGFDL-1.3-invariants-or-later\nGFDL-1.3-no-invariants-only\nGFDL-1.3-no-invariants-or-later\nGFDL-1.3-only\nGFDL-1.3-or-later\nGL2PS\nGLWTPL\nGPL-1.0-only\nGPL-1.0-or-later\nGPL-2.0-only\nGPL-2.0-or-later\nGPL-3.0-only\nGPL-3.0-or-later\nGiftware\nGlide\nGlulxe\nGraphics-Gems\nHP-1986\nHP-1989\nHPND\nHPND-DEC\nHPND-Markus-Kuhn\nHPND-Pbmplus\nHPND-UC\nHPND-doc\nHPND-doc-sell\nHPND-export-US\nHPND-export-US-modify\nHPND-sell-regexpr\nHPND-sell-variant\nHPND-sell-variant-MIT-disclaimer\nHTMLTIDY\nHaskellReport\nHippocratic-2.1\nIBM-pibs\nICU\nIEC-Code-Components-EULA\nIJG\nIJG-short\nIPA\nIPL-1.0\nISC\nImageMagick\nImlib2\nInfo-ZIP\nInner-Net-2.0\nIntel\nIntel-ACPI\nInterbase-1.0\nJPL-image\nJPNIC\nJSON\nJam\nJasPer-2.0\nKastrup\nKazlib\nKnuth-CTAN\nLAL-1.2\nLAL-1.3\nLGPL-2.0-only\nLGPL-2.0-or-later\nLGPL-2.1-only\nLGPL-2.1-or-later\nLGPL-3.0-only\nLGPL-3.0-or-later\nLGPLLR\nLOOP\nLPL-1.0\nLPL-1.02\nLPPL-1.0\nLPPL-1.1\nLPPL-1.2\nLPPL-1.3a\nLPPL-1.3c\nLZMA-SDK-9.11-to-9.20\nLZMA-SDK-9.22\nLatex2e\nLatex2e-translated-notice\nLeptonica\nLiLiQ-P-1.1\nLiLiQ-R-1.1\nLiLiQ-Rplus-1.1\nLibpng\nLinux-OpenIB\nLinux-man-pages-1-para\nLinux-man-pages-copyleft\nLinux-man-pages-copyleft-2-para\nLinux-man-pages-copyleft-var\nLucida-Bitmap-Fonts\nMIT\nMIT-0\nMIT-CMU\nMIT-Festival\nMIT-Modern-Variant\nMIT-Wu\nMIT-advertising\nMIT-enna\nMIT-feh\nMIT-open-group\nMIT-testregex\nMITNFA\nMMIXware\nMPEG-SSG\nMPL-1.0\nMPL-1.1\nMPL-2.0\nMPL-2.0-no-copyleft-exception\nMS-LPL\nMS-PL\nMS-RL\nMTLL\nMakeIndex\nMartin-Birgmeier\nMcPhee-slideshow\nMinpack\nMirOS\nMotosoto\nMulanPSL-1.0\nMulanPSL-2.0\nMultics\nMup\nNAIST-2003\nNASA-1.3\nNBPL-1.0\nNCGL-UK-2.0\nNCSA\nNGPL\nNICTA-1.0\nNIST-PD\nNIST-PD-fallback\nNIST-Software\nNLOD-1.0\nNLOD-2.0\nNLPL\nNOSL\nNPL-1.0\nNPL-1.1\nNPOSL-3.0\nNRL\nNTP\nNTP-0\nNaumen\nNet-SNMP\nNetCDF\nNewsletr\nNokia\nNoweb\nO-UDA-1.0\nOCCT-PL\nOCLC-2.0\nODC-By-1.0\nODbL-1.0\nOFFIS\nOFL-1.0\nOFL-1.0-RFN\nOFL-1.0-no-RFN\nOFL-1.1\nOFL-1.1-RFN\nOFL-1.1-no-RFN\nOGC-1.0\nOGDL-Taiwan-1.0\nOGL-Canada-2.0\nOGL-UK-1.0\nOGL-UK-2.0\nOGL-UK-3.0\nOGTSL\nOLDAP-1.1\nOLDAP-1.2\nOLDAP-1.3\nOLDAP-1.4\nOLDAP-2.0\nOLDAP-2.0.1\nOLDAP-2.1\nOLDAP-2.2\nOLDAP-2.2.1\nOLDAP-2.2.2\nOLDAP-2.3\nOLDAP-2.4\nOLDAP-2.5\nOLDAP-2.6\nOLDAP-2.7\nOLDAP-2.8\nOLFL-1.3\nOML\nOPL-1.0\nOPL-UK-3.0\nOPUBL-1.0\nOSET-PL-2.1\nOSL-1.0\nOSL-1.1\nOSL-2.0\nOSL-2.1\nOSL-3.0\nOpenPBS-2.3\nOpenSSL\nPADL\nPDDL-1.0\nPHP-3.0\nPHP-3.01\nPSF-2.0\nParity-6.0.0\nParity-7.0.0\nPlexus\nPolyForm-Noncommercial-1.0.0\nPolyForm-Small-Business-1.0.0\nPostgreSQL\nPython-2.0\nPython-2.0.1\nQPL-1.0\nQPL-1.0-INRIA-2004\nQhull\nRHeCos-1.1\nRPL-1.1\nRPL-1.5\nRPSL-1.0\nRSA-MD\nRSCPL\nRdisc\nRuby\nSAX-PD\nSCEA\nSGI-B-1.0\nSGI-B-1.1\nSGI-B-2.0\nSGI-OpenGL\nSGP4\nSHL-0.5\nSHL-0.51\nSISSL\nSISSL-1.2\nSL\nSMLNJ\nSMPPL\nSNIA\nSPL-1.0\nSSH-OpenSSH\nSSH-short\nSSPL-1.0\nSWL\nSaxpath\nSchemeReport\nSendmail\nSendmail-8.23\nSimPL-2.0\nSleepycat\nSoundex\nSpencer-86\nSpencer-94\nSpencer-99\nSugarCRM-1.1.3\nSunPro\nSymlinks\nTAPR-OHL-1.0\nTCL\nTCP-wrappers\nTMate\nTORQUE-1.1\nTOSL\nTPDL\nTPL-1.0\nTTWL\nTTYP0\nTU-Berlin-1.0\nTU-Berlin-2.0\nTermReadKey\nUCAR\nUCL-1.0\nUPL-1.0\nURT-RLE\nUnicode-DFS-2015\nUnicode-DFS-2016\nUnicode-TOU\nUnixCrypt\nUnlicense\nVOSTROM\nVSL-1.0\nVim\nW3C\nW3C-19980720\nW3C-20150513\nWTFPL\nWatcom-1.0\nWidget-Workshop\nWsuipa\nX11\nX11-distribute-modifications-variant\nXFree86-1.1\nXSkat\nXdebug-1.03\nXerox\nXfig\nXnet\nYPL-1.0\nYPL-1.1\nZPL-1.1\nZPL-2.0\nZPL-2.1\nZed\nZeeff\nZend-2.0\nZimbra-1.3\nZimbra-1.4\nZlib\nblessing\nbzip2-1.0.6\ncheck-cvs\ncheckmk\ncopyleft-next-0.3.0\ncopyleft-next-0.3.1\ncurl\ndiffmark\ndtoa\ndvipdfm\neGenix\netalab-2.0\nfwlw\ngSOAP-1.3b\ngnuplot\niMatix\nlibpng-2.0\nlibselinux-1.0\nlibtiff\nlibutil-David-Nugent\nlsof\nmagaz\nmetamail\nmpi-permissive\nmpich2\nmplus\npnmstitch\npsfrag\npsutils\npython-ldap\nsnprintf\nssh-keyscan\nswrule\nulem\nw3m\nxinetd\nxlock\nxpp\nzlib-acknowledgement\n\n# SUSE Additions\n\n|License Tag|\n|-----------|\n|SUSE-BSD-3-Clause-with-non-nuclear-addition|\n|SUSE-BSD-Mark-Modifications|\n|SUSE-CC-Sampling-Plus-1.0|\n|SUSE-CPL-0.5|\n|SUSE-CacertRoot|\n|SUSE-Copyleft-Next-0.3.0|\n|SUSE-Curb|\n|SUSE-DMTF|\n|SUSE-Docbook-XSL|\n|SUSE-EULA|\n|SUSE-Egenix-1.1.0|\n|SUSE-FHS|\n|SUSE-FLTK|\n|SUSE-Firmware|\n|SUSE-Free-Art-1.3|\n|SUSE-Freetype|\n|SUSE-Freeware|\n|SUSE-GL2PS-2.0|\n|SUSE-GPL-2.0+-with-openssl-exception|\n|SUSE-GPL-2.0+-with-sane-exception|\n|SUSE-GPL-2.0-with-FLOSS-exception|\n|SUSE-GPL-2.0-with-OSI-exception|\n|SUSE-GPL-2.0-with-linking-exception|\n|SUSE-GPL-2.0-with-openssl-exception|\n|SUSE-GPL-2.0-with-plugin-exception|\n|SUSE-GPL-3.0+-with-font-exception|\n|SUSE-GPL-3.0+-with-openssl-exception|\n|SUSE-GPL-3.0-with-FLOSS-exception|\n|SUSE-GPL-3.0-with-font-exception|\n|SUSE-GPL-3.0-with-openssl-exception|\n|SUSE-GPL-3.0-with-template-exception|\n|SUSE-Gitslave|\n|SUSE-Gnuplot|\n|SUSE-Hack-Open-Font-2.0|\n|SUSE-IBPL-1.0|\n|SUSE-IDPL-1.0|\n|SUSE-IEEE|\n|SUSE-Innernet-2.0|\n|SUSE-Innernet-2.00|\n|SUSE-LDPL-2.0|\n|SUSE-LGPL-2.0-with-linking-exception|\n|SUSE-LGPL-2.1-with-digia-exception-1.1|\n|SUSE-LGPL-2.1-with-nokia-exception-1.1|\n|SUSE-Liberation|\n|SUSE-MIT-Khronos|\n|SUSE-Manpages|\n|SUSE-Matplotlib|\n|SUSE-MgOpen|\n|SUSE-Oasis-Specification-Notice|\n|SUSE-OldFSFDocLicense|\n|SUSE-OpenPublication-1.0|\n|SUSE-PHP-2.02|\n|SUSE-Permissive|\n|SUSE-Permissive-Modify-By-Patch|\n|SUSE-Public-Domain|\n|SUSE-Python-1.6|\n|SUSE-QWT-1.0|\n|SUSE-Redistributable-Content|\n|SUSE-Repoze|\n|SUSE-SIP|\n|SUSE-SLIB|\n|SUSE-SNIA-1.0|\n|SUSE-SNIA-1.1|\n|SUSE-Scrot|\n|SUSE-Sun-Laboratories|\n|SUSE-TGPPL-1.0|\n|SUSE-TeX|\n|SUSE-Ubuntu-Font-License-1.0|\n|SUSE-XDebug|\n|SUSE-XFree86-with-font-exception|\n|SUSE-XSL-Lint|\n|SUSE-Xano|\n|SUSE-Xenonsoft-1.00|\n|SUSE-mirror|\n|SUSE-wxWidgets-3.1|\n",
    "bugtrack_url": null,
    "license": "BSD-3-Clause",
    "summary": "RPM .spec files cleaner",
    "version": "1.2.4",
    "project_urls": {
        "Homepage": "https://github.com/rpm-software-management/spec-cleaner",
        "Issues": "https://github.com/rpm-software-management/spec-cleaner/issues",
        "Repository": "https://github.com/rpm-software-management/spec-cleaner.git"
    },
    "split_keywords": [
        "suse",
        " rpm",
        " .spec",
        " cleaner"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "0a376082522ba612692c5a17aa0e5c95803f89fbc955536c09ae1076ea27cd08",
                "md5": "6b44c6dca87d3b0645a73e2def7923de",
                "sha256": "e3743bf14b6f905f1f53643b813b98a360c6ebbbf7206effbe86b0c0212e204d"
            },
            "downloads": -1,
            "filename": "spec_cleaner-1.2.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "6b44c6dca87d3b0645a73e2def7923de",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 441403,
            "upload_time": "2025-08-06T07:48:29",
            "upload_time_iso_8601": "2025-08-06T07:48:29.331033Z",
            "url": "https://files.pythonhosted.org/packages/0a/37/6082522ba612692c5a17aa0e5c95803f89fbc955536c09ae1076ea27cd08/spec_cleaner-1.2.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "11581d1de83cd5bacf5d01b51faaa3544afc0cfb7332d7e2dd494cfcde42e13d",
                "md5": "6cefd606bf1fcdab789bab49c13462c3",
                "sha256": "b78a6eb08113e9eed18b30592f0b6a34fc5457fa078997054171f9420b2940ba"
            },
            "downloads": -1,
            "filename": "spec_cleaner-1.2.4.tar.gz",
            "has_sig": false,
            "md5_digest": "6cefd606bf1fcdab789bab49c13462c3",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 548837,
            "upload_time": "2025-08-06T07:48:31",
            "upload_time_iso_8601": "2025-08-06T07:48:31.486691Z",
            "url": "https://files.pythonhosted.org/packages/11/58/1d1de83cd5bacf5d01b51faaa3544afc0cfb7332d7e2dd494cfcde42e13d/spec_cleaner-1.2.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-08-06 07:48:31",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "rpm-software-management",
    "github_project": "spec-cleaner",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "spec-cleaner"
}
        
Elapsed time: 1.80327s