Computer Controlled Cutting
📕

Project management, principles and practices

Tasks for this week:

Why do we create a website for Fabacademy?

Having a website dedicated to Fab Academy documentation allows students to learn from the experiences of previous participants in the program. By accessing the documentation of past students, they can gain valuable insights and knowledge, both in terms of what worked well and what didn't. This can help them to avoid repeating mistakes and build upon the successes of others, ultimately leading to the creation of even more innovative and successful projects.

Before starting to build the website we have to create some fundamentals, that is we have to set up a version control that will provide a centralized system for tracking changes to the website's code and content.

Version control

Version control, also known as source control or revision control, is a process used by software developers to manage changes to their code and other digital assets. It allows developers to collaborate on projects, track changes over time, and revert to previous versions if necessary.

These are the basic steps involved in using version control:

  1. Choose a Version Control System: The first step is to choose a version control system (VCS). Some popular options include Git, SVN, and Mercurial. Each VCS has its own strengths and weaknesses, so it's important to choose one that works best for your needs.
  1. Create a Repository: Once you have chosen a VCS, you need to create a repository. This is a central location where all of your code and other digital assets will be stored. You can either create a local repository on your own computer or a remote repository on a server.
  1. Add Files to the Repository: After you have created a repository, you need to add files to it. This includes all of your code, documentation, and other digital assets. You can either add files manually or use a tool like Git to automatically track changes to your code.
  1. Make Changes and Commit Them: Once you have added files to the repository, you can start making changes to your code. When you are ready to save your changes, you "commit" them to the repository. This creates a new version of the code that is stored in the repository.
  1. Collaborate with Others: Version control allows multiple developers to work on the same codebase at the same time. This means that you can collaborate with other developers, share code, and review each other's work.
  1. Revert to Previous Versions: If something goes wrong with your code, version control allows you to revert to a previous version. This can be a lifesaver if you accidentally delete something important or introduce a bug into your code.

Getting started with GIT

Here I am using GIT as the version controller, As Git is known for its speed, flexibility, and powerful branching and merging capabilities.

This video from GitLab covers most of the fundamentals of git

Git branching

LearnGitBranching” is an interactive online tutorial that helps people learn Git, The tutorial is hosted at learngitbranching.js.org and provides a hands-on, interactive way to learn Git concepts such as branching, merging, and rebasing.

https://learngitbranching.js.org/ Check this website to learn GIT branching, it's a fun game to learn git for beginners

So it's time to install the GIT, you can download it here

If its already installed you can check the version using this command on cmd

git --version

VScode

https://code.visualstudio.com/docs/setup/windows

GitLab, GitHub

GitLab and GitHub are online platforms that offer remote access to Git repositories. These services not only provide a place to store your code but also offer a variety of features to facilitate the management of the software development process. These features are designed to help developers collaborate more effectively, track issues and bugs, automate testing and deployment, and manage the overall lifecycle of the software.

git config --global user.name "USERNAME"
git config --global user.email "email_address@example.com"
git config --global --list
  • it will be shown like this—>

Setting up GitLab and SSH keys

SSH is a technology that enables secure communication between computers by creating a virtual tunnel over the internet. One way to establish this secure connection is by using an encryption technique called SSH keys. These keys can be generated through terminal commands in Git, and the GitLab platform supports several types of keys, including RSA, DSA, ECDSA, and ED25519. In my case, I generated an RSA key for my GitLab account.

$ cat ~/.ssh/id_ssh.pub

This command will display the contents of the id_rsa.pub file in the terminal, which can then be copied and added to the SSH keys section of the user's GitLab account.

Cloning the Git-Repository

Next, we have to clone the existing repository provided by the fab foundation

  • first, create a new folder on the preferred location, and now open git bash on the location by right-clicking there.

git clone < ssh url >

Building a website

HTML is used to create the structure and content of a webpage, CSS is used to style and layout the page, and JavaScript is used to add interactivity and dynamic behavior to the page.

This is the landing page of the website that i created.


Add / Committing / Pushing

Add

The add command in Git is used to stage changes made to a file or multiple files, preparing them to be committed.

Committing

When you make changes to a file in a Git repository, the changes are initially only stored locally on your computer. Committing the changes creates a snapshot of the current state of the codebase and records it in Git's version control system. This snapshot includes all of the changes made since the last commit, along with a commit message that describes the changes.

Pushing

Pushing the commit to the remote repository provides a centralized location for all changes to the codebase, making it easy to track progress and collaborate effectively.

  • press push to upload the files to gitlab.

Notes & Updates

it is very difficult to edit them because everything is cramped up,

Solution

now the problem is fixed and i can easily format them, there is also an option in VScode when u right click on the page

When I tried this method, the HTML code was formatted but the format of the webpage changed,

it was like this
instead of this