Skip to content

Commit

Permalink
Docs folder standardization and other fixes (#36)
Browse files Browse the repository at this point in the history
  • Loading branch information
luizcmarin committed Apr 23, 2024
1 parent 1de33b3 commit 718141d
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 37 deletions.
8 changes: 4 additions & 4 deletions LICENSE.md
@@ -1,17 +1,17 @@
Copyright © 2008 by Yii Software (https://www.yiiframework.com/)
Copyright © 2008 by Yii Software (<https://www.yiiframework.com/>)
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:

* Redistributions of source code must retain the above copyright
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions, and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
* Neither the name of Yii Software nor the names of its
* Neither the name of Yii Software nor the names of its
contributors may be used to endorse or promote products derived
from this software without specific prior written permission.

Expand Down
36 changes: 9 additions & 27 deletions README.md
Expand Up @@ -30,7 +30,7 @@ centralized thick application (e.g. one server, no dedicated load balancers, etc

The package could be installed with composer:

```
```shell
composer require yiisoft/cache-apcu --prefer-dist
```

Expand All @@ -39,7 +39,6 @@ composer require yiisoft/cache-apcu --prefer-dist
The package does not contain any additional functionality for interacting with the cache,
except those defined in the [PSR-16](https://www.php-fig.org/psr/psr-16/) interface.


```php
$cache = new \Yiisoft\Cache\Apcu\ApcuCache();
$parameters = ['user_id' => 42];
Expand Down Expand Up @@ -75,37 +74,20 @@ To work with values in a more efficient manner, batch operations should be used:

This package can be used as a cache handler for the [Yii Caching Library](https://github.com/yiisoft/cache).

## Testing

### Unit testing

The package is tested with [PHPUnit](https://phpunit.de/). To run tests:

```shell
./vendor/bin/phpunit
```
## Documentation

### Mutation testing
- [Internals](docs/internals.md)

The package tests are checked with [Infection](https://infection.github.io/) mutation framework. To run it:
## Support

```shell
./vendor/bin/infection
```

### Static analysis

The code is statically analyzed with [Psalm](https://psalm.dev/). To run static analysis:

```shell
./vendor/bin/psalm
```
If you need help or have a question, the [Yii Forum](https://forum.yiiframework.com/c/yii-3-0/63) is a good place for that.
You may also check out other [Yii Community Resources](https://www.yiiframework.com/community).

### Support the project
## Support the project

[![Open Collective](https://img.shields.io/badge/Open%20Collective-sponsor-7eadf1?logo=open%20collective&logoColor=7eadf1&labelColor=555555)](https://opencollective.com/yiisoft)

### Follow updates
## Follow updates

[![Official website](https://img.shields.io/badge/Powered_by-Yii_Framework-green.svg?style=flat)](https://www.yiiframework.com/)
[![Twitter](https://img.shields.io/badge/twitter-follow-1DA1F2?logo=twitter&logoColor=1DA1F2&labelColor=555555?style=flat)](https://twitter.com/yiiframework)
Expand All @@ -115,7 +97,7 @@ The code is statically analyzed with [Psalm](https://psalm.dev/). To run static

## License

The Yii Logging Library - APCu Handler is free software. It is released under the terms of the BSD License.
The Yii Cache Library - APCu Handler is free software. It is released under the terms of the BSD License.
Please see [`LICENSE`](./LICENSE.md) for more information.

Maintained by [Yii Software](https://www.yiiframework.com/).
4 changes: 0 additions & 4 deletions UPGRADE.md

This file was deleted.

2 changes: 1 addition & 1 deletion composer.json
Expand Up @@ -15,7 +15,7 @@
"issues": "https://github.com/yiisoft/cache-apcu/issues?state=open",
"forum": "https://www.yiiframework.com/forum/",
"wiki": "https://www.yiiframework.com/wiki/",
"irc": "irc://irc.freenode.net/yii",
"irc": "ircs://irc.libera.chat:6697/yii",
"chat": "https://t.me/yii3en",
"source": "https://github.com/yiisoft/cache-apcu"
},
Expand Down
35 changes: 35 additions & 0 deletions docs/internals.md
@@ -0,0 +1,35 @@
# Internals

## Unit testing

The package is tested with [PHPUnit](https://phpunit.de/). To run tests:

```shell
./vendor/bin/phpunit
```

## Mutation testing

The package tests are checked with [Infection](https://infection.github.io/) mutation framework with
[Infection Static Analysis Plugin](https://github.com/Roave/infection-static-analysis-plugin). To run it:

```shell
./vendor/bin/roave-infection-static-analysis-plugin
```

## Static analysis

The code is statically analyzed with [Psalm](https://psalm.dev/). To run static analysis:

```shell
./vendor/bin/psalm
```

## Rector

Use [Rector](https://github.com/rectorphp/rector) to make codebase follow some specific rules or
use either newest or any specific version of PHP:

```shell
./vendor/bin/rector
```
2 changes: 1 addition & 1 deletion src/ApcuCache.php
Expand Up @@ -24,7 +24,7 @@
/**
* ApcuCache provides APCu caching in terms of an application component.
*
* To use this application component, the [APCu PHP extension](http://www.php.net/apcu) must be loaded.
* To use this application component, the [APCu PHP extension](https://www.php.net/apcu) must be loaded.
* In order to enable APCu for CLI you should add "apc.enable_cli = 1" to your php.ini.
*
* See {@see \Psr\SimpleCache\CacheInterface} for common cache operations that ApcCache supports.
Expand Down

0 comments on commit 718141d

Please sign in to comment.