Release RMC-06.02
(2024-04-29)
|
Contents
Description
Description
Environment
OS / Shell
GBS runs on:
WSL Considerations
You will need:
- X server (e.g. Xming)
- Additional bash commands:
- Optionally a Desktop environment (e.g.: GNOME, Xfce, KDE, etc)
More information: Install Notes→Environment→WSL
Linux considerations
On some Linux distributions some necessary bash commands are not installed.
You will need:
More information: Install Notes→Environment→Linux
Perl
GBS is based on Perl-scripts.
Perl must be installed and the perl command must be either in the PATH or
specified via an Environment-Variable (GBS_PERL_PATH).
You need at least Perl version 5.16.3.
More information on installing Perl for GBS can be found in
Install Notes→Environment
Install
GBS can be installed in two ways:
- Single User:
GBS will be installed in your environment.
Setup (make this version current) is optional.
A Local Shortcut will be created to run the Setup.
- Multi User:
GBS will be installed in a System area or on another global accessible location (E.g.: network drive).
A System Shortcut will be created for individual users to Setup this version.
Elevated privileges are required. (Linux: sudo -E, Windows: Run as Administrator).
If GBS is pre-installed (local or on a network drive) you will then only need to do the
Setup as explained below.
If you need to install GBS yourself:
- Obtain the GBS Installation file (.zip)
- Unzip the file to a temporary location
Follow the instructions in the ReadeMe.txt file.
Do not unzip the file at the location where you want to install GBS!
- Run Install as explained in the ReadMe file
- Defaults are fine for QuickStart!
- You will need to provide a Site-ID
and a Company name
More info on Install: Install Notes→Install
Setup
To setup GBS:
If setup was not executed by Install:
- Use the 'GBS Setup [version]' shortcut to start the Setup.
It may be on your Desktop and/or the Programs Folder.
If it is not present (maybe you do not have a desktop or deleted it...):
- [ Inquire at your GBS Administrator
where GBS is installed. ]
- Navigate to the directory where the wanted GBS-version is installed.
e.g.: Q:\Tools\RMC\GBS\2.02
- You may need to open a Terminal there
- Execute:
_gbssetup.bat (Windows) (Mind the '_'!) or
. _gbssetup.sh (Linux) (Mind the dot, the space and the '_'!)
- Answer the questions.
- Defaults are fine for QuickStart!
- Possible values are between ( )
- Default value is between [ ]
- Enter ! to quit processing safely
Lines beginning with a '|' (vertical bar) are grouped in a 'form' with an 'OK?' question
at the end. (N will repeat the questions, E will Cancel)
What happens on Windows:
- Some internal stuff is setup
- A GBS Startup and a GBS Help shortcut are placed on your Desktop and in the 'All Programs' menu.
What happens on Linux:
- Some internal stuff is setup
- An alias gbsstartup is added to your ~/.bashrc or ~/.bash_aliases file
- On systems with a Desktop (e.g. GNOME, Xfce, KDE, etc) a GBS Startup and a GBS Help shortcut are placed on
your Desktop and in the 'All Programs' menu.
More info on Setup: Install Notes→Setup
Startup
Startup GBS
Use the 'GBS Startup [cur]' shortcut to startup GBS.
It may be on your Desktop and/or the Programs Folder.
If it is not present (maybe you do not have a desktop or deleted it...):
- On Linux you should have a gbsstartup alias.
- Open a Terminal
- Enter: gbsstartup
- else
- [ Inquire at your GBS Administrator
where GBS is installed. ]
- Navigate to the directory where the wanted GBS-version is installed.
e.g.: Q:\Tools\RMC\GBS\2.02
- You may need to open a Terminal there
- Execute:
_gbsstartup.bat (Windows) (Mind the '_'!) or
. _gbsstartup.sh (Linux) (Mind the dot, the space and the '_'!)
You will be presented a choice of functions.
Enter: gbs
The general GBS command line interface is started.
The first time you startup GBS you may need to give its some additional information:
Just answer the questions.
Define your own editor
In GBS you use the gbsedit command to edit (GBS) files. Sometimes other GBS
functions may invoke the editor
The gbsedit command has a lot of builtin knowledge of .gbs files.
It will also aid you in editing your code.
By default GBS uses Notepad on Win32 and gedit on Linux.
You may want to change that to your favourite editor:
gbssettings → Change Config settings → Edit Editor
Make sure you use an editor that startup fast after multiple invocations (or stays alive).
Use a different Terminal type
By default GBS uses CMD Console on Win32 and xterm on Linux.
To change the current Terminal:
gbssettings → Change Config settings → Edit Terminal
Supported Terminals:
- Win32: CMD Console, Windows Console
- Linux: gnome-terminal, konsole, uterm, xterm (, WSL Console)
GBS Manual Page
To obtain current information on all implemented GBS commands enter:
gbsman
GBS Help
To obtain extensive Help in HTML format (including this page) enter:
gbshelp
Getting Started
Organising your GBS-WAs / Systems
You can place a GBS-WA/System anywhere you want. You can also have them all on totally different locations.
They do not need to be grouped in one directory, although that is a good idea.
The default for the GBS WorkArea Path is:
- Win32: %MyDocuments%\GBSWA
- Linux: ~/Documents/GBSWA
SystemName and SystemId
The SystemName is the generic name of your project.
The SystemId is the parent-directory of your GBS WorkArea.
It is important that SystemId reflects the SystemName:
- For the main (trunk) version: The SystemName
- For different versions: The SystemName followed by '_' and the version number
Remember that GBS does not like spaces in directory and filenames and that they are case sensitive!
Yes, also on Win32!
Connect to an existing GBS System (--add)
- Create the SystemId directory
- Checkout the SCM workarea under that directory
cd to that directory (if you are not already there)
- Enter swr --add and answer the questions.
Note that you can only --add a System if it was originally created with
swr --new (below)
Create a new GBS-WA/System (--new)
You enter swr --new.
Creating a new GBS-WA is serious business.
You can find out how to do it in Create a GBS-WA/System
A good understanding of the concept and principles of GBS is needed.
Once done however, things get extremely simple, convenient and fast.
Commands
Use GBS to navigate through your directories
After you have once set them GBS 'remembers' the following 'currencies'
- Current System (per User)
- Current SubSystem (per System)
- Current Component (per SubSystem)
- Current Build (per System)
- Current Audit (per System)
- Current Tool (per System)
Displaying Currencies
To display your currencies just enter: gbs
Currency commands
swr Switch System: set/change the current System (and SubSystem (and Component))
sws Switch SubSystem: set/change the current SubSystem (and Component)
swc Switch Component: To set/change the current Component. This command ends with an explicit cdsrc
swb Switch Build: set/change the current Build
Basic commands
gbsedit Create/Edit a file (you can define your own editor with gbssettings )
gbsbuild Compile, Link, etc. one or more files
gbssysbuild Compile, Link, etc. the whole System (Runs in batch - with logfile)
Navigation commands
| cdlog | | cd to the log directory as specified by GBS_LOG_PATH (or $HOME)
| |
| | cdsystem | | cd to current System
| | cddoc | | cd to the doc of the current System
| | cddev | | cd to the dev of the current System
| | cdext | | cd to the ext of the current System
| | cdres | | cd to the res of the current System
| | cdsys | | cd to the sys of the current System
| | cdsysbuild | | cd to the sysbuild of the current System
| | cdsysaudit | | cd to the sysaudit of the current System
| | cdsystool | | cd to the systool of the current System
| | cdsilo | | cd to the silo of the current System
| | cdtmp | | cd to the tmp of the current System
| |
| | cdsub | | cd to the current SubSystem directory
| | cdbuild | | cd to the build directory of the current SubSystem
| | cdaudit | | cd to the audit directory of the current SubSystem
| | cdtool | | cd to the tool directory of the current SubSystem
| | cdcomp | | cd to the comp of the current SubSystem
| | cdimport | | cd to the import of the current SubSystem
| | cdexport | | cd to the export of the current SubSystem
| |
| | cdapp | | cd to the app directory of the current Non GBS SubSystem
| |
| | cdsrc | | cd to the src directory of the current Component
| | cdinc | | cd to the inc directory of the current Component
| | cdloc | | cd to the loc directory of the current Component
| | cdbld | | cd to the bld directory of the current Component
| | cdbuild | | cd to the bld/Build directory of the current Component / Build
| | cdaud | | cd to the aud directory of the current Component
| | cdopt | | cd to the opt directory of the current Component
| | cddat | | cd to the dat directory of the current Component
| | cdsav | | cd to the sav directory of the current Component
|
Other GBS commands
Note that all GBS-commands accept --h for short help and
--help for long help
Commands to compile, link, etc directly
Commands to compile, link, etc using 'make'
Commands to run Audit programs like QAC and QAC++
This command enables you to select and execute a number of GBS maintenance functions.
Like:
- Clear all 'bld' directories
- Fix/Repair the SubSystem directory structure. (add missing directories)
- Define compilers, builders
- Define Audits (QAC, PCLINT, C++Test, etc)
- Maintain Component 'owner's' file
- More...
This command enables you to define your customizations. (Beeps on/off, Define Editor, etc.)
This command enables you to select and execute SCM-related functions in GBS.
There are a lot more command in GBS. They can be found at All Commands.
General notes on the GBS command-line environment
In a prompt, possible values are embedded in parenthesis
e.g.:
GBS: Are you sure? (y/n):
In a prompt, the default value is embedded in square brackets
e.g.:
GBS: Are you sure? (y/n)[y]:
Entering a single '!' will quit the script.
Entering a single '?' will give you some additional help (if available)
In general, options for GBS-commands start with -- (double hyphens).
This is to be able to discern options for GBS and options for applications (like QAC)
All GBS-commands accept --h for short help and --help for long help
More in The Command-line Interface
|