Skip to content

Commit

Permalink
Merge pull request #35 from NingW101/main
Browse files Browse the repository at this point in the history
Add CI workflow yml
  • Loading branch information
ibelem authored Jul 16, 2024
2 parents 903db69 + 46b9097 commit ec3e6ff
Show file tree
Hide file tree
Showing 2 changed files with 114 additions and 0 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/deploy_page_ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# 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@v4
- name: Install tool dependencies
run: npm install
- name: Build for production
run: npm run prod:github
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload distribution folder
path: 'dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
69 changes: 69 additions & 0 deletions .github/workflows/web_ai_showcase_ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
#
# Copyright (C) 2024 Intel Corporation. All rights reserved.
# Licensed under the Apache License 2.0. See LICENSE in the project root for license information.
# SPDX-License-Identifier: Apache-2.0
#

name: Web AI Showcase CI

# Controls when the action will run. Workflow runs when manually triggered using the UI
# or API.
on:
push:
branches:
- main
paths-ignore:
- "README.md"
- "CODE_OF_CONDUCT.md"
- "CONTRIBUTING.md"
- "LICENSE"
- "SECURITY.md"
- "ATTRIBUTIONS.md"
pull_request:
types:
- opened
- synchronize
paths-ignore:
- "README.md"
- "CODE_OF_CONDUCT.md"
- "CONTRIBUTING.md"
- "LICENSE"
- "SECURITY.md"
- "ATTRIBUTIONS.md"
# allow to be triggered manually
workflow_dispatch:

# Cancel any in-flight jobs for the same PR/branch so there's only one active
# at a time
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
linting_check:
runs-on: ubuntu-20.04
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 5

- name: Install tool dependencies
run: npm install

- name: Linting Check
run: npm run lint

build_prod_4_gh_pages:
runs-on: ubuntu-20.04
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 5

- name: Install tool dependencies
run: npm install

- name: Build production
run: npm run prod:github

0 comments on commit ec3e6ff

Please sign in to comment.