Skip to content

CodePal (Clean Code) is a highly configurable engine, fully integrated in the ABAP development framework ensuring Cloud’s built-in quality.

License

Notifications You must be signed in to change notification settings

abap-weasel/code-pal-for-abap

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Code Pal for ABAP

Note: Netweaver release 7.40 SP8 or higher is required.

Code pal is a tool which supports you in writing clean ABAP code. Clean Code allows you to read your code like well-written prose, it is easily understandable, maintainable and extensible. In addition, you can write high quality and reliable Unit Tests without hurdles and hereby reduce the total cost of ownership of the software.

Furthermore... It's free and open source: code pal is licensed under the Apache License, Version 2.0 - see license.txt

Features

  • Checks can be executed via Code Inspector and via ATC (e.g. within SE80, Eclipse)
  • Automatic Exclusion of Code which shall not be checked (like generated code, …)
  • Execution of Checks is User-based
  • Scope is customizable (via the object creation date)
  • Thresholds are customizable
  • Message severity is customizable (e.g. error, warning, notification, …)
  • Checking productive code and/or test code is customizable
  • Findings can be suppressed via Code Inspector Pragmas

How to bring Code Pal into your system

1. Create a local package

Create a local package in which you can pull the git repository (for example $CLEAN_CODE_MAIN) Screenshot of Package Attributes

2. Start Transaction ZABAPGIT*

Screenshot of Transaction ZABAPGIT

Press 'Online' in the menu and provide the following information as seen in the screenshot. As package use the same name as the one created in step (1): Screenshot of ZABAPGIT Code Pal

*In case transaction ZABAPGIT is not present in your system, please follow this link which describes the installation procedure and the complete user guide and documentation of abapGit: https://docs.abapgit.org/

3. Include the new Checks into Code Inspector

Start transaction SCI and tick the newly added Clean Code Checks in the "Check Management" section (Ctrl+Shift+F5): Screenshot of Code Inspector

(In some system releases, the path to the Check Management might differ from the screenshot.)

Please make sure to activate Y_CHECK_CATEGORY first and alone, since it is a prerequisite of all checks. Afterwards, you might activate all checks you wish in any sequence/order. Screenshot of Code Inspector Check Activation

How to use Code Pal

When code pal is in your system, just go to Transaction SCI or SCII and execute the Checks with your prefered Thresholds. To have a consistent set of Checks and Thresholds you can always create a Code Inspector Variant.

To understand how the checks work, please refer to the Check Documentation. Screenshot of Check Execution

Then simply execute the Checks.

Further Reading

Other interesting projects

About

CodePal (Clean Code) is a highly configurable engine, fully integrated in the ABAP development framework ensuring Cloud’s built-in quality.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • ABAP 100.0%