Skip to content

Commit

Permalink
update to remove model code
Browse files Browse the repository at this point in the history
  • Loading branch information
askedrelic committed Dec 23, 2024
1 parent 16c2ebe commit 971730b
Show file tree
Hide file tree
Showing 70 changed files with 11 additions and 48,926 deletions.
1 change: 0 additions & 1 deletion .openapi-generator/FILES
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
.gitignore
.openapi-generator-ignore
.travis.yml
Cargo.toml
README.md
Expand Down
3 changes: 0 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,5 @@ serde = "^1.0"
serde_derive = "^1.0"
serde_json = "^1.0"
url = "^2.2"
[dependencies.reqwest]
version = "^0.11"
features = ["json", "multipart"]

[dev-dependencies]
13 changes: 10 additions & 3 deletions regen.bash
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,17 @@ rm -rf "${gen_dir}"
# Remove unnecessary files generated by openapi-generator.
rm -rf .travis.yml swagger.json swagger.json.unprocessed git_push.sh

# Delete api code
rm -r src/apis
sed -i '' '/pub mod apis;/d' "src/lib.rs"
sed -i '' '/extern crate reqwest;/d' "src/lib.rs"
cargo remove reqwest

# Remove empty doc comments
sed -i '' '/^[[:space:]]*\/\/\/[[:space:]]*$/d' src/models/*.rs

# Do not format generated code.
cat > rustfmt.toml <<EOF
ignore = ["/"]
EOF
echo 'ignore = ["/"]' > rustfmt.toml

cargo build

Expand Down
1 change: 1 addition & 0 deletions rustfmt.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ignore = ["/"]
62 changes: 0 additions & 62 deletions src/apis/admissionregistration_api.rs

This file was deleted.

Loading

0 comments on commit 971730b

Please sign in to comment.