Skip to content

Commit

Permalink
feat: ✨ Implement the crate
Browse files Browse the repository at this point in the history
  • Loading branch information
fungiboletus committed Sep 13, 2024
1 parent 62001f0 commit acc5d8d
Show file tree
Hide file tree
Showing 44 changed files with 3,982 additions and 82 deletions.
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*.rs]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
25 changes: 25 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Cargo Build & Test

on:
push:
pull_request:

env:
CARGO_TERM_COLOR: always

jobs:
build_and_test:
name: Rust project - latest
runs-on: ubuntu-latest
strategy:
matrix:
toolchain:
- stable
- beta
#- nightly
steps:
- uses: actions/checkout@v3
- name: Set up Rust
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- name: Test the project
run: cargo test --verbose
20 changes: 19 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,19 @@
/target
# Apple's crap
.DS_Store

# Generated by Cargo
# will have compiled files and executables
debug/
target/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html

# These are backup files generated by rustfmt
**/*.rs.bk

# MSVC Windows builds of rustc generate these, which store debugging information
*.pdb

# For code coverage
coverage/
151 changes: 141 additions & 10 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 23 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,32 @@
name = "rusty-chunkenc"
version = "0.1.0"
edition = "2021"
description = "A Rust implementation of Prometheus' chunkenc library"
license = "Apache-2.0"
keywords = ["prometheus", "chunkenc", "encoding", "time-series", "gorilla"]
documentation = "https://docs.rs/rusty-chunkenc"
authors = ["Antoine Pultier <antoine.pultier@sintef.no>"]
repository = "https://github.com/sintef/rusty-chunkenc"
include = [
"README.md",
"LICENSE",
"src/*.rs",
"src/**/*.rs",
"Cargo.toml",
"Cargo.lock",
]

[dependencies]
base64 = "0.22"
nom = "7.1"
crc32c = "0.6"
xxhash-rust = { version = "0.8", features = ["xxh64"] }
thiserror = "1.0"
bitstream-io = "2.5"
smallvec = { version = "2.0.0-alpha.7", features = ["std"] }

[dev-dependencies]
base64 = "0.22"
once_cell = "1.19"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
crc32c = "0.6"
xxhash-rust = { version = "0.8", features = ["xxh64"] }
rand = "0.8"
Loading

0 comments on commit acc5d8d

Please sign in to comment.