Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Follow rules when abbreviating #342

Open
kjetil-kilhavn opened this issue Oct 18, 2023 · 1 comment
Open

Follow rules when abbreviating #342

kjetil-kilhavn opened this issue Oct 18, 2023 · 1 comment
Labels
clean-abap New Rule The issue or PR proposes an new rule or set of rules

Comments

@kjetil-kilhavn
Copy link
Contributor

Proposed Rule

When abbreviations are required, follow a set of rules instead of trying to be creative. Not only does it require less thinking on your part, it also makes it more likely that another developer will understand what has been abbreviated.

  1. Use common abbreviations such as doc for document and tel for telephone
  2. Remove filler words such as of or at, i.e. arrival_time_port instead of arrivl_tme_at_prt
  3. Omit vowels, unless they are at the beginning or end of a word
  4. Replace double consonants with single consonants
  5. Abbreviate the least significant and/or longest parts first, i.e. purchsr_city instead of purchaser_ct
  6. Abbreviate the last parts before the first parts, i.e. purchase_requisitn instead of prchse_requisition

Additionally, avoid that the result is similar to a common abbreviation for a completely different term.

" you have 15 characters available for 'delegation responsibility'
dlgtn_rspnsblty

is better than

" anti-pattern - is it response or responsibility?
delegation_resp

Justification

These are the recommendations in SAP's documentation which has a lot more to say about the topic - but I wasn't sure if such a long text block could be included in a rule here. https://help.sap.com/doc/abapdocu_752_index_htm/7.52/en-US/abentelling_names_guidl.htm

@kjetil-kilhavn kjetil-kilhavn added clean-abap New Rule The issue or PR proposes an new rule or set of rules labels Oct 18, 2023
@larshp
Copy link
Contributor

larshp commented Oct 18, 2023

I think #253 is relevant in this case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clean-abap New Rule The issue or PR proposes an new rule or set of rules
Projects
None yet
Development

No branches or pull requests

2 participants