Skip to content

Commit

Permalink
Merge pull request #1 from Nliver/main
Browse files Browse the repository at this point in the history
init commit
  • Loading branch information
Nliver authored Jan 12, 2025
2 parents 41df256 + ab258bd commit 4fd77b1
Show file tree
Hide file tree
Showing 363 changed files with 52,225 additions and 22 deletions.
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
__fixtures__/** linguist-generated
__snapshots__/** linguist-generated
47 changes: 47 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
version: 2
updates:
- package-ecosystem: "cargo"
directory: "/"
schedule:
interval: "weekly"
ignore:
- dependency-name: "markdown"
- dependency-name: "usvg"
groups:
cli:
patterns:
- "*"
update-types:
- "minor"
- "patch"

- package-ecosystem: "npm"
directory: "/ui"
schedule:
interval: "weekly"
groups:
web-application:
patterns:
- "*"
update-types:
- "minor"
- "patch"

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
groups:
github-actions:
patterns:
- "*"

- package-ecosystem: "docker"
directory: "/"
schedule:
interval: "weekly"
groups:
docker:
patterns:
- "*"

25 changes: 25 additions & 0 deletions .github/workflows/build-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build images

on:
push:
branches:
- main

jobs:
build-landscape2-image:
if: github.ref == 'refs/heads/main'
runs-on:
labels: ubuntu-latest-8-cores
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Login to AWS Public ECR
uses: docker/login-action@v3
with:
registry: public.ecr.aws
username: ${{ secrets.AWS_ACCESS_KEY_ID }}
password: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
- name: Build and push image
run: |
docker build -f crates/cli/Dockerfile -t public.ecr.aws/g6m3a0y9/landscape2:latest .
docker push public.ecr.aws/g6m3a0y9/landscape2:latest
78 changes: 78 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: CI

on:
merge_group:
pull_request:
branches:
- main

jobs:
lint-and-test-cli-tool:
runs-on:
labels: ubuntu-latest-8-cores
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.78.0
components: clippy, rustfmt
- name: Install wasm-pack
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
- name: Run clippy
run: cargo clippy --all-targets --all-features -- --deny warnings
- name: Run rustfmt
run: cargo fmt --all -- --check
- name: Run tests
run: cargo test

lint-and-test-webapp:
runs-on:
labels: ubuntu-latest-8-cores
env:
NODE_OPTIONS: --max_old_space_size=4096
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Cache node modules
uses: actions/cache@v4
with:
path: ./ui/webapp/node_modules
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install dependencies
working-directory: ./ui/webapp
run: yarn install --network-concurrency 1
- name: Run prettier
working-directory: ./ui/webapp
run: yarn format:diff
- name: Run eslint
working-directory: ./ui/webapp
run: yarn lint

lint-and-test-embed:
runs-on:
labels: ubuntu-latest-8-cores
env:
NODE_OPTIONS: --max_old_space_size=4096
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Cache node modules
uses: actions/cache@v4
with:
path: ./ui/embed/node_modules
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install dependencies
working-directory: ./ui/embed
run: yarn install --network-concurrency 1
- name: Run prettier
working-directory: ./ui/embed
run: yarn format:diff
- name: Run eslint
working-directory: ./ui/embed
run: yarn lint
Loading

0 comments on commit 4fd77b1

Please sign in to comment.