Commit Graph

22 Commits

Author SHA1 Message Date
Christian Günter
af48aec066
Repo view: Fix path and filenames (#5205)
Co-authored-by: Lars Hvam <larshp@hotmail.com>
2021-12-13 07:49:23 +01:00
Marc Bernard
c7e4af3be2
Add user exit for serialize postprocessing (#5194)
There are scenarios where you want to serialize objects differently than abapGit. This exit is called at the end of the serialize process and gives an opportunity to change the content of the serialzed files.

One such scenario would be to automatically pretty-print code. This can be achieved by looping over all `.abap` files and processing them accordingly in this exit.

Closes #5050

Co-authored-by: Lars Hvam <larshp@hotmail.com>
2021-12-11 07:30:50 +01:00
Marc Bernard
97821c8428
Add user exit for adjusting display of filenames (#5185)
The filenames can become very long, for example, usage of many sub-packages, namespaces, objects like function groups, or BSP/Fiori apps with many sub-objects, or a long paths as starting folder. This can make the repository view very busy or render the output as a very wide table (see #5169, #5178).

This exit allows to adjust the filename according to your own rules. 

Here's an example for shortening the display of files for sub-objects:

```abap
  METHOD zif_abapgit_exit~adjust_display_filename.

    DATA:
      lv_path TYPE string,
      lv_name TYPE string,
      lv_ext1 TYPE string,
      lv_ext2 TYPE string.

    SPLIT iv_filename AT '.' INTO lv_path lv_name lv_ext1 lv_ext2.

    IF lv_ext2 IS INITIAL.
      " Main object
      rv_filename = iv_filename.
    ELSE.
      " Sub object
      rv_filename = |…{ lv_ext1 }.{ lv_ext2 }|.
    ENDIF.

  ENDMETHOD.
```
2021-12-08 08:07:45 +01:00
Lars Hvam
117aa2b474
CLAS serialization bugfix (#4960)
closes #4959
2021-09-18 06:50:33 +02:00
Marc Bernard
c63d92e6f1
Post-processing option for custom class serializer (#4953)
* Post-processing option for custom class serializer

When using the current exit for serializing classes, you have to code the complete serialization yourself (i.e. reading and formatting the code). 
https://docs.abapgit.org/ref-exits.html#custom_serialize_abap_clif

With this change, you get the option to let abapGit serialize the class first and then post-process the source in the exit. The change is compatible with existing implementations of the exit.

To use the post-processing option, add the following code to the beginning of the exit:

```abap
IF it_source IS INITIAL.
  RETURN.
ENDIF.
```

* Update ref-exits.md

Co-authored-by: Lars Hvam <larshp@hotmail.com>
2021-09-18 06:23:06 +02:00
Lars Hvam
da310e0137
zcl_abapgit_exit: add IF gi_exit IS NOT INITIAL. (#4884)
* zcl_abapgit_exit: add IF gi_exit IS NOT INITIAL.

* set description
2021-07-31 11:28:00 +02:00
Marc Bernard
0d993d4854
Add user exit for event handler (#4766)
* Add user exit for event handler

Closes #4722

* Remove debuginfo change

* Update docs

* Update docs

* fix typo

Co-authored-by: Lars Hvam <larshp@hotmail.com>
2021-05-14 11:01:53 +02:00
Lars Hvam
cac2de1ced
user exit: wall messages (#4653)
* wall messages

closes #4530

* update docs
2021-03-22 13:15:03 +01:00
Alexander Tsybulsky
17eac7b6c3
Strip XML details user exit (#4599)
* exit draft

* call exit

* linter fix

* PRE_CALCULATE_REPO_STATUS docs

* settings UI

* wire status calculation and repo settings

* uppercase

* diff rendering fix

* adjust docs

* adjust docs

* Remove settings

* more docs adjustments

* pass repo meta data into the exit

Co-authored-by: Lars Hvam <larshp@hotmail.com>
2021-03-06 09:35:35 +01:00
Domi Bigl
15dcf41984
add user exit for commit display URL (#4073)
* add user exit for commit display URL

  METHODS adjust_display_commit_url
    IMPORTING iv_repo_url    TYPE zif_abapgit_persistence=>ty_repo-url
              iv_commit_hash TYPE zif_abapgit_definitions=>ty_sha1
    CHANGING  cv_display_url TYPE zif_abapgit_persistence=>ty_repo-url

* adjust UT

* provide also repo name and key in the exit

* Update ref-exits.md

* Update ref-exits.md

Co-authored-by: Lars Hvam <larshp@hotmail.com>
2020-10-28 07:00:37 +01:00
Marc Bernard
caea4865bf
Integration of unit test with CI (#3993)
Co-authored-by: Lars Hvam <larshp@hotmail.com>
2020-10-27 08:15:52 +01:00
Rakshith Gore
14b9c7d864
Deserialize postprocess (#3461)
* Update 3 objects

* Update zcl_abapgit_exit.clas.abap

Pretty printer didnt work in JAVA GUI, so had to manually change the file

* IS_STEP as input parameter

* Issue in JAVA based GUI

Pretty printer not working for class name in implementation

* Move TY_STEP_DATA to ZIF_ABAPGIT_DEFINITIONS

* try moving ty_deserialization_step

Co-authored-by: Lars Hvam <larshp@hotmail.com>
2020-06-08 06:05:49 +02:00
Fabian Lupa
d6dfa424ae Add exit for CLAS CLIF source serialization (#2630)
* Add user exit for serialize_abap_clif_source

* Document CLIF serializer exit

* Add exit redirection for CLIF serializer

* Add link to example for CLIF serialization exit
2019-04-16 05:14:15 -07:00
larshp
ff6725e759 replace uses of log with interface 2019-03-17 01:39:52 -07:00
Lars Hvam
e54cac4bdc
fix for user exit SSL ID (#2373)
* fix for user exit SSL ID

* also pass url to HTTP_CLIENT exit
2019-02-09 23:28:09 -08:00
Lars Hvam
db74b1ea52
Move SSL_ID determination to user exit (#2114)
* docs: change id to parameter

* move ssl_id determination to exit #2102

* docs: add new exit

* update abaplint to latest
2018-11-19 07:15:25 +01:00
Christian Guenter
fbc4896d65 New user exit create_http_client
With this commit one can implement the new user exit method
create_http_client for custom http client instantiation.
E.g. to use RFC destinations.
2018-08-20 18:27:26 +02:00
Johannes Konings
f214fab73d fix some naming convention
https://github.com/larshp/abapGit/issues/1132
2018-08-07 12:03:21 +02:00
Christian Guenter
a38d9feaff Pass log object to user exit method change_tadir 2018-06-13 19:15:53 +00:00
Christian Guenter
c7179ed509 new exit: change_tadir 2018-06-10 10:59:00 +02:00
Lars Hvam
be0b9d0df4
exit to modify http client #1252 (#1253)
plus make sure the program does not dump when implementations are missing in the exit
2018-03-18 15:22:16 +01:00
larshp
ebe43a42c4 lcl_exit to global
breaking change, if using user exit then rename class to zcl_abapgit_user_exit
2018-02-11 10:09:03 +00:00