Skip to content

valenzano-lab/labsite

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Valenzano lab website repo

This document contains the instructions on how to contribute to the development and maintenance of the Valenzano lab website at the Leibniz Institute on Aging.

The Valenzano lab website is written in RMarkdown and is built using the Distill package.

---
title: "Valenzano Lab"
description: |
  Evolution and ecology of aging 
site: distill::distill_website

output:
  distill::distill_article:
    theme: theme.css
---

If you are a member of the Valenzano lab and are interested in actively contributing to the lab website, please do the following:

  1. get your own github account
  2. familiarize yourself with git, version control and markdown
  3. request to Dario to add you as a collaborator on this repo.

Once you are a collaborator on this repo, you can contribute to improving its content by issuing pull requests.

How to push changes to the 'master' branch

username$ git status
username$ git add .
username$ git commit -m "description of changes"
username$ git push -u origin main

How to create a new branch

username$ git branch -a # to list all your current branches
username$ git checkout master # to switch to the branch 'master'
username$ git checkout -b develop # creates a new branch named 'develop'

Now you can commit and push changes on 'develop'

username$ git checkout develop # puts you in the 'develop' branch in case you're not there
username$ git add .
username$ git commit -m "whatever" # commits your changes to the branch 'develop'
username$ git push -u origin develop # pushes your commits to the remote branch 'develop' 

Merging branches ('develop' into 'master')

username$ git branch -a
username$ git checkout master 
username$ git merge develop
username$ git push

Deleting a remote and local branch (don't do this unless you know what you're doing)

username$ git push -d origin develop # in this case we're deleting the branch 'develop'
username$ git branch -d develop

As a rule-of-thumb, do not push your changes to the 'master' branch.
Rather, first push your changes to a remote branch, like 'develop', and only then merge on the 'master' branch following the instructions above.