robertcorponoi/godot-rust-cli

Godot Rust CLI is an easy to incorporate Rust modules into your Godot project

Also keep in mind that the main branch will usually be ahead of the version on GitHub repo

Godot Rust CLI

.

Note: Godot Rust CLI is below v1.0.0 and may contain bugs, please report any bugs as issues in the GitHub repo or feel free to ask questions in the Discord.

Also keep in mind that the main branch will usually be ahead of the version on crates.io.

Table of Contents

  • Introduction
  • Prerequisites
  • Installation
  • Tutorials
  • Command Reference
  • Compatibility
  • Updating
  • Questions
  • License

Introduction

Note: Godot Rust CLI is below v1.0.0 and may contain bugs, please report any bugs as issues in the GitHub repo.

Godot Rust CLI is a simple command line interface to help you create and update Rust components for your Godot projects.

Using Rust in your Godot project is great for performance critical code and with Godot Rust CLI, you can create your entire project in Rust or you can mix it with new or existing gdscript.

Currently, Godot Rust CLI supports creating Rust modules for Windows, MacOS, and Linux. If you need support for any other platform just put in a request as an issue in the GitHub repo and it'll be added if possible.

Note: Godot Rust CLI is the successor to Godot Rust Helper. Godot Rust CLI aims to be much more simple but more strict. This also means that Godot Rust CLI doesn't have as many features and it enforces a much more strict project structure.

Note: Godot Rust CLI currently builds Rust modules using the godot-rust (gdnative) crate.

Note: All refrences to modules refer to project-level modules. Godot Rust CLI does not build editor-level modules.

Prerequisites

Godot Rust CLI requires the following prerequisites:

  • bindgen - This is required to build the required gdnative crate so you should follow the instructions to install it for your operating system.

  • The latest version of Rust.

  • rustfmt - This is need to format files after creating/editing them. You can install this with rustup component add rustfmt.

Installation

To install Godot Rust CLI, use:

cargo install godot-rust-cli

To upgrade your version of Godot Rust CLI to the latest version, use:

cargo install --force godot-rust-cli

Tutorials

  1. Basic usage
  2. Creating a Godot plugin
  3. Platforms (experimental)

Command Reference

  • new/plugin
  • create
  • destroy
  • build
  • platform

Compatibility

Godot Rust Version Godot Rust CLI Version
0.9.1 >=0.1.1
0.9.3 >=0.2.0

Updating

0.1.x to 0.2.x

To update your project to be compatible with 0.2.x versions from 0.1.x versions, you will need to rename your project.toml file to godot-rust-cli.toml.

0.2.x to 0.3.x

Libraries have switched from a toml config to a json config so if you want to update your library it is recommended to check out what the json config looks like and update your local one to match.

A tool is in development to make upgrading between major changes easier. If you need help, questions and concerns are always welcome on Discord.

If you have been developing a plugin, there is unfortunately no way to upgrade without creating a new project as there was a major overhaul to plugin creation.

Questions

Check out the Discord to ask any questions or concerns about the cli or Godot + Rust in general.

License

MIT

Issues

Collection of the latest Issues

RedstoneMedia

RedstoneMedia

Comment Icon0

The build command can't copy the library dll, if the msvc toolchain is used (Installed via Visual Studio) and not gnu.
This is because the get_platform_toolchain function always assumes gnu and does not consider msvc to be an option.

robertcorponoi

robertcorponoi

Comment Icon0

It would be neat to be able to create a library based off an existing non-godot-rust-cli library. I think this might be a good command or an extension of the new command.

robertcorponoi

robertcorponoi

Comment Icon0

We need better documentation than just the readme.

I've come across a few options like mdBook, VuePress, etc but I think I've decided on creating a Gridsome site and host it on Netlify or GitHub pages.

This means that changing documentation will require working in a different repo but it's a better alternative than having an npm library within the cargo package. We could also set up an action to copy the build files of the documentation into a /docs directory in this repo and use it with GitHub pages.

robertcorponoi

robertcorponoi

Comment Icon0

This shouldn't be too far off, it just needs the correct Dockerfile created.

The issue that we're currently facing is documented here.

Essentially:

  • We need to extend the default docker file for 64 bit Linux.
  • We need this image to have clang 3.9 or higher.
dancodedev

dancodedev

Comment Icon10

Hi, thanks for making this library. Is there any possibility to add Android compatibility

Thanks.

Versions

Find the latest versions by id

v0.4.0 - Jul 10, 2021

  • Added ability to add platforms, starting with windows. Platforms are other operating systems that your Rust modules can be built for. Check out the documentation on platforms for more information.
  • Added ability to create release builds instead of just debug builds.
  • Added tests for new features.
  • Updated and improved documentation.

v0.3.0 - Jun 15, 2021

  • Fixed issue with Godot throwing an error because it couldn't find the dynamic library before a build was run.
  • Changed plugin architecture so now plugins are libraries in themselves with modules that are a part of that plugin.
  • Modules can now be moved around in the Godot project.
  • Migrated from Travis CI to GitHub Actions.
  • Improved error messages and code comments.

v0.2.0 - May 25, 2021

  • Updated crates
  • Updated gdnative version 0.9.3
  • Switched from using project.toml to godot-rust-cli.toml

v0.1.3 - Apr 02, 2021

  • Fixed an issue where the build with the watch flag would stop watching on errors.

v0.1.2 - Feb 12, 2021

Moved docs to a separate branch.

v0.1.1 - Feb 09, 2021

Removed unnecessary dependencies

v0.1.0 - Feb 09, 2021

Initial release

Information - Updated Jun 11, 2022

Stars: 14
Forks: 2
Issues: 7

rust-clipboard is a cross-platform library for getting and setting the contents of the OS-level clipboard

It has been tested on Windows, Mac OSX, GNU/Linux, and FreeBSD

rust-clipboard is a cross-platform library for getting and setting the contents of the OS-level clipboard

EventStoreDB Rust Client

EventStoreDB rust gRPC gRPC Client

EventStoreDB Rust Client

Rust CLI template

A quick and dirty CLI boilerplate template for Rust

Rust CLI template

Rust CLI Template

Template for creating Rust-based CLI tools

Rust CLI Template

Pure Rust client for YubiHSM 2 devices from Yubico

YubiHSM 2 devices from Documentation

Pure Rust client for YubiHSM 2 devices from Yubico

Parsec Rust Client

When using the JWT-SVID authentication method, the client will expect the SPIFFE_ENDPOINT_SOCKET environment variable to contain the path of the Workload API endpoint

Parsec Rust Client

A Rust client for connecting to OmniSciDB via its RPC protocol of Thrift

OmniSciDB via its RPC protocol of Cargo, using cargo build

A Rust client for connecting to OmniSciDB via its RPC protocol of Thrift

Cardano Rust CLI

com/clemenshorn/cardano-rust-cli

Cardano Rust CLI

Rust client implementation for Brasil API

Rust client implementation for BrasilAPI GitHub Project

Rust client implementation for Brasil API

Rust client for TDlib

Library allows you to interact with Telegram Database library

Rust client for TDlib
Facebook Instagram Twitter GitHub Dribbble
Privacy