forked from ScottPlot/ScottPlot
-
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 ScottPlot#2254 from ScottPlot/2022-11-10c
SP5 cookbook: build and deploy using CI system
- Loading branch information
Showing
9 changed files
with
95 additions
and
24 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,10 +8,22 @@ on: | |
paths: | ||
- "src/ScottPlot5/ScottPlot5 Cookbook/**" | ||
|
||
permissions: | ||
contents: read | ||
pages: write | ||
id-token: write | ||
|
||
concurrency: | ||
group: "pages" | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
name: Cookbook | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: Cookbook | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
steps: | ||
- name: 🛒 Checkout | ||
uses: actions/checkout@v2 | ||
|
@@ -26,12 +38,13 @@ jobs: | |
run: dotnet build "src/ScottPlot5/ScottPlot5 Cookbook" --no-restore | ||
- name: 🧑🍳 Generate Cookbook | ||
run: dotnet test "src/ScottPlot5/ScottPlot5 Cookbook" --no-restore --verbosity minimal | ||
- name: 🔑 Install SSH Key | ||
run: | | ||
install -m 600 -D /dev/null ~/.ssh/id_rsa | ||
echo "${{ secrets.PRIVATE_SSH_KEY }}" > ~/.ssh/id_rsa | ||
echo "${{ secrets.KNOWN_HOSTS }}" > ~/.ssh/known_hosts | ||
- name: 🚀 Deploy | ||
run: rsync --archive --stats -e 'ssh -p 18765' 'src/ScottPlot5/ScottPlot5 Cookbook/bin/Debug/net6.0/cookbook-output' ${{ secrets.REMOTE_DEST_COOKBOOK50 }} # [email protected]:/scottplot.net/public_html/cookbook/5.0/ | ||
- name: 🧹 Purge Cache | ||
run: curl --user deploy:${{ secrets.PURGE_PASSWORD }} https://scottplot.net/admin/purge/ | ||
|
||
- name: 🛠️ Configure Pages | ||
uses: actions/configure-pages@v2 | ||
- name: 📦 Upload Artifact | ||
uses: actions/upload-pages-artifact@v1 | ||
with: | ||
path: "./dev/www" | ||
- name: 🚀 Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v1 |
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,40 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
<title>ScottPlot Developer Website</title> | ||
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" | ||
integrity="sha384-Zenh87qX5JnK2Jl0vWa8Ck2rdkQ2Bzep5IDxbcnCeuOxjzrPF/et3URy9Bv1WTRi" crossorigin="anonymous"> | ||
<style> | ||
a { | ||
text-decoration: none; | ||
} | ||
|
||
a:hover { | ||
text-decoration: underline; | ||
} | ||
</style> | ||
</head> | ||
|
||
<body> | ||
<main class="container my-5"> | ||
<h1 class="my-4">ScottPlot Developer Website</h1> | ||
<div class="fs-5"> | ||
<ul> | ||
<li class="my-4"> | ||
<a href='cookbook/5.0'>ScottPlot 5.0 Cookbook</a> - Automatically deployed cookbook that | ||
demonstrates features available in the latest commit to the main branch of ScottPlot's source code | ||
on GitHub. Features may be present that are not yet available in ScottPlot on NuGet. | ||
</li> | ||
<li class="my-4"> | ||
<a href='https://scottplot.net/cookbook/4.1/'>ScottPlot 4.1 Cookbook</a> - Manually deployed | ||
cookbook that demonstrates features available in the latest version of ScottPlot available on NuGet. | ||
</li> | ||
</ul> | ||
</div> | ||
</main> | ||
</body> | ||
|
||
</html> |
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
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
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