gh-workflow

Crates.iogh-workflow
lib.rsgh-workflow
version
sourcesrc
created_at2024-11-08 07:40:28.689669
updated_at2024-12-11 23:46:36.003003
descriptionA type-safe GitHub Actions workflow generator
homepagehttps://github.com/tailcallhq/gh-workflow
repositoryhttps://github.com/tailcallhq/gh-workflow
max_upload_size
id1440963
Cargo.toml error:TOML parse error at line 17, column 1 | 17 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include`
size0
Tushar Mathur (tusharmath)

documentation

https://docs.rs/gh-workflow

README

🦀 Rust GitHub Actions Workflow 🚀

Rust Build Status License: MIT Crates.io Contributors GitHub forks Stars Issues

🧑‍💻 What is Rust GitHub Workflows?

Rust GitHub Workflows is a library that allows developers to write GitHub Actions in Rust. It empowers you to automate, manage, and improve your CI/CD pipelines in a type-safe manner.

GitHub Actions is powerful, but writing workflows can sometimes feel repetitive, tricky and frustrating with no strict type-checking. That's where Rust GitHub Workflows steps in! 🦾

  • 🔥 Rust-Powered: Leverage the type-safety of Rust for writing workflows.
  • 📦 Crate-friendly: Build reusable workflows and publish them as crates.

📦 Installation

To use Rust GitHub Workflows in your project, add it to your Cargo.toml:

[build-dependencies]
gh-workflow = "*" # Add the latest version

Then you can start creating GitHub Actions in your tests/ci.rs.

👷 Usage

  • Simply add a tests/ci.rs file to your project's tests directory.

  • Add the following code to generate the GitHub Actions workflow:

    use gh_workflows::*;
    
    #[test]
    fn main() {
        // Create a basic workflow
        let workflow = Workflow::setup_rust();
    
        // Generate the ci.yml
        workflow.generate().unwrap();
    }
    

    To view a fully functional example, check out the tests/ci.rs of this project.

  • Run cargo test to generate the GitHub Actions workflow.

🛠️ Roadmap

  • Support for Automated Cargo Releases
  • Improve Type Safety of Nightly Builds
  • Updates Rust Docs using Github's official documentation for the API

💡 Why Rust?

Rust provides the perfect combination of speed, safety, and flexibility, making it an ideal choice for writing GitHub Actions. With Rust, you get strong typing, memory safety, and the ability to reuse existing code, which can make your automation scripts more robust and maintainable.

📄 License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details.

🙌 Contributors

A big thank you to all the contributors who helped make this project a success! 🙏

Contributors

🌟 Show Your Support

If you like this project, please consider giving it a ⭐ on GitHub and share it with the community!

🔗 Inspiration

This project was inspired by the following repositories:


Happy automating with Rust! 🦀❤️

Commit count: 223

cargo fmt