Skip to content

Commit

Permalink
Add 'turbopack/' from commit '9b632810ae1c56ab44e9ea2928bf9de1d159b91e'
Browse files Browse the repository at this point in the history
git-subtree-dir: turbopack
git-subtree-mainline: dea722d
git-subtree-split: 9b63281
  • Loading branch information
ForsakenHarmony committed Jul 30, 2024
2 parents dea722d + 9b63281 commit 93986d9
Show file tree
Hide file tree
Showing 2,322 changed files with 378,957 additions and 0 deletions.
24 changes: 24 additions & 0 deletions turbopack/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# http://editorconfig.org
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*.t]
trim_trailing_whitespace = false

[Makefile]
indent_style = tab

[{go.mod,go.sum,*.go}]
indent_style = tab

[*.rs]
# Keep in sync with rustfmt
max_line_length = 100
indent_size = 4
64 changes: 64 additions & 0 deletions turbopack/.github/workflows/test-turbopack-rust-bench-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: Turbopack Rust testing benchmarks
on:
workflow_call:
inputs:
runner:
type: string
os:
type: string
all:
type: boolean

env:
TURBOPACK_BENCH_COUNTS: "100"
TURBOPACK_BENCH_PROGRESS: "1"

jobs:
test:
name: Test
# alias custom runner name to our labels array
runs-on: ${{ inputs.runner == 'ubuntu-latest-metal' && fromJSON('[ "self-hosted", "linux", "x64", "metal" ]') || inputs.runner }}
steps:
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
if: inputs.os == 'windows'

- name: Checkout
uses: actions/checkout@v3

- name: Setup Rust
uses: ./.github/actions/setup-rust
env:
GITHUB_TOKEN: ${{ github.token }}
with:
save-cache: true
github-token: "${{ secrets.GITHUB_TOKEN }}"

- name: Setup Node.js
uses: ./.github/actions/setup-node
with:
node-version: 18

- name: Build benchmarks for tests
timeout-minutes: 120
run: |
cargo tp-bench-test --no-run
- name: Run cargo test on benchmarks
timeout-minutes: 120
run: |
cargo tp-bench-test
- name: Build benchmarks for tests for other bundlers
if: inputs.all
timeout-minutes: 120
run: |
cargo test --benches --release -p turbopack-bench --no-run
- name: Run cargo test on benchmarks for other bundlers
if: inputs.all
timeout-minutes: 120
run: |
cargo test --benches --release -p turbopack-bench
47 changes: 47 additions & 0 deletions turbopack/crates/node-file-trace/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
[package]
name = "node-file-trace"
version = "0.1.0"
description = "TBD"
license = "MPL-2.0"
edition = "2021"

[[bin]]
name = "node-file-trace"
path = "src/main.rs"
bench = false

[features]
default = ["cli", "custom_allocator"]
cli = ["dep:clap", "turbo-tasks-malloc"]
persistent_cache = []
serializable = []
tokio_console = [
"dep:console-subscriber",
"tokio/tracing",
"turbo-tasks/tokio_tracing",
]
node-api = []
custom_allocator = ["turbo-tasks-malloc", "turbo-tasks-malloc/custom_allocator"]

[lints]
workspace = true

[dependencies]
anyhow = { workspace = true }
clap = { workspace = true, optional = true, features = ["derive"] }
console-subscriber = { workspace = true, optional = true }
serde = { workspace = true, features = ["derive"] }
serde_json = { workspace = true }
tokio = { workspace = true, features = ["full"] }

turbo-tasks = { workspace = true }
turbo-tasks-fs = { workspace = true }
turbo-tasks-malloc = { workspace = true, optional = true, default-features = false }
turbo-tasks-memory = { workspace = true }
turbopack = { workspace = true }
turbopack-cli-utils = { workspace = true }
turbopack-core = { workspace = true }
turbopack-resolve = { workspace = true }

[build-dependencies]
turbo-tasks-build = { workspace = true }
5 changes: 5 additions & 0 deletions turbopack/crates/node-file-trace/build.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
use turbo_tasks_build::generate_register;

fn main() {
generate_register();
}
Loading

0 comments on commit 93986d9

Please sign in to comment.