{"id":17028736,"url":"https://github.com/cmsirbu/codelint","last_synced_at":"2025-03-22T19:47:00.061Z","repository":{"id":86108832,"uuid":"282163172","full_name":"cmsirbu/codelint","owner":"cmsirbu","description":"Code Linting \u0026 Formatting Showcase","archived":false,"fork":false,"pushed_at":"2021-05-27T13:27:09.000Z","size":4,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-27T23:47:09.416Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cmsirbu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-07-24T08:17:18.000Z","updated_at":"2021-05-27T13:27:12.000Z","dependencies_parsed_at":null,"dependency_job_id":"e4c90284-7b80-42b8-8d28-48a72196c998","html_url":"https://github.com/cmsirbu/codelint","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmsirbu%2Fcodelint","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmsirbu%2Fcodelint/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmsirbu%2Fcodelint/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmsirbu%2Fcodelint/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cmsirbu","download_url":"https://codeload.github.com/cmsirbu/codelint/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245013994,"owners_count":20547178,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-14T07:55:57.473Z","updated_at":"2025-03-22T19:47:00.030Z","avatar_url":"https://github.com/cmsirbu.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Code Linting \u0026 Formatting Showcase\n\nThe [![Build Status](https://travis-ci.org/cmsirbu/codelint.svg?branch=master)](https://travis-ci.org/cmsirbu/codelint) is intentional, see if you can find out why!\n\nTry linting `example.py` with `pylint`, `pylama` and reformat it with `black`.\n\n```\npip install -r requirements.txt\npylint example.py\npylama example.py\nblack --check --diff example.py\n```\n\nFor YAML, first lint `playbook.yml` with `yamllint`.\n\n```\nyamllint playbook.yml\nplaybook.yml\n  1:1       error    too many blank lines (1 \u003e 0)  (empty-lines)\n  2:3       warning  comment not indented like content  (comments-indentation)\n  3:1       warning  missing document start \"---\"  (document-start)\n  3:81      error    line too long (101 \u003e 80 characters)  (line-length)\n  8:20      error    too many spaces before colon  (colons)\n  13:7      error    duplication of key \"ios\" in mapping  (key-duplicates)\n```\n\nNow, fix the duplicate key error on line 13 in `playbook.yml` and run `ansible-lint`. Note the custom rule (in the `custom_rules` folder) that checks whether task names are written in all uppercase.\n\n```\nansible-lint -Rr custom_rules playbook.yml\n[289] All task names should be capitalized\nplaybook.yml:19\nTask/Handler: Task 1 - ensure snmp commands exist on ios and vmx devices\n\n[502] All tasks should be named\nplaybook.yml:23\nTask/Handler: cli_config msg=A task without a name, so lazy! __line__=23 __file__=playbook.yml\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcmsirbu%2Fcodelint","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcmsirbu%2Fcodelint","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcmsirbu%2Fcodelint/lists"}