{"id":19746962,"url":"https://github.com/jordanbrauer/phelpers","last_synced_at":"2025-04-30T08:32:02.838Z","repository":{"id":55946308,"uuid":"194584210","full_name":"jordanbrauer/phelpers","owner":"jordanbrauer","description":"Collection of random helper QoL functions for PHP.","archived":false,"fork":false,"pushed_at":"2021-02-10T00:45:23.000Z","size":257,"stargazers_count":3,"open_issues_count":3,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-05-28T14:09:32.116Z","etag":null,"topics":["dependency-less","functional","helpers","library","php7"],"latest_commit_sha":null,"homepage":"","language":"PHP","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/jordanbrauer.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}},"created_at":"2019-07-01T02:10:02.000Z","updated_at":"2024-05-28T14:09:32.117Z","dependencies_parsed_at":"2022-08-15T10:01:07.290Z","dependency_job_id":null,"html_url":"https://github.com/jordanbrauer/phelpers","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jordanbrauer%2Fphelpers","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jordanbrauer%2Fphelpers/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jordanbrauer%2Fphelpers/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jordanbrauer%2Fphelpers/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jordanbrauer","download_url":"https://codeload.github.com/jordanbrauer/phelpers/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224202777,"owners_count":17272807,"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":["dependency-less","functional","helpers","library","php7"],"created_at":"2024-11-12T02:16:20.995Z","updated_at":"2024-11-12T02:16:21.663Z","avatar_url":"https://github.com/jordanbrauer.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PHelPers\n\n[![Latest Stable Version](https://poser.pugx.org/jordanbrauer/phelpers/version?format=flat-square)](https://packagist.org/packages/jordanbrauer/phelpers)\n[![Latest Unstable Version](https://poser.pugx.org/jordanbrauer/phelpers/v/unstable?format=flat-square)](//packagist.org/packages/jordanbrauer/phelpers)\n[![Test Status](https://img.shields.io/github/workflow/status/jordanbrauer/phelpers/CI?label=tests\u0026style=flat-square)](https://github.com/jordanbrauer/phelpers/actions?query=workflow%3ACI)\n\n[![Maintenance](https://img.shields.io/maintenance/yes/2021.svg?style=flat-square)](https://github.com/jordanbrauer/phelpers)\n[![Packagist](https://img.shields.io/packagist/dt/jordanbrauer/phelpers.svg?style=flat-square)](https://packagist.org/packages/jordanbrauer/phelpers)\n[![PHP from Packagist](https://img.shields.io/packagist/php-v/jordanbrauer/phelpers.svg?style=flat-square)](https://secure.php.net/releases/)\n[![composer.lock available](https://poser.pugx.org/jordanbrauer/phelpers/composerlock?format=flat-square)](https://packagist.org/packages/jordanbrauer/phelpers)\n[![license](https://img.shields.io/github/license/jordanbrauer/phelpers.svg?style=flat-square)](https://github.com/jordanbrauer/phelpers/blob/master/LICENSE)\n\n\u003cbr /\u003e\n\nA collection of random quality of life functions for PHP – a sort of _toolbox_.\n\n## Requirements\n\nThere are not many requirements for this library; infact, the only true requirement is PHP, but if you plan to contribute, having GNU Make installed will make for nicer dev experience than without.\n\n| Requirement      | Version |\n|:-----------------|:-------:|\n| PHP              | `^7.2`  |\n| Make (dev only)  | `^3.81` |\n\n## Installation\n\nNothing much to do but require the library in your own project's composer dependencies!\n\n```bash\n$ composer require jordanbrauer/phelpers\n```\n\nOnce you have the library installed, head over to the list of [**available functions**](#Available-Functions) to shop around.\n\n## Development\n\n1. Start by cloning the project to your own machine.\n1. Move yourself into the newly cloned repository directory.\n1. Run make to install dev dependencies.\n\n```bash\n$ git clone https://github.com/jordanbrauer/phelpers.git \\\n    \u0026\u0026 cd ./phelpers \\\n    \u0026\u0026 make vendor \\\n    \u0026\u0026 make;\n```\n\n### Usage \n\nAs mentioned in the _Requirements_ section of this document, having GNU Make installed on your system will make for nice development experience while contributing. To get started, run Make without any targets or arguments:\n\n```bash\n$ make\n```\n\nAnd you will be greeted with the list of targets for this project!\n\n```\nUsage:\n  make [target] [arg=\"val\"...]\n\nTargets:\n  analysis        Run analysis\n  help            Show this help message\n  repl            Start a REPL instance and interact with the library\n  test            Run tests\n  vendor          Install vendor dependencies\n```\n\n### Try Me\n\nIf you're not sure that this library is right for you, can \"try before you buy\". Start by [installing the project for development](#Development), and then simply boot up [the **REPL**](https://github.com/bobthecow/psysh) packaged with the repository!\n\n```bash\n$ make repl\n```\n\nUsing the functions is easy – just make sure that you preface your functions with the projects namespace first.\n\n```php\nλ Phelpers\\is_console() # true\nλ Phelpers\\is_web()     # false\n```\n\n## Available Functions\n\n### Array Functions\n\n* `append`\n* `array_make`\n* `generate`\n* `head`\n* `is_associative`\n* `only`\n* `prepend`\n* `tail`\n* `wrap`\n\n### Number Functions\n\n* `between`\n* `ordinal`\n* `random_float`\n\n### Object Functions\n\n_N/A_\n\n### String Functions\n\n* `append`\n* `camel_case`\n* `class_basename`\n* `kebab_case`\n* `pascal_case`\n* `prepend`\n* `snake_case`\n* `str_random`\n\n### Miscellaneous Functions\n\n* `blank`\n* `retry`\n* `swap`\n* `tap`\n* `transform`\n* `value`\n* `with`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjordanbrauer%2Fphelpers","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjordanbrauer%2Fphelpers","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjordanbrauer%2Fphelpers/lists"}