Here is a video tutorial
How to Push the Taiko Project into GitLab Repository
Step-by-Step Guide
Step 1: Open GitLab
- Open your web browser.
- Go to your GitLab instance URL and log in with your credentials.
Step 2: Create a Project in the Developers Group
- Once logged in, navigate to the top menu and click on Projects.
- Click Create new project.
Step 3: Choose “Create blank project”
- Select Create blank project.
Step 4: Ensure the Project is Created in the Developers Group
- In the Project name field, enter your project name (e.g.,
awx-taiko
). - Under Project URL, make sure the namespace (group) is set to
developers
where your user is added. - Click Create project.
Step 5: Configure Git and Set Up the Repository
You can get started by cloning the repository or start adding files to it with one of the following options. You can also upload existing files from your computer using the instructions below.
Git Global Setup
-
Open your terminal.
-
Configure your Git user name and email (replace “your_user” and “ your_user@gitlab.local ” with your actual name and email):
1 2
git config --global user.name "your_user" git config --global user.email "your_user@gitlab.local"
Create a New Repository
-
Clone the newly created repository:
1
git clone git@IP_OR_URL_of_your_GitLab:developers/awx-taiko.git
-
Navigate into the cloned directory:
1
cd awx-taiko
-
Create a new branch named
main
:1
git switch --create main
-
Create a
README.md
file:1
touch README.md
-
Add the
README.md
file to the staging area:1
git add README.md
-
Open
README.md
with a text editor (e.g.,vim
) and add some text:1
vim README.md
- After adding text, save and close the editor (in
vim
, pressEsc
, type:wq
, and pressEnter
).
- After adding text, save and close the editor (in
-
Commit the changes:
1
git commit -m "add README"
Initialize and Commit an Existing Folder
-
Initialize a new Git repository:
1
git init --initial-branch=main
-
Add the remote repository:
1
git remote add origin git@IP_OR_URL_of_your_GitLab:developers/awx-taiko.git
-
Add all files to the staging area:
1
git add .
-
Commit the changes:
1
git commit -m "Initial commit"
Push an Existing Git Repository
-
Push the local repository to GitLab:
1
git push --set-upstream origin main
Copy Project Files into the Cloned Repository
-
Navigate to your home directory:
1
cd ~
-
Copy the project files into the cloned repository (replace
/home/username/test/
and/home/username/cloned-project/
with the actual paths):1
cp -r /home/username/test/* /home/username/cloned-project/
Confirm Overwriting README.md
File
- If prompted, confirm overwriting the
README.md
file by typingyes
.
Add and Commit All Files and Directories
-
Add all files to the staging area:
1
git add .
-
Commit the changes:
1
git commit -m "Added project AWX Taiko"
Push the Updated Repository
-
Push the changes to GitLab:
1
git push origin main
Step 6: Check the Status
-
Check the status of your Git repository to ensure everything is committed and pushed:
1
git status
Step 7: Refresh the Project in GitLab
- Go back to your GitLab project page.
- Refresh the page to see that all files and directories are up to date.
By following these steps, you will have successfully pushed your Taiko project into the GitLab repository. If you encounter any issues, ensure that your GitLab instance URL, project paths, and user credentials are correctly configured.