Skip to content

Commit

Permalink
feat: auto update ipfs version in installation docs (#1081)
Browse files Browse the repository at this point in the history
  • Loading branch information
laurentsenta authored Mar 25, 2022
1 parent 1aff741 commit 54ebc03
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
9 changes: 9 additions & 0 deletions .github/actions/update-on-new-ipfs-tag/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,15 @@ else
make
http-api-docs > $API_FILE

# update installation docs
cd $ROOT # go back to root of ipfs-docs repo
CURRENT_IPFS_NUMBER=${CURRENT_IPFS_TAG:1}
LATEST_IPFS_NUMBER=${LATEST_IPFS_TAG:1}
while read -r file; do
echo "replacing $CURRENT_IPFS_NUMBER with $LATEST_IPFS_NUMBER in $file"
sed -E -i "s/$CURRENT_IPFS_NUMBER/$LATEST_IPFS_NUMBER/g" $file
done <<< "$(grep "current-ipfs-version" ./docs -R --files-with-matches)"

# update cli docs
cd $ROOT # go back to root of ipfs-docs repo
git clone https://github.com/ipfs/go-ipfs.git
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-on-new-ipfs-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ jobs:
github_token: ${{ secrets.GITHUB_TOKEN }}
source_branch: ${{ steps.update.outputs.updated_branch }}
destination_branch: "main"
pr_title: "Bump CLI and HTTP API reference to go-ipfs ${{ steps.latest_ipfs.outputs.latest_tag }}"
pr_title: "Bump references to go-ipfs ${{ steps.latest_ipfs.outputs.latest_tag }}"
pr_body: "Release Notes: https://github.com/ipfs/go-ipfs/releases/${{ steps.latest_ipfs.outputs.latest_tag }}"
pr_label: "needs/triage,P0"
1 change: 1 addition & 0 deletions docs/install/command-line.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: Command-line
description: Using IPFS through the command-line allows you to do everything that IPFS Desktop can do, but at a more granular level since you can specify which commands to run. Learn how to install it here.
current-ipfs-version: v0.12.0
---

# Command-line
Expand Down

0 comments on commit 54ebc03

Please sign in to comment.