{"id":22922475,"url":"https://github.com/kamaranl/bunsh","last_synced_at":"2026-05-01T13:33:08.981Z","repository":{"id":220613940,"uuid":"743977500","full_name":"KamaranL/bunsh","owner":"KamaranL","description":"Bundler for shell scripts","archived":false,"fork":false,"pushed_at":"2024-02-13T17:39:39.000Z","size":53,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-01T14:42:47.196Z","etag":null,"topics":["bash","bundler","compiler","executable","library","module","package","shell","shell-script"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/KamaranL.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","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-01-16T11:40:31.000Z","updated_at":"2024-02-03T12:52:02.000Z","dependencies_parsed_at":"2025-04-01T14:46:43.609Z","dependency_job_id":null,"html_url":"https://github.com/KamaranL/bunsh","commit_stats":null,"previous_names":["kamaranl/bunsh"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/KamaranL/bunsh","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KamaranL%2Fbunsh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KamaranL%2Fbunsh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KamaranL%2Fbunsh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KamaranL%2Fbunsh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KamaranL","download_url":"https://codeload.github.com/KamaranL/bunsh/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KamaranL%2Fbunsh/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32499681,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["bash","bundler","compiler","executable","library","module","package","shell","shell-script"],"created_at":"2024-12-14T08:10:51.451Z","updated_at":"2026-05-01T13:33:08.956Z","avatar_url":"https://github.com/KamaranL.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"```bash\n    __                     __\n   / /_  __  ______  _____/ /_\n  / __ \\/ / / / __ \\/ ___/ __ \\\n / /_/ / /_/ / / / (__  ) / / /\n/_.___/\\__,_/_/ /_/____/_/ /_/\n```\n\n\u003e bundle your shell scripts into a single executable script or library\n\n[![latest release](https://badgen.net/github/release/KamaranL/bunsh?icon=github\u0026cache=3600)](https://github.com/KamaranL/bunsh/releases/latest)\n\n- [Configuration](#configuration)\n- [Installation and Usage](#installation-and-usage)\n  - [Dependencies](#dependencies)\n  - [Install](#install)\n    - [Local](#local)\n    - [GitHub Actions](#github-actions)\n  - [Usage](#usage)\n    - [Decorators](#decorators)\n- [Examples](#examples)\n- [Validity](#validity)\n\n## Configuration\n\nbunsh can be configured via command line options, config file, or a combination of both. If no config file or args are provided, bunsh will use hardcoded defaults. Below is a table showing what configuration options are available, and their defaults.\n\n| Config File Key  | Description                                   | Command Line Equivalent        | Default Value           |\n| ---------------- | --------------------------------------------- | ------------------------------ | ----------------------- |\n| b.src            | source directory                              | -s \\| --source                 | ./src                   |\n| b.out            | output directory                              | -o \\| --out                    | ./out                   |\n| b.name           | bundled file name                             | -n \\| --name                   | bundled-\\\u003cshort_sha256\u003e |\n| s.version        | bundled file version                          | --opt s.version=\\\u003csemver\u003e      | 0.1.0                   |\n| s.libonly        | generate library only                         | --opt s.libonly=\\\u003cbool\u003e        | false                   |\n| s.err_noargs     | make bundle error when `$# == 0` on commands  | --opt s.err_noargs=\\\u003cbool\u003e     | false                   |\n| s.err_illegalopt | make bundle error on unknown args on commands | --opt s.err_illegalopt=\\\u003cbool\u003e | false                   |\n\n## Installation and Usage\n\n### Dependencies\n\n[^1]\n\n- bash `\u003e=4`\n- cat\n- date\n- dirname\n- grep\n- mkdir\n- realpath\n- sed\n- sha256sum\n\n### Install\n\n#### Local\n\nCopy + paste the following in your terminal to download, unpack, and link the [latest release](https://github.com/KamaranL/bunsh/releases/latest):\n\n  ```bash\n  NAME=bunsh VER=\"$(curl -sL \"https://raw.githubusercontent.com/KamaranL/$NAME/main/VERSION.txt\")\" \u0026\u0026 {\n     DIR=\"/usr/local/etc/$NAME.d\"\n     [ ! -d \"$DIR\" ] \u0026\u0026 mkdir -p \"$DIR\"\n     curl -L \"https://github.com/KamaranL/$NAME/releases/download/v$VER/$NAME-v$VER.tgz\" | tar -vxz -C \"$DIR\"\n     chmod +x \"$DIR/$NAME\"\n     [ ! -f \"/usr/local/bin/$NAME\" ] \u0026\u0026 ln -s \"$DIR/$NAME\" \"/usr/local/bin/$NAME\"\n     \"$NAME\" -v \u0026\u0026 \"$NAME\" -h\n  }\n  ```\n\n#### GitHub Actions\n\n  ```yml\n  #...\n  jobs:\n    ci:\n      runs-on: ubuntu-latest\n      steps:\n        - uses: KamaranL/bunsh@main\n  #...\n  ```\n\n### Usage\n\n```text\nusage: bunsh [options]\noptions:\n  -c,--config \u003cfile\u003e  specify a config file to read from\n  -s,--src \u003cpath\u003e     specify a source directory to read from\n  -o,--out \u003cpath\u003e     specify an output directory to place the bundle\n  -n,--name \u003cval\u003e     specify a name for the bundle\n  --opt \u003ckey\u003e=\u003cval\u003e   specify additional config option\n  -d,--dry-run        do not write bundle to file, print to console\n  -q,--quiet          suppress all output to console\n  -x,-xx,--verbose    print verbose output to the console\n  -h,--help           print this help message\n  -v,--version        print version\n```\n\n#### Decorators\n\nbunsh uses pre-defined decorators[^2] to generate the help messages for each function:\n\n| Name     | Purpose                                                                                                                                                 |\n| -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `@desc`  | provides a brief description of the function when viewed from a parent help menu - each `@desc` line will be read altogether (as one whole description) |\n| `@param` | defines the named parameters, or options, that are available to the function - each `@param` line will be read individually                             |\n| `@arg`   | defines the positional parameters, or args, that are available to the function - each `@arg` line will be read individually                             |\n\n## Examples\n\nSee [examples](/examples/README.md#examples)\n\n## Validity\n\nEveryone has doubts, see [my wiki page](https://github.com/KamaranL/KamaranL/wiki#validation) on validation if you're like everyone :smile:\n\n[^1]: Most, if not all, of the listed dependencies come pre-installed on MacOS and a good number of Linux distributions- provided for transparency.\n\n[^2]: Take a look at [this file](https://github.com/KamaranL/bunsh/blob/main/examples/src/public/greet) to see how decorators can be used.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkamaranl%2Fbunsh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkamaranl%2Fbunsh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkamaranl%2Fbunsh/lists"}