{"id":23141556,"url":"https://github.com/neoapps-dev/buildit","last_synced_at":"2025-05-07T18:24:14.220Z","repository":{"id":268129122,"uuid":"903404923","full_name":"neoapps-dev/buildit","owner":"neoapps-dev","description":"The Universal Building Tool for *any* kind of project!","archived":false,"fork":false,"pushed_at":"2025-01-01T17:46:26.000Z","size":541,"stargazers_count":5,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-31T12:58:05.767Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/neoapps-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-14T14:18:26.000Z","updated_at":"2025-02-06T18:10:31.000Z","dependencies_parsed_at":"2024-12-14T15:22:30.254Z","dependency_job_id":"e8a30c8d-e42c-427b-864d-a8ba055b606d","html_url":"https://github.com/neoapps-dev/buildit","commit_stats":null,"previous_names":["neoapps-dev/buildit"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neoapps-dev%2Fbuildit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neoapps-dev%2Fbuildit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neoapps-dev%2Fbuildit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neoapps-dev%2Fbuildit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/neoapps-dev","download_url":"https://codeload.github.com/neoapps-dev/buildit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252932451,"owners_count":21827305,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-17T14:13:56.992Z","updated_at":"2025-05-07T18:24:14.197Z","avatar_url":"https://github.com/neoapps-dev.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cimg width=\"150\" height=\"150\" src=\"github_assets/logo.png\"\u003e\n  \u003ch1\u003eBuildIt\u003c/h1\u003e\n  \u003cp\u003e\u003cem\u003eCross-Platform Build Automation\u003c/em\u003e\u003c/p\u003e\n  \n  [![Codeac](https://static.codeac.io/badges/2-903404923.svg \"Codeac\")](https://app.codeac.io/github/neoapps-dev/buildit) [![License](https://img.shields.io/github/license/neoapps-dev/buildit.svg?style=flat-square)](https://github.com/neoapps-dev/buildit/blob/master/LICENSE) ![Rust](https://img.shields.io/badge/Rust-000000?logo=Rust\u0026logoColor=white) [![Linux](https://img.shields.io/badge/GNU/Linux-FCC624?logo=linux\u0026logoColor=black)](#) [![Windows](https://custom-icon-badges.demolab.com/badge/Windows-0078D6?logo=windows11\u0026logoColor=white)](#) [![macOS](https://img.shields.io/badge/macOS-000000?logo=apple\u0026logoColor=F0F0F0)](#)\n  [![BSD](https://img.shields.io/badge/BSD-000000?logo=freebsd\u0026logoColor=F0F0F0)](#)\n\u003c/div\u003e\n\nBuildIt is a simple and universal solution for automating build processes across multiple platforms, including Windows, GNU/Linux, Unix, and macOS. It reads a `BuildFile` that defines functions for each platform, and then executes the corresponding commands in a platform-specific manner.\n\n## Features\n\n- **Cross-Platform Support**: Supports Windows, GNU/Linux, macOS and any Unix-like/based OS that Rust supports.\n- **Customizable Build Functions**: Allows users to define platform-specific commands in a `BuildFile`.\n- **Configurations**: Uses a simple format to change specific things in the building process.\n\n## Prerequisites\n\n- **Rust**: The Rust programming language is required to build the application.\n- **Supported OS**: Windows, GNU/Linux, macOS, or any Unix-like/based OS.\n\n## Installation\n\nTo install BuildIt on your system:\n\n- AUR (for Arch GNU/Linux):\n    ```bash\n    yay -S buildit-git\n    ```\n\n## Manual Installation\n\nFollow these steps to get BuildIt up and running on your system:\n\n1. **Clone the repository**:\n\n   ```bash\n   git clone https://github.com/neoapps-dev/buildit.git\n   ```\n\n2. **Navigate into the project directory**:\n\n   ```bash\n   cd buildit\n   ```\n\n3. **Build the project using Cargo**:\n\n   ```bash\n   cargo build --release\n   ```\n\n4. **Locate the executable** in the `target/release` directory after the build is complete.\n\n5. **Add to PATH**: Add the `target/release/buildit` or `target\\release\\buildit.exe` if you're on Windows to your PATH.\n\n## Usage\n\nOnce built and added to PATH, you can use BuildIt to automate build tasks on different platforms by specifying a function name.\n\n### Command Syntax\n\n```bash\nbuildit \u003cFunctionName\u003e\n```\n\n### Example\n\nTo execute a `build` function defined in your `BuildFile`, run:\n\n```bash\nbuildit build\n```\n\n## `BuildFile` Format\n\nThe `BuildFile` is where platform-specific functions are defined. It uses a simple format to specify commands to be executed on different platforms.\n\n### Example `BuildFile`\n\n```BuildFile\n\n# An Optional Config Function\nconfig:buildit {\n# Turns off using PowerShell on Windows. default: `false`\nusePowershellOnWindows: false\n# Turns off using PowerShell 7 instead of the default PowerShell 5 on Windows. default: `false`\nusePowershell7: false\n}\n\n# Windows Script with a Batch Script\nbuild:windows {\n    @echo off\n    echo \"Building project on Windows\"\n    cargo build --release\n}\n\n# GNU/Linux Script with Bash\nbuild:lignux {\n    #!/bin/bash\n    echo \"Building project on GNU/Linux\"\n    cargo build --release\n}\n\n# macOS Script with zsh\nbuild:macos {\n    #!/bin/zsh\n    echo \"Building project on macOS\"\n    cargo build --release\n}\n\n# Unix/BSD Script with sh\nbuild:unix {\n    #!/bin/sh\n    echo \"Hello from Unix!\"\n}\n```\n\n### Format Explanation\n\n- The first part (`build:windows {`) specifies the function name (`build`) and the platform (`windows`).\n- The commands inside the curly braces are the steps that will be executed on the specified platform.\n- Each platform-specific section can include its own commands, such as `cargo build`, `gcc`, or any other shell command.\n\n## How It Works\n\n1. **Platform Detection**: BuildIt detects the current platform (Windows, GNU/Linux, Unix, or macOS).\n2. **Function Lookup**: It looks for a function in the `BuildFile` that matches the specified function name.\n3. **Command Execution**: The corresponding commands for the detected platform are extracted and executed in a temporary script (either `.bat` for Windows or `.sh` for Unix-like systems).\n4. **Error Handling**: If a function or platform-specific command is missing, BuildIt will output an error message and terminate the process.\n\n## Error Handling\n\nIf there are errors during command execution, BuildIt will display:\n\n- An error message with the failed command.\n- The specific error status for the command execution.\n\n## Known Issues\n\n- [ ] [#1](https://github.com/neoapps-dev/buildit/issues/1)\n\n## License\n\nThis project is licensed under the [GNU General Public License v3.0](LICENSE) License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneoapps-dev%2Fbuildit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fneoapps-dev%2Fbuildit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneoapps-dev%2Fbuildit/lists"}