Set up GH Linting action for dataone-indexer

Open
#159 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
42/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
github-actions, java
Domain
ci-cd, tooling

Research direction

Start with the linked GitHub Super-Linter documentation and marketplace action, then compare its Java checks with the Google Java Style Guide and the requested IDE-level inspections. Determine where the GitHub Actions workflow and configurable rules belong, and verify that a test pull request produces review comments for style, deprecation, Javadoc, and spelling findings.

Written by the indexing model from the issue text.

Description

_onboarding devtools

User Story

As a PR reviewer, I want to be more efficient by focusing on architecture, code logic and finding potential bugs, instead of flagging issues with syntax, coding style, deprecations, typos etc. that could easily be picked up by an automatic linting tool.

Acceptance Criteria

  • Rules must be configurable
  • Feedback automatically added as PR review comments
  • Checks against the Google Java Style Guide, with the one exception that indents are 4 spaces instead of 2
  • (some of these are negotiable) Includes the level of insight provided by IDEs (e.g. IntelliJ IDEA community edition). Examples include:
    • checks for deprecated code; example:

      deprecated since version 9 and marked for removal: 'Long(java.lang.String)'
      
    • checks for code simplifications. Examples:

      * Field can be converted to a local variable
      * Private field 'spaceAllocated' is assigned but never accessed
      * Method 'hasPermission(java.lang.String, java.lang.String)' is never used
      * 'equals("")' can be replaced with 'isEmpty()'
      
    • Javadoc linting; example: Cannot resolve symbol 'docid,' (i.e. @param in javadoc does not match actual method params)

    • spell-checking in javadoc & comments; example: Typo: In word 'peroperties'

Useful info

Dominant language
Java
Stars
0
Forks
2
Avg merge
6d 6h
Merged PRs (30d)
3

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from DataONEorg/dataone-indexer

All issues in DataONEorg/dataone-indexer

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.