Skip to content

Commit

Permalink
Ported boostorg/outcome conversion script to github actions.
Browse files Browse the repository at this point in the history
  • Loading branch information
ned14 committed Nov 17, 2020
1 parent e64a553 commit b970251
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 1 deletion.
64 changes: 64 additions & 0 deletions .github/workflows/make_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,67 @@ jobs:
asset_path: ../outcome-v2-all-sources.tar.xz
asset_name: outcome-v2-all-sources-${{ github.sha }}.tar.xz
asset_content_type: application/gzip

- name: Extract boostorg/outcome ssh keys
id: vars
shell: bash
run: |
if [ -n "$BOOSTORG_OUTCOME_DEPLOY_KEY" ] && [ "${{ steps.waitforstatuschecks.outputs.status }}" = "success" ]; then
mkdir -p ~/.ssh;
printf "%s" "$BOOSTORG_OUTCOME_DEPLOY_KEY" > "~/.ssh/id_boostorg_outcome";
chmod -R og-rwx ~/.ssh;
unset HAS_DEPLOY_KEY;
HAS_DEPLOY_KEY='true';
fi
echo ::set-output name=HAS_DEPLOY_KEY::${HAS_DEPLOY_KEY}
- name: Convert to boostorg/outcome
if: steps.vars.outputs.HAS_DEPLOY_KEY
shell: bash
run: |
pip install --user gitpython
git remote add outcome https://github.com/ned14/outcome
git fetch outcome
git submodule update --init
cd ..
git clone https://github.com/boostorg/outcome boost-outcome
cd boost-outcome
git checkout -b develop origin/develop
git checkout master
git remote add outcome https://github.com/ned14/outcome
git fetch outcome
git checkout -b orig-develop outcome/develop
git checkout -b orig-master outcome/master
git checkout master
cd ..
git clone --depth 1 https://github.com/ned14/quickcpplib.git
python quickcpplib/scripts/boostify_git_repo.py boost-outcome outcome ned14/outcome@
cd boost-outcome
git checkout master
cd doc/src
rm -rf ../html
HUGO_BOOSTDOCDISABLECOMMONHEADING=1 hugo
cd ../html
git add . || true
cd ../..
git commit -a -m "CI regenerates Boost.Outcome docs" || true
git checkout develop
cd doc/src
rm -rf ../html
HUGO_BOOSTDOCDISABLECOMMONHEADING=1 hugo
cd ../html
git add . || true
cd ../..
git commit -a -m "CI regenerates Boost.Outcome docs" || true
git push https://jenkins-nedprod:[email protected]/boostorg/outcome master || true
git push https://jenkins-nedprod:[email protected]/boostorg/outcome develop || true
cd doc
rm -rf html
git clone -b gh-pages --single-branch https://github.com/boostorg/outcome html
cd src
hugo
cd ../html
git add . || true
git commit -a -m "CI regenerates Boost.Outcome docs" || true
git push -f https://jenkins-nedprod:[email protected]/boostorg/outcome gh-pages
cd ../..
File renamed without changes.
2 changes: 1 addition & 1 deletion doc/html
Submodule html updated 456 files

0 comments on commit b970251

Please sign in to comment.