Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: CI

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

jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6

- name: Setup Node
uses: actions/setup-node@v6
with:
node-version-file: .tool-versions
cache: npm

- name: Install dependencies
run: npm ci

- name: Run Elm tests
run: npx elm-test
52 changes: 52 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Deploy to GitHub Pages

on:
push:
branches:
- main
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

# Only allow one deployment at a time, but don't cancel in-progress runs
concurrency:
group: pages
cancel-in-progress: false

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6

- name: Setup Node
uses: actions/setup-node@v6
with:
node-version-file: .tool-versions
cache: npm

- name: Install dependencies
run: npm ci

- name: Build
run: npm run build

- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: dist

deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

# Distribution
build/
dist/
.parcel-cache/

# elm-package generated files
elm-stuff
Expand Down
6 changes: 6 additions & 0 deletions .parcelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": ["@parcel/config-default"],
"transformers": {
"*.elm": ["@parcel/transformer-elm"]
}
}
1 change: 1 addition & 0 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
nodejs 24
31 changes: 29 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,39 @@

App to demonstrate gravitational slingshot maneuvers.

https://adamnfish.github.io/luna/index.html
https://adamnfish.github.io/luna/

## Local development

Install dependencies:

```sh
npm install
```

Start the dev server (available at http://localhost:1234):

```sh
npm start
```

Run the Elm tests:

```sh
npm test
```

Build for production (output in `dist/`):

```sh
npm run build
```

## Source code

This is an Elm application built using
[create-elm-app](https://github.com/halfzebra/create-elm-app). The
[Parcel](https://parceljs.org/) with
[@parcel/transformer-elm](https://github.com/nicois/parcel-transformer-elm). The
program runs from [`src/Main.elm`](src/Main.elm), which provides the
initial state and browser integration (including a subscription to
`requestAnimationFrame`). Updates to the state come from messages,
Expand Down
11 changes: 0 additions & 11 deletions docs/asset-manifest.json

This file was deleted.

1 change: 0 additions & 1 deletion docs/index.html

This file was deleted.

1 change: 0 additions & 1 deletion docs/service-worker.js

This file was deleted.

3 changes: 0 additions & 3 deletions docs/static/css/main.f98b609c.chunk.css

This file was deleted.

1 change: 0 additions & 1 deletion docs/static/css/main.f98b609c.chunk.css.map

This file was deleted.

2 changes: 0 additions & 2 deletions docs/static/js/main.7ba80f70.chunk.js

This file was deleted.

1 change: 0 additions & 1 deletion docs/static/js/main.7ba80f70.chunk.js.map

This file was deleted.

2 changes: 0 additions & 2 deletions docs/static/js/runtime~main.538a88e8.js

This file was deleted.

1 change: 0 additions & 1 deletion docs/static/js/runtime~main.538a88e8.js.map

This file was deleted.

Loading