{"id":21466421,"url":"https://github.com/csaintos/premake-init","last_synced_at":"2025-10-15T21:18:25.827Z","repository":{"id":240309081,"uuid":"673521263","full_name":"CSaintos/Premake-Init","owner":"CSaintos","description":"My personal Premake build setup snippet for C++ projects.","archived":false,"fork":false,"pushed_at":"2024-05-21T01:38:29.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-23T15:29:16.203Z","etag":null,"topics":["premake5"],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CSaintos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2023-08-01T20:23:18.000Z","updated_at":"2024-05-21T01:38:32.000Z","dependencies_parsed_at":"2024-05-17T23:29:12.167Z","dependency_job_id":"7edf0a64-6bb2-4bec-9742-e8fb748514e8","html_url":"https://github.com/CSaintos/Premake-Init","commit_stats":null,"previous_names":["csaintos/premake-init"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CSaintos%2FPremake-Init","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CSaintos%2FPremake-Init/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CSaintos%2FPremake-Init/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CSaintos%2FPremake-Init/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CSaintos","download_url":"https://codeload.github.com/CSaintos/Premake-Init/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243982136,"owners_count":20378606,"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":["premake5"],"created_at":"2024-11-23T08:14:06.467Z","updated_at":"2025-10-15T21:18:20.806Z","avatar_url":"https://github.com/CSaintos.png","language":"Lua","readme":"# Premake-Init\n\n## What is it?\nPremake-Init is my personal [Premake](https://github.com/premake/premake-core) build setup snippet for building C++ projects using premake and GNU make.\n\nUnlike other premake build snippets that may be commonly found online, Premake-Init uses only Lua and doesn't require any other language scripts such as Batch, Powershell, Python, Bash, etc... to automate Premake.\n\n## Default Project Structure\nBy default or convention (personal), the typical project structure is shown as follows:\n```\nroot/\n| premake/\n| | script/\n| | | cmd/\n| | | | build.lua\n| | | | clean.lua\n| | | workspace/\n| | | | project.lua\n| | | | workspace.lua\n| | | global.lua\n| | | libs.lua\n| | LICENSE.txt\n| | premake5\n| | premake5.lua\n| | .gitignore\n| workspace/\n| | inc/\n| | src/\n```\n\n## How to Install?\n\n- Step 1. [Download Premake](https://premake.github.io/download/)\n- Step 2. Clone PremakeInit (this repo) somewhere on your machine where you keep code snippets or the sort.\n- Step 3. Copy the Premake binaries you downloaded into `Premake-Init/premake`.\n- Step 4 (Optional). Create a terminal command that copies your local repository **contents** (not the repo itself) into your current working directory. \n  - Make sure to delete the `README.md` in your repository to avoid `README.md` collision.\n  - Make sure your copy command doesn't copy the `.git` directory. (You can also just delete the `.git` directory).\n  - You are free to delete the `.gitignore` and modify the `premake/.gitignore`.\n\n## How to Use?\n\nWhen you want to create a new C++ project and build it using Make, make a copy of your Premake-Init local repo **contents** (without `.git/`, `.gitignore/`, and `README.md`) into your new project directory.\n- If you followed [step 4](#how-to-install), then you can simply call the terminal command to do this for you.\nIf you haven't done so already, create a C++ project workspace with your source code and headers in your project folder following the [convention](#default-project-structure).\nNext, configure the Premake build scripts in the premake directory to build your workspace. For more info on Premake and writing build scripts see their [documentation](https://premake.github.io/docs/).\nFinally, open a terminal in the premake directory and execute your premake commands for building your C++ project.\n- `./premake5 gmake2`\n- `./premake5 build --{workspace}={project}`\n- For a list of premake commands:\n  - `./premake5 --help`\n\n[//]: # (## Extras)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcsaintos%2Fpremake-init","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcsaintos%2Fpremake-init","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcsaintos%2Fpremake-init/lists"}