Skip to content

Commit 5a7be81

Browse files
committed
docs: update static
1 parent 4ea41d0 commit 5a7be81

File tree

4 files changed

+25
-28
lines changed

4 files changed

+25
-28
lines changed

.github/workflows/docs.yaml

Lines changed: 8 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ name: Deploy static content to Pages
44
on:
55
# Runs on pushes targeting the default branch
66
push:
7-
branches: ["main"]
7+
branches: ["main", "develop"]
88

99
# Allows you to run this workflow manually from the Actions tab
1010
workflow_dispatch:
@@ -31,31 +31,23 @@ jobs:
3131
runs-on: ubuntu-latest
3232
steps:
3333
- name: Checkout
34-
uses: actions/checkout@v3
35-
- name: Install Node.js
36-
uses: actions/setup-node@v3
37-
with:
38-
node-version: 20
39-
- uses: pnpm/action-setup@v3
40-
with:
41-
version: 9
42-
run_install: true
43-
- name: Build packages before
44-
run: pnpm build
45-
- run: pnpm ember build --env=production
34+
uses: actions/checkout@v4
35+
- name: Pnpm install
36+
uses: wyvox/action-setup-pnpm@v3
37+
- run: pnpm turbo build
4638
working-directory: doc-app
4739
env:
4840
DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}
4941
- name: Setup Pages
50-
uses: actions/configure-pages@v3
42+
uses: actions/configure-pages@v5
5143
- name: Upload artifact
52-
uses: actions/upload-pages-artifact@v2
44+
uses: actions/upload-pages-artifact@v3
5345
with:
5446
# Upload entire repository
5547
path: 'doc-app/dist'
5648
- name: Deploy to GitHub Pages
5749
id: deployment
58-
uses: actions/deploy-pages@v2
50+
uses: actions/deploy-pages@v4
5951

6052

6153

doc-app/config/environment.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,11 @@ module.exports = function (environment) {
4141
}
4242

4343
if (environment === 'production') {
44+
ENV.rootURL = '/ember-common-ui/';
4445
// here you can enable a production-specific feature
4546
}
4647

48+
console.log(ENV);
49+
4750
return ENV;
4851
};

patches/@embroider__vite.patch

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
diff --git a/dist/src/content-for.js b/dist/src/content-for.js
2-
index b7541151131e62c64e83bbd96ac486679d43d0db..ec4f5c3cf741d05278df276f083375f973877a4a 100644
2+
index b7541151131e62c64e83bbd96ac486679d43d0db..38b4a2203974ad89cffb82441d16c03397e272b1 100644
33
--- a/dist/src/content-for.js
44
+++ b/dist/src/content-for.js
5-
@@ -10,6 +10,9 @@ export function contentFor() {
6-
transformIndexHtml(html, { path }) {
7-
let config = readJSONSync(join(locateEmbroiderWorkingDir(process.cwd()), 'content-for.json'));
8-
let contentsForConfig = config[path];
9-
+ if (!contentsForConfig) {
10-
+ return html;
11-
+ }
12-
for (const [contentType, htmlContent] of Object.entries(contentsForConfig)) {
5+
@@ -14,6 +14,11 @@ export function contentFor() {
136
html = html.replace(`{{content-for "${contentType}"}}`, `${htmlContent}`);
147
html = html.replace(`{{content-for '${contentType}'}}`, `${htmlContent}`);
8+
}
9+
+
10+
+ if (config['index.html'].includes('production')) {
11+
+ html = html.replace('assets/', 'ember-common-ui/assets/');
12+
+ }
13+
+
14+
return html;
15+
},
16+
};

pnpm-lock.yaml

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)