From d51d222bdc4865382a7075876952f99458884a77 Mon Sep 17 00:00:00 2001 From: Gennadi McKelvey Date: Wed, 10 Jul 2024 12:01:39 +0200 Subject: [PATCH 1/2] add workflow --- .../template/.github/workflows/build-docs.yml | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 build/template/.github/workflows/build-docs.yml diff --git a/build/template/.github/workflows/build-docs.yml b/build/template/.github/workflows/build-docs.yml new file mode 100644 index 00000000..6ae5b8ab --- /dev/null +++ b/build/template/.github/workflows/build-docs.yml @@ -0,0 +1,21 @@ +name: Build and deploy documentation +on: + release: + types: [published] + workflow_dispatch: ~ + +jobs: + build-documentation: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Setup Python + uses: actions/setup-python@v2 + with: + python-version: '3.x' + architecture: 'x64' + - name: Install dependencies + run: python -m pip install --upgrade pip mkdocs mkdocs-material + - name: Deploy documentation + run: mkdocs gh-deploy --force From b535012b439ff653e8dbb3f1a872f0a5eaa356d7 Mon Sep 17 00:00:00 2001 From: Gennadi McKelvey Date: Wed, 10 Jul 2024 12:02:11 +0200 Subject: [PATCH 2/2] update index.md remove shim suggestion --- build-deptrac.sh | 6 ++++-- docs/index.md | 16 ++++------------ 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/build-deptrac.sh b/build-deptrac.sh index e37d0073..ab4c24b0 100644 --- a/build-deptrac.sh +++ b/build-deptrac.sh @@ -33,10 +33,12 @@ info "Dump Composer Autoloader" $PHP /usr/bin/composer dump-autoload --working-dir $BUILD_TMP -a --no-dev info "Copy package templates" -cp -R $BUILD_DIR/template/* *.md mkdocs.yml docs -t $BUILD_TMP +cp -r $BUILD_DIR/template/* *.md mkdocs.yml docs -t $BUILD_TMP +cp -r $BUILD_DIR/template/.* -t $BUILD_TMP info "Copy build into deptrac distrubtion repository" -cp -a $BUILD_TMP/. $DEPTRAC_DIR +cp -r $BUILD_TMP/* $DEPTRAC_DIR +cp -rv $BUILD_TMP/.* $DEPTRAC_DIR # info "Git commit changes" # echo "Update $(date)" > git_commit_message.txt diff --git a/docs/index.md b/docs/index.md index 33ad0d0e..d3a6b7a2 100644 --- a/docs/index.md +++ b/docs/index.md @@ -23,7 +23,7 @@ You can analyse projects that require an older PHP version as long as ## Installation -You can install Deptrac via Composer. We recommend using the [deptrac-shim](https://github.com/qossmic/deptrac-shim) package for this. +You can install Deptrac via Composer. We recommend using the [deptrac](https://github.com/qossmic/deptrac) package for this. Alternatively, you can also use [PHIVE](#phive) or download the [PHAR](#phar) attached to each release on GitHub. This will ensure that Deptrac and its dependencies are @@ -31,16 +31,8 @@ bundled together and will not interfere with any of your project's dependencies. ### Composer -We strongly advise against using the deptrac package directly as a composer dependency. -We update dependencies regularly, which might cause disruptions in your project. -Instead, please use the dedicated distribution repository . - -When you install Deptrac using the qossmic/deptrac-shim package, you will get -the benefit of using the phar installation, but you can use it like any other -composer dependency, i.e. you run Deptrac like this: - ```console -$ composer require --dev qossmic/deptrac-shim +$ composer require --dev qossmic/deptrac vendor/bin/deptrac analyse ``` @@ -61,7 +53,7 @@ Feel free to add Deptrac to your PATH (i.e. `/usr/local/bin/deptrac`) to make it globally available. ```console -$ curl -LS https://github.com/qossmic/deptrac/releases/download/1.0.2/deptrac.phar -o deptrac.phar +$ curl -LS https://github.com/qossmic/deptrac/releases/download/2.0.1/deptrac.phar -o deptrac.phar # optional $ sudo chmod +x deptrac.phar @@ -75,7 +67,7 @@ You can install Deptrac with [Phive](https://phar.io/#Install) `phive install -g qossmic/deptrac` and accept the key with fingerprint -`41DD E075 4745 9FAE CFA1 7813 B8F6 4013 4AB1 782E`. +`57CB 556F 242F C8D4 FD48 3C2C 4743 6587 D82C 4A39`. To upgrade Deptrac use the following command: