Skip to content

Commit

Permalink
Merge branch 'update_scripts'
Browse files Browse the repository at this point in the history
  • Loading branch information
HenningHolmDE committed Nov 9, 2024
2 parents a82a29c + 7af450e commit 6205c8f
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 1 deletion.
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 2 additions & 1 deletion script/generate_api_code.sh → scripts/generate_api_code.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ placement_group,PlacementGroup; do
done

# add deprecation notice for `GET /actions`` endpoint
sed -i".bak" "/actions_api/i\#[deprecated = \"According to the [official docs](https://docs.hetzner.cloud/), the \`GET \/actions\` endpoint will be disabled from \`1 October 2023\` onwards. Users should switch to the new resource-specific endpoints ASAP.\"]" src/apis/mod.rs
sed -i".bak" "/actions_api/i\\
#[deprecated = \"According to the [official docs](https://docs.hetzner.cloud/), the \`GET /actions\` endpoint will be disabled from \`1 October 2023\` onwards. Users should switch to the new resource-specific endpoints ASAP.\"]" src/apis/mod.rs

# The extension parameter (`sed -i EXTENSION`) is required on macOS while it is
# optional for the GNU version of `sed`. Additionally, while it would be ok to
Expand Down
File renamed without changes.
7 changes: 7 additions & 0 deletions scripts/remove_all_comments.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash
# Remove all comments in Rust files for diffing non-doc changes
find src -name '*.rs' -exec sed -Ei".bak" "/^[ ]*\/\/\//d" {} \;

rm -rf src/*.bak
rm -rf src/apis/*.bak
rm -rf src/models/*.bak

0 comments on commit 6205c8f

Please sign in to comment.