4D and Git: From Beginner to Expert

So by now, you know that projects come with a tremendous benefit: the ability to use Git (the revision control system) and GitHub (the hosting service) to get your 4D application up and running in a more productive development environment.

Newbie or full-fledged senior developer version control has been a staple in every work environment where multiple resources collaborate to participate in what could be called a software chain of production.

To help you get familiar with Git, we’ve made available many resources at your disposal. This blog post is a compilation of everything we’ve provided on this topic… so far. If you feel lost and don’t know where to start, keep reading; we’ve included:

  • other blog posts,
  • a detailed guide,
  • a top-rated summit video,
  • and even a training course.


What to read?

1- An introductory guide to 4D and VCS

We recommend reading this detailed guide: An introductory guide to 4D and Version Control Systems, where Damien Fuzeau, Product Owner at 4D, explains how version control systems (VCS) work. And shows how they can easily manage 4D projects and take charge of the source code management part of the 4D Server.

2- How to share your 4D code via GitHub

Once you understand the subject, you are ready to jump and get your hands dirty. Go ahead and set up your GitHub account, the blog post How to share your 4D code via GitHub, shows you step by step how to proceed.




3- Git. Commit. Pull. Push & more

Once your account is set, this blog post shows you some scenarios a developer may encounter, such as cloning a remote repository, ignoring already committed files, and solving merge conflicts.


4- GitHub actions

Your project is now on GitHub. This means managing several versions of your software, monitoring changes, and integrating corrections or new features is much simpler now. Why not also take advantage of continuous integration?

Starting with 4D v19, you can launch the compilation of your project with a command. As a result, you have all the building blocks needed to automate your integration chain.

This blog post will give you an example of automation with the GitHub manager and GitHub Actions.

5- Server code development

And If you are more interested in client/server development and how versioning can fit into it, it’s highly recommended to check Server code development in project applications.


What to watch?

Interested in more details and concrete examples? Here is a breakout session on 4D and Git presented by Ahlam Benhachem, a development engineer at 4D Morocco, where she shows you step by step how to use Git with GitHub for your 4D application:


How to access all 4D projects?

Again, with the introduction of projects in 4D, the source code of components, demo applications, and other tools in 4D are hosted on GitHub. And you have access to everything.

4D has three GitHub organizations.

  • On 4D, you can find the source code of the internal 4D components. So you can adapt them to your needs.
  • 4D Depot contains all the help tools: HDIs, demonstrations, application examples, etc.
  • 4D Go Mobile hosts all custom list forms, detail forms, login forms, formatters, and input controls. 

Read this blog post from Vanessa Talbot, Product Owner at 4D, to learn how to improve your usage and navigation on GitHub.



What about a training course?

Yes, we got you covered!

The past month, Thomas Maul, VP of strategy at 4D, delivered a training where he showed how to work with 4D and Git using practical examples and get your 4D application up and running in a more productive development environment. In case you are interested in knowing:

  • How to create a Git repository on GitHub.
  • How to push code changes and deal with merge conflicts.
  • How to fix a bug in the development and deployment branches (without having to do the work twice).
  • How to run multiple branches in parallel (development version, LTS delivery, and a beta version).
  • How to try out a new idea, feature, or concept in your code in a way that doesn’t affect a main stable release.


These sessions are for you and will be available soon! 


Where to go from here?

If you think these resources are insufficient or need more information, please contact us on the 4D forums; we will be happy to help ?.

• Product Marketing Manager • Intissar joined 4D in 2017 as a Product Marketing Manager. She works closely with the product, marketing, engineering, and technical support teams to highlight the ‘why’, the ‘how’, and the ‘what’ of new and updated features to different audiences. This close proximity allows her to craft messaging frameworks and write in-depth content and code samples for the 4D blog and website. After graduating with an engineer's degree in Computer Science from VINCI university, Intissar worked in several startups as a software engineer. Her hands-on experience includes software specification, design, and development, user training and support, and team management.