Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
jyoung4242 committed Jun 16, 2024
0 parents commit beaad40
Show file tree
Hide file tree
Showing 18 changed files with 3,541 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Format

on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_call:

jobs:
format:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Format code
uses: creyD/[email protected]
with:
prettier_options: --write **/*.{js,jsx,ts,tsx,css,scss,md}
46 changes: 46 additions & 0 deletions .github/workflows/itch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Deploy

on:
push:
branches:
- main
workflow_dispatch:

env:
ITCH_USERNAME: Mookie4242
ITCH_GAME_ID: cellular-automata
jobs:
lint:
uses: ./.github/workflows/lint.yml
test:
uses: ./.github/workflows/vittest.yml

deploy:
needs: [lint, test]
name: Upload to Itch
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Install dependencies
run: npm install

- name: Build
run: npm run build

- name: Extract version from package.json
uses: sergeysova/jq-action@v2
id: version
with:
cmd: "jq .version package.json -r"

- uses: KikimoraGames/[email protected]
with:
butlerApiKey: ${{secrets.BUTLER_API_KEY}}
gameData: ./dist
itchUsername: ${{env.ITCH_USERNAME}}
itchGameId: ${{ env.ITCH_GAME_ID }}
buildChannel: itch_build
buildNumber: ${{ steps.version.outputs.value }}
29 changes: 29 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Lint

on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_call:

jobs:
lint:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 20

- name: Install dependencies
run: npm ci

- name: Lint code
run: npx eslint .
27 changes: 27 additions & 0 deletions .github/workflows/vittest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Test Suite

on:
push:
branches:
- main
pull_request:
workflow_call:

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: "16"

- name: Install dependencies
run: npm install

- name: Run tests
run: npm test
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
node_modules
build
ExcaliburStarter.bat
dist
notes.ts
6 changes: 6 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// @ts-check

import eslint from "@eslint/js";
import tseslint from "typescript-eslint";

export default tseslint.config(eslint.configs.recommended, ...tseslint.configs.recommended);
11 changes: 11 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Hello VITE</title>
<script type="module" src="/src/main.ts"> </script>
</head>
<body>
</body>
</html>
Loading

0 comments on commit beaad40

Please sign in to comment.