Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 2 additions & 71 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
# The use of Git in Statisical Programming

🚧 This repository is under construction yet. 🚧

It is intended to support the working group for the use of **Git in Statistical Programming**.
This repository supports the working group for the use of **Git in Statistical Programming**.

If you are interested in joining, please go [here](https://advance.hub.phuse.global/wiki/spaces/WEL/pages/90472449/The+Use+of+Git+in+Statistical+Programming) to find out more!

Expand Down Expand Up @@ -37,75 +36,7 @@ You can get involved in one of the following ways

2.3 - You can propose a merge request via a fork if you see something that needs fixing

If you want to update content, please read this [contributors guide](https://phuse-org.github.io/git-in-statistical-programming/Contribute.html)

### 2.3. Using Git, to propose changes!


<details>

<summary>2.3.1 About cloning, branching and pushing</summary>

Basic steps to get into this "Git world"

0- Ensure you have installed Git, and you use the terminal to go to your favorite directory.

1- Clone the repo from your terminal `git clone https://github.com/phuse-org/git-in-statistical-programming.git`

2- Create a branch with your username `git checkout -b yourname_dev` All the changes and contributions will be done here

3- once this is done, add changes to stage `git add .`

4- once this is done, commit the changes with a message `git commit -m " i did this change (your summary of the changes)"

5- finally push the changes! `git push origin yourname_dev`

6- if you go now to the repo https://github.com/phuse-org/git-in-statistical-programming.git you will see at the top a message saying your changes has been pushed into your named branch.

7- if you want your changes being in the "main" branch (default page), you have to create a merge request. (green button top right saying "compare & pull request")



💡NOTE: If you like to use your Chat GPT to teach you more about these steps, use it. No fear to break anything!
💡NOTE2: There is a wonderful tutorial in [Coursera] (https://www.coursera.org/learn/making-data-science-work-for-clinical-reporting#modules) to practise on your own how to do these steps. Very easy and well explained (and you get a certification 🎓 at the end!)

</details>



<details>

<summary>2.3.2 About R</summary>


This repository will be using quarto. To support this repository, there is an **renv lock** file which is currently bare bones.
(This means we can keep traceability of the R packages we are using within this repo)

```R
# reinstall environment packages
renv::restore() # to install packages required

# if you made changes to the environment (installing new packages) you can save them by:
renv::snapshot()

```

For the poster it would be nice to have some stats in a jupyter or Rmarkdown about issues around Git (or some charts explaining key points).
To start with,

0 - after you have clones the repo in your laptop

1 - you are in your branch

```sh
# in terminal, within your project directory
#create your own git branch:
git checkout -b yourname_dev
# or switch to your branch
git switch yourname_dev
```

2- A folder called **"script_ideas"** will be the SANDBOX with your scripts/ collaborative scripts/pictures to get some charts/numbers around this topic (for the paper or poster, or to discuss in our meetings).

</details>


108 changes: 108 additions & 0 deletions site/Contribute.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
---
title: "Contributor Guide"
page-layout: full
toc: true

---

# Introduction

This short guide looks at how you can contribute to this project.

# Signing up

You do not need to join the working group to make contributions to this repository, but you are welcome to do so by [going here]([go here](https://advance.hub.phuse.global/wiki/spaces/WEL/pages/90472449/The+Use+of+Git+in+Statistical+Programming))

# Commenting on issues

[Issues](https://github.com/phuse-org/git-in-statistical-programming/issues) are available to anyone with a public Github account. You can simply comment or even open new issues if you have an opinion on a subject there.

You can also join in the more [wide ranging discussions](https://github.com/phuse-org/git-in-statistical-programming/discussions)

# Contributing

If you wish to get involved in the content produced by the working group, you can find out how to do so in this short guide.

## Signing up

If you wish to contribute content to the site you can either request to be added to the repository directly on [this issue](https://github.com/phuse-org/git-in-statistical-programming/issues/1), or [fork](https://github.com/phuse-org/git-in-statistical-programming/fork) the repository, make your changes and then request to merge your changes in

## Adding content

Typically the workflow we expect contributors to follow is

### 1. [Optional] Make an issue on the topic they wish to contribute on

This is only needed if there is not already an issue, so can be skipped otherwise!

### 2. Assign yourself to the issue

Assigning yourself to an issue makes it clear that you are working on this, and lets others know to work on another project. While individuals can work on the same issue, it will require direct collaboration and it is normally easy to work independenly.

![screenshot of assigning on an issue](assign.png)

### 3. Make a new branch to work on

If you are not familiar with branches, they are basically seperate working areas and allow you to work independently without impacting other users. Read [this guide](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches) for more.

The new branch should be off of main, and should normally be made on Github. The naming convention is <issue number>-<description>

![screenshot of making a new branch](branch.png)

### 4. Start working!

How you work depends on your setup.

#### Working on github

If you don't want to deal with setup, you can edit files directly on Github.

When you switch to the branch you created, you can directly edit and make new files on github. This is the easiest way to work, but you will not be able to preview the websites you have created. If you wish to add images you will also need to upload them manually.

#### Working locally

Alternatively, you can [install Git](https://git-scm.com/install/) and [Quarto](https://quarto.org/docs/get-started/) locally.

Then you can clone the repository with the command (note, before doing so you will need to [set up ssh keys](https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent))

`git clone git@github.com:phuse-org/git-in-statistical-programming.git`

Then switch to your branch

`cd <folder name>`

`git checkout <branch name>`

Once you have made changes you wish to get back on the website, you can use

`git add .`
`git commit -m <A message describing what you did>`
`git push`

to get the changes you've made on the website.

## Working with Quarto

This site is written in Quarto. There are some [great tutorials](https://quarto.org/docs/get-started/hello/rstudio.html) on the [Quarto website](https://quarto.org/).

In particular, there are two parts to this site

### Blog

The blog and website content is under /site. If you wish to make a new blog post go to /posts and make a new folder with the name of the blog post you want. You can copy the content in an existing folder to get you started in terms of needed formatting.

### White paper

The white paper content is under /white-paper. Each chapter is a seperate file in that folder. If you want to make a new chapter, you will need to make a new chapter, and then add that name to /white-paper/_quarto.yml, which will ensure that it appears on the main site.

### Rendering the site

If you want to render the site locally to preview it, you will need to do so in two parts

1) `quarto render site`
2) `quarto render white-paper`

The content will automatically be created under /docs.

**NOTE**: /docs is gitignored on **purpose**. The content will be generated on Github, and does not need to be commited!

Binary file added site/assign.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added site/assign.png:sec.endpointdlp
Binary file not shown.
Binary file added site/branch.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added site/branch.png:sec.endpointdlp
Binary file not shown.
17 changes: 8 additions & 9 deletions site/index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,23 @@ about:
image: phuselogo.png
template: solana
links:
- text: Contribute
href: Contribute.qmd
- icon: github
text: Github
href: https://github.com/phuse-org/git-in-statistical-programming

---

This blog contains posts from the PHUSE working group on The use of Git in Statistical Programming
This is the website for the PHUSE working group on The use of Git in Statistical Programming.

# Meetings
It includes a [blog](posts.qmd) and a draft for a [white paper](white-paper/index.html)

Meetings are happening bi-weekly every Friday
# Meetings

# Goal
Meetings are happening bi-weekly switching between Friday and Wednesday

- White paper about Git in pharma for statisticians : Guidelines
- Poster for Europe PHUSE 2025
# Contribute

# Content
Want to contribute? Read [this guide](Contribute.qmd)

- [White Paper draft](white-paper/index.html)
- [Blog posts](posts.qmd)