WEEK 2

Assignment :

Build a personal site describing you and your final project.
Upload it to the class archive. Work through a git tutorial.

Build a personal website





As a fresher to the field of web designing it was a hard time for me to start designing a webpage .So here are some usefull resources which helped me in creating my website.

1.Ask a friend




‎Since i was totally unaware about where to start this problem i was confused about which platform should i use and where should I look for reference etc.Though these resources are available in the web it was difficult for me to surfe through an ocean i was never been before.So i found asking to a friend is a better option for starting . My fllow fabbers, Instructors and friends helped in this area.

2.Choose an online learning platform




‎If you have some basic knowledge then it should be better to choose an online learning platform is the best option for further improvements.I found W3School as a very good learning platform .It has a well structured documentation, on-site simulator, stylesheets and some pretty good templates .



3.Choose an HTML editor




‎I don't have a lap top . So I must have to use multiple systems to complete my assignments. If I could use a pendrive for storing my files I cauld easly use multiple systems. So my preferences about a text editor were.
I found sublime as a posible candidate . If you are expecting something more I cauld prefer you to use atom , GNU Emacs or bracket all of them are very good platforms But i found Emacs is a bit complicate to use for a beginer and since I was looking for a lightweight one I choose sublime .

week2_gitlab


4.How to learn




‎Here I found the real benefit of W3School. The best way to learn any language is by using it .So I choose a default w3 template and modified my code with some different commands .I observed what changes happened and with some reference about the commands I could able to figure out the working of the code . So this approch improved my working efficiency and reduced my time consumption. There after I modified the code to accomplish my requirements .
For an introduction to the sublime environment this youtube video by Brian Jenney realy helped me.thank you Brian.

Upload to the class archive

Installing and Configuring Git

Git is a distributed revision control system used to manage work flows between multiple people working on the same file. Every Git directory on every computer is a full-fledged repository with complete history and full version tracking abilities, independent of network access or a central server. Git enables us to work on the same repository from different machines. Git tracks all the changes in the file and helps sync them with all the users. The figure shown below will briefly explane how git works[wiki]



Since I was new to git decided to go through a git tutorial. try.github.io is a great platform to learn some basics about git and its usage.



Installing

  1. Go to your accound in Git lab
    • Go to https://gitlab.fabcloud.org
    • Installing Git
      • Open the terminal (Ctrl+Alt+T) and type
      • sudo apt-get install git
    • Generate SSH keys
      • Open terminal (Ctrl+Alt+T) and type
      • ssh-keygen -t rsa -b 4096 -C "your mail id"
      • Enter a file in which to save the key (/Users/you /.ssh/id_rsa): [Press enter]
      • Press enter to chose the default location.
      • Set up a passphrase. This is similar to a password for your Git.
      • A window will open showing you the SSH keys.
      • Id_rsa is your private key and id_rsa is your public key.
    • The next step is to Add an SSH agent
      • Open terminal (Ctrl+Alt+T) and type
      • eval "$(ssh-agent you -s)"
      • ssh-add ~/.ssh/id_rsa # Add key to the agent
    • Add a global username and global email id.
      • Open terminal (Ctrl+Alt+T) and type
      • git config --global user.name "your username"
      • git config --global user.email your mail id
    • The next step is to Add your public key to gitlab account
      • Open terminal (Ctrl+Alt+T) and type
      • sudo gedit ~/.ssh/id_rsa.pub
      • Copy the entire thing and close the gedit window.
    • Open the gitlab account (git.fabacademy.org)
      • Click on Profile Settings → SSH Keys
      • Paste the content under “Key”
      • Give a title to identify which PC has the above Key
      • Click on Add key and Done.

Syncing files with local repository

Git uses two commands to sync files between your local repo and the server these are the 'Pull' and ' push' commands.If you want to clone an already existing git repository you can use the git clone command.



  1. Open terminal by clicking (Ctrl+Alt+T)
  2. Go to your local directory in the terminal using the 'cd' command.
  3. Type git status to see all the files that needed to be added to the server.


  4. Type git add --all to add the files to the index.
  5. Type git commit -m "Initial comment" commit these files to the next push.
  6. Type git pull to get an updated copy of the repository.
  7. Type git push push the indexed files into the server.