Skip to content

Commit

Permalink
Deploying to gh-pages from @ ba971f0 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
hdolinh committed Aug 28, 2023
1 parent 4795f15 commit ceb6532
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 20 deletions.
2 changes: 1 addition & 1 deletion 2023-08-delta/search.json
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@
"href": "session_02.html#introduction",
"title": "2  Publishing your analysis to the web with GitHub Pages",
"section": "2.1 Introduction",
"text": "2.1 Introduction\nSharing your work with others in engaging ways is an important part of the scientific process.\nSo far in this course, we’ve introduced a small set of powerful tools for doing open science:\n\nR and its many packages\nRStudio\nGit\nGitHub\nQuarto\n\nQuarto, in particular, is amazingly powerful for creating scientific reports but, so far, we haven’t tapped its full potential for sharing our work with others.\nIn this lesson, we’re going to take our training_{USERNAME} GitHub repository and turn it into a beautiful and easy to read web page using the tools listed above.\n\n\n\n\n\n\nSet up\n\n\n\n\nMake sure you are in training_{USERNAME} project\nAdd a new Quarto file at the top level called index.qmd\n\nGo to the RStudio menu File > New File > Quarto Document…\nThis will bring up a dialog box. Add the title “GitHub Pages Example”, keep the Default Output Format as “HTML”, and then click “OK”\n\nSave the Quarto file you just created. Use index.qmd as the file name\n\nBe sure to use the exact case (lower case ‘index’) as different operating systems handle case differently and it can interfere with loading your web page later\n\nPress “Render” and observe the rendered output\n\nNotice the new file in the same directory index.html\nThis is our Quarto file rendered as HTML (a web page)\n\nCommit your changes (for both index.qmd and index.html) with a commit message, pull and then push to GitHub\nOpen your web browser to the GitHub.com and navigate to the page for your training_{USERNAME} repository\nActivate GitHub Pages for the main branch\n\nGo to Settings > Pages (underneath the Code and Automation section)\nKeep the “Source” as “Deploy from a branch”\nUnder “Branch” you’ll see a message that says “GitHub Pages is currently disabled”. To change this, change the branch from “None” to main. Keep the folder as the root and then click “Save”\nYou should see the message change to “Your GitHub Pages site is currently being built from the main branch”\n\n\nNote: index.qmd represents the default file for a web site, and is returned whenever you visit the web site but doesn’t specify an explicit file to be returned.\n\n\nNow, the rendered website version of your repo will show up at a special URL.\nGitHub Pages follows a convention like this:\n\nNote that it changes from github.com to github.io\n\nGo to https://{username}.github.io/{repo_name}/ (Note the trailing /)\nObserve the awesome rendered output\n\nNow that we’ve successfully published a web page from an Quarto document, let’s make a change to our document and follow the steps to publish the change on the web:\n\n\n\n\n\n\nUpdate content in your published page\n\n\n\n\nGo back to your index.qmd\nDelete all the content, except the YAML frontmatter\nType “Hello world”\nSave and render your file\nUse Git workflow: Stage > Commit > Pull > Push\nGo back to https://{username}.github.io/{repo_name}/\n\n\n\nNext, we will show how you can link different qmds rendered into html so you can easily share different parts of your work.\n\n\n\n\n\n\nExercise\n\n\n\nIn this exercise, you’ll create a table of contents with the lessons of this course on the main page, and link some of the files we have work on so far.\n\nGo back to the RStudio server and to your index.Rmd file\nCreate a table of contents with the names of the main technical lessons of this course, like so:\n\n## coreR workshop\n\n- Introduction to Quarto \n- Cleaning and Wrangling data\n- Data Visualization\n- Spatial Analysis\n\nMake sure you have the html versions of your intro-to-rmd.Rmd and data-cleaning.Rmd files. If you only see the Rmd version, you need to “Knit” your files first\nIn your index.Rmd let’s add the links to the html files we want to show on our webpage. Do you remember the Markdown syntax to create a link?\n\n\n\nMarkdown syntax to create a link:\n\n\n[Text you want to hyperlink](link)\n\nExample: [Data wrangling and cleaning](data-wrangling-cleaning.html)\n\n\n\n\nUse Git workflow: Stage > Commit > Pull > Push\n\nNow when you visit your web site, you’ll see the table of contents, and can navigate to the others file you linked.\n\n\nQuarto web pages are a great way to share work in progress with your colleagues. Here we showed an example with the materials we have created in this course. However, you can use these same steps to share the different files and progress of a project you’ve been working on. To do so simply requires thinking through your presentation so that it highlights the workflow to be reviewed. You can include multiple pages and build a simple web site and make your work accessible to people who aren’t set up to open your project in R. Your site could look something like this:"
"text": "2.1 Introduction\nSharing your work with others in engaging ways is an important part of the scientific process.\nSo far in this course, we’ve introduced a small set of powerful tools for doing open science:\n\nR and its many packages\nRStudio\nGit\nGitHub\nQuarto\n\nQuarto, in particular, is amazingly powerful for creating scientific reports but, so far, we haven’t tapped its full potential for sharing our work with others.\nIn this lesson, we’re going to take our training_{USERNAME} GitHub repository and turn it into a beautiful and easy to read web page using the tools listed above.\n\n\n\n\n\n\nSet up\n\n\n\n\nMake sure you are in training_{USERNAME} project\nAdd a new Quarto file at the top level called index.qmd\n\nGo to the RStudio menu File > New File > Quarto Document…\nThis will bring up a dialog box. Add the title “GitHub Pages Example”, keep the Default Output Format as “HTML”, and then click “OK”\n\nSave the Quarto file you just created. Use index.qmd as the file name\n\nBe sure to use the exact case (lower case ‘index’) as different operating systems handle case differently and it can interfere with loading your web page later\n\nPress “Render” and observe the rendered output\n\nNotice the new file in the same directory index.html\nThis is our Quarto file rendered as HTML (a web page)\n\nCommit your changes (for both index.qmd and index.html) with a commit message, pull and then push to GitHub\nOpen your web browser to the GitHub.com and navigate to the page for your training_{USERNAME} repository\nActivate GitHub Pages for the main branch\n\nGo to Settings > Pages (underneath the Code and Automation section)\nKeep the “Source” as “Deploy from a branch”\nUnder “Branch” you’ll see a message that says “GitHub Pages is currently disabled”. To change this, change the branch from “None” to main. Keep the folder as the root and then click “Save”\nYou should see the message change to “Your GitHub Pages site is currently being built from the main branch”\n\n\nNote: index.qmd represents the default file for a web site, and is returned whenever you visit the web site but doesn’t specify an explicit file to be returned.\n\n\nNow, the rendered website version of your repo will show up at a special URL.\nGitHub Pages follows a convention like this:\n\nNote that it changes from github.com to github.io\n\nGo to https://{username}.github.io/{repo_name}/ (Note the trailing /)\nObserve the awesome rendered output\n\nNow that we’ve successfully published a web page from an Quarto document, let’s make a change to our document and follow the steps to publish the change on the web:\n\n\n\n\n\n\nUpdate content in your published page\n\n\n\n\nGo back to your index.qmd\nDelete all the content, except the YAML frontmatter\nType “Hello world”\nSave and render your file\nUse Git workflow: Stage > Commit > Pull > Push\nGo back to https://{username}.github.io/{repo_name}/\n\n\n\nNext, we will show how you can link different qmds rendered into html so you can easily share different parts of your work.\n\n\n\n\n\n\nExercise\n\n\n\nIn this exercise, you’ll create a table of contents with the lessons of this course on the main page, and link some of the files we have work on so far.\n\nGo back to the RStudio server and to your index.qmd file\nCreate a table of contents with the names of the some of the technical lessons we have or will cover:\n\n## R workshop\n\n- Introduction to Quarto \n- Cleaning and Wrangling data\n- Data Visualization\n- Spatial Analysis\n\nMake sure you have the html versions of your intro-to-quarto.qmd and data-cleaning.qmd files. If you only see the qmd version, you need to “Render” your files first\nIn your index.qmd let’s add the links to the html files we want to show on our webpage. Do you remember the Markdown syntax to create a link?\n\n\n\nMarkdown syntax to create a link:\n\n\n[Text you want to hyperlink](link)\n\nExample: [Data wrangling and cleaning](data-wrangling-cleaning.html)\n\n\n\n\nUse Git workflow: Stage > Commit > Pull > Push\n\nNow when you visit your web site, you’ll see the table of contents, and can navigate to the others file you linked.\n\n\nQuarto web pages are a great way to share work in progress with your colleagues. Here we showed an example with the materials we have created in this course. However, you can use these same steps to share the different files and progress of a project you’ve been working on. To do so simply requires thinking through your presentation so that it highlights the workflow to be reviewed. You can include multiple pages and build a simple web site and make your work accessible to people who aren’t set up to open your project in R. Your site could look something like this:"
},
{
"objectID": "session_03.html#learning-objectives",
Expand Down
10 changes: 5 additions & 5 deletions 2023-08-delta/session_02.html
Original file line number Diff line number Diff line change
Expand Up @@ -344,18 +344,18 @@ <h2 data-number="2.1" class="anchored" data-anchor-id="introduction"><span class
<div class="callout-body-container callout-body">
<p>In this exercise, you’ll create a table of contents with the lessons of this course on the main page, and link some of the files we have work on so far.</p>
<ul>
<li>Go back to the RStudio server and to your <code>index.Rmd</code> file</li>
<li>Create a table of contents with the names of the main technical lessons of this course, like so:</li>
<li>Go back to the RStudio server and to your <code>index.qmd</code> file</li>
<li>Create a table of contents with the names of the some of the technical lessons we have or will cover:</li>
</ul>
<pre><code>## coreR workshop
<pre><code>## R workshop

- Introduction to Quarto
- Cleaning and Wrangling data
- Data Visualization
- Spatial Analysis</code></pre>
<ul>
<li><p>Make sure you have the <code>html</code> versions of your <code>intro-to-rmd.Rmd</code> and <code>data-cleaning.Rmd</code> files. If you only see the <code>Rmd</code> version, you need to “Knit” your files first</p></li>
<li><p>In your <code>index.Rmd</code> let’s add the links to the html files we want to show on our webpage. Do you remember the Markdown syntax to create a link?</p></li>
<li><p>Make sure you have the <code>html</code> versions of your <code>intro-to-quarto.qmd</code> and <code>data-cleaning.qmd</code> files. If you only see the <code>qmd</code> version, you need to “Render” your files first</p></li>
<li><p>In your <code>index.qmd</code> let’s add the links to the html files we want to show on our webpage. Do you remember the Markdown syntax to create a link?</p></li>
</ul>
<details>
<summary>
Expand Down
Loading

0 comments on commit ceb6532

Please sign in to comment.