Skip to content

Commit

Permalink
docs and fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshuaEstes committed Oct 21, 2023
1 parent 5885335 commit 2577047
Show file tree
Hide file tree
Showing 3 changed files with 61 additions and 8 deletions.
11 changes: 7 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PHP_CS_FIXER = tools/php-cs-fixer/vendor/bin/php-cs-fixer
PHPUNIT = tools/phpunit/vendor/bin/phpunit
PSALM = tools/psalm/vendor/bin/psalm
PSALM_BASELINE_FILE = psalm-baseline.xml
BARD = packages/bard/bin/bard
BARD = src/SonsOfPHP/Bard/bin/bard

COVERAGE_DIR = docs/coverage

Expand All @@ -30,10 +30,13 @@ upgrade: tools-upgrade

composer-install: composer.json # Install Dependencies via Composer
XDEBUG_MODE=off $(COMPOSER) install --no-interaction --prefer-dist --optimize-autoloader
XDEBUG_MODE=off $(COMPOSER) install --working-dir=packages/bard --no-interaction --prefer-dist --optimize-autoloader
XDEBUG_MODE=off $(COMPOSER) install --working-dir=src/SonsOfPHP/Bard --no-interaction --prefer-dist --optimize-autoloader

purge: # Purge vendor and lock files
rm -rf vendor/ packages/*/vendor/ packages/*/composer.lock
rm -rf vendor/ src/SonsOfPHP/Bard/vendor/ src/SonsOfPHP/Bard/composer.lock
rm -rf vendor/ src/SonsOfPHP/Bridge/*/vendor/ src/SonsOfPHP/Bridge/*/composer.lock
rm -rf vendor/ src/SonsOfPHP/Bundle/*/vendor/ src/SonsOfPHP/Bundle/*/composer.lock
rm -rf vendor/ src/SonsOfPHP/Component/*/vendor/ src/SonsOfPHP/Component/*/composer.lock

test: ## Run PHPUnit Tests
XDEBUG_MODE=off $(PHP) -dxdebug.mode=off $(PHPUNIT) --order-by=defects
Expand All @@ -49,7 +52,7 @@ phpunit-upgrade:
lint: lint-php ## Lint files

lint-php: # lint php files
@! find packages/ -name "*.php" -not -path "packages/**/vendor/*" | xargs -I{} $(PHP) -l '{}' | grep -v "No syntax errors detected"
@! find src/ -name "*.php" -not -path "src/**/vendor/*" | xargs -I{} $(PHP) -l '{}' | grep -v "No syntax errors detected"

coverage: ## Build Code Coverage Report
XDEBUG_MODE=coverage $(PHP) -dxdebug.mode=coverage $(PHPUNIT) --coverage-html $(COVERAGE_DIR)
Expand Down
38 changes: 38 additions & 0 deletions docs/bard/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
title: Bard
---

# Bard

Bard is used to manage monorepos.

## Usage

Initialize a new bard.json file

```shell
bard init
```

Add repositories

```shell
bard add path/to/code repoUrl
```

Push changes to read-only repos

```shell
bard push
```

Create a release

```shell
bard release major
bard release minor
bard release patch
```

Bard will track the versions so you can just use the keywords: major, minor,
patch.
20 changes: 16 additions & 4 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,31 @@

<testsuites>
<testsuite name="all">
<directory>packages/*/Tests</directory>
<!--<directory>src/SonsOfPHP/Bard/src/Tests</directory>-->
<directory>src/SonsOfPHP/Bridge/Doctrine/*/Tests</directory>
<directory>src/SonsOfPHP/Bridge/Symfony/*/Tests</directory>
<directory>src/SonsOfPHP/Bundle/*/Tests</directory>
<directory>src/SonsOfPHP/Component/*/Tests</directory>
</testsuite>
</testsuites>

<coverage/>

<source>
<include>
<directory>packages/*</directory>
<directory>src/*</directory>
</include>
<exclude>
<directory>packages/*/Tests</directory>
<directory>packages/*/vendor</directory>
<!--<directory>src/SonsOfPHP/Bard/src/Tests</directory>-->
<directory>src/SonsOfPHP/Bard/vendor</directory>
<directory>src/SonsOfPHP/Bridge/Doctrine/*/Tests</directory>
<directory>src/SonsOfPHP/Bridge/Doctrine/*/vendor</directory>
<directory>src/SonsOfPHP/Bridge/Symfony/*/Tests</directory>
<directory>src/SonsOfPHP/Bridge/Symfony/*/vendor</directory>
<directory>src/SonsOfPHP/Bundle/*/Tests</directory>
<directory>src/SonsOfPHP/Bundle/*/vendor</directory>
<directory>src/SonsOfPHP/Component/*/Tests</directory>
<directory>src/SonsOfPHP/Component/*/vendor</directory>
</exclude>
</source>

Expand Down

0 comments on commit 2577047

Please sign in to comment.