abapGit – so easy
Are you an ABAP developer? Are you using abapGit?
If you answered “Yes” to the first question did you answer “Yes” to the second question too?
You might be thinking – “What is abapGit?” – so let’s start there. The simple answer is that abapGit is a Git client written in ABAP for ABAP.
Some of you are now thinking “What is Git?”. I’m sorry that is outside the scope of this post but please, please, please use Google to figure that out. And I urge you do it quickly – like “now” – and then return to this post later. Git is a fundamental part of the contemporary developer’s toolkit. IMO ignoring Git is not an option for developers in 2017.
Back to the topic at hand. abapGit is an Open-source project initiated by Lars Hvam under an MIT License.
At time of writing there are 24 contributors to the abapGit project. There have been over 400 commits in the past 5 months alone which shows this is a very active and vibrant project. Maybe you too will want to contribute and help make abapGit bigger and better?
One of the design goals of abapGit is that it should have a “small footprint”. This can mean many things to many people. One thing is it is absolutely the easiest ABAP project to install – EVER! No transports. No multiple steps. No pre-install of other things. No file uploads. No patches required. No add-ins required. Simply copy and paste code into a program on your ABAP development system and activate.
The first thing you might want to do after installation is connect to GitHub so you can keep your abapGit code up to date. Yeah – amazing concept isn’t it? We can pull down the latest version of the abapGit project any time we like. Kapow! Take that CTS! abapGit also has a “background mode” so you can automate this task.
You are highly likely to want to use GitHub for some of your repositories anyway. It is the most popular hosted Git out there, it is free, and it contains some other awesome ABAP Open-source projects like abap2xlxs.
For abapGit to talk to GitHub we have to use TLS. This means we have to install some root certificates on our ABAP system using transaction STRUST. The abapGit installation documentation takes you through how to get these certificates and install them. And there is also a simple test program so you can ensure the connection to GitHub works.
If you want to connect abapGit to other Git servers they may well mandate you use TLS as well and therefore you might have to install other root certificates depending who their CA is.
So now that is done, let’s see how we can link to the abapGit repository on GitHub so we can keep our installed abapGit code up to date with the latest developments. There is a wizard to help you do this in a few clicks of the mouse.
When abapGit is run for the first time it will take you to the abapGit tutorial page. You can also find this via the menu Help->Tutorial. Simply click on the “install abapGit repo” link to kick off the process. You will be asked to confirm that you want to install into package $ABAPGIT. abapGit links Git repositories (repos) to ABAP packages. So we need to store the abapGit artifacts in a local package of their own – in this case $ABAPGIT. You will also be asked if you want to overwrite the ZABAPGIT program you just created. Answer “Ok” to this. Activate all the abapGit artifacts and you are done.
To finalise this post – and hopefully to leave you with just one example of how abapGit changes the game for ABAP developers let me take you through a simple scenario. We need to start by cloning a repo to an ABAP package. I am going to use the sample code from my recent presentations on Building Gateway Services which can be found at https://github.com/grahamrobbo/teched16_example.
See how easy that was? A few clicks here and there and I have all that ABAP code pulled down from GitHub into a package I was able to create from inside the abapGit UI including activated everything. Kapow!
Now watch as I stupidly decide that my code needs a little too much refactoring. I brilliantly decide to delete the interface ZIF_GW_METHODS because I have forgotten how this is used all over the place. Suddenly I have lost important code, the stuff I have is broken, and I can’t activate anything. Arrrggghhhh. I guess I will have to logon to the production system and copy and paste the old code from there to get me back on track? Assuming I can remember all the other changes I had in progress as well.
Or – I can just refresh my package from the latest commit on my GitHub repo. And because I “commit early and commit often” I have lost none of my work in progress either.
And that is just one benefit of bringing Git to the ABAP developer toolset.
RIP Adam West
BREAKING NEWS BREAKING NEWS BREAKING NEWS BREAKING NEWS BREAKING NEWS
In his SAP TechEd Las Vegas keynote presentation Bjoern Goerke announced that “we (SAP) are going to work with the SAP Mentors to embed this (abapGit) into the ABAP design-time“.
You can hear this announcement and see Bjoern’s demo around the 41 minute mark of the keynote presentation replay.
I like this Spot and batman too 🙂 I've never used AbapGit. Two questions like a stranger:
Thanks for the Blog
that are many questions. I think Gregor Wolf and Lars Hvam can give the best answers.
abapGit has a very good documentation http://larshp.github.io/abapGit/ . In my understanding it is not a "cloud" project. You can export to file and use also own local repositories. That people use github for openSource projects is convenience. But real customer applications might be stored on a local repository.
Regarding SAPlink you should for instance ask Gregor Wolf. My understanding is, that abapGit is more powerful than SAPlink, so I doubt that there will be many people that keep improving SAPlink. Nonetheless, you could do this.
Eclipse ADT keeps local versions of code. abapGit is much more powerful than this as it connects to git.So versions can be shared between many developers and repositories. I would not call this an emulation.
I use abapGit since a few months and I am happy that Lars Hvam invested the effort to develop it. I also used SAPlink sometimes to export and import coding. But working with a version control like git is much more powerful and saves me currently a lot of work.
Short answer for your first question: abap2xlsx project has recently switched from SAPlink to abapGit ?
And in abapGit there is such a thing as “offline projects” which are not connected to git and nothing but zip archives when you’re exporting them from the system. So they can be used to pass offline files back and forward. It means abapGit is not only about version control.
For me abapGit is a absolutely advantage for every developer. I just can repeat Graham.. if you do not know GIT at all.. go and get used to it.
I mainly use it to get my templates quick from one system to another system without the need to create everything by hand. A Transport-request is not an option because these are my own small pieces of a solution and abapGit is providing an awesome benefit for it.
I'm still in that phase that my stuff has te be commited to git, but I hope to finish that task before the end of the year:-)
Thanks for your comments - I started to respond to the abapGit vs SAPlink thread but instead went for a new post. You can find it here.
Regarding the certificates. Does a basis person need to perform this task?
Basis probably might need to be aware of it, but something they should definitely know about is the need to activate TLS on your system (if not already done) which requires you to set the cryptic parameters in rz10 (note 510007 referenced by 2110020):
ssl/ciphersuites = 135:PFS:HIGH
ssl/client_ciphersuites = 150:PFS:HIGH
ps. Robbo - All installed, but just need to figure out how to create a repo from a package safely. Almost there...
Thanks Lars - Wasn't hard at all to find the doco I needed that you pointed out and was just taking it one step at a time (unfortunately this step actually failed for me but I'm dealing with lots of authenticated proxies that work one minute, but not the next so figured I'd come back to it another day). Mighty impressive work has been done here!
It’s a great option for developers, my great concern is the installation of the certificates and the communication to the external servers. Many organization doesn’t like to have communication to external providers directly to their backend, sometimes not even with a cloud middleware, and in some cases, backend is not allowed to have internet access at all. That’s something Architecture need to approve. Then certificates installation is a Basis activity that for sure will need approval from infrastructure as well. I am not sure how feasible it is until more and more enterprises change their mindset about online tools directly to their backend.
Yeah, I agree
In abapGit there is also a feature for offline projects, which works with uploading and downloading zip files from the frontend PC, see
I’ve also been working on a git server in ABAP, this way the code does not have to leave the system, see blog https://blogs.sap.com/2017/05/07/abap-using-git-for-safety-and-transparency/
And, of course, you can implement your own Git server inside your firewall if you want to.......but please understand we are only talking about pulling and pushing from your ABAP development system. This is what developers do on all other platforms right now.
I understand that customers need to be comfortable with this but I think it important that they don't treat SAP as a special case. If their Windows systems are getting updates directly from Microsoft servers, if their Unix systems get regular updates from external servers, if their corporate smartphones and tablets get app updates directly from external servers (without any QA process) why can't their SAP developers use an external code management system when the code subsequently goes through a rigorous QA process before even getting close to production?
SAP is not a special case here.
Nice blog Graham!
Just curious, I saw in the video that you have a URL (google) in your SAP Easy Access. I know how to change the image there but how do you make it to be a URL rather than an image?
See this blog from the awesome Former Member.
I have some questions:
- if i understood correctly a developer is able with abap for git to create a local version(clone) of the production code(remote repo) in a development/local package and sync it with git (push, pull). Does this imply that the developer should have installed a local version of ABAP on the local machine or it is possible that the local version and the 'remote repo' are on the same machine. Because as far as i know the usual abap development system is one remote machine where all developers log in and change the code/which is locked if multiple users access the same file?
- now during the clone the package name should change. E.g: the remote repo code (master branch) has package /XYZ/DATA_ACCESS. How to a create a local version of it? Save it in my temporary package /TMP/UNAME? The names of all the files is changed?
- how do i merge a branch to the master branch? how do i solve code conflicts?
- How would you setup a environemnt using abapGit. Environment: development system, test system, performance system, delivery system.
- How can you integrate abapGit and the standard snote delivery?
I typically use abapGit for moving code between systems that are not in the same landscape, this works very well for open source projects.
With abapGit it is possible to work in a lot of different ways, but it is limited by the functionality in the SAP kernel. You can take a look at http://searchsap.techtarget.com/tip/Implementing-modern-practices-in-an-ABAP-development-shop for some suggestions on how to work.
Not implemented, but pull requests welcome. The difficult part is renaming the dependencies, eg structure using data elements
There is a feature under Branch -> Overview for merging branches(feature not documented yet). Conflict handling currently not implemented, https://github.com/larshp/abapGit/issues/797
Not integrated, abapGit is a community project.
I really like the first glance of abapGIT, but I still have a couple of doubts. When we say the program is editted "locally", that means on a file on my machine in a local git repository? Would that be edited through Eclipse?
That's ok for code control, but that means I cannot test different branches (like a release branch for the future) in the same environment, correct?
it is great to see you looking at abapGit.
When running the abapGit git client the "local" repository refers to your ABAP package. The "remote" repo will typically be hosted somewhere like GitHub.
You use the same tools to edit the local repo you always have. ABAP workbench, eclipse with ADT, etc.
As you have make changes you test them and then you commit them so they are inserted into the remote repo. Remember to commit early and to commit often.
There are plenty of different ideas about the best developer workflow - but I like GitHub Flow.
When I want to make changes to my ABAP code I create a new working branch. This means my master branch remains unchanged so I can always return to it easily. Over time I might make many commits to my working branch. Remember to commit early and commit often. 😉
I might even have a few different ideas about the best way to refactor my code. So I can create a different working branch for each idea as I try it out. Those I like I keep - or merge into the original working branch - those that don't pan out I simple delete that branch.
As I switch between branches abapGit pulls down the latest code for that branch from the remote repo and replaces my "local" repo (my ABAP package) with it.
Therefore you can test each branch in turn in your local ABAP environment. You can also revert to the master branch at anytime - for example to apply an emergency fix to the latest production code. And you can then switch back to your working branch and continue your developments.
Once you are happy with your changes you can merge your working branch into your master branch.
I hope that helps.
I am just starting to explore abapGit, but spotted several things that don't work similar way git works with other application servers.
A typical scenario for non-SAP development (i.e. using PHP on Apache with Git) is like:
Now new Developer2 joins the project and needs to start working on different functionality of the same application. What he does is:
What that means:
With abapGit the usage of git is different:
Assuming above as far as the project is developed on same NW server, abapGit seems a very neat tool only for backup and prototyping (using git branching), and an exchange tool accross different NW's server. It does not however leverage power of Git for shared projects, probably due to SAP naming restrictions and the fact that most developers don't have their own NW localhost.
Hoping to hear you thoughts on this 🙂
Thanks for your comments Marcin,
you have highlighted some key issues.
However these issues are not abapGit-specific - they are ABAP-specific.
IMO we need to work towards a way for each ABAP developer to have their own development environment. Virtualisation, containerisation, etc. will all help here but it will take a while.
I would love to be able to provision my own developer instance in minutes. wouldn't that make life easier?
But I agree with you that we should be looking at how other developer tools and techniques work and challenge the ABAP world to move in that direction.
Thanks for your comment. It's sad to hear my worries were resonable. I spotted that unless you share coding with someone else, you could utilize abapGit branching for prototyping. Unfortunately branches merging seems not to work well, so one would be forced to do it at github. This leads to another issue - the github itself.
A free account makes your code public, which would violate most customers' security politics. On the other hand a private one entails additional costs. The solution for this could be leveraging abapGitServer, but it seems to lack this option as well.
With this in mind, I don't think there is an extra feature that isn't covered by existing open source tools.
thanks for contributing to this topic.
Just to pick up on one thing you mentioned – the perceived cost of having private git repositories.
You rightly say that most customers would not be comfortable with public repositories. But I think most customers also have non-SAP development project teams working for them – even if it is only to build their public web-site. Surely they have source control? It is probably git. It is probably a private git repo.
If they can see the sense of a private repo – and be prepared to pay for it – for these projects why would they push back for any other project? This includes SAP projects.
To mis-quote Ethan Jewett – why do SAP teams think they are a “special snowflake”?
p.s. abapGit is an open source project - if you have ideas for improving branch merging please contribute them. 😉 #seewhatididthere
I agree, the total cost of such private repo should be in most customers budget
Not because they think so, but because SAP itself is so. I found that what people treat as something extraordinary in ABAP, has been in daily use in other dev landscapes for years. Consider old ABAP vs OO one. There is still lots of developers that consider switching to OO programming as a new coding fashion. Personally what truely gives me such impression is ABAP 7.4, but I might also be a newbie in here.
Totally agree. Instead of complaining, one should suggest improvements, including myself
I am using abapGit along with the abapGitServer since a couple of months. It's a nice polished product. Good job done to Lars & other project contributors!
Any updates on this feature?
nice to hear you are seeing the value in abapGit. Expect to hear more soon.
As for conflict handling - remember this is an open source project. You can start this work yourself if it is important to you. 😉 #seewhatIdidthere
I said to "Expect to hear more soon". Look above for BREAKING NEWS.
are there ideas how to handle "non-code" artifacts, especially BOPF objects that are stored inside SAP BOPF tables? Maybe (de)serialize the BOPF table content in XML? Inside ABAP server versioning it is afaik not possible to get a diff for BOPF objects.
BOPF objects are supported in the project abapGit-Plugins. If you find there are problems please report them as issues.
Wow, seems like Linus Thorwalds secretly learnt ABAP and is publishing under alias Lars Hvam
Thx and cheers
An interesting theory Rolf. I have never seen them in the same room together.
Just one thing more I'm trying to understand: Can I have different repositories per Project, per Package, or both are essentially the same thing? What if I need to modify a specific program as part of two different projects at the same time, and merge the changes afterwards?
Thanks in advance!!
the abapGit paradigm is that you essentially link an ABAP package to a Git repository. You can make use of the ABAP package hierarchy so that sub-packages are included in the Git repo.
In theory you can link a Git repo to multiple ABAP packages on the same system - but in practise you can't because ABAP does not use the package as part of the object name so you would get duplicate object names. (ABAP namespace issues are many and varied and a mess IMO #justsayin)
I haven't tried it but you should also be able to use a Git Submodule to clone another repository into your project and keep your commits separate.
I know this doesn't answer your question. 🙂
Taking your simple example of "modify a specific program as part of two different projects at the same time" - I guess I need to better understand what you mean.
If you mean that a single project (i.e. git repo) has been replicated to two different ABAP systems and been modified on each you are probably asking how to handle conflict resolution when the two changes need to get merged back into the master branch. abapGit does not support conflict resolution itself yet. It is obviously an important feature that many would like to see supported - and really it comes down to finding some contributors who are motivated to work on this issue.
However most git services (esp. GitHub) include tools for conflict resolution that you can make use of. So when I demo abapGit I show how you can use the GitHub conflict resolution tools to handle conflicts.
I also like the GitHub Flow developer workflow. If you follow this pattern both your developers should create their own development branches. The first developer to merge his branch into the master branch will have no conflicts. The second developer won't be able to merge into master until he resolves any conflicts in his branch. This ensures the master branch is always deployable. Note when using GitHub Flow you should protect the master branch - this ensures you can't commit directly to the master branch but must merge from another branch via a pull request.
If your question is asking for the best way to modify an ABAP program that is going to be deployed to two different ABAP systems then I think the simplest way is to do the development in one of those systems, commit the changes and then pull the updated version onto both systems for testing. This should ensure there are no conflicts which do, after all, complicate the process.
I hope that goes some way to addressing your question.
Thanks for the clarifications, Graham! Just so you know the reason I'm asking all of these questions, my colleagues want to implement Charm for object management in SAP/ABAP. As I know git is a great tool, I am trying to understand whether AbapGIT would improve development productivity/management if used in conjunction or instead Charm.
The way I see now, while Charm would help with better object sequencing/management, git would help with easier management of codes and projects... still working on that puzzle though... will share more about it when getting to an outcome!
very interesting discussion so far, thanks for the insights!
Is anybody using abapGIT in an enterprise production environment yet and can give us some lessons learned? Is it stable enough to use in mission critical systems without fear of breaking "something". What about change management on an organzational level? I would imagine that not evrybody is happy using these new hippster methods of developing software... 🙂
I understand that abapGIT is currently not available for Eclipse ADT? Any plans to adopt it as Eclipse is pushed more and more as standard ABAP ide (at least this is my impression)?
I dó think it is possible to use ABAPGit by Executing the Z-report for ABAPGit directly although I must confess I haven't used it Yet. See this GitHub-issue on ABAPGit Eclipse-Support : link
you can run abapGit from inside Eclipse ADT like any other program - but at this stage it is not provided as an Eclipse plug-in.
Can use ABAPGIT with SAP_BASIS 7.00?
Git client for ABAP
ABAP Version: 702 or higher
ZABAPGIT with a lot of compilation errors(missing classes, types, etc).
Maria João Rocha
Please see https://github.com/larshp/abapGit/issues/635
Thanks for your reply.
I'm going to study.
abapGit – not so easy for 7.00 !
Maria João Rocha
AbapGit doesn't support multi lingual or neither Documentation (Long).
Feel free to open an issue at https://github.com/larshp/abapGit/issues 🙂
Hi Graham, Lars,
there are lots of issues that need to be considered when choosing how far back to backport a project.
The reality is that this is an Open Source project that relies upon its' contributors to donate their time to work on it. Therefore what is doable is directly related to the priorities, interests and resources of those contributors.
For example I have no access to a 4.7 system to develop on - even if the dependency issues could be resolved.
But you do. So by all means raise an issue and see if you can find enough people who would like to contribute to a backport to 4.7. Or even create a pull request for discussion around the topic and see where it goes?
I can't speak for Lars - who knows the code much better than I do - but if you find enough support and resources for this initiative I suspect the best thing to do would be to fork to a new project as the dependencies are huge - much more than the few that are obvious. This means your code line will have to diverge significantly from the main branch.
Hi ABAP Git Magicians,
I want to move a report btw. 2 systems , but the objects are distributed across packages. For example data elements under ZBC and the report within package ZBC_UTIL (under the ZBC package. I do not want to move all (unnecessary) objects of ZBC to the other system. There is an option under Advanced menu to "Object to files". How do I import it in the other system ? Probably the goal of this option is not I want to achieve, but rather place an object to an external repository manually. I would like to do the same as with SAPLink before. To create a nugget with arbitrary objects list and import it in another system. A workaround what I found out, is to create a transport request and record the required objects inside, and after use the transport to zip option(not tried yet). The report was created before the system was upgraded, so the original requests re gone.
What would be the best in your opinion to realize my requirement with ABAPGit ? (I know that Git is project/package based and not like SAPLink, but if I can do this somehow easy, it would be great)
a common problem - and an annoying one too.
I think you are on the right track. Git conforms to a hierarchical filesystem paradigm where a repository is related to a sort of folder endpoint - so all tracked objects need to be children of the same parent. Therefore the obvious structure to link a repo to to is an ABAP package.
It sounds like your objects are all under the same package structure - so that is not a problem for you - but you also want to cherry pick just a few objects and move just them. What this describes is what CTS does - and SAPLink as well.
So I think your strategy of identifying the objects you want and then serialising them and moving them to the target system is probably the only way to do it. Whether you choose to use an SAP transport request, SAPLink or abapGit .zip option probably doesn't matter. The hard bit will be identifying all the dependencies you need to move.
The only other suggestion I have - and it is a slightly mad one - is that you could use abapGit to push your entire package structure to a git repository, clone the repo to your local filesystem, create a new branch, delete all the objects you don't want from that branch, push the branch back to the repo and finally pull down the branch into the new system.
Sorry I have no silver bullet for you.
thank you very much for Your answer. It is very valuable, and I will have it in my mind in the future. I did some reorg/restructuring of objects into several packages/subpackages to proceed with the offline approach, to move only those objects/packages which are dependent.
Finally got to try this out. Wow - it genuinely is *so* easy.
Having imported a transport request the old way, am nearly crying with relief here ;-).
Great stuff Julie - reach out if you have any issues.
Recalling a recent twitter convo we had ...
Thanks Graham - will do, but so far no issues.
I've also DM-ed you on Twtr.
All the best , Julie.
thanks a lot for this wonderful introduction! I have a question regarding abapgit:
Can we use abapgit for distributed development just like in a Java environment, or is it more used for code review, version management (execution of rollback)?
Looking forward to your reply & have a great day!
Absolutely for distributed development. +100
Does AbapGit also include transporting (STMS)?
I was wondering what happens after the code reviews are done in AbapGit – I assume all the objects committed to Git were initially locked in transports (SE10) on the development system, when the programmer first changed them?
Does abapGit have some kind of transport functionality? If so, how does it handle conflicts with objects that might be in other transports?
when explaining the respective responsibilities of abapGit and CTS I try to define them by their very different goals.
abapGit is about code management, including versioning, branching, merging, etc. while you are building code in your development environment.
CTS is about code promotion, i.e. moving code from your development environment to downstream systems/landscapes.
These are gross oversimplifications but for me abapGit is a tool for developers who are building code whilst CTS is a tool to deploy the finished code to downstream systems.
I see them as two very different tools. Others disagree. 😉
So the answer is "No" abapGit does not have some kind of transport functionality although it does allow you to pull down ABAP artifacts into your development system.
I hope that all makes sense.
thanks for this blog post! I’m wondering if the ABAPGit program can help me with the following scenario:
I already tried to save objects via “Advanced –> Transport to zip” and have those files saved locally. What I don’t immediately see is an option to use those files to simply “re-import” them after the refresh. Am I looking in the wrong place if I expect to see the counterpart activity under “Advanced”? And is ABAPGit even suitable for what I’d like to do?
Thanks much and Cheers
glad you are seeing the value of abapGit.
To import a .zip to a package you first need to create an offline project using the +Offline menu.
Then you should be right to go.
But probably a better way to do it - assuming all your ABAP artifacts can be placed in the same package - is to define that package as an offline abapGit project and simply export it to a .zip rather than export a transport to a .zip.
I'm a true Git fan but I'm puzzled when it comes to understand how the main and great benefit from Git can apply to SAP development : having multiple developpers contributing to the same source on the same environnement?
Because the beauty of Git is the distributed architecture which I can't figure out with SAP "all in one place and one and only one active version at a time" paradigm...
What did I missed ?
thanks for your comments - you raise some good points. Many of these have been discussed in other areas such as the abapGit slack channel (abapgit.slack.com) and at various SAP Inside Tracks and other less informal meetups - so let me start with a quick brain-dump of some of the things I find most useful when I am using abapGit to assist my ABAP development.
The most obvious benefit for me is that I can revert to any previous commit quickly and easily. SAP tools provide some support for reverting to previous versions but they are very object centric - whereas the git perspective is repository centric.
I'm not saying this ever happens to me 😉 but if I was to decide to refactor some of my code, maybe break some methods down into multiple smaller more manageable ones, change some data structures, remove some obsolete methods from an interface or two, etc. I might find I have gone down a deep rabbit hole and unintentionally broken things. Maybe a whole lot of dependencies I wasn't aware of are now broken. Now I can't even activate a whole bunch of stuff. I might struggle to even identify all the unintended consequences of my brilliant plan to improve my code. As I said - this would never happen to me.
A few simple code changes might be easy to revert. Perhaps I could use the SAP tools to do that - but we all know (don't tell anyone) that it is easier to just log on to the QA or PRD system to copy and paste the code back into the DEV system. Problem solved. But what about if I had changed many ABAP artifacts? Perhaps dozens or even hundreds? What if I have made changes to non-code artifacts like data dictionary objects that can't simply be copy and pasted back? A full system restore because one developer lost control of his changes seems a bit drastic - and disruptive.
But with abapGit I can just do a "Reset Local" and in seconds I am back to my last commit. Or I could delete my feature branch and create a new one from the master branch to start all over again.
Similarly when building something new I may have a few different ideas about the best way to do it. So I can create a new branch for each idea, start coding, and then I can quickly switch between each branch as I try different ways to solve the problem. Once I have chosen the best one I keep that branch and delete the others.
I am sure these examples give you ideas for many more.
However your point about SAP's “all in one place and one and only one active version at a time” paradigm is spot on too. abapGit can help here because using the git branch concept you can have multiple versions but this doesn't help you with only being able to have one active version in your ABAP system.
I believe the way forward must include discarding the concept that all developers have to share the one provisioned environment. Why can't each developer have their own environment - as they do in most other languages? Modern infrastructure concepts like machine virtualisation, containerisation, etc. make this much easier to achieve than it ever has been before. The Steampunk environment currently provisions a new instance in about 20 minutes I am told. If not a development environment per developer at least per project or per team?
I envisage that a developer could provision their own development environment - which in most respects would be almost a copy of the existing production system. Most organisations take a snapshot of their production system every night. The Friday night snapshot could feed into an automatic process that creates a new "developer" snapshot with a subset of data, anonymisation of data, etc. When the developer chooses to instantiate a new developer environment it takes the latest "developer" snapshot, allows them to nominate abapGit repositories/branches that are required (in lieu of another package management solution) and provisions that instance for them. Hopefully in minutes - not hours.
These new "developer" instances would not require any permanent tracking of changes or inclusion in the good old "transport landscape". They need to be totally independent so that they can be provisioned and discarded without impacting any other system or landscape. Developers would need to "commit early and commit often". This means their developments are no longer tracked inside a nicely managed ABAP system but in a git repository. They can build away to their hearts content but mindful that no one is backing up their ABAP development system - unless they do it themselves. The one source of the ABAP truth is in the git repositories.
Once they are ready the changes can be merged into the master branch which is being tracked by another ABAP system that is recording changes - so they go into transports - and there the developments can be tested and moved through the system landscape until they make it to production in the same way they do now.
Just my 2 cents worth. 😉
Currently playing with similar ideas, not practicing yet
Have a docker instance on aws, can start a new instance from the command line in a few minutes.
Did it for a demo in teched, thinking about doing the same for real, at least as an experiment.
Btw, why stop at development? I'd like to have my QA done the same way 😉
The real issue is customising, still have to try configuration sets or what they are called
Awesome stuff Marcello.
Why stop at development? Because it freaks people out. 😉 The same reason I didn't mention why not have production just pull it's code directly from a git repo instead of having to move it through a transport landscape. LOL
Yep - configuration is a problem yet to be solved.
Honestly I would stick with transports for the time being for the last 2 steps: regression test and production. Partly because I sell a transport related product ? , but mostly because of configuration and the fact that git pulls are still unreliable with sizeable codebases. I can deal with that in DEV/QA, not in prod.
PS: I want a regression test system to validate the stuff I send to production. Ideally with full automated test, but even a bit of smoke test is better than nothing. And I can ensure the transports import correctly too
How do I start contributing to abapGit project? I have created a fork but not sure which folder to be pulled from the repository to make the changes?
Contribution guidelines are here .
Good blog content, Graham Robinson ,
I have a query related to security, since we need to copy the code from abapgit text file and create a report. Doesn't this be a security violation.
You are free to read through the code, as of right now there are 118 people watching the repository, getting notifications about every change, I'd say all code is reviewed by many more people than average ABAP code.
Thanks Lars Hvam
So we can copy the code from zabapgit.abap as mentioned in the URL https://docs.abapgit.org/#security and reuse in our environment. Correct?
abapGit is provided as clear text, also all repositories being installed is in clear text, allowing developers to read and understand the change before importing. With classic transports, the content cannot(?) be investigated before import.
I like AbapGit a lot and used it for saving my developments I made so far. Yet there's a little problem. I had stored my developments under a huge dev-package in a single zip-file, Now I would like to include just one program and a certain class of it into my actual development environment, without having to pull all the other stuff. Is there a possibility to do this easily? Somehow I couldn't find out how to do it.
Thanks for any help.
If you have a zip file, just unzip it, delete the unnecessary files, zip it again and import that.
Alternatively when pulling, you can choose which objects to import, https://github.com/abapGit/abapGit/pull/5985
Thank you for your quick reply!
Deleting the unnecessary stuff finally did the trick - so easy, that I just couldn't see this simple solution. The other alternative didn't really work, as the program seems to do all the checks for all the items, although just a few are selected. Anyways - deleting the unneeded is much easier and quicker. Great help!