Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ The linter runs automatically when you save a file and displays warnings and err
## Requirements

This extension ships with the gdscript formatter binary for your specific platform at version `0.16.1` and uses it by default.
If you want to provide your own binary, you can retrieve the one for your platform [here](https://github.com/GDQuest/GDScript-formatter/releases). You can either add it to your system's PATH for autodiscovery or specify the path to the executable in the extension settings (see below). If the binary is added to PATH, make sure to remove the platform and architecture from the filename, e.g. rename `gdscript-formatter-windows-x86_64.exe` to `gdscript-formatter.exe` or `gdscript-formatter-linux-aarch64` to `gdscript-formatter`. Then disable the `useBuiltInBinary` setting.
If you want to provide your own binary, you can retrieve the one for your platform [here](https://github.com/GDQuest/GDScript-formatter/releases). You can either add it to your system's PATH for autodiscovery or specify the path to the executable in the extension settings (see below). If the binary is added to PATH, make sure to remove the version tag, platform and architecture from the filename, e.g. rename `gdscript-formatter-0.16.1-windows-x86_64.exe` to `gdscript-formatter.exe` or `gdscript-formatter-0.16.1-linux-aarch64` to `gdscript-formatter`. Then disable the `useBuiltInBinary` setting.

## Extension Settings

Expand Down
4 changes: 2 additions & 2 deletions get-binary.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ file_ext=""
if [[ "$TARGET" == windows* ]]; then
file_ext=".exe"
fi
url="https://github.com/GDQuest/GDScript-formatter/releases/download/$VERSION/gdscript-formatter-$TARGET$file_ext.zip"
url="https://github.com/GDQuest/GDScript-formatter/releases/download/$VERSION/gdscript-formatter-$VERSION-$TARGET$file_ext.zip"
echo "Downloading gdscript-formatter version $VERSION for target $TARGET at: $url"

curl -L --output temp.zip $url && \
unzip -o temp.zip -d binaries && \
rm temp.zip && \
mv "binaries/gdscript-formatter-$TARGET$file_ext" "binaries/gdscript-formatter$file_ext"
mv "binaries/gdscript-formatter-$VERSION-$TARGET$file_ext" "binaries/gdscript-formatter$file_ext"