Skip to content

Commit a3187cf

Browse files
committed
chore: automate release
1 parent aa9175b commit a3187cf

File tree

5 files changed

+74
-35
lines changed

5 files changed

+74
-35
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
#!/bin/bash
2+
3+
cd $( dirname ${BASH_SOURCE[0]} )
4+
5+
REGEX_VERSION='^\d+\.\d+\.\d+$'
6+
7+
echo "$1" | egrep -q $REGEX_VERSION
8+
if [ $? -ne 0 ]; then
9+
echo 1>&2 "Version \"$1\" must be N.N.N"
10+
exit 1
11+
fi
12+
13+
perl -pe "s/^version = .*$/version = \"$1\"/" < Cargo.toml > new_Cargo.toml
14+
mv new_Cargo.toml Cargo.toml
15+
16+
find src -depth 1 | egrep -v '(intercept.rs|lib.rs|software_externs.rs)' | xargs rm -rf
17+
cd ../..
18+
make polymorph_rust transpile_rust test_rust
19+
cd runtimes/rust
20+
rm -rf target
21+
rm -rf ../../../releases/rust/db_esdk
22+
cp -r . ../../../releases/rust/db_esdk
23+
cd ../../../releases/rust/db_esdk
24+
git checkout dafny_runtime_rust
25+
rm -f *~
26+
rm -f copy_externs.sh prepare_release.sh test_release *.pem
27+
echo Cargo.lock > .gitignore
28+
echo target >> .gitignore
29+
30+
cargo test
31+
cargo run --example main
32+
rm -f Cargo.lock *.pem
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
*~
2+
*.pem
3+
src
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
[package]
2+
name = "aws-db-esdk-examples"
3+
version = "0.1.0"
4+
edition = "2021"
5+
rust-version = "1.80.0"
6+
keywords = ["cryptography", "security", "dynamodb", "encryption", "client-side"]
7+
license = "ISC AND (Apache-2.0 OR ISC)"
8+
description = "aws-db-esdk is a library for implementing client side encryption with DynamoDB."
9+
homepage = "https://github.com/aws/aws-database-encryption-sdk-dynamodb/tree/main/releases/rust/db_esdk"
10+
repository = "https://github.com/aws/aws-database-encryption-sdk-dynamodb/tree/main/releases/rust/db_esdk"
11+
authors = ["AWS-CryptoTools"]
12+
documentation = "https://docs.rs/crate/aws-db-esdk"
13+
readme = "README.md"
14+
15+
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
16+
17+
[dependencies]
18+
aws-config = "1.5.10"
19+
aws-lc-rs = "1.11.1"
20+
aws-lc-sys = "0.23.1"
21+
aws-sdk-dynamodb = "1.54.0"
22+
aws-sdk-kms = "1.50.0"
23+
aws-smithy-runtime-api = {version = "1.7.3", features = ["client"] }
24+
aws-smithy-types = "1.2.9"
25+
chrono = "0.4.38"
26+
dafny-runtime = "0.1.1"
27+
dashmap = "6.1.0"
28+
pem = "3.0.4"
29+
tokio = {version = "1.41.1", features = ["full"] }
30+
uuid = { version = "1.11.0", features = ["v4"] }
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/bash -eu
2+
3+
cd $( dirname ${BASH_SOURCE[0]} )
4+
5+
rm -rf test_examples/src
6+
cp -r examples test_examples/src/
7+
cd test_examples
8+
cargo add aws-db-esdk
9+
cargo run

releases/rust/db_esdk/.gitignore~

-35
This file was deleted.

0 commit comments

Comments
 (0)