generated from Openscapes/quarto-website-tutorial
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12 from Openscapes/part1
Clean Welcome Setup Explore structure, delete some unused images, edi…
- Loading branch information
Showing
22 changed files
with
138 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
title: "Part 2: Contribute via GitHub" | ||
--- | ||
|
||
## Contribute your updates using GitHub | ||
|
||
*TODO: refine this list of steps, keep the list here, turn it into a demo with screenshots* | ||
|
||
1. GitHub commit, push, pull request, review PRs, merge (now we’re on GitHub.com….) | ||
|
||
1. Good commit messages | ||
|
||
2. Push to GitHub then move to GitHub.com, screenshot yellow banner to compare and make a pull request | ||
|
||
3. Not finished proposing your updates? Can make Draft PR at the start so folks can see your thinking. Set Ready for Review when ready. Request specific reviewer(s). | ||
|
||
4. Condense/ adapt [Review a pull request](https://nasa-openscapes.github.io/earthdata-cloud-cookbook/contributing/workflow.html#review-a-pull-request) from Cookbook; note using “suggesting” and commenting, “Start your Review” instead of adding single comments (fewer notifications) | ||
|
||
5. **Demo**: have someone commit and push, PR, tag Stef as reviewer. Screenshare the above steps to review. That person screenshares to commit suggested edits, merge their PR. | ||
|
||
6. **Task**: people pair up to review each other’s PRs. |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
--- | ||
title: "Setup and Explore" | ||
editor: visual | ||
--- | ||
|
||
TODO: Do Setup after Welcome, then do Explore while Hub is initiating. Setup includes Hub login, clone, branch. Preview site is step 1 in Lessons: Edit Quarto site. | ||
|
||
## Setup Part 1: Log in to the Hub | ||
|
||
Go to the Hub https://openscapes.2i2c.cloud \> log in with your GitHub Account \> select the Python server. | ||
|
||
[![Login page for the NASA Openscapes 2i2c JupyterHub, "the Hub"](images/jupyterhub-2i2c-login.png)](https://openscapes.2i2c.cloud/) | ||
|
||
![Hub server options](images/jupyterhub-server-options.png) | ||
|
||
![](images/jupyterhub-loading.png) | ||
|
||
It takes a few minutes for the Hub to load. Please be patient! | ||
|
||
While the server starts up, we’ll explore the GitHub Clinic website structure side by side with the repo. | ||
|
||
## Explore | ||
|
||
With this Clinic, we have a working example website that we will explore together. We'll learn a few rules and look for patterns to get an understanding of what things to do to help you start customizing and making it your own. And you can continue to use this website as a reference after the clinic, along with [Quarto](https://quarto.org) documentation. | ||
|
||
We'll start our exploration online looking at the website architecture and GitHub repository. Then we'll setup a copy for ourselves so that we can modify from a working example, which is a great way to learn something new. We'll set it up so that any modifications (commits) will automatically be republished via GitHub Actions. | ||
|
||
### The website itself | ||
|
||
[This Quarto Clinic website](https://openscapes.github.io/quarto-clinic/) has 4 things you can see on the left sidebar: | ||
|
||
- Welcome | ||
- Setup & Explore | ||
- Lessons | ||
- Next Steps | ||
|
||
Most of these are pages, but you'll see that "Lessons" has an arrow `>`; it is a folder with additional pages inside. | ||
|
||
### The website's source repo | ||
|
||
Let's go to this website's GitHub repository (also called a "repo"), <https://github.com/Openscapes/quarto-clinic>. You can also click there from any page in this tutorial website by clicking the GitHub octocat icon underneath the Openscapes logo in the left navbar (click it holding command on Mac, or control on a PC to open it in a different tab in your browser). | ||
|
||
**Have a look at the filenames.** We can recognize the names of the webpages we've seen above, and they have red arrows marking them in the image below. You'll see the "quarto-workflows" folder and the rest in this site are `.qmd` files, which are plain text Quarto files that can combine Markdown text with code. `index.qmd` is the home page. If you click inside "quarto-workflows" you'll see a mix of filetypes! | ||
|
||
*TODO: replace screenshots* | ||
|
||
![quarto-website-tutorial GitHub repository with files for webpages marked with red arrows](images/quarto-files-github.png){fig-alt="Screenshot of files on GitHub with red arrows identifying the files that we saw in the left sidebar" fig-align="center" width="80%"} | ||
|
||
**The `_site` folder** has html files with names that should be familiar: they match the `.qmd` files we were just exploring. This folder is where Quarto stores files to build the website. | ||
|
||
### `_quarto.yml` intro | ||
|
||
There is also a `_quarto.yml` file, which is the website's configuration file. It is essentially metadata for the website that includes the order that the pages/chapters will be in. This is where you update the organization of your website: which page comes before another. If we compare side-by-side, you'll see that the pages that appear on our website are listed there. | ||
|
||
![\_quarto.yml and website side-by-side](images/quarto-yml-site-side-by-side3.png){fig-align="center"} | ||
|
||
We'll learn more about how to interact with `_quarto.yml` in the [Lessons](lessons/index.qmd). | ||
|
||
## Setup Part 2: Clone the Quarto Clinic repo | ||
|
||
After our Hub server is loaded, we'll clone the Quarto Clinic repository into the Hub. | ||
|
||
**Option A:** Use the Git tab to Clone repo | ||
|
||
![Clone a GitHub repository in the Hub](images/jupyterhyb-clone-repo.png) | ||
|
||
**Option B:** Do this by opening a terminal (File \> New \> Terminal). In the Terminal, `git clone` your repository and `cd` into it: | ||
|
||
``` bash | ||
git clone https://github.com/openscapes/quarto-clinic | ||
cd quarto-clinic | ||
``` | ||
|
||
### Make a branch | ||
|
||
Working in a branch means you have your own version of the Quarto Clinic to edit and preview. Later, we'll learn how to contribute your edits to the Main branch of the Clinic by making a "Pull Request". | ||
|
||
branch name = your name | ||
|
||
*TODO screenshot and cmd line* | ||
|
||
## Onward! | ||
|
||
Now you are ready to start editing! The next chapter describes how to do this in the JupyterHub. |