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
1 change: 1 addition & 0 deletions .codesandbox/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
FROM node:22-bullseye
23 changes: 23 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
FROM ubuntu:22.04

RUN apt update && apt install -y git sudo unzip curl

ARG USERNAME=vscode
ARG USER_UID=1000
ARG USER_GID=$USER_UID
RUN groupadd --gid $USER_GID $USERNAME \
&& useradd --uid $USER_UID --gid $USER_GID -m $USERNAME --shell /bin/bash \
&& echo "$USERNAME ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers.d/$USERNAME \
&& chmod 0440 /etc/sudoers.d/$USERNAME
RUN usermod -aG dialout ${USERNAME}
USER $USERNAME

RUN mkdir -p /home/$USERNAME/workspace
WORKDIR /home/$USERNAME/workspace

RUN curl -fsSL https://bun.com/install | bash

RUN echo 'export BUN_INSTALL="$HOME/.bun"' >> ~/.bashrc
RUN echo 'export PATH="$BUN_INSTALL/bin:$PATH"' >> ~/.bashrc

ENTRYPOINT ["/bin/bash"]
20 changes: 20 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"name": "Webdev Container",
"remoteUser": "vscode",
"image": "agrobotappliedai/webdev-containers:latest",
"customizations": {
"settings": {
"terminal.integrated.shell.linux": "bash"
}
},
"workspaceFolder": "/home/vscode/workspace",
"workspaceMount": "source=.,target=/home/vscode/workspace,type=bind,consistency=cached",
"updateRemoteUserUID": false,
"mounts": [],
"runArgs": [
"--net=host",
"-it",
"--rm"
],
"postAttachCommand": "bun install --frozen-lockfile"
}
42 changes: 42 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Build

on:
pull_request:
branches:
- main

jobs:
build-checks:
runs-on: blacksmith-2vcpu-ubuntu-2404
container:
image: agrobotappliedai/webdev-containers:latest
options: --user root

steps:
- name: Checkout Code
id: checkout
uses: actions/checkout@v4

- name: Add bun to PATH
id: path
run: echo "/home/vscode/.bun/bin" >> $GITHUB_PATH

- name: Install dependencies
id: install
run: bun install --frozen-lockfile

- name: Check format
id: fmt
run: bun run fmt:check

- name: Check lint
id: lint
run: bun run lint:check

- name: Check build
id: check
run: bun run build:check

- name: Build
id: build
run: bun run build
47 changes: 47 additions & 0 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Deploy

on:
push:
branches:
- main

jobs:
build-deploy:
runs-on: blacksmith-2vcpu-ubuntu-2404
container:
image: agrobotappliedai/webdev-containers:latest
options: --user root
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
permissions:
pages: write
id-token: write

steps:
- name: Checkout Code
id: checkout
uses: actions/checkout@v4

- name: Add bun to PATH
id: path
run: echo "/home/vscode/.bun/bin" >> $GITHUB_PATH

- name: Install dependencies
id: install
run: bun install --frozen-lockfile

- name: Build
id: build
run: bun run build

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

- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules/
dist/
.astro/
12 changes: 12 additions & 0 deletions .oxfmtrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"$schema": "./node_modules/oxfmt/configuration_schema.json",
"ignorePatterns": [
"dist/**",
"node_modules/**",
"README.md",
"global.css",
"*.yaml",
"*.yml",
"*.json"
]
}
48 changes: 48 additions & 0 deletions .oxlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"$schema": "./node_modules/oxlint/configuration_schema.json",
"plugins": null,
"categories": {},
"rules": {},
"settings": {
"jsx-a11y": {
"polymorphicPropName": null,
"components": {},
"attributes": {}
},
"next": {
"rootDir": []
},
"react": {
"formComponents": [],
"linkComponents": [],
"version": null,
"componentWrapperFunctions": []
},
"jsdoc": {
"ignorePrivate": false,
"ignoreInternal": false,
"ignoreReplacesDocs": true,
"overrideReplacesDocs": true,
"augmentsExtendsReplacesDocs": false,
"implementsReplacesDocs": false,
"exemptDestructuredRootsFromChecks": false,
"tagNamePreference": {}
},
"vitest": {
"typecheck": false
}
},
"env": {
"builtin": true
},
"globals": {},
"ignorePatterns": [
"dist/**",
"node_modules/**",
"README.md",
"global.css",
"*.yaml",
"*.yml",
"*.json"
]
}
9 changes: 9 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"recommendations": [
"astro-build.astro-vscode",
"oxc.oxc-vscode"
],
"oxc.fmt.configPath": ".oxfmtrc.json",
"editor.defaultFormatter": "oxc.oxc-vscode",
"editor.formatOnSave": true
}
11 changes: 11 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// @ts-check
import { defineConfig } from "astro/config";

import tailwindcss from "@tailwindcss/vite";

// https://astro.build/config
export default defineConfig({
vite: {
plugins: [tailwindcss()],
},
});
Loading