Skip to content

Commit 7a09507

Browse files
authored
chore: fix release and documentation actions (#2030)
1 parent 2fa15d9 commit 7a09507

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

.github/actions/docs/entrypoint.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
#!/bin/sh -l
22

33
apt-get update
4-
apt-get install -y git
4+
apt-get install -y git wget
55
git reset --hard HEAD
66

77
# Create the directories
88
mkdir .docs
99
mkdir .cache
1010

11+
wget https://github.com/jdpedrie/Sami/releases/download/v4.3.0/sami.phar
12+
1113
# Run the docs generation command
12-
php vendor/bin/sami.php update .github/actions/docs/sami.php
14+
php sami.phar update .github/actions/docs/sami.php
15+
chmod -R 0777 .

.github/workflows/asset-release.yml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,9 @@ jobs:
1818
name: Get Tag
1919
run: echo ::set-output name=tag::${GITHUB_REF#refs/*/}
2020

21-
- uses: octokit/[email protected]
22-
id: getLatestRelease
23-
with:
24-
route: GET /repos/:repository/releases/tags/:tag
25-
repository: ${{ github.repository }}
26-
tag: ${{ steps.tagName.outputs.tag }}
21+
- name: Get release
22+
id: get_release
23+
uses: bruceadams/[email protected]
2724
env:
2825
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2926

@@ -60,7 +57,7 @@ jobs:
6057
env:
6158
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
6259
with:
63-
upload_url: ${{ fromJson(steps.getLatestRelease.outputs.data).upload_url }}
60+
upload_url: ${{ steps.get_release.outputs.upload_url }}
6461
asset_path: ./google-api-php-client-${{ steps.tagName.outputs.tag }}-PHP${{ matrix.php }}.zip
6562
asset_name: google-api-php-client-${{ steps.tagName.outputs.tag }}-PHP${{ matrix.php }}.zip
6663
asset_content_type: application/zip

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
with:
2020
timeout_minutes: 10
2121
max_attempts: 3
22-
command: composer config repositories.sami vcs https://${{ secrets.GITHUB_TOKEN }}@github.com/jdpedrie/sami.git && composer require sami/sami:dev-master && git reset --hard HEAD
22+
command: composer install
2323
- name: Generate and Push Documentation
2424
uses: docker://php:7.3-cli
2525
env:

0 commit comments

Comments
 (0)