Skip to content

Commit

Permalink
chore: fix cmd for preview site and style sync
Browse files Browse the repository at this point in the history
  • Loading branch information
ElderJames committed Mar 15, 2021
1 parent 101e4c4 commit 913d62b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
9 changes: 2 additions & 7 deletions .github/workflows/nightly-build.yml
Expand Up @@ -47,9 +47,7 @@ jobs:
id: previoustag
run: |
git fetch --tags
# This suppress an error occurred when the repository is a complete one.
git fetch --prune --unshallow || true
LAST_VERSION=$(git describe --abbrev=0 --tags)
LAST_VERSION=$(git describe --abbrev=0 --tags | sed 's/* //' )
echo "Last Version: ${LAST_VERSION}"
echo "::set-output name=previous_tag::${LAST_VERSION}"
Expand Down Expand Up @@ -88,7 +86,7 @@ jobs:
env:
next_version: ${{ steps.get_next_version.outputs.next_version }}

- name: Push to GitHub package registry
- name: Push to MyGet package registry
run: dotnet nuget push ./publish/*.nupkg --source https://www.myget.org/F/ant-design-blazor/api/v3/index.json --api-key ${{ secrets.MYGET_API_KEY }} --skip-duplicate

- name: Sync to Gitee 馃挄
Expand All @@ -102,9 +100,6 @@ jobs:
- name: Publish Docs 馃帀
run: |
npm install
echo "/* updated `date "+%Y-%m-%d %H:%M:%S"` */" >> ./site/AntDesign.Docs.Wasm/wwwroot/service-worker.published.js
cp -rf scripts/gh-pages/* scripts/gh-pages/.nojekyll scripts/gh-pages/.spa ./site/AntDesign.Docs.Wasm/wwwroot
sed -i s/{version}/$PACKAGE_VERSION/g ./site/AntDesign.Docs.Wasm/wwwroot/index.html
sed -i s/{version}/$PACKAGE_VERSION/g ./site/AntDesign.Docs/Shared/HeaderMenu.razor
dotnet publish ./site/AntDesign.Docs.Wasm -c Release -f net5 -o cargo
env:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/style-sync.yml
Expand Up @@ -22,6 +22,7 @@ jobs:
echo "Last Version of ant-design: ${LAST_VERSION}"
git checkout ${LAST_VERSION}
cd ../ant-design-blazor
git checkout feature
BRANCH_NAME="sync-style/${LAST_VERSION}"
if [ $( git branch -a | egrep "remotes/origin/${BRANCH_NAME}" | wc -l) -gt 0 ]; then
echo "Branch ${BRANCH_NAME} already exists."
Expand All @@ -48,4 +49,4 @@ jobs:
cat>PR<<EOF
chore: sync ant-design v${LAST_VERSION}
EOF
bin/hub pull-request -F PR -b ant-design-blazor:master -h ant-design-blazor:${BRANCH_NAME} -a ElderJames
bin/hub pull-request -F PR -b ant-design-blazor:feature -h ant-design-blazor:${BRANCH_NAME} -a ElderJames

0 comments on commit 913d62b

Please sign in to comment.