Skip to content

Commit

Permalink
Release 0.1.1-pre
Browse files Browse the repository at this point in the history
  • Loading branch information
piperswe committed Aug 20, 2021
0 parents commit 296b62b
Show file tree
Hide file tree
Showing 45 changed files with 3,233 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .cargo-husky/hooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/sh
# SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
# SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
# SPDX-FileContributor: Piper McCorkle <[email protected]>

set -euxo pipefail

cargo test
cargo check
cargo clippy -- -D warnings
cargo fmt -- --check
python -m reuse lint
7 changes: 7 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
# SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
# SPDX-FileContributor: Piper McCorkle <[email protected]>

FROM mcr.microsoft.com/vscode/devcontainers/rust:0-1

RUN rustup default nightly
32 changes: 32 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
// SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
// SPDX-FileContributor: Piper McCorkle <[email protected]>
{
"name": "Rust",
"build": {
"dockerfile": "Dockerfile"
},
"runArgs": [
"--cap-add=SYS_PTRACE",
"--security-opt",
"seccomp=unconfined"
],

"settings": {
"lldb.executable": "/usr/bin/lldb",
"files.watcherExclude": {
"**/target/**": true
},
"rust-analyzer.checkOnSave.command": "clippy"
},

"extensions": [
"vadimcn.vscode-lldb",
"mutantdino.resourcemonitor",
"matklad.rust-analyzer",
"tamasfe.even-better-toml",
"serayuzgur.crates"
],

"remoteUser": "vscode"
}
6 changes: 6 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
# SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
# SPDX-FileContributor: Piper McCorkle <[email protected]>

github: [LutrisEng]
liberapay: lutriseng
108 changes: 108 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
# SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
# SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
# SPDX-FileContributor: Piper McCorkle <[email protected]>

name: CI

on:
push:
pull_request:
schedule:
- cron: '0 0 * * *'

env:
CARGO_TERM_COLOR: always

jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: check

test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
override: true
- uses: Swatinem/rust-cache@v1
- run: cargo test --all-features --doc

fmt:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
components: rustfmt, clippy
profile: minimal
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --all-features
name: Clippy

security_audit:
name: Security Audit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions-rs/audit-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}

reuse:
name: REUSE
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- run: pip install reuse
- run: reuse lint

publish_docs:
name: Publish Docs
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: doc
- run: cp docs/index.html target/doc/
- uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./target/doc
force_orphan: true
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
commit_message: Auto-generated documentation
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
# SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
# SPDX-FileContributor: Piper McCorkle <[email protected]>

/target
/roundtrip
/testdbs
Cargo.lock
10 changes: 10 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
// SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
// SPDX-FileContributor: Piper McCorkle <[email protected]>

{
"recommendations": [
"matklad.rust-analyzer",
"vadimcn.vscode-lldb"
]
}
140 changes: 140 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,140 @@
// SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
// SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
// SPDX-FileContributor: Piper McCorkle <[email protected]>

{
"version": "0.2.0",
"configurations": [
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in library 'datom'",
"cargo": {
"args": [
"test",
"--no-run",
"--lib",
"--package=datom"
],
"filter": {
"name": "datom",
"kind": "lib"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'peer_server'",
"cargo": {
"args": [
"build",
"--bin=peer_server",
"--package=datom"
],
"filter": {
"name": "peer_server",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'peer_server'",
"cargo": {
"args": [
"test",
"--no-run",
"--bin=peer_server",
"--package=datom"
],
"filter": {
"name": "peer_server",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'transactor'",
"cargo": {
"args": [
"build",
"--bin=transactor",
"--package=datom"
],
"filter": {
"name": "transactor",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'transactor'",
"cargo": {
"args": [
"test",
"--no-run",
"--bin=transactor",
"--package=datom"
],
"filter": {
"name": "transactor",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug integration test 'sled_test'",
"cargo": {
"args": [
"test",
"--no-run",
"--test=sled_test",
"--package=datom"
],
"filter": {
"name": "sled_test",
"kind": "test"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug benchmark 'serial'",
"cargo": {
"args": [
"test",
"--no-run",
"--bench=serial",
"--package=datom"
],
"filter": {
"name": "serial",
"kind": "bench"
}
},
"args": [],
"cwd": "${workspaceFolder}"
}
]
}
8 changes: 8 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// SPDX-FileCopyrightText: 2021 Lutris Engineering, Inc
// SPDX-License-Identifier: BlueOak-1.0.0 OR BSD-2-Clause-Patent
// SPDX-FileContributor: Piper McCorkle <[email protected]>

{
"rust-analyzer.checkOnSave.command": "clippy",
"files.insertFinalNewline": true
}
Loading

0 comments on commit 296b62b

Please sign in to comment.