-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Squash all commits for a fresh start.
This is only to avoid accidentally leaking any secrets from early development especially in the light of short-sha attacks.
- Loading branch information
0 parents
commit bdb3735
Showing
603 changed files
with
88,250 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
.hooks/ | ||
|
||
target/ | ||
../../target/ | ||
**/target/ | ||
**/node_modules/ | ||
**/dist/ | ||
|
||
traildepot/ | ||
docs/ | ||
|
||
Dockerfile* | ||
.docker* | ||
|
||
.git/ | ||
.git* | ||
|
||
*.image | ||
.rustfmt.toml | ||
.env |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: test | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: [main] | ||
|
||
jobs: | ||
|
||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: 'true' | ||
- name: Install Dependencies | ||
run: | | ||
sudo apt-get update && \ | ||
sudo apt-get install -y --no-install-recommends curl libssl-dev pkg-config libclang-dev protobuf-compiler libprotobuf-dev libsqlite3-dev | ||
- uses: pnpm/action-setup@v4 | ||
with: | ||
version: 9 | ||
- name: PNPM install | ||
run: | | ||
pnpm i | ||
- name: Set up Flutter | ||
uses: subosito/flutter-action@v2 | ||
with: | ||
channel: stable | ||
flutter-version: 3.24.3 | ||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
default: true | ||
- uses: actions/setup-python@v3 | ||
- uses: pre-commit/[email protected] | ||
# - name: Rust tests | ||
# run: | | ||
# cargo test -p trailbase-core -p trailbase-extension -p trailbase-sqlite -p trailbase-cli |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Build artifacts | ||
target/ | ||
node_modules/ | ||
|
||
# macOS-specific files | ||
.DS_Store | ||
|
||
# jetbrains setting folder | ||
.idea/ | ||
|
||
# Dev artifacts | ||
public/ | ||
traildepot/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[submodule "vendor/refinery"] | ||
path = vendor/refinery | ||
url = [email protected]:trailbaseio/refinery.git | ||
[submodule "vendor/sqlite_loadable"] | ||
path = vendor/sqlite-loadable | ||
url = [email protected]:trailbaseio/sqlite-loadable-rs.git | ||
[submodule "vendor/sqlean/bundled/sqlean"] | ||
path = vendor/sqlean/bundled/sqlean | ||
url = https://github.com/trailbaseio/sqlean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
exclude: '(trailbase-core/bindings|bindings)/.*' | ||
|
||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.6.0 | ||
hooks: | ||
- id: check-byte-order-marker | ||
- id: check-case-conflict | ||
- id: check-merge-conflict | ||
- id: check-symlinks | ||
- id: check-yaml | ||
- id: end-of-file-fixer | ||
- id: mixed-line-ending | ||
- id: trailing-whitespace | ||
|
||
# Self-validation for pre-commit manifest. | ||
- repo: https://github.com/pre-commit/pre-commit | ||
rev: v3.8.0 | ||
hooks: | ||
- id: validate_manifest | ||
|
||
- repo: local | ||
hooks: | ||
### Rust ### | ||
- id: cargofmt | ||
name: Cargo Format | ||
entry: cargo fmt -- --check | ||
pass_filenames: false | ||
# NOTE: language refers to the language in which the hook is implemented | ||
# in, rather than the inputs. In this case we rely on cargo being | ||
# installed on the system | ||
language: system | ||
# NOTE: types/files/exclude narrow the inputs the hook should run on. | ||
types: [rust] | ||
exclude: '^vendor/' | ||
|
||
- id: cargoclippy | ||
name: Cargo Clippy | ||
# Be verbose to at least still see warnings scroll by. | ||
verbose: true | ||
entry: cargo clippy --workspace --no-deps | ||
language: system | ||
types: [rust] | ||
exclude: '^vendor/' | ||
pass_filenames: false | ||
|
||
- id: cargotest | ||
name: Cargo Test | ||
entry: cargo test --workspace -- --show-output | ||
language: system | ||
types: [rust] | ||
exclude: '^(vendor|bindings)/' | ||
pass_filenames: false | ||
|
||
### Auth, Admin, Docs UI ### | ||
- id: prettier | ||
name: Prettier | ||
entry: pnpm -r format --check | ||
language: system | ||
types: [file] | ||
files: .*\.(js|mjs|cjs|ts|jsx|tsx|astro|md|mdx)$ | ||
pass_filenames: false | ||
|
||
- id: typescript_check | ||
name: Typescript Check | ||
entry: pnpm -r check | ||
language: system | ||
types: [file] | ||
files: .*\.(js|mjs|cjs|ts|jsx|tsx|astro|mdx)$ | ||
pass_filenames: false | ||
|
||
- id: javascript_test | ||
name: JavaScript Test | ||
entry: pnpm -r test | ||
language: system | ||
types: [file] | ||
files: .*\.(js|mjs|cjs|ts|jsx|tsx|astro)$ | ||
pass_filenames: false | ||
|
||
### Dart client and example | ||
- id: dart_format | ||
name: Dart format | ||
entry: dart format -o none --set-exit-if-changed client/trailbase-dart examples/blog/flutter | ||
language: system | ||
types: [file] | ||
files: .*\.dart$ | ||
pass_filenames: false | ||
|
||
- id: dart_analyze | ||
name: Dart analyze | ||
entry: sh -c 'dart pub -C client/trailbase-dart get && dart pub -C examples/blog/flutter get && dart analyze -- client/trailbase-dart examples/blog/flutter' | ||
language: system | ||
types: [file] | ||
files: .*\.dart$ | ||
pass_filenames: false | ||
|
||
- id: dart_test | ||
name: Dart test | ||
entry: sh -c 'cd client/trailbase-dart && dart pub get && dart test' | ||
language: system | ||
types: [file] | ||
files: .*\.dart$ | ||
pass_filenames: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Docs: https://rust-lang.github.io/rustfmt/ | ||
edition = "2021" | ||
brace_style = "SameLineWhere" | ||
empty_item_single_line = true | ||
max_width = 100 | ||
comment_width = 100 | ||
wrap_comments = true | ||
tab_spaces = 2 |
Oops, something went wrong.