Skip to content

Commit

Permalink
deploy doc
Browse files Browse the repository at this point in the history
  • Loading branch information
AmauryD committed Oct 1, 2023
1 parent 7b00168 commit 02eeb67
Show file tree
Hide file tree
Showing 14 changed files with 80 additions and 92 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- uses: actions/checkout@v3
- uses: wyvox/action-setup-pnpm@v2
with:
node-version: 16
node-version: 20
- name: Lint
run: pnpm lint
- name: Run Tests
Expand All @@ -34,7 +34,7 @@ jobs:
- uses: actions/checkout@v3
- uses: wyvox/action-setup-pnpm@v2
with:
node-version: 16
node-version: 20
- name: Run Tests
run: pnpm test

Expand All @@ -47,19 +47,19 @@ jobs:
fail-fast: false
matrix:
try-scenario:
- ember-lts-4.8
- ember-lts-4.12
- ember-release
- ember-beta
- ember-canary
# - ember-lts-4.8
# - ember-lts-4.12
# - ember-release
# - ember-beta
# - ember-canary
- embroider-safe
- embroider-optimized

steps:
- uses: actions/checkout@v3
- uses: wyvox/action-setup-pnpm@v2
with:
node-version: 16
node-version: 20
- name: Run Tests
run: ./node_modules/.bin/ember try:one ${{ matrix.try-scenario }}
working-directory: test-app
56 changes: 56 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Simple workflow for deploying static content to GitHub Pages
name: Deploy static content to Pages

on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false

jobs:
# Single deploy job since we're just deploying
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: 20
- uses: pnpm/[email protected]
with:
version: 8
run_install: true
- run: pnpm ember build --env=production
working-directory: test-app
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
# Upload entire repository
path: 'test-app/dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2



10 changes: 3 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# @triptyk/ember-utils

[Short description of the addon.]
Various utilities for TRIPTYK ember projects

## Compatibility

Expand All @@ -13,13 +13,9 @@
ember install @triptyk/ember-utils
```

## Usage
## Documentation

[Longer description of how to use the addon in apps.]

## Contributing

See the [Contributing](CONTRIBUTING.md) guide for details.
- [Documentation](https://triptyk.github.io/ember-utils/)

## License

Expand Down
8 changes: 4 additions & 4 deletions test-app/app/router.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,25 +8,25 @@ const Router = AddonDocsRouter.extend({

Router.map(function () {
docsRoute(this, function () {
this.route('decorators', function() {
this.route('decorators', function () {
this.route('disable-in-fastboot');
});
this.route('helpers', function() {
this.route('helpers', function () {
this.route('date-format');
this.route('html-safe');
this.route('includes');
this.route('is-even');
this.route('translate-country');
this.route('truncate');
});
this.route('services', function() {
this.route('services', function () {
this.route('current-changeset');
this.route('current-transition');
this.route('download-file');
this.route('extended-store');
this.route('store-document');
});
this.route('utils', function() {
this.route('utils', function () {
this.route('ensure-model-properties');
this.route('file-to-form-data');
this.route('generic-diff');
Expand Down
5 changes: 5 additions & 0 deletions test-app/app/styles/app.css
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
/* Ember supports plain CSS out of the box. More info: https://cli.emberjs.com/release/advanced-use/stylesheets/ */
#demo-index {
max-width: 40rem;
margin: 0 auto;
padding: 0 1.5rem;
}
2 changes: 1 addition & 1 deletion test-app/app/templates/index.hbs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<DocsHero/>

<div style="max-width: 40rem; margin: 0 auto; padding: 0 1.5rem">
<div id="demo-index">
<DocsDemo as |demo|>
<demo.example @name="my-demo.hbs">

Expand Down
2 changes: 1 addition & 1 deletion test-app/config/environment.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ module.exports = function (environment) {

if (environment === 'production') {
// Allow ember-cli-addon-docs to update the rootURL in compiled assets
ENV.rootURL = '/ADDON_DOCS_ROOT_URL/';
ENV.rootURL = '/ember-utils/';
// here you can enable a production-specific feature
}

Expand Down
2 changes: 1 addition & 1 deletion test-app/ember-cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = function (defaults) {
},
'ember-cli-addon-docs': {
documentingAddonAt: '../ember-utils',
}
},
});

const { maybeEmbroider } = require('@embroider/test-setup');
Expand Down
26 changes: 0 additions & 26 deletions test-app/tests/integration/components/application-test.ts

This file was deleted.

10 changes: 0 additions & 10 deletions test-app/tests/integration/components/async-data/component-test.ts

This file was deleted.

11 changes: 0 additions & 11 deletions test-app/tests/unit/routes/application-test.ts

This file was deleted.

11 changes: 0 additions & 11 deletions test-app/tests/unit/routes/docs-test.ts

This file was deleted.

11 changes: 0 additions & 11 deletions test-app/tests/unit/routes/index-test.ts

This file was deleted.

2 changes: 1 addition & 1 deletion test-app/types/ember-data/types/registries/model.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
* Catch-all for ember-data.
*/
export default interface ModelRegistry {
[key: string]: any;
[key: string]: unknown;
}

0 comments on commit 02eeb67

Please sign in to comment.