Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

config: update repo config files and documents #112

Open
wants to merge 15 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false

[*.{yml,yaml}]
indent_size = 2
14 changes: 14 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
* text=auto eol=lf

.circleci/ export-ignore
.github/ export-ignore
.vscode/ export-ignore
tests/ export-ignore

.editorconfig export-ignore
.gitattributes export-ignore
.gitignore export-ignore
CODE-OF-CONDUCT.md export-ignore
CONTRIBUTING.md export-ignore
phpunit.xml export-ignore
pint.json export-ignore
33 changes: 13 additions & 20 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Thank you for investing your time in contributing to this project! Please take a moment to review this document in order to streamline the contribution process for you and any reviewers involved.

Read our [Code of Conduct](./CODE_OF_CONDUCT.md) to keep our community approachable and respectable.
Read our [Code of Conduct](CODE-OF-CONDUCT.md) to keep our community approachable and respectable.

In this guide you will get an overview of the contribution workflow from opening an issue, creating a PR, reviewing, and merging the PR.

Expand Down Expand Up @@ -56,11 +56,9 @@ Commits should be in the format `<type>(<scope>): <description>`. This allows ou

### Example workflow

Follow this process if you'd like your work considered for inclusion in the
project:
Follow this process if you'd like your work considered for inclusion in the project:

1. [Fork](http://help.github.com/fork-a-repo/) the project, clone your fork,
and configure the remotes:
1. [Fork](http://help.github.com/fork-a-repo/) the project, clone your fork, and configure the remotes:

```bash
# Clone your fork of the repo into the current directory
Expand All @@ -78,16 +76,13 @@ project:
git pull upstream <dev-branch>
```

3. Create a new topic branch (off the main project development branch) to
contain your feature, change, or fix:
3. Create a new topic branch (off the main project development branch) to contain your feature, change, or fix:

```bash
git checkout -b <topic-branch-name>
```

4. Commit your changes in logical chunks. Use Git's
[interactive rebase](https://help.github.com/articles/interactive-rebase)
feature to tidy up your commits before making them public.
4. Commit your changes in logical chunks. Use Git's [interactive rebase](https://help.github.com/articles/interactive-rebase) feature to tidy up your commits before making them public.

5. Locally merge (or rebase) the upstream development branch into your topic branch:

Expand All @@ -101,24 +96,22 @@ project:
git push origin <topic-branch-name>
```

7. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/)
with a clear title and description.
7. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/) with a clear title and description.

**IMPORTANT**: By submitting a patch, you agree to allow the project owner to
license your work under the same license as that used by the project.
**IMPORTANT**: By submitting a patch, you agree to allow the project owner to license your work under the same license as that used by the project.

# Pre-requisites
## Pre-requisites

1. Check php is installed globally
2. Install composer locally according to instructions here: https://getcomposer.org/download/

# Install deps
## Install deps

Run `php composer.phar i` to install deps
Run `php composer.phar install` to install deps

# Development
## Development

Commands:

- Run unit tests: `./vendor/bin/phpunit`
- Update dependencies: `php composer.phar u`
- Run unit tests: `php composer.phar run test`
- Update dependencies: `php composer.phar update`
64 changes: 39 additions & 25 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,41 @@
{
"name": "imgix/imgix-php",
"description": "A PHP client library for generating URLs with imgix.",
"type": "library",
"version": "4.1.0",
"license": "BSD-2-Clause",
"keywords": [
"imgix"
],
"require": {
"php": "^8.0"
},
"require-dev": {
"laravel/pint": "^1.4",
"phpunit/phpunit": "^9.5.10"
},
"autoload": {
"psr-4": {
"Imgix\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Imgix\\Tests\\": "tests/"
}
}
"name": "imgix/imgix-php",
"description": "A PHP client library for generating URLs with imgix.",
"type": "library",
"keywords": [
"imgix"
],
"license": "BSD-2-Clause",
"homepage": "https://docs.imgix.com",
"support": {
"issues": "https://github.com/imgix/imgix-php/issues",
"source": "https://github.com/imgix/imgix-php"
},
"require": {
"php": "^8.0"
},
"require-dev": {
"laravel/pint": "^1.4",
"phpunit/phpunit": "^9.5.10"
},
"autoload": {
"psr-4": {
"Imgix\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Imgix\\Tests\\": "tests/"
}
},
"scripts": {
"format": "vendor/bin/pint",
"test": "vendor/bin/phpunit",
"test-coverage": "@test --coverage-text"
},
"config": {
"sort-packages": true
},
"minimum-stability": "dev",
"prefer-stable": true
}
30 changes: 15 additions & 15 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pint.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"preset": "psr12"
"preset": "laravel"
}