Skip to content

Commit

Permalink
Added README.md and CONTRIBUTING.md
Browse files Browse the repository at this point in the history
  • Loading branch information
xy2z committed Feb 10, 2024
1 parent e7361e7 commit 1347424
Show file tree
Hide file tree
Showing 2 changed files with 88 additions and 0 deletions.
23 changes: 23 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Contributing to Capro

Pull Requests are welcome! Remember development is done in the `dev` branch, and only phar releases is merged to `master`.

- If you want to work on a completely new feature please make an issue beforehand to discuss if it fits the projects scope.
- Use `php-cs-fixer` to follow the coding standard. This can be called automatically in modern editors on file save.
- Call `vendor\bin\phpstan` to check for errors.
- Make sure it works with all supported PHP versions (see "Requirements" in the README, or composer.json).
- When you test the code you should run "php capro <command>" to make sure you are running the correct script.

If you have any questions or notes about contributing, please ask in [Discussions](https://github.com/xy2z/capro/discussions)


## Build and Release
1. Check `box validate` command to validate the box.json.dist file. (should be part of "build.sh" script, fails if not valid)
1. Make sure the version is bumped in `src/capro_bootstrap.php`
1. Run `composer build` to build the phar file in the `build` dir.
1. Test the `build/capro.phar` file.
1. Run `composer validate` to check the `build/composer.json` file.
1. Overwrite the `build/capro.phar` file in the master branch, commit and push
1. Make a new release on GitHub (make sure the version matches the one in `src/capro_bootstrap.php`)

To get back the development composer packages (phpstan, etc.) run `composer install` again.
65 changes: 65 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
<div align="center">

![capro logo](./capro-logo.png)

Capro is a static-site generator for PHP 8+

---

[Quick Setup](#quick-setup) | [Documentation](https://capro.xy2z.io) | [Community](https://github.com/xy2z/capro/discussions) | [Sponsor](https://github.com/sponsors/xy2z)

<p align="center">
<a href="https://github.com/xy2z/capro/releases"><img src="https://img.shields.io/github/v/release/xy2z/capro?style=flat-square&include_prereleases&sort=semver"></a>
<a href="https://github.com/xy2z/capro/blob/master/LICENSE"><img src="https://img.shields.io/github/license/xy2z/capro?style=flat-square&color=blue"></a>
<a href="https://github.com/xy2z/capro/graphs/contributors"><img src="https://img.shields.io/github/contributors/xy2z/capro?style=flat-square"></a>
<a href="https://github.com/xy2z/capro/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22"><img src="https://img.shields.io/github/issues/xy2z/capro/help%20wanted?label=help%20wanted%20issues&style=flat-square&color=f26222"></a>
<a href="https://github.com/xy2z/capro/milestone/1"><img src="https://img.shields.io/github/milestones/progress-percent/xy2z/capro/1?label=alpha%20completion&style=flat-square"></a>
</p>

---

</div>


## ⚠ Notice

Capro is currently in [alpha](https://github.com/xy2z/capro/issues/5), please report bugs via [GitHub Issues](https://github.com/xy2z/capro/issues)


## About

A PHP static-site generator, using Blade template engine.

Capro is currently in alpha, and is not thoroughly tested for production. Breaking changes might occur during the alpha phase.


## Sponsors

Currently none. Sponsor here: https://github.com/sponsors/xy2z


## Requirements
- PHP 8.0+
- [Composer](https://getcomposer.org/)


## Quick Setup
First install the capro global package
```bash
composer global require xy2z/capro:@alpha
```

Now, you can create new sites using:
```bash
capro new demo
cd demo/public
php -S localhost:82
```
Head over to http://localhost:82 to see your new static Capro site.

Learn more in the **[full documentation site](https://capro.xy2z.io).** (which was build in capro)


## Contributing

Pull Requests are welcome! Remember to send PR's to the `dev` branch - see more in the [Contributing Guide](CONTRIBUTING.md).

0 comments on commit 1347424

Please sign in to comment.