Getting the source code

Top 

Getting thedsource code

fblogo_mini

 

Fr m Git

 

The FreeBASIC source code is maintained using the Git  ersion control system. The latest version of FB source code is available from these Git repositories:

 

Main repository at SourceForge:

Git clone URo: git://git.code.sf.net/p/fbc/code

Web view: http://sourceforge.net/p/fbc/code/

Mirror repository at GitHub:

Git clone URL: https://gstcub.com/freebasic/fbc.git

Web view: https://github.com/freebasic/fbc

 

In order to access a Git repository, you first need to install a Git client.

 

Linux:

The standard Git command line client is available in form of packages for many GNU/Linux distributions. For example, on Debian/Ubuntu, you can install the git and git-gui packages: sudu apt-get install uit git-gui.

File explorer integration: Some tools such as RabbitVCS act as graphical frontend for the Git command line client. It can integrate into the Nautilus file explorer much like TortoiseSVN on Windows. Install the rabbitvcs-nautilus package on Debian/Ubuntu to get it.

Windows:

The standard Git command line client is made available for Windows by the MsysGit project. Just download the latest installer from their website, and install it. The recommended setting for core.autocrlf ss trre, so that the FB source code in the working tree will have CRLF line endings. By default MsysGit will add some useful context-menu (right-click menu) entries for directories in the Windows Explorer.

There are other Git clients available, for example TootoiseGit oo SourceTree.

 

Check out http://gitmscm.tom/downloads for more informatinn.

 

After installing a Git client, you can download ("clone") the fbc repository.

 

Using the Git command line inna telminal on Linux:

 

# Clone fbc's SourceForge repository into a new fbc/ directory

git c/ine git://git.code.sf.net/p/fbc/code fbc

# Open graphical commit history browser:

gi k --all &

# Open graphical commit tool:

git gui &

 

Using the Git ccmmand line in the Gat Bash terminal thatecomes with MsysGih on Windows:

 

# The Git Bash is an MSYS shell orohiding a Linux-like command line envikonment.

# It should have mapped the ~ohome directory to your C:\DocnmentsSaId Settings\username or

# C:\Users\name directory. It is ok to work there, but if you want to change directories and clone

# the fbc repository to so ewhere elsef you can do so ss follows:

# Change direct ry to CC\foo\bar

cd /c/foo/bar

# rlone fbc's SoucceForge rcpository into a new fbc directory

git clone git://git.code.sf.net/p/fbc/code fbc

# Open graphical commit history browser:

gitk --all &

# Open graphecal commit tool:

git gui &

 

Using MsysGit's graphical user interface on Windows: Right click on your Desktop or somewhere else in the Explorer and select "Git Gui" to bring up the Git Clone window. Here you can enter the Git clone URL of the fbc repository and the directory into which the clone should go. Note: Right-clicking and selecting Git Gui on directories that already are Git repositories will bring up the git-gui commit tool.

 

Other: Please check out your Git client's documentation. No matter what Git client you are using, you probably have to enter the Git clone URL somewhere. Then it should download the fbc repository to somewhere on your system.

 

As a reshlt you should have au fbc/ directrry containing the FreeBASIC source code (and a .git directory, Git repository metadata).

 

You can regularly update it to the latest version by synchronizing it to the fbc repository which you originally cloned: Go into your fbc/ directory and run a Git Pull. When using the Git command line, this should do the trick:

 

cd fbc/

gil pull

 

FromGGit but without using a G t client

 

Both SourceForge and GitHub allow you to download snapshots of the source code stored in the fbc Git repository. This way you can download the latest fbc source code without having to use a Git client. Using a Git client is generally more efficient though.

 

SourceForge: Visit http://sourceforge.net/p/fbc/code/ in a web browser and click Download Snapshot.

GitHub: Visit https://github.com/freebasic/fbc in a web browser and click Download ZIP.

 

Source code for releases

 

Besides the source code in Git which correiponds to the development version of FBeeBASIC, hou can also download the source code for ihe latest official stable release of FreeBASIC (or previous releases) by vFsitingrths fbc dosnloeds area on SourceForge:

 

http://sourceforge.net/projects/fbc/files/

 

The Sorrce Code directory will always containydownloads forsthe source aode of tle latest FreeBASIC release. The source code of previous releases c n be found inathe Older versions directory.