-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add a workflow to deply the markdown playground #1966
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
c083e86
work on deploying the markdown playground
devoncarew c31c72e
add a workflow to deply the markdown playground
devoncarew 6905aa8
update the package version and changelog
devoncarew 7b9f8d9
update version.dart
devoncarew 1c64ca2
deploy the site to a markdown/ subdir
devoncarew File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
@@ -0,0 +1,53 @@ | ||
# Publish the GitHub Pages site for this repo. | ||
|
||
name: "Deploy Pages" | ||
|
||
on: | ||
# Run on pushes to the default branch. | ||
push: | ||
branches: [ main ] | ||
paths: | ||
- '.github/workflows/deploy_pages.yaml' | ||
- 'pkgs/markdown/**' | ||
|
||
jobs: | ||
deploy: | ||
permissions: | ||
contents: read | ||
pages: write | ||
id-token: write | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: github-pages | ||
url: ${{steps.deployment.outputs.page_url}} | ||
|
||
steps: | ||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 | ||
- uses: dart-lang/setup-dart@e630b99d28a3b71860378cafdc2a067c71107f94 | ||
|
||
# Build the markdown playground. | ||
- name: "markdown: pub get" | ||
run: dart pub get | ||
working-directory: pkgs/markdown | ||
- name: "markdown: build playground" | ||
run: > | ||
dart compile js -o example/app.dart.js | ||
--minify --no-frequency-based-minification --no-source-maps | ||
example/app.dart | ||
working-directory: pkgs/markdown/example | ||
|
||
# Create the _site directory. | ||
- run: mkdir _site | ||
- run: cp -r pkgs/markdown/example _site/markdown | ||
- run: rm _site/markdown/*.dart | ||
|
||
# Deploy to GitHub Pages. | ||
- name: setup pages | ||
uses: actions/configure-pages@v5 | ||
- name: upload artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: _site | ||
- name: deploy to github pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
# https://dart.dev/tools/pub/private-files | ||
.dart_tool | ||
pubspec.lock | ||
_site/ |
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 |
---|---|---|
|
@@ -3,3 +3,7 @@ | |
.pub | ||
pubspec.lock | ||
doc/ | ||
|
||
example/app.dart.js | ||
example/app.dart.js.deps | ||
example/app.dart.js.map |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should get a redirect in the old place, too.
https://github.com/dart-archive/dart-lang.github.io is how you do it. Not sure why it was archived.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You probably mean https://github.com/dart-lang/markdown (the archived repo above was for package:io).
+1 to a re-direct.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I DON'T! You can put anything in
dart-lang.github.io/XYZ
. Even/markdown
if the repo isn't there.