Skip to main content

Kotlin Style Check


This open-source python package automatically fixes your Kotlin code to follow coding conventions listed here:

https://kotlinlang.org/docs/reference/coding-conventions.html#naming-rules

https://kotlinlang.org/docs/reference/coding-conventions.html#documentation-comments


Installation

https://pypi.org/project/kotlin-style-check/

pip install kotlin_style_check


Searches for all .kt files in given path and fixes naming and comments errors

python -m kotlin_style_check --input_path


Example

from kotlin_style_check import KotlinStyleChecker

print(KotlinStyleChecker().fix(["val My_Var = 5;"], ["out.log"])) # outputs "val myVar = 5;", logs changes to "out.log"

Short description of class KotlinStyleChecker

def fix_in_files(self, input_path) # input_path - path to dir or file to fix code style. logs data relatively to this path

def run_tests(self, log_file) # runs small checks

def setup_logger(self, log_file, level=logging.INFO) # needed to log data when calling lower level functions of this class (check_comments for example), overwrites it's global logger

""" ... other stuff you can find in source code """

Metadata

Release files for kotlin-style-check 1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for kotlin-style-check 1.0
File Size Uploaded Provenance Actions
kotlin_style_check-1.0.tar.gz 8.6 kB Without provenance Details for kotlin_style_check-1.0.tar.gz

Release files / kotlin_style_check-1.0.tar.gz

Download URL kotlin_style_check-1.0.tar.gz
Size 8.6 kB
Tags Source
SHA-256 checksum
How to use checksums
0239631fbe01fde29407d4c4d2caef48fb21815374f7c075a22b9de0e5fc2d74
BLAKE2b-256 checksum
How to use checksums
2fbbed52bf1888498cd2067fadc712a0c5ec853aaea89d130fa65b65c1871a19
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.54.0 CPython/3.8.4

Security for kotlin-style-check 1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page