- Description
- How to use it
- 1. Setting up Bitbucket
- 2. Setting up Gitpod
- 2.1 Debug Gitpod:
- 3. build-one commands
- Problems and solutions
Description
For development with Build.One, we use the Git process.
- Branch: In version control systems, a "branch" is a separate line of development that allows you to work on a specific set of changes or features without affecting the main codebase.
- Feature Branch: A "feature branch" is a type of branch used to isolate and develop a new feature or functionality within a software project, keeping it separate from the main code until it's ready for integration.
- Commit: A "commit" is a snapshot of the changes you've made to your code, typically accompanied by a message that describes what the changes are for. Commits are used to track and record the history of code changes.
- Pull Request: A "pull request" (often abbreviated as PR) is a request to merge changes from one branch, typically a feature branch, into another, usually the main or master branch. It allows for review and discussion of the proposed changes before merging.
- Merge Conflict: A "merge conflict" occurs when the version control system cannot automatically merge changes from one branch into another due to conflicting changes in the same code regions. Resolving these conflicts is necessary before the merge can proceed.
- Merge: "Merge" is the process of combining changes from one branch into another, typically to integrate new features, bug fixes, or improvements into the main codebase. Merging can be done automatically or with manual resolution of conflicts.
- Hotfix: A "hotfix" is a type of branch created to address critical issues or bugs in the production code quickly. It allows for the swift development and deployment of urgent fixes without disrupting regular development work.
For this purpose, we use tools like Bitbucket. A version control tool, often referred to as a version control system (VCS), is a software application that tracks changes to files and directories over time. It allows multiple contributors to collaborate on a project by managing different versions of the code, enabling efficient tracking, coordination, and rollback of changes, ensuring code integrity and facilitating teamwork in software development.Of course, any other version control tool such as Github can also be used.
For developing with Build.One, we use a cloud-based and containerised online IDE. These Gitpod workspaces are used to implement the code, open Build.One in the developer overview, and develop the application there.
How to use it
1. Setting up Bitbucket
- Create a new Bitbucket Repository
- Open bitbucket.org
- Create a new repository
- Select a project
- Give it a name i.e.
myapp
- please keep it lowercase and usehyphen -
to structure if need be - Do not include
README
- Access Level
Private repository
- Enter default branch name
main
- Include
.gitignore
in order to have a first commit. This allows it to be started with gitpod. - Press
Create repository
- Use the Gitpod extension to start a blank workspace
- Copy the plain starter Build.One repository (This step is typically handled by the Build.One Onboarding Team)
- Commit and push the copied repository
2. Setting up Gitpod
- Create an organization in Gitpod for your company.
- Create a project for Build.One within Gitpod. (Watch out, do not use your personal workspace, unless it is a personal project)
- Choose your newly created Bitbucket repository from step 1.
- Navigate to Project Settings and create the following environment variables:
- The following variables must be created here (provided by the Build.One Onboarding team during setup):
- BUILDONE_TOKEN
- FONTAWESOME_NPM_AUTH_TOKEN
- GITPOD_IMAGE_AUTH
- Navigate to the "Prebuild" section and run a prebuild for your "develop" or "main" branch.
2.1 Debug Gitpod:
- Prebuilds are not working, reasons could be:
- No credits are assigned to the corresponding gitpod team → Add credit card information
- The connection between bitbucket and gitpod is missing, no webhook in bitbucket available → recreate the gitpod team by a bitbucket admin
3. build-one
commands
In the terminal of the GitPod UI, you can call build-one
to retrieve a list of commands. Here we briefly explain some of the useful commands.
build-one init
- Installs Build.One into the current development environment.
build-one update [version|latest]
- Updates the Build.One framework.
build-one up
- Starts the Build.One stack.
build-one down
- Stops the Build.One stack.
build-one destroy
- Stops and destroys the Build.One stack. Use with caution! Data loss possible! 🔥
build-one preview
- Opens a Simple Browser preview window.
build-one env
- Sets the Build.One environment variables.
build-one trim
- Trims the PASOE agents and updates the backend cache. Use this command to ensure that your backend changes are reflected in the application within the development environment.
build-one extension
- Installs the Build.One extension.
build-one import
- Imports the application-specific data.
build-one genver
- Generates a version file and optionally tags it using Gitversion.
b1 update <SWAT Version>
- Update to latest SWAT Version
build-one
you can also use b1
e.g. b1 preview
Problems and solutions
To see how to create a branch and start working see Version Control
Back to Documentation
Back to Home Page